]> granicus.if.org Git - postgresql/blob - configure
Ensure that the result tuple of an EvalPlanQual cycle gets materialized
[postgresql] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.63 for PostgreSQL 8.5devel.
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-2009, 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='8.5devel'
602 PACKAGE_STRING='PostgreSQL 8.5devel'
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 LIBOBJS
671 HAVE_IPV6
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
681 perl_embed_ldflags
682 perl_useshrplib
683 perl_privlibexp
684 perl_archlibexp
685 PERL
686 FLEXFLAGS
687 FLEX
688 BISONFLAGS
689 BISON
690 MKDIR_P
691 AWK
692 LN_S
693 TAR
694 WINDRES
695 DLLWRAP
696 DLLTOOL
697 AR
698 STRIP_SHARED_LIB
699 STRIP_STATIC_LIB
700 STRIP
701 RANLIB
702 ld_R_works
703 with_gnu_ld
704 LD
705 LDFLAGS_SL
706 ELF_SYS
707 EGREP
708 GREP
709 with_zlib
710 with_system_tzdata
711 with_libxslt
712 with_libxml
713 XML2_CONFIG
714 with_ossp_uuid
715 with_openssl
716 with_bonjour
717 with_ldap
718 with_pam
719 krb_srvtab
720 with_krb5
721 with_gssapi
722 with_python
723 with_perl
724 with_tcl
725 enable_thread_safety
726 INCLUDES
727 autodepend
728 TAS
729 GCC
730 CPP
731 SUN_STUDIO_CC
732 OBJEXT
733 EXEEXT
734 ac_ct_CC
735 CPPFLAGS
736 LDFLAGS
737 CFLAGS
738 CC
739 enable_dtrace
740 DTRACEFLAGS
741 DTRACE
742 enable_coverage
743 GENHTML
744 LCOV
745 GCOV
746 enable_profiling
747 enable_debug
748 enable_rpath
749 enable_shared
750 default_port
751 WANTED_LANGUAGES
752 enable_nls
753 PORTNAME
754 host_os
755 host_vendor
756 host_cpu
757 host
758 build_os
759 build_vendor
760 build_cpu
761 build
762 PG_MAJORVERSION
763 configure_args
764 target_alias
765 host_alias
766 build_alias
767 LIBS
768 ECHO_T
769 ECHO_N
770 ECHO_C
771 DEFS
772 mandir
773 localedir
774 libdir
775 psdir
776 pdfdir
777 dvidir
778 htmldir
779 infodir
780 docdir
781 oldincludedir
782 includedir
783 localstatedir
784 sharedstatedir
785 sysconfdir
786 datadir
787 datarootdir
788 libexecdir
789 sbindir
790 bindir
791 program_transform_name
792 prefix
793 exec_prefix
794 PACKAGE_BUGREPORT
795 PACKAGE_STRING
796 PACKAGE_VERSION
797 PACKAGE_TARNAME
798 PACKAGE_NAME
799 PATH_SEPARATOR
800 SHELL'
801 ac_subst_files=''
802 ac_user_opts='
803 enable_option_checking
804 with_template
805 with_includes
806 with_libraries
807 with_libs
808 enable_integer_datetimes
809 enable_nls
810 with_pgport
811 enable_shared
812 enable_rpath
813 enable_spinlocks
814 enable_debug
815 enable_profiling
816 enable_coverage
817 enable_dtrace
818 with_blocksize
819 with_segsize
820 with_wal_blocksize
821 with_wal_segsize
822 with_CC
823 enable_depend
824 enable_cassert
825 enable_thread_safety
826 with_tcl
827 with_tclconfig
828 with_perl
829 with_python
830 with_gssapi
831 with_krb5
832 with_krb_srvnam
833 with_pam
834 with_ldap
835 with_bonjour
836 with_openssl
837 with_readline
838 with_libedit_preferred
839 with_ossp_uuid
840 with_libxml
841 with_libxslt
842 with_system_tzdata
843 with_zlib
844 with_gnu_ld
845 enable_float4_byval
846 enable_float8_byval
847 enable_largefile
848 '
849       ac_precious_vars='build_alias
850 host_alias
851 target_alias
852 CC
853 CFLAGS
854 LDFLAGS
855 LIBS
856 CPPFLAGS
857 CPP
858 LDFLAGS_SL
859 DOCBOOKSTYLE'
860
861
862 # Initialize some variables set by options.
863 ac_init_help=
864 ac_init_version=false
865 ac_unrecognized_opts=
866 ac_unrecognized_sep=
867 # The variables have the same names as the options, with
868 # dashes changed to underlines.
869 cache_file=/dev/null
870 exec_prefix=NONE
871 no_create=
872 no_recursion=
873 prefix=NONE
874 program_prefix=NONE
875 program_suffix=NONE
876 program_transform_name=s,x,x,
877 silent=
878 site=
879 srcdir=
880 verbose=
881 x_includes=NONE
882 x_libraries=NONE
883
884 # Installation directory options.
885 # These are left unexpanded so users can "make install exec_prefix=/foo"
886 # and all the variables that are supposed to be based on exec_prefix
887 # by default will actually change.
888 # Use braces instead of parens because sh, perl, etc. also accept them.
889 # (The list follows the same order as the GNU Coding Standards.)
890 bindir='${exec_prefix}/bin'
891 sbindir='${exec_prefix}/sbin'
892 libexecdir='${exec_prefix}/libexec'
893 datarootdir='${prefix}/share'
894 datadir='${datarootdir}'
895 sysconfdir='${prefix}/etc'
896 sharedstatedir='${prefix}/com'
897 localstatedir='${prefix}/var'
898 includedir='${prefix}/include'
899 oldincludedir='/usr/include'
900 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
901 infodir='${datarootdir}/info'
902 htmldir='${docdir}'
903 dvidir='${docdir}'
904 pdfdir='${docdir}'
905 psdir='${docdir}'
906 libdir='${exec_prefix}/lib'
907 localedir='${datarootdir}/locale'
908 mandir='${datarootdir}/man'
909
910 ac_prev=
911 ac_dashdash=
912 for ac_option
913 do
914   # If the previous option needs an argument, assign it.
915   if test -n "$ac_prev"; then
916     eval $ac_prev=\$ac_option
917     ac_prev=
918     continue
919   fi
920
921   case $ac_option in
922   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
923   *)    ac_optarg=yes ;;
924   esac
925
926   # Accept the important Cygnus configure options, so we can diagnose typos.
927
928   case $ac_dashdash$ac_option in
929   --)
930     ac_dashdash=yes ;;
931
932   -bindir | --bindir | --bindi | --bind | --bin | --bi)
933     ac_prev=bindir ;;
934   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
935     bindir=$ac_optarg ;;
936
937   -build | --build | --buil | --bui | --bu)
938     ac_prev=build_alias ;;
939   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
940     build_alias=$ac_optarg ;;
941
942   -cache-file | --cache-file | --cache-fil | --cache-fi \
943   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
944     ac_prev=cache_file ;;
945   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
946   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
947     cache_file=$ac_optarg ;;
948
949   --config-cache | -C)
950     cache_file=config.cache ;;
951
952   -datadir | --datadir | --datadi | --datad)
953     ac_prev=datadir ;;
954   -datadir=* | --datadir=* | --datadi=* | --datad=*)
955     datadir=$ac_optarg ;;
956
957   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
958   | --dataroo | --dataro | --datar)
959     ac_prev=datarootdir ;;
960   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
961   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
962     datarootdir=$ac_optarg ;;
963
964   -disable-* | --disable-*)
965     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
966     # Reject names that are not valid shell variable names.
967     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
968       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
969    { (exit 1); exit 1; }; }
970     ac_useropt_orig=$ac_useropt
971     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
972     case $ac_user_opts in
973       *"
974 "enable_$ac_useropt"
975 "*) ;;
976       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
977          ac_unrecognized_sep=', ';;
978     esac
979     eval enable_$ac_useropt=no ;;
980
981   -docdir | --docdir | --docdi | --doc | --do)
982     ac_prev=docdir ;;
983   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
984     docdir=$ac_optarg ;;
985
986   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
987     ac_prev=dvidir ;;
988   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
989     dvidir=$ac_optarg ;;
990
991   -enable-* | --enable-*)
992     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
993     # Reject names that are not valid shell variable names.
994     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
995       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
996    { (exit 1); exit 1; }; }
997     ac_useropt_orig=$ac_useropt
998     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
999     case $ac_user_opts in
1000       *"
1001 "enable_$ac_useropt"
1002 "*) ;;
1003       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1004          ac_unrecognized_sep=', ';;
1005     esac
1006     eval enable_$ac_useropt=\$ac_optarg ;;
1007
1008   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1009   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1010   | --exec | --exe | --ex)
1011     ac_prev=exec_prefix ;;
1012   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1013   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1014   | --exec=* | --exe=* | --ex=*)
1015     exec_prefix=$ac_optarg ;;
1016
1017   -gas | --gas | --ga | --g)
1018     # Obsolete; use --with-gas.
1019     with_gas=yes ;;
1020
1021   -help | --help | --hel | --he | -h)
1022     ac_init_help=long ;;
1023   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1024     ac_init_help=recursive ;;
1025   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1026     ac_init_help=short ;;
1027
1028   -host | --host | --hos | --ho)
1029     ac_prev=host_alias ;;
1030   -host=* | --host=* | --hos=* | --ho=*)
1031     host_alias=$ac_optarg ;;
1032
1033   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1034     ac_prev=htmldir ;;
1035   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1036   | --ht=*)
1037     htmldir=$ac_optarg ;;
1038
1039   -includedir | --includedir | --includedi | --included | --include \
1040   | --includ | --inclu | --incl | --inc)
1041     ac_prev=includedir ;;
1042   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1043   | --includ=* | --inclu=* | --incl=* | --inc=*)
1044     includedir=$ac_optarg ;;
1045
1046   -infodir | --infodir | --infodi | --infod | --info | --inf)
1047     ac_prev=infodir ;;
1048   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1049     infodir=$ac_optarg ;;
1050
1051   -libdir | --libdir | --libdi | --libd)
1052     ac_prev=libdir ;;
1053   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1054     libdir=$ac_optarg ;;
1055
1056   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1057   | --libexe | --libex | --libe)
1058     ac_prev=libexecdir ;;
1059   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1060   | --libexe=* | --libex=* | --libe=*)
1061     libexecdir=$ac_optarg ;;
1062
1063   -localedir | --localedir | --localedi | --localed | --locale)
1064     ac_prev=localedir ;;
1065   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1066     localedir=$ac_optarg ;;
1067
1068   -localstatedir | --localstatedir | --localstatedi | --localstated \
1069   | --localstate | --localstat | --localsta | --localst | --locals)
1070     ac_prev=localstatedir ;;
1071   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1072   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1073     localstatedir=$ac_optarg ;;
1074
1075   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1076     ac_prev=mandir ;;
1077   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1078     mandir=$ac_optarg ;;
1079
1080   -nfp | --nfp | --nf)
1081     # Obsolete; use --without-fp.
1082     with_fp=no ;;
1083
1084   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1085   | --no-cr | --no-c | -n)
1086     no_create=yes ;;
1087
1088   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1089   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1090     no_recursion=yes ;;
1091
1092   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1093   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1094   | --oldin | --oldi | --old | --ol | --o)
1095     ac_prev=oldincludedir ;;
1096   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1097   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1098   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1099     oldincludedir=$ac_optarg ;;
1100
1101   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1102     ac_prev=prefix ;;
1103   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1104     prefix=$ac_optarg ;;
1105
1106   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1107   | --program-pre | --program-pr | --program-p)
1108     ac_prev=program_prefix ;;
1109   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1110   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1111     program_prefix=$ac_optarg ;;
1112
1113   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1114   | --program-suf | --program-su | --program-s)
1115     ac_prev=program_suffix ;;
1116   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1117   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1118     program_suffix=$ac_optarg ;;
1119
1120   -program-transform-name | --program-transform-name \
1121   | --program-transform-nam | --program-transform-na \
1122   | --program-transform-n | --program-transform- \
1123   | --program-transform | --program-transfor \
1124   | --program-transfo | --program-transf \
1125   | --program-trans | --program-tran \
1126   | --progr-tra | --program-tr | --program-t)
1127     ac_prev=program_transform_name ;;
1128   -program-transform-name=* | --program-transform-name=* \
1129   | --program-transform-nam=* | --program-transform-na=* \
1130   | --program-transform-n=* | --program-transform-=* \
1131   | --program-transform=* | --program-transfor=* \
1132   | --program-transfo=* | --program-transf=* \
1133   | --program-trans=* | --program-tran=* \
1134   | --progr-tra=* | --program-tr=* | --program-t=*)
1135     program_transform_name=$ac_optarg ;;
1136
1137   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1138     ac_prev=pdfdir ;;
1139   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1140     pdfdir=$ac_optarg ;;
1141
1142   -psdir | --psdir | --psdi | --psd | --ps)
1143     ac_prev=psdir ;;
1144   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1145     psdir=$ac_optarg ;;
1146
1147   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1148   | -silent | --silent | --silen | --sile | --sil)
1149     silent=yes ;;
1150
1151   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1152     ac_prev=sbindir ;;
1153   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1154   | --sbi=* | --sb=*)
1155     sbindir=$ac_optarg ;;
1156
1157   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1158   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1159   | --sharedst | --shareds | --shared | --share | --shar \
1160   | --sha | --sh)
1161     ac_prev=sharedstatedir ;;
1162   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1163   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1164   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1165   | --sha=* | --sh=*)
1166     sharedstatedir=$ac_optarg ;;
1167
1168   -site | --site | --sit)
1169     ac_prev=site ;;
1170   -site=* | --site=* | --sit=*)
1171     site=$ac_optarg ;;
1172
1173   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1174     ac_prev=srcdir ;;
1175   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1176     srcdir=$ac_optarg ;;
1177
1178   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1179   | --syscon | --sysco | --sysc | --sys | --sy)
1180     ac_prev=sysconfdir ;;
1181   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1182   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1183     sysconfdir=$ac_optarg ;;
1184
1185   -target | --target | --targe | --targ | --tar | --ta | --t)
1186     ac_prev=target_alias ;;
1187   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1188     target_alias=$ac_optarg ;;
1189
1190   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1191     verbose=yes ;;
1192
1193   -version | --version | --versio | --versi | --vers | -V)
1194     ac_init_version=: ;;
1195
1196   -with-* | --with-*)
1197     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1198     # Reject names that are not valid shell variable names.
1199     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1200       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1201    { (exit 1); exit 1; }; }
1202     ac_useropt_orig=$ac_useropt
1203     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1204     case $ac_user_opts in
1205       *"
1206 "with_$ac_useropt"
1207 "*) ;;
1208       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1209          ac_unrecognized_sep=', ';;
1210     esac
1211     eval with_$ac_useropt=\$ac_optarg ;;
1212
1213   -without-* | --without-*)
1214     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1215     # Reject names that are not valid shell variable names.
1216     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1217       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1218    { (exit 1); exit 1; }; }
1219     ac_useropt_orig=$ac_useropt
1220     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1221     case $ac_user_opts in
1222       *"
1223 "with_$ac_useropt"
1224 "*) ;;
1225       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1226          ac_unrecognized_sep=', ';;
1227     esac
1228     eval with_$ac_useropt=no ;;
1229
1230   --x)
1231     # Obsolete; use --with-x.
1232     with_x=yes ;;
1233
1234   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1235   | --x-incl | --x-inc | --x-in | --x-i)
1236     ac_prev=x_includes ;;
1237   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1238   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1239     x_includes=$ac_optarg ;;
1240
1241   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1242   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1243     ac_prev=x_libraries ;;
1244   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1245   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1246     x_libraries=$ac_optarg ;;
1247
1248   -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
1249 Try \`$0 --help' for more information." >&2
1250    { (exit 1); exit 1; }; }
1251     ;;
1252
1253   *=*)
1254     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1255     # Reject names that are not valid shell variable names.
1256     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1257       { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1258    { (exit 1); exit 1; }; }
1259     eval $ac_envvar=\$ac_optarg
1260     export $ac_envvar ;;
1261
1262   *)
1263     # FIXME: should be removed in autoconf 3.0.
1264     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1265     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1266       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1267     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1268     ;;
1269
1270   esac
1271 done
1272
1273 if test -n "$ac_prev"; then
1274   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1275   { $as_echo "$as_me: error: missing argument to $ac_option" >&2
1276    { (exit 1); exit 1; }; }
1277 fi
1278
1279 if test -n "$ac_unrecognized_opts"; then
1280   case $enable_option_checking in
1281     no) ;;
1282     fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
1283    { (exit 1); exit 1; }; } ;;
1284     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1285   esac
1286 fi
1287
1288 # Check all directory arguments for consistency.
1289 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1290                 datadir sysconfdir sharedstatedir localstatedir includedir \
1291                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1292                 libdir localedir mandir
1293 do
1294   eval ac_val=\$$ac_var
1295   # Remove trailing slashes.
1296   case $ac_val in
1297     */ )
1298       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1299       eval $ac_var=\$ac_val;;
1300   esac
1301   # Be sure to have absolute directory names.
1302   case $ac_val in
1303     [\\/$]* | ?:[\\/]* )  continue;;
1304     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1305   esac
1306   { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1307    { (exit 1); exit 1; }; }
1308 done
1309
1310 # There might be people who depend on the old broken behavior: `$host'
1311 # used to hold the argument of --host etc.
1312 # FIXME: To remove some day.
1313 build=$build_alias
1314 host=$host_alias
1315 target=$target_alias
1316
1317 # FIXME: To remove some day.
1318 if test "x$host_alias" != x; then
1319   if test "x$build_alias" = x; then
1320     cross_compiling=maybe
1321     $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1322     If a cross compiler is detected then cross compile mode will be used." >&2
1323   elif test "x$build_alias" != "x$host_alias"; then
1324     cross_compiling=yes
1325   fi
1326 fi
1327
1328 ac_tool_prefix=
1329 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1330
1331 test "$silent" = yes && exec 6>/dev/null
1332
1333
1334 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1335 ac_ls_di=`ls -di .` &&
1336 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1337   { $as_echo "$as_me: error: working directory cannot be determined" >&2
1338    { (exit 1); exit 1; }; }
1339 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1340   { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
1341    { (exit 1); exit 1; }; }
1342
1343
1344 # Find the source files, if location was not specified.
1345 if test -z "$srcdir"; then
1346   ac_srcdir_defaulted=yes
1347   # Try the directory containing this script, then the parent directory.
1348   ac_confdir=`$as_dirname -- "$as_myself" ||
1349 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1350          X"$as_myself" : 'X\(//\)[^/]' \| \
1351          X"$as_myself" : 'X\(//\)$' \| \
1352          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1353 $as_echo X"$as_myself" |
1354     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1355             s//\1/
1356             q
1357           }
1358           /^X\(\/\/\)[^/].*/{
1359             s//\1/
1360             q
1361           }
1362           /^X\(\/\/\)$/{
1363             s//\1/
1364             q
1365           }
1366           /^X\(\/\).*/{
1367             s//\1/
1368             q
1369           }
1370           s/.*/./; q'`
1371   srcdir=$ac_confdir
1372   if test ! -r "$srcdir/$ac_unique_file"; then
1373     srcdir=..
1374   fi
1375 else
1376   ac_srcdir_defaulted=no
1377 fi
1378 if test ! -r "$srcdir/$ac_unique_file"; then
1379   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1380   { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1381    { (exit 1); exit 1; }; }
1382 fi
1383 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1384 ac_abs_confdir=`(
1385         cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
1386    { (exit 1); exit 1; }; }
1387         pwd)`
1388 # When building in place, set srcdir=.
1389 if test "$ac_abs_confdir" = "$ac_pwd"; then
1390   srcdir=.
1391 fi
1392 # Remove unnecessary trailing slashes from srcdir.
1393 # Double slashes in file names in object file debugging info
1394 # mess up M-x gdb in Emacs.
1395 case $srcdir in
1396 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1397 esac
1398 for ac_var in $ac_precious_vars; do
1399   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1400   eval ac_env_${ac_var}_value=\$${ac_var}
1401   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1402   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1403 done
1404
1405 #
1406 # Report the --help message.
1407 #
1408 if test "$ac_init_help" = "long"; then
1409   # Omit some internal or obsolete options to make the list less imposing.
1410   # This message is too long to be a string in the A/UX 3.1 sh.
1411   cat <<_ACEOF
1412 \`configure' configures PostgreSQL 8.5devel to adapt to many kinds of systems.
1413
1414 Usage: $0 [OPTION]... [VAR=VALUE]...
1415
1416 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1417 VAR=VALUE.  See below for descriptions of some of the useful variables.
1418
1419 Defaults for the options are specified in brackets.
1420
1421 Configuration:
1422   -h, --help              display this help and exit
1423       --help=short        display options specific to this package
1424       --help=recursive    display the short help of all the included packages
1425   -V, --version           display version information and exit
1426   -q, --quiet, --silent   do not print \`checking...' messages
1427       --cache-file=FILE   cache test results in FILE [disabled]
1428   -C, --config-cache      alias for \`--cache-file=config.cache'
1429   -n, --no-create         do not create output files
1430       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1431
1432 Installation directories:
1433   --prefix=PREFIX         install architecture-independent files in PREFIX
1434                           [$ac_default_prefix]
1435   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1436                           [PREFIX]
1437
1438 By default, \`make install' will install all the files in
1439 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1440 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1441 for instance \`--prefix=\$HOME'.
1442
1443 For better control, use the options below.
1444
1445 Fine tuning of the installation directories:
1446   --bindir=DIR            user executables [EPREFIX/bin]
1447   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1448   --libexecdir=DIR        program executables [EPREFIX/libexec]
1449   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1450   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1451   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1452   --libdir=DIR            object code libraries [EPREFIX/lib]
1453   --includedir=DIR        C header files [PREFIX/include]
1454   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1455   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1456   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1457   --infodir=DIR           info documentation [DATAROOTDIR/info]
1458   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1459   --mandir=DIR            man documentation [DATAROOTDIR/man]
1460   --docdir=DIR            documentation root [DATAROOTDIR/doc/postgresql]
1461   --htmldir=DIR           html documentation [DOCDIR]
1462   --dvidir=DIR            dvi documentation [DOCDIR]
1463   --pdfdir=DIR            pdf documentation [DOCDIR]
1464   --psdir=DIR             ps documentation [DOCDIR]
1465 _ACEOF
1466
1467   cat <<\_ACEOF
1468
1469 System types:
1470   --build=BUILD     configure for building on BUILD [guessed]
1471   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1472 _ACEOF
1473 fi
1474
1475 if test -n "$ac_init_help"; then
1476   case $ac_init_help in
1477      short | recursive ) echo "Configuration of PostgreSQL 8.5devel:";;
1478    esac
1479   cat <<\_ACEOF
1480
1481 Optional Features:
1482   --disable-option-checking  ignore unrecognized --enable/--with options
1483   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1484   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1485   --disable-integer-datetimes
1486                           disable 64-bit integer date/time support
1487   --enable-nls[=LANGUAGES]
1488                           enable Native Language Support
1489   --disable-shared        do not build shared libraries
1490   --disable-rpath         do not embed shared library search path in
1491                           executables
1492   --disable-spinlocks     do not use spinlocks
1493   --enable-debug          build with debugging symbols (-g)
1494   --enable-profiling      build with profiling enabled
1495   --enable-coverage       build with coverage testing instrumentation
1496   --enable-dtrace         build with DTrace support
1497   --enable-depend         turn on automatic dependency tracking
1498   --enable-cassert        enable assertion checks (for debugging)
1499   --disable-thread-safety disable thread-safety in client libraries
1500   --disable-float4-byval  disable float4 passed by value
1501   --disable-float8-byval  disable float8 passed by value
1502   --disable-largefile     omit support for large files
1503
1504 Optional Packages:
1505   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1506   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1507   --with-template=NAME    override operating system template
1508   --with-includes=DIRS    look for additional header files in DIRS
1509   --with-libraries=DIRS   look for additional libraries in DIRS
1510   --with-libs=DIRS        alternative spelling of --with-libraries
1511   --with-pgport=PORTNUM   set default port number [5432]
1512   --with-blocksize=BLOCKSIZE
1513                           set table block size in kB [8]
1514   --with-segsize=SEGSIZE  set table segment size in GB [1]
1515   --with-wal-blocksize=BLOCKSIZE
1516                           set WAL block size in kB [8]
1517   --with-wal-segsize=SEGSIZE
1518                           set WAL segment size in MB [16]
1519   --with-CC=CMD           set compiler (deprecated)
1520   --with-tcl              build Tcl modules (PL/Tcl)
1521   --with-tclconfig=DIR    tclConfig.sh is in DIR
1522   --with-perl             build Perl modules (PL/Perl)
1523   --with-python           build Python modules (PL/Python)
1524   --with-gssapi           build with GSSAPI support
1525   --with-krb5             build with Kerberos 5 support
1526   --with-krb-srvnam=NAME  default service principal name in Kerberos
1527                           [postgres]
1528   --with-pam              build with PAM support
1529   --with-ldap             build with LDAP support
1530   --with-bonjour          build with Bonjour support
1531   --with-openssl          build with OpenSSL support
1532   --without-readline      do not use GNU Readline nor BSD Libedit for editing
1533   --with-libedit-preferred
1534                           prefer BSD Libedit over GNU Readline
1535   --with-ossp-uuid        use OSSP UUID library when building
1536                           contrib/uuid-ossp
1537   --with-libxml           build with XML support
1538   --with-libxslt          use XSLT support when building contrib/xml2
1539   --with-system-tzdata=DIR
1540                           use system time zone data in DIR
1541   --without-zlib          do not use Zlib
1542   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1543
1544 Some influential environment variables:
1545   CC          C compiler command
1546   CFLAGS      C compiler flags
1547   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1548               nonstandard directory <lib dir>
1549   LIBS        libraries to pass to the linker, e.g. -l<library>
1550   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1551               you have headers in a nonstandard directory <include dir>
1552   CPP         C preprocessor
1553   LDFLAGS_SL  linker flags for shared library linking
1554   DOCBOOKSTYLE
1555               location of DocBook stylesheets
1556
1557 Use these variables to override the choices made by `configure' or to help
1558 it to find libraries and programs with nonstandard names/locations.
1559
1560 Report bugs to <pgsql-bugs@postgresql.org>.
1561 _ACEOF
1562 ac_status=$?
1563 fi
1564
1565 if test "$ac_init_help" = "recursive"; then
1566   # If there are subdirs, report their specific --help.
1567   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1568     test -d "$ac_dir" ||
1569       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1570       continue
1571     ac_builddir=.
1572
1573 case "$ac_dir" in
1574 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1575 *)
1576   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1577   # A ".." for each directory in $ac_dir_suffix.
1578   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1579   case $ac_top_builddir_sub in
1580   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1581   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1582   esac ;;
1583 esac
1584 ac_abs_top_builddir=$ac_pwd
1585 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1586 # for backward compatibility:
1587 ac_top_builddir=$ac_top_build_prefix
1588
1589 case $srcdir in
1590   .)  # We are building in place.
1591     ac_srcdir=.
1592     ac_top_srcdir=$ac_top_builddir_sub
1593     ac_abs_top_srcdir=$ac_pwd ;;
1594   [\\/]* | ?:[\\/]* )  # Absolute name.
1595     ac_srcdir=$srcdir$ac_dir_suffix;
1596     ac_top_srcdir=$srcdir
1597     ac_abs_top_srcdir=$srcdir ;;
1598   *) # Relative name.
1599     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1600     ac_top_srcdir=$ac_top_build_prefix$srcdir
1601     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1602 esac
1603 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1604
1605     cd "$ac_dir" || { ac_status=$?; continue; }
1606     # Check for guested configure.
1607     if test -f "$ac_srcdir/configure.gnu"; then
1608       echo &&
1609       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1610     elif test -f "$ac_srcdir/configure"; then
1611       echo &&
1612       $SHELL "$ac_srcdir/configure" --help=recursive
1613     else
1614       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1615     fi || ac_status=$?
1616     cd "$ac_pwd" || { ac_status=$?; break; }
1617   done
1618 fi
1619
1620 test -n "$ac_init_help" && exit $ac_status
1621 if $ac_init_version; then
1622   cat <<\_ACEOF
1623 PostgreSQL configure 8.5devel
1624 generated by GNU Autoconf 2.63
1625
1626 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1627 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
1628 This configure script is free software; the Free Software Foundation
1629 gives unlimited permission to copy, distribute and modify it.
1630
1631 Copyright (c) 1996-2009, PostgreSQL Global Development Group
1632 _ACEOF
1633   exit
1634 fi
1635 cat >config.log <<_ACEOF
1636 This file contains any messages produced by compilers while
1637 running configure, to aid debugging if configure makes a mistake.
1638
1639 It was created by PostgreSQL $as_me 8.5devel, which was
1640 generated by GNU Autoconf 2.63.  Invocation command line was
1641
1642   $ $0 $@
1643
1644 _ACEOF
1645 exec 5>>config.log
1646 {
1647 cat <<_ASUNAME
1648 ## --------- ##
1649 ## Platform. ##
1650 ## --------- ##
1651
1652 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1653 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1654 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1655 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1656 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1657
1658 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1659 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1660
1661 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1662 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1663 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1664 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1665 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1666 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1667 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1668
1669 _ASUNAME
1670
1671 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1672 for as_dir in $PATH
1673 do
1674   IFS=$as_save_IFS
1675   test -z "$as_dir" && as_dir=.
1676   $as_echo "PATH: $as_dir"
1677 done
1678 IFS=$as_save_IFS
1679
1680 } >&5
1681
1682 cat >&5 <<_ACEOF
1683
1684
1685 ## ----------- ##
1686 ## Core tests. ##
1687 ## ----------- ##
1688
1689 _ACEOF
1690
1691
1692 # Keep a trace of the command line.
1693 # Strip out --no-create and --no-recursion so they do not pile up.
1694 # Strip out --silent because we don't want to record it for future runs.
1695 # Also quote any args containing shell meta-characters.
1696 # Make two passes to allow for proper duplicate-argument suppression.
1697 ac_configure_args=
1698 ac_configure_args0=
1699 ac_configure_args1=
1700 ac_must_keep_next=false
1701 for ac_pass in 1 2
1702 do
1703   for ac_arg
1704   do
1705     case $ac_arg in
1706     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1707     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1708     | -silent | --silent | --silen | --sile | --sil)
1709       continue ;;
1710     *\'*)
1711       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1712     esac
1713     case $ac_pass in
1714     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1715     2)
1716       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1717       if test $ac_must_keep_next = true; then
1718         ac_must_keep_next=false # Got value, back to normal.
1719       else
1720         case $ac_arg in
1721           *=* | --config-cache | -C | -disable-* | --disable-* \
1722           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1723           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1724           | -with-* | --with-* | -without-* | --without-* | --x)
1725             case "$ac_configure_args0 " in
1726               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1727             esac
1728             ;;
1729           -* ) ac_must_keep_next=true ;;
1730         esac
1731       fi
1732       ac_configure_args="$ac_configure_args '$ac_arg'"
1733       ;;
1734     esac
1735   done
1736 done
1737 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1738 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1739
1740 # When interrupted or exit'd, cleanup temporary files, and complete
1741 # config.log.  We remove comments because anyway the quotes in there
1742 # would cause problems or look ugly.
1743 # WARNING: Use '\'' to represent an apostrophe within the trap.
1744 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1745 trap 'exit_status=$?
1746   # Save into config.log some information that might help in debugging.
1747   {
1748     echo
1749
1750     cat <<\_ASBOX
1751 ## ---------------- ##
1752 ## Cache variables. ##
1753 ## ---------------- ##
1754 _ASBOX
1755     echo
1756     # The following way of writing the cache mishandles newlines in values,
1757 (
1758   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1759     eval ac_val=\$$ac_var
1760     case $ac_val in #(
1761     *${as_nl}*)
1762       case $ac_var in #(
1763       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1764 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
1765       esac
1766       case $ac_var in #(
1767       _ | IFS | as_nl) ;; #(
1768       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
1769       *) $as_unset $ac_var ;;
1770       esac ;;
1771     esac
1772   done
1773   (set) 2>&1 |
1774     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1775     *${as_nl}ac_space=\ *)
1776       sed -n \
1777         "s/'\''/'\''\\\\'\'''\''/g;
1778           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1779       ;; #(
1780     *)
1781       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1782       ;;
1783     esac |
1784     sort
1785 )
1786     echo
1787
1788     cat <<\_ASBOX
1789 ## ----------------- ##
1790 ## Output variables. ##
1791 ## ----------------- ##
1792 _ASBOX
1793     echo
1794     for ac_var in $ac_subst_vars
1795     do
1796       eval ac_val=\$$ac_var
1797       case $ac_val in
1798       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1799       esac
1800       $as_echo "$ac_var='\''$ac_val'\''"
1801     done | sort
1802     echo
1803
1804     if test -n "$ac_subst_files"; then
1805       cat <<\_ASBOX
1806 ## ------------------- ##
1807 ## File substitutions. ##
1808 ## ------------------- ##
1809 _ASBOX
1810       echo
1811       for ac_var in $ac_subst_files
1812       do
1813         eval ac_val=\$$ac_var
1814         case $ac_val in
1815         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1816         esac
1817         $as_echo "$ac_var='\''$ac_val'\''"
1818       done | sort
1819       echo
1820     fi
1821
1822     if test -s confdefs.h; then
1823       cat <<\_ASBOX
1824 ## ----------- ##
1825 ## confdefs.h. ##
1826 ## ----------- ##
1827 _ASBOX
1828       echo
1829       cat confdefs.h
1830       echo
1831     fi
1832     test "$ac_signal" != 0 &&
1833       $as_echo "$as_me: caught signal $ac_signal"
1834     $as_echo "$as_me: exit $exit_status"
1835   } >&5
1836   rm -f core *.core core.conftest.* &&
1837     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1838     exit $exit_status
1839 ' 0
1840 for ac_signal in 1 2 13 15; do
1841   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1842 done
1843 ac_signal=0
1844
1845 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1846 rm -f -r conftest* confdefs.h
1847
1848 # Predefined preprocessor variables.
1849
1850 cat >>confdefs.h <<_ACEOF
1851 #define PACKAGE_NAME "$PACKAGE_NAME"
1852 _ACEOF
1853
1854
1855 cat >>confdefs.h <<_ACEOF
1856 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1857 _ACEOF
1858
1859
1860 cat >>confdefs.h <<_ACEOF
1861 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1862 _ACEOF
1863
1864
1865 cat >>confdefs.h <<_ACEOF
1866 #define PACKAGE_STRING "$PACKAGE_STRING"
1867 _ACEOF
1868
1869
1870 cat >>confdefs.h <<_ACEOF
1871 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1872 _ACEOF
1873
1874
1875 # Let the site file select an alternate cache file if it wants to.
1876 # Prefer an explicitly selected file to automatically selected ones.
1877 ac_site_file1=NONE
1878 ac_site_file2=NONE
1879 if test -n "$CONFIG_SITE"; then
1880   ac_site_file1=$CONFIG_SITE
1881 elif test "x$prefix" != xNONE; then
1882   ac_site_file1=$prefix/share/config.site
1883   ac_site_file2=$prefix/etc/config.site
1884 else
1885   ac_site_file1=$ac_default_prefix/share/config.site
1886   ac_site_file2=$ac_default_prefix/etc/config.site
1887 fi
1888 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
1889 do
1890   test "x$ac_site_file" = xNONE && continue
1891   if test -r "$ac_site_file"; then
1892     { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1893 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
1894     sed 's/^/| /' "$ac_site_file" >&5
1895     . "$ac_site_file"
1896   fi
1897 done
1898
1899 if test -r "$cache_file"; then
1900   # Some versions of bash will fail to source /dev/null (special
1901   # files actually), so we avoid doing that.
1902   if test -f "$cache_file"; then
1903     { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
1904 $as_echo "$as_me: loading cache $cache_file" >&6;}
1905     case $cache_file in
1906       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1907       *)                      . "./$cache_file";;
1908     esac
1909   fi
1910 else
1911   { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
1912 $as_echo "$as_me: creating cache $cache_file" >&6;}
1913   >$cache_file
1914 fi
1915
1916 # Check that the precious variables saved in the cache have kept the same
1917 # value.
1918 ac_cache_corrupted=false
1919 for ac_var in $ac_precious_vars; do
1920   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1921   eval ac_new_set=\$ac_env_${ac_var}_set
1922   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1923   eval ac_new_val=\$ac_env_${ac_var}_value
1924   case $ac_old_set,$ac_new_set in
1925     set,)
1926       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1927 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1928       ac_cache_corrupted=: ;;
1929     ,set)
1930       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1931 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1932       ac_cache_corrupted=: ;;
1933     ,);;
1934     *)
1935       if test "x$ac_old_val" != "x$ac_new_val"; then
1936         # differences in whitespace do not lead to failure.
1937         ac_old_val_w=`echo x $ac_old_val`
1938         ac_new_val_w=`echo x $ac_new_val`
1939         if test "$ac_old_val_w" != "$ac_new_val_w"; then
1940           { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1941 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1942           ac_cache_corrupted=:
1943         else
1944           { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1945 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1946           eval $ac_var=\$ac_old_val
1947         fi
1948         { $as_echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
1949 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
1950         { $as_echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
1951 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
1952       fi;;
1953   esac
1954   # Pass precious variables to config.status.
1955   if test "$ac_new_set" = set; then
1956     case $ac_new_val in
1957     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1958     *) ac_arg=$ac_var=$ac_new_val ;;
1959     esac
1960     case " $ac_configure_args " in
1961       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1962       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1963     esac
1964   fi
1965 done
1966 if $ac_cache_corrupted; then
1967   { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1968 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1969   { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1970 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1971   { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1972 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1973    { (exit 1); exit 1; }; }
1974 fi
1975
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 ac_ext=c
2001 ac_cpp='$CPP $CPPFLAGS'
2002 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2003 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2004 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2005
2006
2007
2008
2009
2010
2011 ac_aux_dir=
2012 for ac_dir in config "$srcdir"/config; do
2013   if test -f "$ac_dir/install-sh"; then
2014     ac_aux_dir=$ac_dir
2015     ac_install_sh="$ac_aux_dir/install-sh -c"
2016     break
2017   elif test -f "$ac_dir/install.sh"; then
2018     ac_aux_dir=$ac_dir
2019     ac_install_sh="$ac_aux_dir/install.sh -c"
2020     break
2021   elif test -f "$ac_dir/shtool"; then
2022     ac_aux_dir=$ac_dir
2023     ac_install_sh="$ac_aux_dir/shtool install -c"
2024     break
2025   fi
2026 done
2027 if test -z "$ac_aux_dir"; then
2028   { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
2029 $as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
2030    { (exit 1); exit 1; }; }
2031 fi
2032
2033 # These three variables are undocumented and unsupported,
2034 # and are intended to be withdrawn in a future Autoconf release.
2035 # They can cause serious problems if a builder's source tree is in a directory
2036 # whose full name contains unusual characters.
2037 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2038 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2039 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2040
2041
2042
2043 configure_args=$ac_configure_args
2044
2045
2046
2047 cat >>confdefs.h <<_ACEOF
2048 #define PG_VERSION "$PACKAGE_VERSION"
2049 _ACEOF
2050
2051 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\.[0-9][0-9]*\)'`
2052
2053
2054 cat >>confdefs.h <<_ACEOF
2055 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2056 _ACEOF
2057
2058
2059 # Make sure we can run config.sub.
2060 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2061   { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2062 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2063    { (exit 1); exit 1; }; }
2064
2065 { $as_echo "$as_me:$LINENO: checking build system type" >&5
2066 $as_echo_n "checking build system type... " >&6; }
2067 if test "${ac_cv_build+set}" = set; then
2068   $as_echo_n "(cached) " >&6
2069 else
2070   ac_build_alias=$build_alias
2071 test "x$ac_build_alias" = x &&
2072   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2073 test "x$ac_build_alias" = x &&
2074   { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2075 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2076    { (exit 1); exit 1; }; }
2077 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2078   { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2079 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2080    { (exit 1); exit 1; }; }
2081
2082 fi
2083 { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2084 $as_echo "$ac_cv_build" >&6; }
2085 case $ac_cv_build in
2086 *-*-*) ;;
2087 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2088 $as_echo "$as_me: error: invalid value of canonical build" >&2;}
2089    { (exit 1); exit 1; }; };;
2090 esac
2091 build=$ac_cv_build
2092 ac_save_IFS=$IFS; IFS='-'
2093 set x $ac_cv_build
2094 shift
2095 build_cpu=$1
2096 build_vendor=$2
2097 shift; shift
2098 # Remember, the first character of IFS is used to create $*,
2099 # except with old shells:
2100 build_os=$*
2101 IFS=$ac_save_IFS
2102 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2103
2104
2105 { $as_echo "$as_me:$LINENO: checking host system type" >&5
2106 $as_echo_n "checking host system type... " >&6; }
2107 if test "${ac_cv_host+set}" = set; then
2108   $as_echo_n "(cached) " >&6
2109 else
2110   if test "x$host_alias" = x; then
2111   ac_cv_host=$ac_cv_build
2112 else
2113   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2114     { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2115 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2116    { (exit 1); exit 1; }; }
2117 fi
2118
2119 fi
2120 { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2121 $as_echo "$ac_cv_host" >&6; }
2122 case $ac_cv_host in
2123 *-*-*) ;;
2124 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2125 $as_echo "$as_me: error: invalid value of canonical host" >&2;}
2126    { (exit 1); exit 1; }; };;
2127 esac
2128 host=$ac_cv_host
2129 ac_save_IFS=$IFS; IFS='-'
2130 set x $ac_cv_host
2131 shift
2132 host_cpu=$1
2133 host_vendor=$2
2134 shift; shift
2135 # Remember, the first character of IFS is used to create $*,
2136 # except with old shells:
2137 host_os=$*
2138 IFS=$ac_save_IFS
2139 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2140
2141
2142
2143 template=
2144 { $as_echo "$as_me:$LINENO: checking which template to use" >&5
2145 $as_echo_n "checking which template to use... " >&6; }
2146
2147
2148
2149
2150 # Check whether --with-template was given.
2151 if test "${with_template+set}" = set; then
2152   withval=$with_template;
2153   case $withval in
2154     yes)
2155       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2156 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2157    { (exit 1); exit 1; }; }
2158       ;;
2159     no)
2160       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2161 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2162    { (exit 1); exit 1; }; }
2163       ;;
2164     *)
2165
2166   case $withval in
2167     list)   echo; ls "$srcdir/src/template"; exit;;
2168     *)      if test -f "$srcdir/src/template/$with_template" ; then
2169               template=$withval
2170             else
2171               { { $as_echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
2172 $as_echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
2173    { (exit 1); exit 1; }; }
2174             fi;;
2175   esac
2176
2177       ;;
2178   esac
2179
2180 else
2181
2182 # --with-template not given
2183
2184 case $host_os in
2185      aix*) template=aix ;;
2186     bsdi*) template=bsdi ;;
2187   cygwin*) template=cygwin ;;
2188   darwin*) template=darwin ;;
2189     dgux*) template=dgux ;;
2190  freebsd*) template=freebsd ;;
2191     hpux*) template=hpux ;;
2192     irix*) template=irix ;;
2193  linux*|gnu*|k*bsd*-gnu)
2194            template=linux ;;
2195    mingw*) template=win32 ;;
2196   netbsd*) template=netbsd ;;
2197 nextstep*) template=nextstep ;;
2198  openbsd*) template=openbsd ;;
2199      osf*) template=osf ;;
2200      sco*) template=sco ;;
2201  solaris*) template=solaris ;;
2202    sunos*) template=sunos4 ;;
2203  sysv4.2*)
2204         case $host_vendor in
2205           univel) template=univel ;;
2206         esac ;;
2207    sysv4*) template=svr4 ;;
2208    sysv5*) template=unixware ;;
2209   ultrix*) template=ultrix4 ;;
2210 esac
2211
2212   if test x"$template" = x"" ; then
2213     { { $as_echo "$as_me:$LINENO: error:
2214 *******************************************************************
2215 PostgreSQL has apparently not been ported to your platform yet.
2216 To try a manual configuration, look into the src/template directory
2217 for a similar platform and use the '--with-template=' option.
2218
2219 Please also contact <pgsql-bugs@postgresql.org> to see about
2220 rectifying this.  Include the above 'checking host system type...'
2221 line.
2222 *******************************************************************
2223 " >&5
2224 $as_echo "$as_me: error:
2225 *******************************************************************
2226 PostgreSQL has apparently not been ported to your platform yet.
2227 To try a manual configuration, look into the src/template directory
2228 for a similar platform and use the '--with-template=' option.
2229
2230 Please also contact <pgsql-bugs@postgresql.org> to see about
2231 rectifying this.  Include the above 'checking host system type...'
2232 line.
2233 *******************************************************************
2234 " >&2;}
2235    { (exit 1); exit 1; }; }
2236   fi
2237
2238
2239 fi
2240
2241
2242
2243 { $as_echo "$as_me:$LINENO: result: $template" >&5
2244 $as_echo "$template" >&6; }
2245
2246 PORTNAME=$template
2247
2248
2249 # Initialize default assumption that we do not need separate assembly code
2250 # for TAS (test-and-set).  This can be overridden by the template file
2251 # when it's executed.
2252 need_tas=no
2253 tas_file=dummy.s
2254
2255
2256
2257 ##
2258 ## Command line options
2259 ##
2260
2261 #
2262 # Add non-standard directories to the include path
2263 #
2264
2265
2266
2267 # Check whether --with-includes was given.
2268 if test "${with_includes+set}" = set; then
2269   withval=$with_includes;
2270   case $withval in
2271     yes)
2272       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2273 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2274    { (exit 1); exit 1; }; }
2275       ;;
2276     no)
2277       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2278 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2279    { (exit 1); exit 1; }; }
2280       ;;
2281     *)
2282
2283       ;;
2284   esac
2285
2286 fi
2287
2288
2289
2290
2291 #
2292 # Add non-standard directories to the library search path
2293 #
2294
2295
2296
2297 # Check whether --with-libraries was given.
2298 if test "${with_libraries+set}" = set; then
2299   withval=$with_libraries;
2300   case $withval in
2301     yes)
2302       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2303 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2304    { (exit 1); exit 1; }; }
2305       ;;
2306     no)
2307       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2308 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2309    { (exit 1); exit 1; }; }
2310       ;;
2311     *)
2312       LIBRARY_DIRS=$withval
2313       ;;
2314   esac
2315
2316 fi
2317
2318
2319
2320
2321
2322
2323 # Check whether --with-libs was given.
2324 if test "${with_libs+set}" = set; then
2325   withval=$with_libs;
2326   case $withval in
2327     yes)
2328       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2329 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2330    { (exit 1); exit 1; }; }
2331       ;;
2332     no)
2333       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2334 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2335    { (exit 1); exit 1; }; }
2336       ;;
2337     *)
2338       LIBRARY_DIRS=$withval
2339       ;;
2340   esac
2341
2342 fi
2343
2344
2345
2346
2347 #
2348 # 64-bit integer date/time storage: enabled by default.
2349 #
2350 { $as_echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
2351 $as_echo_n "checking whether to build with 64-bit integer date/time support... " >&6; }
2352
2353
2354 # Check whether --enable-integer-datetimes was given.
2355 if test "${enable_integer_datetimes+set}" = set; then
2356   enableval=$enable_integer_datetimes;
2357   case $enableval in
2358     yes)
2359
2360 cat >>confdefs.h <<\_ACEOF
2361 #define USE_INTEGER_DATETIMES 1
2362 _ACEOF
2363
2364       ;;
2365     no)
2366       :
2367       ;;
2368     *)
2369       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
2370 $as_echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
2371    { (exit 1); exit 1; }; }
2372       ;;
2373   esac
2374
2375 else
2376   enable_integer_datetimes=yes
2377
2378 cat >>confdefs.h <<\_ACEOF
2379 #define USE_INTEGER_DATETIMES 1
2380 _ACEOF
2381
2382 fi
2383
2384
2385 { $as_echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
2386 $as_echo "$enable_integer_datetimes" >&6; }
2387
2388
2389 #
2390 # NLS
2391 #
2392 { $as_echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
2393 $as_echo_n "checking whether NLS is wanted... " >&6; }
2394
2395
2396 # Check whether --enable-nls was given.
2397 if test "${enable_nls+set}" = set; then
2398   enableval=$enable_nls;
2399   case $enableval in
2400     yes)
2401       :
2402       ;;
2403     no)
2404       :
2405       ;;
2406     *)
2407       enable_nls=yes
2408 WANTED_LANGUAGES=$enableval
2409       ;;
2410   esac
2411
2412 else
2413   enable_nls=no
2414 fi
2415
2416
2417
2418 if test "$enable_nls" = yes; then
2419
2420 cat >>confdefs.h <<\_ACEOF
2421 #define ENABLE_NLS 1
2422 _ACEOF
2423
2424 fi
2425
2426 { $as_echo "$as_me:$LINENO: result: $enable_nls" >&5
2427 $as_echo "$enable_nls" >&6; }
2428
2429
2430
2431 #
2432 # Default port number (--with-pgport), default 5432
2433 #
2434 { $as_echo "$as_me:$LINENO: checking for default port number" >&5
2435 $as_echo_n "checking for default port number... " >&6; }
2436
2437
2438
2439 # Check whether --with-pgport was given.
2440 if test "${with_pgport+set}" = set; then
2441   withval=$with_pgport;
2442   case $withval in
2443     yes)
2444       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2445 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2446    { (exit 1); exit 1; }; }
2447       ;;
2448     no)
2449       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2450 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2451    { (exit 1); exit 1; }; }
2452       ;;
2453     *)
2454       default_port=$withval
2455       ;;
2456   esac
2457
2458 else
2459   default_port=5432
2460 fi
2461
2462
2463 { $as_echo "$as_me:$LINENO: result: $default_port" >&5
2464 $as_echo "$default_port" >&6; }
2465 # Need both of these because some places want an integer and some a string
2466
2467 cat >>confdefs.h <<_ACEOF
2468 #define DEF_PGPORT ${default_port}
2469 _ACEOF
2470
2471
2472 cat >>confdefs.h <<_ACEOF
2473 #define DEF_PGPORT_STR "${default_port}"
2474 _ACEOF
2475
2476
2477
2478 #
2479 # Option to disable shared libraries
2480 #
2481
2482
2483 # Check whether --enable-shared was given.
2484 if test "${enable_shared+set}" = set; then
2485   enableval=$enable_shared;
2486   case $enableval in
2487     yes)
2488       :
2489       ;;
2490     no)
2491       :
2492       ;;
2493     *)
2494       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
2495 $as_echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
2496    { (exit 1); exit 1; }; }
2497       ;;
2498   esac
2499
2500 else
2501   enable_shared=yes
2502
2503 fi
2504
2505
2506
2507
2508 #
2509 # '-rpath'-like feature can be disabled
2510 #
2511
2512
2513 # Check whether --enable-rpath was given.
2514 if test "${enable_rpath+set}" = set; then
2515   enableval=$enable_rpath;
2516   case $enableval in
2517     yes)
2518       :
2519       ;;
2520     no)
2521       :
2522       ;;
2523     *)
2524       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
2525 $as_echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
2526    { (exit 1); exit 1; }; }
2527       ;;
2528   esac
2529
2530 else
2531   enable_rpath=yes
2532
2533 fi
2534
2535
2536
2537
2538 #
2539 # Spinlocks
2540 #
2541
2542
2543 # Check whether --enable-spinlocks was given.
2544 if test "${enable_spinlocks+set}" = set; then
2545   enableval=$enable_spinlocks;
2546   case $enableval in
2547     yes)
2548       :
2549       ;;
2550     no)
2551       :
2552       ;;
2553     *)
2554       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
2555 $as_echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
2556    { (exit 1); exit 1; }; }
2557       ;;
2558   esac
2559
2560 else
2561   enable_spinlocks=yes
2562
2563 fi
2564
2565
2566
2567 #
2568 # --enable-debug adds -g to compiler flags
2569 #
2570
2571
2572 # Check whether --enable-debug was given.
2573 if test "${enable_debug+set}" = set; then
2574   enableval=$enable_debug;
2575   case $enableval in
2576     yes)
2577       :
2578       ;;
2579     no)
2580       :
2581       ;;
2582     *)
2583       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
2584 $as_echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
2585    { (exit 1); exit 1; }; }
2586       ;;
2587   esac
2588
2589 else
2590   enable_debug=no
2591
2592 fi
2593
2594
2595
2596
2597 #
2598 # --enable-profiling enables gcc profiling
2599 #
2600
2601
2602 # Check whether --enable-profiling was given.
2603 if test "${enable_profiling+set}" = set; then
2604   enableval=$enable_profiling;
2605   case $enableval in
2606     yes)
2607       :
2608       ;;
2609     no)
2610       :
2611       ;;
2612     *)
2613       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-profiling option" >&5
2614 $as_echo "$as_me: error: no argument expected for --enable-profiling option" >&2;}
2615    { (exit 1); exit 1; }; }
2616       ;;
2617   esac
2618
2619 else
2620   enable_profiling=no
2621
2622 fi
2623
2624
2625
2626
2627 #
2628 # --enable-coverage enables generation of code coverage metrics with gcov
2629 #
2630
2631
2632 # Check whether --enable-coverage was given.
2633 if test "${enable_coverage+set}" = set; then
2634   enableval=$enable_coverage;
2635   case $enableval in
2636     yes)
2637       for ac_prog in gcov
2638 do
2639   # Extract the first word of "$ac_prog", so it can be a program name with args.
2640 set dummy $ac_prog; ac_word=$2
2641 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2642 $as_echo_n "checking for $ac_word... " >&6; }
2643 if test "${ac_cv_prog_GCOV+set}" = set; then
2644   $as_echo_n "(cached) " >&6
2645 else
2646   if test -n "$GCOV"; then
2647   ac_cv_prog_GCOV="$GCOV" # Let the user override the test.
2648 else
2649 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2650 for as_dir in $PATH
2651 do
2652   IFS=$as_save_IFS
2653   test -z "$as_dir" && as_dir=.
2654   for ac_exec_ext in '' $ac_executable_extensions; do
2655   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2656     ac_cv_prog_GCOV="$ac_prog"
2657     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2658     break 2
2659   fi
2660 done
2661 done
2662 IFS=$as_save_IFS
2663
2664 fi
2665 fi
2666 GCOV=$ac_cv_prog_GCOV
2667 if test -n "$GCOV"; then
2668   { $as_echo "$as_me:$LINENO: result: $GCOV" >&5
2669 $as_echo "$GCOV" >&6; }
2670 else
2671   { $as_echo "$as_me:$LINENO: result: no" >&5
2672 $as_echo "no" >&6; }
2673 fi
2674
2675
2676   test -n "$GCOV" && break
2677 done
2678
2679 if test -z "$GCOV"; then
2680   { { $as_echo "$as_me:$LINENO: error: gcov not found" >&5
2681 $as_echo "$as_me: error: gcov not found" >&2;}
2682    { (exit 1); exit 1; }; }
2683 fi
2684 for ac_prog in lcov
2685 do
2686   # Extract the first word of "$ac_prog", so it can be a program name with args.
2687 set dummy $ac_prog; ac_word=$2
2688 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2689 $as_echo_n "checking for $ac_word... " >&6; }
2690 if test "${ac_cv_prog_LCOV+set}" = set; then
2691   $as_echo_n "(cached) " >&6
2692 else
2693   if test -n "$LCOV"; then
2694   ac_cv_prog_LCOV="$LCOV" # Let the user override the test.
2695 else
2696 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2697 for as_dir in $PATH
2698 do
2699   IFS=$as_save_IFS
2700   test -z "$as_dir" && as_dir=.
2701   for ac_exec_ext in '' $ac_executable_extensions; do
2702   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2703     ac_cv_prog_LCOV="$ac_prog"
2704     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2705     break 2
2706   fi
2707 done
2708 done
2709 IFS=$as_save_IFS
2710
2711 fi
2712 fi
2713 LCOV=$ac_cv_prog_LCOV
2714 if test -n "$LCOV"; then
2715   { $as_echo "$as_me:$LINENO: result: $LCOV" >&5
2716 $as_echo "$LCOV" >&6; }
2717 else
2718   { $as_echo "$as_me:$LINENO: result: no" >&5
2719 $as_echo "no" >&6; }
2720 fi
2721
2722
2723   test -n "$LCOV" && break
2724 done
2725
2726 if test -z "$LCOV"; then
2727   { { $as_echo "$as_me:$LINENO: error: lcov not found" >&5
2728 $as_echo "$as_me: error: lcov not found" >&2;}
2729    { (exit 1); exit 1; }; }
2730 fi
2731 for ac_prog in genhtml
2732 do
2733   # Extract the first word of "$ac_prog", so it can be a program name with args.
2734 set dummy $ac_prog; ac_word=$2
2735 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2736 $as_echo_n "checking for $ac_word... " >&6; }
2737 if test "${ac_cv_prog_GENHTML+set}" = set; then
2738   $as_echo_n "(cached) " >&6
2739 else
2740   if test -n "$GENHTML"; then
2741   ac_cv_prog_GENHTML="$GENHTML" # Let the user override the test.
2742 else
2743 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2744 for as_dir in $PATH
2745 do
2746   IFS=$as_save_IFS
2747   test -z "$as_dir" && as_dir=.
2748   for ac_exec_ext in '' $ac_executable_extensions; do
2749   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2750     ac_cv_prog_GENHTML="$ac_prog"
2751     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2752     break 2
2753   fi
2754 done
2755 done
2756 IFS=$as_save_IFS
2757
2758 fi
2759 fi
2760 GENHTML=$ac_cv_prog_GENHTML
2761 if test -n "$GENHTML"; then
2762   { $as_echo "$as_me:$LINENO: result: $GENHTML" >&5
2763 $as_echo "$GENHTML" >&6; }
2764 else
2765   { $as_echo "$as_me:$LINENO: result: no" >&5
2766 $as_echo "no" >&6; }
2767 fi
2768
2769
2770   test -n "$GENHTML" && break
2771 done
2772
2773 if test -z "$GENHTML"; then
2774   { { $as_echo "$as_me:$LINENO: error: genhtml not found" >&5
2775 $as_echo "$as_me: error: genhtml not found" >&2;}
2776    { (exit 1); exit 1; }; }
2777 fi
2778       ;;
2779     no)
2780       :
2781       ;;
2782     *)
2783       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-coverage option" >&5
2784 $as_echo "$as_me: error: no argument expected for --enable-coverage option" >&2;}
2785    { (exit 1); exit 1; }; }
2786       ;;
2787   esac
2788
2789 else
2790   enable_coverage=no
2791
2792 fi
2793
2794
2795
2796
2797 #
2798 # DTrace
2799 #
2800
2801
2802 # Check whether --enable-dtrace was given.
2803 if test "${enable_dtrace+set}" = set; then
2804   enableval=$enable_dtrace;
2805   case $enableval in
2806     yes)
2807
2808 cat >>confdefs.h <<\_ACEOF
2809 #define ENABLE_DTRACE 1
2810 _ACEOF
2811
2812 for ac_prog in dtrace
2813 do
2814   # Extract the first word of "$ac_prog", so it can be a program name with args.
2815 set dummy $ac_prog; ac_word=$2
2816 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2817 $as_echo_n "checking for $ac_word... " >&6; }
2818 if test "${ac_cv_prog_DTRACE+set}" = set; then
2819   $as_echo_n "(cached) " >&6
2820 else
2821   if test -n "$DTRACE"; then
2822   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
2823 else
2824 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2825 for as_dir in $PATH
2826 do
2827   IFS=$as_save_IFS
2828   test -z "$as_dir" && as_dir=.
2829   for ac_exec_ext in '' $ac_executable_extensions; do
2830   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2831     ac_cv_prog_DTRACE="$ac_prog"
2832     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2833     break 2
2834   fi
2835 done
2836 done
2837 IFS=$as_save_IFS
2838
2839 fi
2840 fi
2841 DTRACE=$ac_cv_prog_DTRACE
2842 if test -n "$DTRACE"; then
2843   { $as_echo "$as_me:$LINENO: result: $DTRACE" >&5
2844 $as_echo "$DTRACE" >&6; }
2845 else
2846   { $as_echo "$as_me:$LINENO: result: no" >&5
2847 $as_echo "no" >&6; }
2848 fi
2849
2850
2851   test -n "$DTRACE" && break
2852 done
2853
2854 if test -z "$DTRACE"; then
2855   { { $as_echo "$as_me:$LINENO: error: dtrace not found" >&5
2856 $as_echo "$as_me: error: dtrace not found" >&2;}
2857    { (exit 1); exit 1; }; }
2858 fi
2859
2860       ;;
2861     no)
2862       :
2863       ;;
2864     *)
2865       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2866 $as_echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2867    { (exit 1); exit 1; }; }
2868       ;;
2869   esac
2870
2871 else
2872   enable_dtrace=no
2873
2874 fi
2875
2876
2877
2878
2879 #
2880 # Block size
2881 #
2882 { $as_echo "$as_me:$LINENO: checking for block size" >&5
2883 $as_echo_n "checking for block size... " >&6; }
2884
2885
2886
2887 # Check whether --with-blocksize was given.
2888 if test "${with_blocksize+set}" = set; then
2889   withval=$with_blocksize;
2890   case $withval in
2891     yes)
2892       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2893 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2894    { (exit 1); exit 1; }; }
2895       ;;
2896     no)
2897       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2898 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2899    { (exit 1); exit 1; }; }
2900       ;;
2901     *)
2902       blocksize=$withval
2903       ;;
2904   esac
2905
2906 else
2907   blocksize=8
2908 fi
2909
2910
2911 case ${blocksize} in
2912   1) BLCKSZ=1024;;
2913   2) BLCKSZ=2048;;
2914   4) BLCKSZ=4096;;
2915   8) BLCKSZ=8192;;
2916  16) BLCKSZ=16384;;
2917  32) BLCKSZ=32768;;
2918   *) { { $as_echo "$as_me:$LINENO: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&5
2919 $as_echo "$as_me: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&2;}
2920    { (exit 1); exit 1; }; }
2921 esac
2922 { $as_echo "$as_me:$LINENO: result: ${blocksize}kB" >&5
2923 $as_echo "${blocksize}kB" >&6; }
2924
2925
2926 cat >>confdefs.h <<_ACEOF
2927 #define BLCKSZ ${BLCKSZ}
2928 _ACEOF
2929
2930
2931 #
2932 # Relation segment size
2933 #
2934 { $as_echo "$as_me:$LINENO: checking for segment size" >&5
2935 $as_echo_n "checking for segment size... " >&6; }
2936
2937
2938
2939 # Check whether --with-segsize was given.
2940 if test "${with_segsize+set}" = set; then
2941   withval=$with_segsize;
2942   case $withval in
2943     yes)
2944       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2945 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2946    { (exit 1); exit 1; }; }
2947       ;;
2948     no)
2949       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2950 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2951    { (exit 1); exit 1; }; }
2952       ;;
2953     *)
2954       segsize=$withval
2955       ;;
2956   esac
2957
2958 else
2959   segsize=1
2960 fi
2961
2962
2963 # this expression is set up to avoid unnecessary integer overflow
2964 # blocksize is already guaranteed to be a factor of 1024
2965 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
2966 test $? -eq 0 || exit 1
2967 { $as_echo "$as_me:$LINENO: result: ${segsize}GB" >&5
2968 $as_echo "${segsize}GB" >&6; }
2969
2970
2971 cat >>confdefs.h <<_ACEOF
2972 #define RELSEG_SIZE ${RELSEG_SIZE}
2973 _ACEOF
2974
2975
2976 #
2977 # WAL block size
2978 #
2979 { $as_echo "$as_me:$LINENO: checking for WAL block size" >&5
2980 $as_echo_n "checking for WAL block size... " >&6; }
2981
2982
2983
2984 # Check whether --with-wal-blocksize was given.
2985 if test "${with_wal_blocksize+set}" = set; then
2986   withval=$with_wal_blocksize;
2987   case $withval in
2988     yes)
2989       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2990 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2991    { (exit 1); exit 1; }; }
2992       ;;
2993     no)
2994       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2995 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2996    { (exit 1); exit 1; }; }
2997       ;;
2998     *)
2999       wal_blocksize=$withval
3000       ;;
3001   esac
3002
3003 else
3004   wal_blocksize=8
3005 fi
3006
3007
3008 case ${wal_blocksize} in
3009   1) XLOG_BLCKSZ=1024;;
3010   2) XLOG_BLCKSZ=2048;;
3011   4) XLOG_BLCKSZ=4096;;
3012   8) XLOG_BLCKSZ=8192;;
3013  16) XLOG_BLCKSZ=16384;;
3014  32) XLOG_BLCKSZ=32768;;
3015  64) XLOG_BLCKSZ=65536;;
3016   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&5
3017 $as_echo "$as_me: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3018    { (exit 1); exit 1; }; }
3019 esac
3020 { $as_echo "$as_me:$LINENO: result: ${wal_blocksize}kB" >&5
3021 $as_echo "${wal_blocksize}kB" >&6; }
3022
3023
3024 cat >>confdefs.h <<_ACEOF
3025 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
3026 _ACEOF
3027
3028
3029 #
3030 # WAL segment size
3031 #
3032 { $as_echo "$as_me:$LINENO: checking for WAL segment size" >&5
3033 $as_echo_n "checking for WAL segment size... " >&6; }
3034
3035
3036
3037 # Check whether --with-wal-segsize was given.
3038 if test "${with_wal_segsize+set}" = set; then
3039   withval=$with_wal_segsize;
3040   case $withval in
3041     yes)
3042       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3043 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3044    { (exit 1); exit 1; }; }
3045       ;;
3046     no)
3047       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3048 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3049    { (exit 1); exit 1; }; }
3050       ;;
3051     *)
3052       wal_segsize=$withval
3053       ;;
3054   esac
3055
3056 else
3057   wal_segsize=16
3058 fi
3059
3060
3061 case ${wal_segsize} in
3062   1) ;;
3063   2) ;;
3064   4) ;;
3065   8) ;;
3066  16) ;;
3067  32) ;;
3068  64) ;;
3069   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&5
3070 $as_echo "$as_me: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3071    { (exit 1); exit 1; }; }
3072 esac
3073 { $as_echo "$as_me:$LINENO: result: ${wal_segsize}MB" >&5
3074 $as_echo "${wal_segsize}MB" >&6; }
3075
3076
3077 cat >>confdefs.h <<_ACEOF
3078 #define XLOG_SEG_SIZE (${wal_segsize} * 1024 * 1024)
3079 _ACEOF
3080
3081
3082 #
3083 # C compiler
3084 #
3085
3086 # For historical reasons you can also use --with-CC to specify the C compiler
3087 # to use, although the standard way to do this is to set the CC environment
3088 # variable.
3089
3090
3091
3092 # Check whether --with-CC was given.
3093 if test "${with_CC+set}" = set; then
3094   withval=$with_CC;
3095   case $withval in
3096     yes)
3097       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3098 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3099    { (exit 1); exit 1; }; }
3100       ;;
3101     no)
3102       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3103 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3104    { (exit 1); exit 1; }; }
3105       ;;
3106     *)
3107       CC=$with_CC
3108       ;;
3109   esac
3110
3111 fi
3112
3113
3114
3115 case $template in
3116   aix) pgac_cc_list="gcc xlc";;
3117  irix) pgac_cc_list="cc";; # no gcc
3118     *) pgac_cc_list="gcc cc";;
3119 esac
3120
3121 ac_ext=c
3122 ac_cpp='$CPP $CPPFLAGS'
3123 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3124 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3125 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3126 if test -n "$ac_tool_prefix"; then
3127   for ac_prog in $pgac_cc_list
3128   do
3129     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3130 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3131 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3132 $as_echo_n "checking for $ac_word... " >&6; }
3133 if test "${ac_cv_prog_CC+set}" = set; then
3134   $as_echo_n "(cached) " >&6
3135 else
3136   if test -n "$CC"; then
3137   ac_cv_prog_CC="$CC" # Let the user override the test.
3138 else
3139 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3140 for as_dir in $PATH
3141 do
3142   IFS=$as_save_IFS
3143   test -z "$as_dir" && as_dir=.
3144   for ac_exec_ext in '' $ac_executable_extensions; do
3145   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3146     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3147     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3148     break 2
3149   fi
3150 done
3151 done
3152 IFS=$as_save_IFS
3153
3154 fi
3155 fi
3156 CC=$ac_cv_prog_CC
3157 if test -n "$CC"; then
3158   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3159 $as_echo "$CC" >&6; }
3160 else
3161   { $as_echo "$as_me:$LINENO: result: no" >&5
3162 $as_echo "no" >&6; }
3163 fi
3164
3165
3166     test -n "$CC" && break
3167   done
3168 fi
3169 if test -z "$CC"; then
3170   ac_ct_CC=$CC
3171   for ac_prog in $pgac_cc_list
3172 do
3173   # Extract the first word of "$ac_prog", so it can be a program name with args.
3174 set dummy $ac_prog; ac_word=$2
3175 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3176 $as_echo_n "checking for $ac_word... " >&6; }
3177 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3178   $as_echo_n "(cached) " >&6
3179 else
3180   if test -n "$ac_ct_CC"; then
3181   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3182 else
3183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3184 for as_dir in $PATH
3185 do
3186   IFS=$as_save_IFS
3187   test -z "$as_dir" && as_dir=.
3188   for ac_exec_ext in '' $ac_executable_extensions; do
3189   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3190     ac_cv_prog_ac_ct_CC="$ac_prog"
3191     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3192     break 2
3193   fi
3194 done
3195 done
3196 IFS=$as_save_IFS
3197
3198 fi
3199 fi
3200 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3201 if test -n "$ac_ct_CC"; then
3202   { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3203 $as_echo "$ac_ct_CC" >&6; }
3204 else
3205   { $as_echo "$as_me:$LINENO: result: no" >&5
3206 $as_echo "no" >&6; }
3207 fi
3208
3209
3210   test -n "$ac_ct_CC" && break
3211 done
3212
3213   if test "x$ac_ct_CC" = x; then
3214     CC=""
3215   else
3216     case $cross_compiling:$ac_tool_warned in
3217 yes:)
3218 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
3219 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3220 ac_tool_warned=yes ;;
3221 esac
3222     CC=$ac_ct_CC
3223   fi
3224 fi
3225
3226
3227 test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3228 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3229 { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
3230 See \`config.log' for more details." >&5
3231 $as_echo "$as_me: error: no acceptable C compiler found in \$PATH
3232 See \`config.log' for more details." >&2;}
3233    { (exit 1); exit 1; }; }; }
3234
3235 # Provide some information about the compiler.
3236 $as_echo "$as_me:$LINENO: checking for C compiler version" >&5
3237 set X $ac_compile
3238 ac_compiler=$2
3239 { (ac_try="$ac_compiler --version >&5"
3240 case "(($ac_try" in
3241   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3242   *) ac_try_echo=$ac_try;;
3243 esac
3244 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3245 $as_echo "$ac_try_echo") >&5
3246   (eval "$ac_compiler --version >&5") 2>&5
3247   ac_status=$?
3248   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3249   (exit $ac_status); }
3250 { (ac_try="$ac_compiler -v >&5"
3251 case "(($ac_try" in
3252   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3253   *) ac_try_echo=$ac_try;;
3254 esac
3255 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3256 $as_echo "$ac_try_echo") >&5
3257   (eval "$ac_compiler -v >&5") 2>&5
3258   ac_status=$?
3259   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3260   (exit $ac_status); }
3261 { (ac_try="$ac_compiler -V >&5"
3262 case "(($ac_try" in
3263   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3264   *) ac_try_echo=$ac_try;;
3265 esac
3266 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3267 $as_echo "$ac_try_echo") >&5
3268   (eval "$ac_compiler -V >&5") 2>&5
3269   ac_status=$?
3270   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3271   (exit $ac_status); }
3272
3273 cat >conftest.$ac_ext <<_ACEOF
3274 /* confdefs.h.  */
3275 _ACEOF
3276 cat confdefs.h >>conftest.$ac_ext
3277 cat >>conftest.$ac_ext <<_ACEOF
3278 /* end confdefs.h.  */
3279
3280 int
3281 main ()
3282 {
3283
3284   ;
3285   return 0;
3286 }
3287 _ACEOF
3288 ac_clean_files_save=$ac_clean_files
3289 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3290 # Try to create an executable without -o first, disregard a.out.
3291 # It will help us diagnose broken compilers, and finding out an intuition
3292 # of exeext.
3293 { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3294 $as_echo_n "checking for C compiler default output file name... " >&6; }
3295 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3296
3297 # The possible output files:
3298 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3299
3300 ac_rmfiles=
3301 for ac_file in $ac_files
3302 do
3303   case $ac_file in
3304     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3305     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3306   esac
3307 done
3308 rm -f $ac_rmfiles
3309
3310 if { (ac_try="$ac_link_default"
3311 case "(($ac_try" in
3312   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3313   *) ac_try_echo=$ac_try;;
3314 esac
3315 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3316 $as_echo "$ac_try_echo") >&5
3317   (eval "$ac_link_default") 2>&5
3318   ac_status=$?
3319   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3320   (exit $ac_status); }; then
3321   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3322 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3323 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3324 # so that the user can short-circuit this test for compilers unknown to
3325 # Autoconf.
3326 for ac_file in $ac_files ''
3327 do
3328   test -f "$ac_file" || continue
3329   case $ac_file in
3330     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3331         ;;
3332     [ab].out )
3333         # We found the default executable, but exeext='' is most
3334         # certainly right.
3335         break;;
3336     *.* )
3337         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3338         then :; else
3339            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3340         fi
3341         # We set ac_cv_exeext here because the later test for it is not
3342         # safe: cross compilers may not add the suffix if given an `-o'
3343         # argument, so we may need to know it at that point already.
3344         # Even if this section looks crufty: it has the advantage of
3345         # actually working.
3346         break;;
3347     * )
3348         break;;
3349   esac
3350 done
3351 test "$ac_cv_exeext" = no && ac_cv_exeext=
3352
3353 else
3354   ac_file=''
3355 fi
3356
3357 { $as_echo "$as_me:$LINENO: result: $ac_file" >&5
3358 $as_echo "$ac_file" >&6; }
3359 if test -z "$ac_file"; then
3360   $as_echo "$as_me: failed program was:" >&5
3361 sed 's/^/| /' conftest.$ac_ext >&5
3362
3363 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3364 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3365 { { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
3366 See \`config.log' for more details." >&5
3367 $as_echo "$as_me: error: C compiler cannot create executables
3368 See \`config.log' for more details." >&2;}
3369    { (exit 77); exit 77; }; }; }
3370 fi
3371
3372 ac_exeext=$ac_cv_exeext
3373
3374 # Check that the compiler produces executables we can run.  If not, either
3375 # the compiler is broken, or we cross compile.
3376 { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3377 $as_echo_n "checking whether the C compiler works... " >&6; }
3378 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3379 # If not cross compiling, check that we can run a simple program.
3380 if test "$cross_compiling" != yes; then
3381   if { ac_try='./$ac_file'
3382   { (case "(($ac_try" in
3383   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3384   *) ac_try_echo=$ac_try;;
3385 esac
3386 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3387 $as_echo "$ac_try_echo") >&5
3388   (eval "$ac_try") 2>&5
3389   ac_status=$?
3390   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3391   (exit $ac_status); }; }; then
3392     cross_compiling=no
3393   else
3394     if test "$cross_compiling" = maybe; then
3395         cross_compiling=yes
3396     else
3397         { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3398 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3399 { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
3400 If you meant to cross compile, use \`--host'.
3401 See \`config.log' for more details." >&5
3402 $as_echo "$as_me: error: cannot run C compiled programs.
3403 If you meant to cross compile, use \`--host'.
3404 See \`config.log' for more details." >&2;}
3405    { (exit 1); exit 1; }; }; }
3406     fi
3407   fi
3408 fi
3409 { $as_echo "$as_me:$LINENO: result: yes" >&5
3410 $as_echo "yes" >&6; }
3411
3412 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3413 ac_clean_files=$ac_clean_files_save
3414 # Check that the compiler produces executables we can run.  If not, either
3415 # the compiler is broken, or we cross compile.
3416 { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3417 $as_echo_n "checking whether we are cross compiling... " >&6; }
3418 { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
3419 $as_echo "$cross_compiling" >&6; }
3420
3421 { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
3422 $as_echo_n "checking for suffix of executables... " >&6; }
3423 if { (ac_try="$ac_link"
3424 case "(($ac_try" in
3425   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3426   *) ac_try_echo=$ac_try;;
3427 esac
3428 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3429 $as_echo "$ac_try_echo") >&5
3430   (eval "$ac_link") 2>&5
3431   ac_status=$?
3432   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3433   (exit $ac_status); }; then
3434   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3435 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3436 # work properly (i.e., refer to `conftest.exe'), while it won't with
3437 # `rm'.
3438 for ac_file in conftest.exe conftest conftest.*; do
3439   test -f "$ac_file" || continue
3440   case $ac_file in
3441     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3442     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3443           break;;
3444     * ) break;;
3445   esac
3446 done
3447 else
3448   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3449 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3450 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3451 See \`config.log' for more details." >&5
3452 $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3453 See \`config.log' for more details." >&2;}
3454    { (exit 1); exit 1; }; }; }
3455 fi
3456
3457 rm -f conftest$ac_cv_exeext
3458 { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3459 $as_echo "$ac_cv_exeext" >&6; }
3460
3461 rm -f conftest.$ac_ext
3462 EXEEXT=$ac_cv_exeext
3463 ac_exeext=$EXEEXT
3464 { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
3465 $as_echo_n "checking for suffix of object files... " >&6; }
3466 if test "${ac_cv_objext+set}" = set; then
3467   $as_echo_n "(cached) " >&6
3468 else
3469   cat >conftest.$ac_ext <<_ACEOF
3470 /* confdefs.h.  */
3471 _ACEOF
3472 cat confdefs.h >>conftest.$ac_ext
3473 cat >>conftest.$ac_ext <<_ACEOF
3474 /* end confdefs.h.  */
3475
3476 int
3477 main ()
3478 {
3479
3480   ;
3481   return 0;
3482 }
3483 _ACEOF
3484 rm -f conftest.o conftest.obj
3485 if { (ac_try="$ac_compile"
3486 case "(($ac_try" in
3487   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3488   *) ac_try_echo=$ac_try;;
3489 esac
3490 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3491 $as_echo "$ac_try_echo") >&5
3492   (eval "$ac_compile") 2>&5
3493   ac_status=$?
3494   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3495   (exit $ac_status); }; then
3496   for ac_file in conftest.o conftest.obj conftest.*; do
3497   test -f "$ac_file" || continue;
3498   case $ac_file in
3499     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3500     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3501        break;;
3502   esac
3503 done
3504 else
3505   $as_echo "$as_me: failed program was:" >&5
3506 sed 's/^/| /' conftest.$ac_ext >&5
3507
3508 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3509 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3510 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3511 See \`config.log' for more details." >&5
3512 $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
3513 See \`config.log' for more details." >&2;}
3514    { (exit 1); exit 1; }; }; }
3515 fi
3516
3517 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3518 fi
3519 { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3520 $as_echo "$ac_cv_objext" >&6; }
3521 OBJEXT=$ac_cv_objext
3522 ac_objext=$OBJEXT
3523 { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3524 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3525 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3526   $as_echo_n "(cached) " >&6
3527 else
3528   cat >conftest.$ac_ext <<_ACEOF
3529 /* confdefs.h.  */
3530 _ACEOF
3531 cat confdefs.h >>conftest.$ac_ext
3532 cat >>conftest.$ac_ext <<_ACEOF
3533 /* end confdefs.h.  */
3534
3535 int
3536 main ()
3537 {
3538 #ifndef __GNUC__
3539        choke me
3540 #endif
3541
3542   ;
3543   return 0;
3544 }
3545 _ACEOF
3546 rm -f conftest.$ac_objext
3547 if { (ac_try="$ac_compile"
3548 case "(($ac_try" in
3549   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3550   *) ac_try_echo=$ac_try;;
3551 esac
3552 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3553 $as_echo "$ac_try_echo") >&5
3554   (eval "$ac_compile") 2>conftest.er1
3555   ac_status=$?
3556   grep -v '^ *+' conftest.er1 >conftest.err
3557   rm -f conftest.er1
3558   cat conftest.err >&5
3559   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3560   (exit $ac_status); } && {
3561          test -z "$ac_c_werror_flag" ||
3562          test ! -s conftest.err
3563        } && test -s conftest.$ac_objext; then
3564   ac_compiler_gnu=yes
3565 else
3566   $as_echo "$as_me: failed program was:" >&5
3567 sed 's/^/| /' conftest.$ac_ext >&5
3568
3569         ac_compiler_gnu=no
3570 fi
3571
3572 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3573 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3574
3575 fi
3576 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3577 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3578 if test $ac_compiler_gnu = yes; then
3579   GCC=yes
3580 else
3581   GCC=
3582 fi
3583 ac_test_CFLAGS=${CFLAGS+set}
3584 ac_save_CFLAGS=$CFLAGS
3585 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3586 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3587 if test "${ac_cv_prog_cc_g+set}" = set; then
3588   $as_echo_n "(cached) " >&6
3589 else
3590   ac_save_c_werror_flag=$ac_c_werror_flag
3591    ac_c_werror_flag=yes
3592    ac_cv_prog_cc_g=no
3593    CFLAGS="-g"
3594    cat >conftest.$ac_ext <<_ACEOF
3595 /* confdefs.h.  */
3596 _ACEOF
3597 cat confdefs.h >>conftest.$ac_ext
3598 cat >>conftest.$ac_ext <<_ACEOF
3599 /* end confdefs.h.  */
3600
3601 int
3602 main ()
3603 {
3604
3605   ;
3606   return 0;
3607 }
3608 _ACEOF
3609 rm -f conftest.$ac_objext
3610 if { (ac_try="$ac_compile"
3611 case "(($ac_try" in
3612   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3613   *) ac_try_echo=$ac_try;;
3614 esac
3615 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3616 $as_echo "$ac_try_echo") >&5
3617   (eval "$ac_compile") 2>conftest.er1
3618   ac_status=$?
3619   grep -v '^ *+' conftest.er1 >conftest.err
3620   rm -f conftest.er1
3621   cat conftest.err >&5
3622   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3623   (exit $ac_status); } && {
3624          test -z "$ac_c_werror_flag" ||
3625          test ! -s conftest.err
3626        } && test -s conftest.$ac_objext; then
3627   ac_cv_prog_cc_g=yes
3628 else
3629   $as_echo "$as_me: failed program was:" >&5
3630 sed 's/^/| /' conftest.$ac_ext >&5
3631
3632         CFLAGS=""
3633       cat >conftest.$ac_ext <<_ACEOF
3634 /* confdefs.h.  */
3635 _ACEOF
3636 cat confdefs.h >>conftest.$ac_ext
3637 cat >>conftest.$ac_ext <<_ACEOF
3638 /* end confdefs.h.  */
3639
3640 int
3641 main ()
3642 {
3643
3644   ;
3645   return 0;
3646 }
3647 _ACEOF
3648 rm -f conftest.$ac_objext
3649 if { (ac_try="$ac_compile"
3650 case "(($ac_try" in
3651   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3652   *) ac_try_echo=$ac_try;;
3653 esac
3654 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3655 $as_echo "$ac_try_echo") >&5
3656   (eval "$ac_compile") 2>conftest.er1
3657   ac_status=$?
3658   grep -v '^ *+' conftest.er1 >conftest.err
3659   rm -f conftest.er1
3660   cat conftest.err >&5
3661   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3662   (exit $ac_status); } && {
3663          test -z "$ac_c_werror_flag" ||
3664          test ! -s conftest.err
3665        } && test -s conftest.$ac_objext; then
3666   :
3667 else
3668   $as_echo "$as_me: failed program was:" >&5
3669 sed 's/^/| /' conftest.$ac_ext >&5
3670
3671         ac_c_werror_flag=$ac_save_c_werror_flag
3672          CFLAGS="-g"
3673          cat >conftest.$ac_ext <<_ACEOF
3674 /* confdefs.h.  */
3675 _ACEOF
3676 cat confdefs.h >>conftest.$ac_ext
3677 cat >>conftest.$ac_ext <<_ACEOF
3678 /* end confdefs.h.  */
3679
3680 int
3681 main ()
3682 {
3683
3684   ;
3685   return 0;
3686 }
3687 _ACEOF
3688 rm -f conftest.$ac_objext
3689 if { (ac_try="$ac_compile"
3690 case "(($ac_try" in
3691   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3692   *) ac_try_echo=$ac_try;;
3693 esac
3694 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3695 $as_echo "$ac_try_echo") >&5
3696   (eval "$ac_compile") 2>conftest.er1
3697   ac_status=$?
3698   grep -v '^ *+' conftest.er1 >conftest.err
3699   rm -f conftest.er1
3700   cat conftest.err >&5
3701   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3702   (exit $ac_status); } && {
3703          test -z "$ac_c_werror_flag" ||
3704          test ! -s conftest.err
3705        } && test -s conftest.$ac_objext; then
3706   ac_cv_prog_cc_g=yes
3707 else
3708   $as_echo "$as_me: failed program was:" >&5
3709 sed 's/^/| /' conftest.$ac_ext >&5
3710
3711
3712 fi
3713
3714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3715 fi
3716
3717 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3718 fi
3719
3720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3721    ac_c_werror_flag=$ac_save_c_werror_flag
3722 fi
3723 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3724 $as_echo "$ac_cv_prog_cc_g" >&6; }
3725 if test "$ac_test_CFLAGS" = set; then
3726   CFLAGS=$ac_save_CFLAGS
3727 elif test $ac_cv_prog_cc_g = yes; then
3728   if test "$GCC" = yes; then
3729     CFLAGS="-g -O2"
3730   else
3731     CFLAGS="-g"
3732   fi
3733 else
3734   if test "$GCC" = yes; then
3735     CFLAGS="-O2"
3736   else
3737     CFLAGS=
3738   fi
3739 fi
3740 { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3741 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3742 if test "${ac_cv_prog_cc_c89+set}" = set; then
3743   $as_echo_n "(cached) " >&6
3744 else
3745   ac_cv_prog_cc_c89=no
3746 ac_save_CC=$CC
3747 cat >conftest.$ac_ext <<_ACEOF
3748 /* confdefs.h.  */
3749 _ACEOF
3750 cat confdefs.h >>conftest.$ac_ext
3751 cat >>conftest.$ac_ext <<_ACEOF
3752 /* end confdefs.h.  */
3753 #include <stdarg.h>
3754 #include <stdio.h>
3755 #include <sys/types.h>
3756 #include <sys/stat.h>
3757 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3758 struct buf { int x; };
3759 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3760 static char *e (p, i)
3761      char **p;
3762      int i;
3763 {
3764   return p[i];
3765 }
3766 static char *f (char * (*g) (char **, int), char **p, ...)
3767 {
3768   char *s;
3769   va_list v;
3770   va_start (v,p);
3771   s = g (p, va_arg (v,int));
3772   va_end (v);
3773   return s;
3774 }
3775
3776 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3777    function prototypes and stuff, but not '\xHH' hex character constants.
3778    These don't provoke an error unfortunately, instead are silently treated
3779    as 'x'.  The following induces an error, until -std is added to get
3780    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3781    array size at least.  It's necessary to write '\x00'==0 to get something
3782    that's true only with -std.  */
3783 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3784
3785 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3786    inside strings and character constants.  */
3787 #define FOO(x) 'x'
3788 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3789
3790 int test (int i, double x);
3791 struct s1 {int (*f) (int a);};
3792 struct s2 {int (*f) (double a);};
3793 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3794 int argc;
3795 char **argv;
3796 int
3797 main ()
3798 {
3799 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3800   ;
3801   return 0;
3802 }
3803 _ACEOF
3804 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3805         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3806 do
3807   CC="$ac_save_CC $ac_arg"
3808   rm -f conftest.$ac_objext
3809 if { (ac_try="$ac_compile"
3810 case "(($ac_try" in
3811   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3812   *) ac_try_echo=$ac_try;;
3813 esac
3814 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3815 $as_echo "$ac_try_echo") >&5
3816   (eval "$ac_compile") 2>conftest.er1
3817   ac_status=$?
3818   grep -v '^ *+' conftest.er1 >conftest.err
3819   rm -f conftest.er1
3820   cat conftest.err >&5
3821   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3822   (exit $ac_status); } && {
3823          test -z "$ac_c_werror_flag" ||
3824          test ! -s conftest.err
3825        } && test -s conftest.$ac_objext; then
3826   ac_cv_prog_cc_c89=$ac_arg
3827 else
3828   $as_echo "$as_me: failed program was:" >&5
3829 sed 's/^/| /' conftest.$ac_ext >&5
3830
3831
3832 fi
3833
3834 rm -f core conftest.err conftest.$ac_objext
3835   test "x$ac_cv_prog_cc_c89" != "xno" && break
3836 done
3837 rm -f conftest.$ac_ext
3838 CC=$ac_save_CC
3839
3840 fi
3841 # AC_CACHE_VAL
3842 case "x$ac_cv_prog_cc_c89" in
3843   x)
3844     { $as_echo "$as_me:$LINENO: result: none needed" >&5
3845 $as_echo "none needed" >&6; } ;;
3846   xno)
3847     { $as_echo "$as_me:$LINENO: result: unsupported" >&5
3848 $as_echo "unsupported" >&6; } ;;
3849   *)
3850     CC="$CC $ac_cv_prog_cc_c89"
3851     { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3852 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3853 esac
3854
3855
3856 ac_ext=c
3857 ac_cpp='$CPP $CPPFLAGS'
3858 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3859 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3860 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3861
3862
3863 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
3864 # but has idiosyncrasies of its own.  We assume icc will define
3865 # __INTEL_COMPILER regardless of CFLAGS.
3866
3867 cat >conftest.$ac_ext <<_ACEOF
3868 /* confdefs.h.  */
3869 _ACEOF
3870 cat confdefs.h >>conftest.$ac_ext
3871 cat >>conftest.$ac_ext <<_ACEOF
3872 /* end confdefs.h.  */
3873
3874 int
3875 main ()
3876 {
3877 #ifndef __INTEL_COMPILER
3878 choke me
3879 #endif
3880   ;
3881   return 0;
3882 }
3883 _ACEOF
3884 rm -f conftest.$ac_objext
3885 if { (ac_try="$ac_compile"
3886 case "(($ac_try" in
3887   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3888   *) ac_try_echo=$ac_try;;
3889 esac
3890 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3891 $as_echo "$ac_try_echo") >&5
3892   (eval "$ac_compile") 2>conftest.er1
3893   ac_status=$?
3894   grep -v '^ *+' conftest.er1 >conftest.err
3895   rm -f conftest.er1
3896   cat conftest.err >&5
3897   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3898   (exit $ac_status); } && {
3899          test -z "$ac_c_werror_flag" ||
3900          test ! -s conftest.err
3901        } && test -s conftest.$ac_objext; then
3902   ICC=yes
3903 else
3904   $as_echo "$as_me: failed program was:" >&5
3905 sed 's/^/| /' conftest.$ac_ext >&5
3906
3907         ICC=no
3908 fi
3909
3910 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3911
3912 # Check if it's Sun Studio compiler. We assume that
3913 # __SUNPRO_C will be defined for Sun Studio compilers
3914 cat >conftest.$ac_ext <<_ACEOF
3915 /* confdefs.h.  */
3916 _ACEOF
3917 cat confdefs.h >>conftest.$ac_ext
3918 cat >>conftest.$ac_ext <<_ACEOF
3919 /* end confdefs.h.  */
3920
3921 int
3922 main ()
3923 {
3924 #ifndef __SUNPRO_C
3925 choke me
3926 #endif
3927   ;
3928   return 0;
3929 }
3930 _ACEOF
3931 rm -f conftest.$ac_objext
3932 if { (ac_try="$ac_compile"
3933 case "(($ac_try" in
3934   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3935   *) ac_try_echo=$ac_try;;
3936 esac
3937 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3938 $as_echo "$ac_try_echo") >&5
3939   (eval "$ac_compile") 2>conftest.er1
3940   ac_status=$?
3941   grep -v '^ *+' conftest.er1 >conftest.err
3942   rm -f conftest.er1
3943   cat conftest.err >&5
3944   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3945   (exit $ac_status); } && {
3946          test -z "$ac_c_werror_flag" ||
3947          test ! -s conftest.err
3948        } && test -s conftest.$ac_objext; then
3949   SUN_STUDIO_CC=yes
3950 else
3951   $as_echo "$as_me: failed program was:" >&5
3952 sed 's/^/| /' conftest.$ac_ext >&5
3953
3954         SUN_STUDIO_CC=no
3955 fi
3956
3957 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3958
3959
3960
3961 unset CFLAGS
3962
3963 #
3964 # Read the template
3965 #
3966 . "$srcdir/src/template/$template" || exit
3967
3968 # CFLAGS are selected so:
3969 # If the user specifies something in the environment, that is used.
3970 # else:  If the template file set something, that is used.
3971 # else:  If coverage was enabled, don't set anything.
3972 # else:  If the compiler is GCC, then we use -O2.
3973 # else:  If the compiler is something else, then we use -O, unless debugging.
3974
3975 if test "$ac_env_CFLAGS_set" = set; then
3976   CFLAGS=$ac_env_CFLAGS_value
3977 elif test "${CFLAGS+set}" = set; then
3978   : # (keep what template set)
3979 elif test "$enable_coverage" = yes; then
3980   : # no optimization by default
3981 elif test "$GCC" = yes; then
3982   CFLAGS="-O2"
3983 else
3984   # if the user selected debug mode, don't use -O
3985   if test "$enable_debug" != yes; then
3986     CFLAGS="-O"
3987   fi
3988 fi
3989
3990 # Some versions of GCC support some additional useful warning flags.
3991 # Check whether they are supported, and add them to CFLAGS if so.
3992 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
3993 # but has its own.  Also check other compiler-specific flags here.
3994
3995 if test "$GCC" = yes -a "$ICC" = no; then
3996   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
3997   # These work in some but not all gcc versions
3998   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
3999 $as_echo_n "checking if $CC supports -Wdeclaration-after-statement... " >&6; }
4000 pgac_save_CFLAGS=$CFLAGS
4001 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
4002 cat >conftest.$ac_ext <<_ACEOF
4003 /* confdefs.h.  */
4004 _ACEOF
4005 cat confdefs.h >>conftest.$ac_ext
4006 cat >>conftest.$ac_ext <<_ACEOF
4007 /* end confdefs.h.  */
4008
4009 int
4010 main ()
4011 {
4012
4013   ;
4014   return 0;
4015 }
4016 _ACEOF
4017 rm -f conftest.$ac_objext
4018 if { (ac_try="$ac_compile"
4019 case "(($ac_try" in
4020   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4021   *) ac_try_echo=$ac_try;;
4022 esac
4023 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4024 $as_echo "$ac_try_echo") >&5
4025   (eval "$ac_compile") 2>conftest.er1
4026   ac_status=$?
4027   grep -v '^ *+' conftest.er1 >conftest.err
4028   rm -f conftest.er1
4029   cat conftest.err >&5
4030   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4031   (exit $ac_status); } && {
4032          test -z "$ac_c_werror_flag" ||
4033          test ! -s conftest.err
4034        } && test -s conftest.$ac_objext; then
4035   { $as_echo "$as_me:$LINENO: result: yes" >&5
4036 $as_echo "yes" >&6; }
4037 else
4038   $as_echo "$as_me: failed program was:" >&5
4039 sed 's/^/| /' conftest.$ac_ext >&5
4040
4041         CFLAGS="$pgac_save_CFLAGS"
4042                     { $as_echo "$as_me:$LINENO: result: no" >&5
4043 $as_echo "no" >&6; }
4044 fi
4045
4046 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4047
4048   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wendif-labels" >&5
4049 $as_echo_n "checking if $CC supports -Wendif-labels... " >&6; }
4050 pgac_save_CFLAGS=$CFLAGS
4051 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
4052 cat >conftest.$ac_ext <<_ACEOF
4053 /* confdefs.h.  */
4054 _ACEOF
4055 cat confdefs.h >>conftest.$ac_ext
4056 cat >>conftest.$ac_ext <<_ACEOF
4057 /* end confdefs.h.  */
4058
4059 int
4060 main ()
4061 {
4062
4063   ;
4064   return 0;
4065 }
4066 _ACEOF
4067 rm -f conftest.$ac_objext
4068 if { (ac_try="$ac_compile"
4069 case "(($ac_try" in
4070   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4071   *) ac_try_echo=$ac_try;;
4072 esac
4073 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4074 $as_echo "$ac_try_echo") >&5
4075   (eval "$ac_compile") 2>conftest.er1
4076   ac_status=$?
4077   grep -v '^ *+' conftest.er1 >conftest.err
4078   rm -f conftest.er1
4079   cat conftest.err >&5
4080   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4081   (exit $ac_status); } && {
4082          test -z "$ac_c_werror_flag" ||
4083          test ! -s conftest.err
4084        } && test -s conftest.$ac_objext; then
4085   { $as_echo "$as_me:$LINENO: result: yes" >&5
4086 $as_echo "yes" >&6; }
4087 else
4088   $as_echo "$as_me: failed program was:" >&5
4089 sed 's/^/| /' conftest.$ac_ext >&5
4090
4091         CFLAGS="$pgac_save_CFLAGS"
4092                     { $as_echo "$as_me:$LINENO: result: no" >&5
4093 $as_echo "no" >&6; }
4094 fi
4095
4096 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4097
4098   # Disable strict-aliasing rules; needed for gcc 3.3+
4099   { $as_echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
4100 $as_echo_n "checking if $CC supports -fno-strict-aliasing... " >&6; }
4101 pgac_save_CFLAGS=$CFLAGS
4102 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4103 cat >conftest.$ac_ext <<_ACEOF
4104 /* confdefs.h.  */
4105 _ACEOF
4106 cat confdefs.h >>conftest.$ac_ext
4107 cat >>conftest.$ac_ext <<_ACEOF
4108 /* end confdefs.h.  */
4109
4110 int
4111 main ()
4112 {
4113
4114   ;
4115   return 0;
4116 }
4117 _ACEOF
4118 rm -f conftest.$ac_objext
4119 if { (ac_try="$ac_compile"
4120 case "(($ac_try" in
4121   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4122   *) ac_try_echo=$ac_try;;
4123 esac
4124 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4125 $as_echo "$ac_try_echo") >&5
4126   (eval "$ac_compile") 2>conftest.er1
4127   ac_status=$?
4128   grep -v '^ *+' conftest.er1 >conftest.err
4129   rm -f conftest.er1
4130   cat conftest.err >&5
4131   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4132   (exit $ac_status); } && {
4133          test -z "$ac_c_werror_flag" ||
4134          test ! -s conftest.err
4135        } && test -s conftest.$ac_objext; then
4136   { $as_echo "$as_me:$LINENO: result: yes" >&5
4137 $as_echo "yes" >&6; }
4138 else
4139   $as_echo "$as_me: failed program was:" >&5
4140 sed 's/^/| /' conftest.$ac_ext >&5
4141
4142         CFLAGS="$pgac_save_CFLAGS"
4143                     { $as_echo "$as_me:$LINENO: result: no" >&5
4144 $as_echo "no" >&6; }
4145 fi
4146
4147 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4148
4149   # Disable optimizations that assume no overflow; needed for gcc 4.3+
4150   { $as_echo "$as_me:$LINENO: checking if $CC supports -fwrapv" >&5
4151 $as_echo_n "checking if $CC supports -fwrapv... " >&6; }
4152 pgac_save_CFLAGS=$CFLAGS
4153 CFLAGS="$pgac_save_CFLAGS -fwrapv"
4154 cat >conftest.$ac_ext <<_ACEOF
4155 /* confdefs.h.  */
4156 _ACEOF
4157 cat confdefs.h >>conftest.$ac_ext
4158 cat >>conftest.$ac_ext <<_ACEOF
4159 /* end confdefs.h.  */
4160
4161 int
4162 main ()
4163 {
4164
4165   ;
4166   return 0;
4167 }
4168 _ACEOF
4169 rm -f conftest.$ac_objext
4170 if { (ac_try="$ac_compile"
4171 case "(($ac_try" in
4172   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4173   *) ac_try_echo=$ac_try;;
4174 esac
4175 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4176 $as_echo "$ac_try_echo") >&5
4177   (eval "$ac_compile") 2>conftest.er1
4178   ac_status=$?
4179   grep -v '^ *+' conftest.er1 >conftest.err
4180   rm -f conftest.er1
4181   cat conftest.err >&5
4182   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4183   (exit $ac_status); } && {
4184          test -z "$ac_c_werror_flag" ||
4185          test ! -s conftest.err
4186        } && test -s conftest.$ac_objext; then
4187   { $as_echo "$as_me:$LINENO: result: yes" >&5
4188 $as_echo "yes" >&6; }
4189 else
4190   $as_echo "$as_me: failed program was:" >&5
4191 sed 's/^/| /' conftest.$ac_ext >&5
4192
4193         CFLAGS="$pgac_save_CFLAGS"
4194                     { $as_echo "$as_me:$LINENO: result: no" >&5
4195 $as_echo "no" >&6; }
4196 fi
4197
4198 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4199
4200 elif test "$ICC" = yes; then
4201   # Intel's compiler has a bug/misoptimization in checking for
4202   # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
4203   { $as_echo "$as_me:$LINENO: checking if $CC supports -mp1" >&5
4204 $as_echo_n "checking if $CC supports -mp1... " >&6; }
4205 pgac_save_CFLAGS=$CFLAGS
4206 CFLAGS="$pgac_save_CFLAGS -mp1"
4207 cat >conftest.$ac_ext <<_ACEOF
4208 /* confdefs.h.  */
4209 _ACEOF
4210 cat confdefs.h >>conftest.$ac_ext
4211 cat >>conftest.$ac_ext <<_ACEOF
4212 /* end confdefs.h.  */
4213
4214 int
4215 main ()
4216 {
4217
4218   ;
4219   return 0;
4220 }
4221 _ACEOF
4222 rm -f conftest.$ac_objext
4223 if { (ac_try="$ac_compile"
4224 case "(($ac_try" in
4225   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4226   *) ac_try_echo=$ac_try;;
4227 esac
4228 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4229 $as_echo "$ac_try_echo") >&5
4230   (eval "$ac_compile") 2>conftest.er1
4231   ac_status=$?
4232   grep -v '^ *+' conftest.er1 >conftest.err
4233   rm -f conftest.er1
4234   cat conftest.err >&5
4235   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4236   (exit $ac_status); } && {
4237          test -z "$ac_c_werror_flag" ||
4238          test ! -s conftest.err
4239        } && test -s conftest.$ac_objext; then
4240   { $as_echo "$as_me:$LINENO: result: yes" >&5
4241 $as_echo "yes" >&6; }
4242 else
4243   $as_echo "$as_me: failed program was:" >&5
4244 sed 's/^/| /' conftest.$ac_ext >&5
4245
4246         CFLAGS="$pgac_save_CFLAGS"
4247                     { $as_echo "$as_me:$LINENO: result: no" >&5
4248 $as_echo "no" >&6; }
4249 fi
4250
4251 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4252
4253   # Make sure strict aliasing is off (though this is said to be the default)
4254   { $as_echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
4255 $as_echo_n "checking if $CC supports -fno-strict-aliasing... " >&6; }
4256 pgac_save_CFLAGS=$CFLAGS
4257 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4258 cat >conftest.$ac_ext <<_ACEOF
4259 /* confdefs.h.  */
4260 _ACEOF
4261 cat confdefs.h >>conftest.$ac_ext
4262 cat >>conftest.$ac_ext <<_ACEOF
4263 /* end confdefs.h.  */
4264
4265 int
4266 main ()
4267 {
4268
4269   ;
4270   return 0;
4271 }
4272 _ACEOF
4273 rm -f conftest.$ac_objext
4274 if { (ac_try="$ac_compile"
4275 case "(($ac_try" in
4276   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4277   *) ac_try_echo=$ac_try;;
4278 esac
4279 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4280 $as_echo "$ac_try_echo") >&5
4281   (eval "$ac_compile") 2>conftest.er1
4282   ac_status=$?
4283   grep -v '^ *+' conftest.er1 >conftest.err
4284   rm -f conftest.er1
4285   cat conftest.err >&5
4286   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4287   (exit $ac_status); } && {
4288          test -z "$ac_c_werror_flag" ||
4289          test ! -s conftest.err
4290        } && test -s conftest.$ac_objext; then
4291   { $as_echo "$as_me:$LINENO: result: yes" >&5
4292 $as_echo "yes" >&6; }
4293 else
4294   $as_echo "$as_me: failed program was:" >&5
4295 sed 's/^/| /' conftest.$ac_ext >&5
4296
4297         CFLAGS="$pgac_save_CFLAGS"
4298                     { $as_echo "$as_me:$LINENO: result: no" >&5
4299 $as_echo "no" >&6; }
4300 fi
4301
4302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4303
4304 elif test "$PORTNAME" = "aix"; then
4305   # AIX's xlc has to have strict aliasing turned off too
4306   { $as_echo "$as_me:$LINENO: checking if $CC supports -qnoansialias" >&5
4307 $as_echo_n "checking if $CC supports -qnoansialias... " >&6; }
4308 pgac_save_CFLAGS=$CFLAGS
4309 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
4310 cat >conftest.$ac_ext <<_ACEOF
4311 /* confdefs.h.  */
4312 _ACEOF
4313 cat confdefs.h >>conftest.$ac_ext
4314 cat >>conftest.$ac_ext <<_ACEOF
4315 /* end confdefs.h.  */
4316
4317 int
4318 main ()
4319 {
4320
4321   ;
4322   return 0;
4323 }
4324 _ACEOF
4325 rm -f conftest.$ac_objext
4326 if { (ac_try="$ac_compile"
4327 case "(($ac_try" in
4328   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4329   *) ac_try_echo=$ac_try;;
4330 esac
4331 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4332 $as_echo "$ac_try_echo") >&5
4333   (eval "$ac_compile") 2>conftest.er1
4334   ac_status=$?
4335   grep -v '^ *+' conftest.er1 >conftest.err
4336   rm -f conftest.er1
4337   cat conftest.err >&5
4338   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4339   (exit $ac_status); } && {
4340          test -z "$ac_c_werror_flag" ||
4341          test ! -s conftest.err
4342        } && test -s conftest.$ac_objext; then
4343   { $as_echo "$as_me:$LINENO: result: yes" >&5
4344 $as_echo "yes" >&6; }
4345 else
4346   $as_echo "$as_me: failed program was:" >&5
4347 sed 's/^/| /' conftest.$ac_ext >&5
4348
4349         CFLAGS="$pgac_save_CFLAGS"
4350                     { $as_echo "$as_me:$LINENO: result: no" >&5
4351 $as_echo "no" >&6; }
4352 fi
4353
4354 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4355
4356 fi
4357
4358 # supply -g if --enable-debug
4359 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
4360   CFLAGS="$CFLAGS -g"
4361 fi
4362
4363 # enable code coverage if --enable-coverage
4364 if test "$enable_coverage" = yes; then
4365   if test "$GCC" = yes; then
4366     CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
4367   else
4368     { { $as_echo "$as_me:$LINENO: error: --enable-coverage is supported only when using GCC" >&5
4369 $as_echo "$as_me: error: --enable-coverage is supported only when using GCC" >&2;}
4370    { (exit 1); exit 1; }; }
4371   fi
4372 fi
4373
4374 # enable profiling if --enable-profiling
4375 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
4376   if test "$GCC" = yes; then
4377
4378 cat >>confdefs.h <<\_ACEOF
4379 #define PROFILE_PID_DIR 1
4380 _ACEOF
4381
4382     CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
4383   else
4384     { { $as_echo "$as_me:$LINENO: error: --enable-profiling is supported only when using GCC" >&5
4385 $as_echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
4386    { (exit 1); exit 1; }; }
4387   fi
4388 fi
4389
4390 # We already have this in Makefile.win32, but configure needs it too
4391 if test "$PORTNAME" = "win32"; then
4392   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
4393 fi
4394
4395 # Check if the compiler still works with the template settings
4396 { $as_echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
4397 $as_echo_n "checking whether the C compiler still works... " >&6; }
4398 cat >conftest.$ac_ext <<_ACEOF
4399 /* confdefs.h.  */
4400 _ACEOF
4401 cat confdefs.h >>conftest.$ac_ext
4402 cat >>conftest.$ac_ext <<_ACEOF
4403 /* end confdefs.h.  */
4404
4405 int
4406 main ()
4407 {
4408 return 0;
4409   ;
4410   return 0;
4411 }
4412 _ACEOF
4413 rm -f conftest.$ac_objext conftest$ac_exeext
4414 if { (ac_try="$ac_link"
4415 case "(($ac_try" in
4416   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4417   *) ac_try_echo=$ac_try;;
4418 esac
4419 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4420 $as_echo "$ac_try_echo") >&5
4421   (eval "$ac_link") 2>conftest.er1
4422   ac_status=$?
4423   grep -v '^ *+' conftest.er1 >conftest.err
4424   rm -f conftest.er1
4425   cat conftest.err >&5
4426   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4427   (exit $ac_status); } && {
4428          test -z "$ac_c_werror_flag" ||
4429          test ! -s conftest.err
4430        } && test -s conftest$ac_exeext && {
4431          test "$cross_compiling" = yes ||
4432          $as_test_x conftest$ac_exeext
4433        }; then
4434   { $as_echo "$as_me:$LINENO: result: yes" >&5
4435 $as_echo "yes" >&6; }
4436 else
4437   $as_echo "$as_me: failed program was:" >&5
4438 sed 's/^/| /' conftest.$ac_ext >&5
4439
4440         { $as_echo "$as_me:$LINENO: result: no" >&5
4441 $as_echo "no" >&6; }
4442    { { $as_echo "$as_me:$LINENO: error: cannot proceed" >&5
4443 $as_echo "$as_me: error: cannot proceed" >&2;}
4444    { (exit 1); exit 1; }; }
4445 fi
4446
4447 rm -rf conftest.dSYM
4448 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
4449       conftest$ac_exeext conftest.$ac_ext
4450
4451 # Defend against gcc -ffast-math
4452 if test "$GCC" = yes; then
4453 cat >conftest.$ac_ext <<_ACEOF
4454 /* confdefs.h.  */
4455 _ACEOF
4456 cat confdefs.h >>conftest.$ac_ext
4457 cat >>conftest.$ac_ext <<_ACEOF
4458 /* end confdefs.h.  */
4459
4460 int
4461 main ()
4462 {
4463 #ifdef __FAST_MATH__
4464 choke me
4465 #endif
4466   ;
4467   return 0;
4468 }
4469 _ACEOF
4470 rm -f conftest.$ac_objext
4471 if { (ac_try="$ac_compile"
4472 case "(($ac_try" in
4473   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4474   *) ac_try_echo=$ac_try;;
4475 esac
4476 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4477 $as_echo "$ac_try_echo") >&5
4478   (eval "$ac_compile") 2>conftest.er1
4479   ac_status=$?
4480   grep -v '^ *+' conftest.er1 >conftest.err
4481   rm -f conftest.er1
4482   cat conftest.err >&5
4483   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4484   (exit $ac_status); } && {
4485          test -z "$ac_c_werror_flag" ||
4486          test ! -s conftest.err
4487        } && test -s conftest.$ac_objext; then
4488   :
4489 else
4490   $as_echo "$as_me: failed program was:" >&5
4491 sed 's/^/| /' conftest.$ac_ext >&5
4492
4493         { { $as_echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
4494 $as_echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
4495    { (exit 1); exit 1; }; }
4496 fi
4497
4498 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4499 fi
4500
4501 ac_ext=c
4502 ac_cpp='$CPP $CPPFLAGS'
4503 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4504 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4505 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4506 { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4507 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4508 # On Suns, sometimes $CPP names a directory.
4509 if test -n "$CPP" && test -d "$CPP"; then
4510   CPP=
4511 fi
4512 if test -z "$CPP"; then
4513   if test "${ac_cv_prog_CPP+set}" = set; then
4514   $as_echo_n "(cached) " >&6
4515 else
4516       # Double quotes because CPP needs to be expanded
4517     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4518     do
4519       ac_preproc_ok=false
4520 for ac_c_preproc_warn_flag in '' yes
4521 do
4522   # Use a header file that comes with gcc, so configuring glibc
4523   # with a fresh cross-compiler works.
4524   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4525   # <limits.h> exists even on freestanding compilers.
4526   # On the NeXT, cc -E runs the code through the compiler's parser,
4527   # not just through cpp. "Syntax error" is here to catch this case.
4528   cat >conftest.$ac_ext <<_ACEOF
4529 /* confdefs.h.  */
4530 _ACEOF
4531 cat confdefs.h >>conftest.$ac_ext
4532 cat >>conftest.$ac_ext <<_ACEOF
4533 /* end confdefs.h.  */
4534 #ifdef __STDC__
4535 # include <limits.h>
4536 #else
4537 # include <assert.h>
4538 #endif
4539                      Syntax error
4540 _ACEOF
4541 if { (ac_try="$ac_cpp conftest.$ac_ext"
4542 case "(($ac_try" in
4543   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4544   *) ac_try_echo=$ac_try;;
4545 esac
4546 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4547 $as_echo "$ac_try_echo") >&5
4548   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4549   ac_status=$?
4550   grep -v '^ *+' conftest.er1 >conftest.err
4551   rm -f conftest.er1
4552   cat conftest.err >&5
4553   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4554   (exit $ac_status); } >/dev/null && {
4555          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4556          test ! -s conftest.err
4557        }; then
4558   :
4559 else
4560   $as_echo "$as_me: failed program was:" >&5
4561 sed 's/^/| /' conftest.$ac_ext >&5
4562
4563   # Broken: fails on valid input.
4564 continue
4565 fi
4566
4567 rm -f conftest.err conftest.$ac_ext
4568
4569   # OK, works on sane cases.  Now check whether nonexistent headers
4570   # can be detected and how.
4571   cat >conftest.$ac_ext <<_ACEOF
4572 /* confdefs.h.  */
4573 _ACEOF
4574 cat confdefs.h >>conftest.$ac_ext
4575 cat >>conftest.$ac_ext <<_ACEOF
4576 /* end confdefs.h.  */
4577 #include <ac_nonexistent.h>
4578 _ACEOF
4579 if { (ac_try="$ac_cpp conftest.$ac_ext"
4580 case "(($ac_try" in
4581   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4582   *) ac_try_echo=$ac_try;;
4583 esac
4584 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4585 $as_echo "$ac_try_echo") >&5
4586   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4587   ac_status=$?
4588   grep -v '^ *+' conftest.er1 >conftest.err
4589   rm -f conftest.er1
4590   cat conftest.err >&5
4591   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4592   (exit $ac_status); } >/dev/null && {
4593          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4594          test ! -s conftest.err
4595        }; then
4596   # Broken: success on invalid input.
4597 continue
4598 else
4599   $as_echo "$as_me: failed program was:" >&5
4600 sed 's/^/| /' conftest.$ac_ext >&5
4601
4602   # Passes both tests.
4603 ac_preproc_ok=:
4604 break
4605 fi
4606
4607 rm -f conftest.err conftest.$ac_ext
4608
4609 done
4610 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4611 rm -f conftest.err conftest.$ac_ext
4612 if $ac_preproc_ok; then
4613   break
4614 fi
4615
4616     done
4617     ac_cv_prog_CPP=$CPP
4618
4619 fi
4620   CPP=$ac_cv_prog_CPP
4621 else
4622   ac_cv_prog_CPP=$CPP
4623 fi
4624 { $as_echo "$as_me:$LINENO: result: $CPP" >&5
4625 $as_echo "$CPP" >&6; }
4626 ac_preproc_ok=false
4627 for ac_c_preproc_warn_flag in '' yes
4628 do
4629   # Use a header file that comes with gcc, so configuring glibc
4630   # with a fresh cross-compiler works.
4631   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4632   # <limits.h> exists even on freestanding compilers.
4633   # On the NeXT, cc -E runs the code through the compiler's parser,
4634   # not just through cpp. "Syntax error" is here to catch this case.
4635   cat >conftest.$ac_ext <<_ACEOF
4636 /* confdefs.h.  */
4637 _ACEOF
4638 cat confdefs.h >>conftest.$ac_ext
4639 cat >>conftest.$ac_ext <<_ACEOF
4640 /* end confdefs.h.  */
4641 #ifdef __STDC__
4642 # include <limits.h>
4643 #else
4644 # include <assert.h>
4645 #endif
4646                      Syntax error
4647 _ACEOF
4648 if { (ac_try="$ac_cpp conftest.$ac_ext"
4649 case "(($ac_try" in
4650   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4651   *) ac_try_echo=$ac_try;;
4652 esac
4653 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4654 $as_echo "$ac_try_echo") >&5
4655   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4656   ac_status=$?
4657   grep -v '^ *+' conftest.er1 >conftest.err
4658   rm -f conftest.er1
4659   cat conftest.err >&5
4660   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4661   (exit $ac_status); } >/dev/null && {
4662          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4663          test ! -s conftest.err
4664        }; then
4665   :
4666 else
4667   $as_echo "$as_me: failed program was:" >&5
4668 sed 's/^/| /' conftest.$ac_ext >&5
4669
4670   # Broken: fails on valid input.
4671 continue
4672 fi
4673
4674 rm -f conftest.err conftest.$ac_ext
4675
4676   # OK, works on sane cases.  Now check whether nonexistent headers
4677   # can be detected and how.
4678   cat >conftest.$ac_ext <<_ACEOF
4679 /* confdefs.h.  */
4680 _ACEOF
4681 cat confdefs.h >>conftest.$ac_ext
4682 cat >>conftest.$ac_ext <<_ACEOF
4683 /* end confdefs.h.  */
4684 #include <ac_nonexistent.h>
4685 _ACEOF
4686 if { (ac_try="$ac_cpp conftest.$ac_ext"
4687 case "(($ac_try" in
4688   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4689   *) ac_try_echo=$ac_try;;
4690 esac
4691 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4692 $as_echo "$ac_try_echo") >&5
4693   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4694   ac_status=$?
4695   grep -v '^ *+' conftest.er1 >conftest.err
4696   rm -f conftest.er1
4697   cat conftest.err >&5
4698   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4699   (exit $ac_status); } >/dev/null && {
4700          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4701          test ! -s conftest.err
4702        }; then
4703   # Broken: success on invalid input.
4704 continue
4705 else
4706   $as_echo "$as_me: failed program was:" >&5
4707 sed 's/^/| /' conftest.$ac_ext >&5
4708
4709   # Passes both tests.
4710 ac_preproc_ok=:
4711 break
4712 fi
4713
4714 rm -f conftest.err conftest.$ac_ext
4715
4716 done
4717 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4718 rm -f conftest.err conftest.$ac_ext
4719 if $ac_preproc_ok; then
4720   :
4721 else
4722   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4723 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4724 { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4725 See \`config.log' for more details." >&5
4726 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4727 See \`config.log' for more details." >&2;}
4728    { (exit 1); exit 1; }; }; }
4729 fi
4730
4731 ac_ext=c
4732 ac_cpp='$CPP $CPPFLAGS'
4733 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4734 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4735 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4736
4737
4738
4739
4740 #
4741 # Set up TAS assembly code if needed; the template file has now had its
4742 # chance to request this.
4743 #
4744 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
4745
4746
4747 if test "$need_tas" = yes ; then
4748   TAS=tas.o
4749 else
4750   TAS=""
4751 fi
4752
4753
4754
4755 #
4756 # Automatic dependency tracking
4757 #
4758
4759
4760 # Check whether --enable-depend was given.
4761 if test "${enable_depend+set}" = set; then
4762   enableval=$enable_depend;
4763   case $enableval in
4764     yes)
4765       autodepend=yes
4766       ;;
4767     no)
4768       :
4769       ;;
4770     *)
4771       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
4772 $as_echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
4773    { (exit 1); exit 1; }; }
4774       ;;
4775   esac
4776
4777 else
4778   enable_depend=no
4779
4780 fi
4781
4782
4783
4784
4785
4786 #
4787 # Enable assert checks
4788 #
4789
4790
4791 # Check whether --enable-cassert was given.
4792 if test "${enable_cassert+set}" = set; then
4793   enableval=$enable_cassert;
4794   case $enableval in
4795     yes)
4796
4797 cat >>confdefs.h <<\_ACEOF
4798 #define USE_ASSERT_CHECKING 1
4799 _ACEOF
4800
4801       ;;
4802     no)
4803       :
4804       ;;
4805     *)
4806       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
4807 $as_echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
4808    { (exit 1); exit 1; }; }
4809       ;;
4810   esac
4811
4812 else
4813   enable_cassert=no
4814
4815 fi
4816
4817
4818
4819
4820 #
4821 # Include directories
4822 #
4823 ac_save_IFS=$IFS
4824 IFS="${IFS}${PATH_SEPARATOR}"
4825 # SRCH_INC comes from the template file
4826 for dir in $with_includes $SRCH_INC; do
4827   if test -d "$dir"; then
4828     INCLUDES="$INCLUDES -I$dir"
4829   else
4830     { $as_echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
4831 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
4832   fi
4833 done
4834 IFS=$ac_save_IFS
4835
4836
4837
4838 #
4839 # Library directories
4840 #
4841 ac_save_IFS=$IFS
4842 IFS="${IFS}${PATH_SEPARATOR}"
4843 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
4844 for dir in $LIBRARY_DIRS $SRCH_LIB; do
4845   if test -d "$dir"; then
4846     LIBDIRS="$LIBDIRS -L$dir"
4847   else
4848     { $as_echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
4849 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
4850   fi
4851 done
4852 IFS=$ac_save_IFS
4853
4854 #
4855 # Enable thread-safe client libraries
4856 #
4857 { $as_echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
4858 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
4859
4860
4861 # Check whether --enable-thread-safety was given.
4862 if test "${enable_thread_safety+set}" = set; then
4863   enableval=$enable_thread_safety;
4864   case $enableval in
4865     yes)
4866       :
4867       ;;
4868     no)
4869       :
4870       ;;
4871     *)
4872       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
4873 $as_echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
4874    { (exit 1); exit 1; }; }
4875       ;;
4876   esac
4877
4878 else
4879   enable_thread_safety=yes
4880
4881 fi
4882
4883
4884 if test "$enable_thread_safety" = yes; then
4885
4886 cat >>confdefs.h <<\_ACEOF
4887 #define ENABLE_THREAD_SAFETY 1
4888 _ACEOF
4889
4890 fi
4891 { $as_echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
4892 $as_echo "$enable_thread_safety" >&6; }
4893
4894
4895 #
4896 # Optionally build Tcl modules (PL/Tcl)
4897 #
4898 { $as_echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
4899 $as_echo_n "checking whether to build with Tcl... " >&6; }
4900
4901
4902
4903 # Check whether --with-tcl was given.
4904 if test "${with_tcl+set}" = set; then
4905   withval=$with_tcl;
4906   case $withval in
4907     yes)
4908       :
4909       ;;
4910     no)
4911       :
4912       ;;
4913     *)
4914       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
4915 $as_echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
4916    { (exit 1); exit 1; }; }
4917       ;;
4918   esac
4919
4920 else
4921   with_tcl=no
4922
4923 fi
4924
4925
4926 { $as_echo "$as_me:$LINENO: result: $with_tcl" >&5
4927 $as_echo "$with_tcl" >&6; }
4928
4929
4930 # We see if the path to the Tcl/Tk configuration scripts is specified.
4931 # This will override the use of tclsh to find the paths to search.
4932
4933
4934
4935
4936 # Check whether --with-tclconfig was given.
4937 if test "${with_tclconfig+set}" = set; then
4938   withval=$with_tclconfig;
4939   case $withval in
4940     yes)
4941       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4942 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
4943    { (exit 1); exit 1; }; }
4944       ;;
4945     no)
4946       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4947 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
4948    { (exit 1); exit 1; }; }
4949       ;;
4950     *)
4951
4952       ;;
4953   esac
4954
4955 fi
4956
4957
4958
4959 #
4960 # Optionally build Perl modules (PL/Perl)
4961 #
4962 { $as_echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
4963 $as_echo_n "checking whether to build Perl modules... " >&6; }
4964
4965
4966
4967 # Check whether --with-perl was given.
4968 if test "${with_perl+set}" = set; then
4969   withval=$with_perl;
4970   case $withval in
4971     yes)
4972       :
4973       ;;
4974     no)
4975       :
4976       ;;
4977     *)
4978       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
4979 $as_echo "$as_me: error: no argument expected for --with-perl option" >&2;}
4980    { (exit 1); exit 1; }; }
4981       ;;
4982   esac
4983
4984 else
4985   with_perl=no
4986
4987 fi
4988
4989
4990 { $as_echo "$as_me:$LINENO: result: $with_perl" >&5
4991 $as_echo "$with_perl" >&6; }
4992
4993
4994 #
4995 # Optionally build Python modules (PL/Python)
4996 #
4997 { $as_echo "$as_me:$LINENO: checking whether to build Python modules" >&5
4998 $as_echo_n "checking whether to build Python modules... " >&6; }
4999
5000
5001
5002 # Check whether --with-python was given.
5003 if test "${with_python+set}" = set; then
5004   withval=$with_python;
5005   case $withval in
5006     yes)
5007       :
5008       ;;
5009     no)
5010       :
5011       ;;
5012     *)
5013       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
5014 $as_echo "$as_me: error: no argument expected for --with-python option" >&2;}
5015    { (exit 1); exit 1; }; }
5016       ;;
5017   esac
5018
5019 else
5020   with_python=no
5021
5022 fi
5023
5024
5025 { $as_echo "$as_me:$LINENO: result: $with_python" >&5
5026 $as_echo "$with_python" >&6; }
5027
5028
5029 #
5030 # GSSAPI
5031 #
5032 { $as_echo "$as_me:$LINENO: checking whether to build with GSSAPI support" >&5
5033 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
5034
5035
5036
5037 # Check whether --with-gssapi was given.
5038 if test "${with_gssapi+set}" = set; then
5039   withval=$with_gssapi;
5040   case $withval in
5041     yes)
5042
5043
5044 cat >>confdefs.h <<\_ACEOF
5045 #define ENABLE_GSS 1
5046 _ACEOF
5047
5048   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5049
5050       ;;
5051     no)
5052       :
5053       ;;
5054     *)
5055       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-gssapi option" >&5
5056 $as_echo "$as_me: error: no argument expected for --with-gssapi option" >&2;}
5057    { (exit 1); exit 1; }; }
5058       ;;
5059   esac
5060
5061 else
5062   with_gssapi=no
5063
5064 fi
5065
5066
5067 { $as_echo "$as_me:$LINENO: result: $with_gssapi" >&5
5068 $as_echo "$with_gssapi" >&6; }
5069
5070
5071 #
5072 # Kerberos 5
5073 #
5074 { $as_echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
5075 $as_echo_n "checking whether to build with Kerberos 5 support... " >&6; }
5076
5077
5078
5079 # Check whether --with-krb5 was given.
5080 if test "${with_krb5+set}" = set; then
5081   withval=$with_krb5;
5082   case $withval in
5083     yes)
5084
5085
5086 cat >>confdefs.h <<\_ACEOF
5087 #define KRB5 1
5088 _ACEOF
5089
5090   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5091
5092       ;;
5093     no)
5094       :
5095       ;;
5096     *)
5097       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
5098 $as_echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
5099    { (exit 1); exit 1; }; }
5100       ;;
5101   esac
5102
5103 else
5104   with_krb5=no
5105
5106 fi
5107
5108
5109 { $as_echo "$as_me:$LINENO: result: $with_krb5" >&5
5110 $as_echo "$with_krb5" >&6; }
5111
5112
5113
5114
5115
5116
5117 #
5118 # Kerberos configuration parameters
5119 #
5120
5121
5122
5123 # Check whether --with-krb-srvnam was given.
5124 if test "${with_krb_srvnam+set}" = set; then
5125   withval=$with_krb_srvnam;
5126   case $withval in
5127     yes)
5128       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5129 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5130    { (exit 1); exit 1; }; }
5131       ;;
5132     no)
5133       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5134 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5135    { (exit 1); exit 1; }; }
5136       ;;
5137     *)
5138
5139       ;;
5140   esac
5141
5142 else
5143   with_krb_srvnam="postgres"
5144 fi
5145
5146
5147
5148 cat >>confdefs.h <<_ACEOF
5149 #define PG_KRB_SRVNAM "$with_krb_srvnam"
5150 _ACEOF
5151
5152
5153
5154 #
5155 # PAM
5156 #
5157 { $as_echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
5158 $as_echo_n "checking whether to build with PAM support... " >&6; }
5159
5160
5161
5162 # Check whether --with-pam was given.
5163 if test "${with_pam+set}" = set; then
5164   withval=$with_pam;
5165   case $withval in
5166     yes)
5167
5168 cat >>confdefs.h <<\_ACEOF
5169 #define USE_PAM 1
5170 _ACEOF
5171
5172       ;;
5173     no)
5174       :
5175       ;;
5176     *)
5177       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
5178 $as_echo "$as_me: error: no argument expected for --with-pam option" >&2;}
5179    { (exit 1); exit 1; }; }
5180       ;;
5181   esac
5182
5183 else
5184   with_pam=no
5185
5186 fi
5187
5188
5189 { $as_echo "$as_me:$LINENO: result: $with_pam" >&5
5190 $as_echo "$with_pam" >&6; }
5191
5192
5193
5194 #
5195 # LDAP
5196 #
5197 { $as_echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
5198 $as_echo_n "checking whether to build with LDAP support... " >&6; }
5199
5200
5201
5202 # Check whether --with-ldap was given.
5203 if test "${with_ldap+set}" = set; then
5204   withval=$with_ldap;
5205   case $withval in
5206     yes)
5207
5208 cat >>confdefs.h <<\_ACEOF
5209 #define USE_LDAP 1
5210 _ACEOF
5211
5212       ;;
5213     no)
5214       :
5215       ;;
5216     *)
5217       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
5218 $as_echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
5219    { (exit 1); exit 1; }; }
5220       ;;
5221   esac
5222
5223 else
5224   with_ldap=no
5225
5226 fi
5227
5228
5229 { $as_echo "$as_me:$LINENO: result: $with_ldap" >&5
5230 $as_echo "$with_ldap" >&6; }
5231
5232
5233
5234 #
5235 # Bonjour
5236 #
5237 { $as_echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
5238 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
5239
5240
5241
5242 # Check whether --with-bonjour was given.
5243 if test "${with_bonjour+set}" = set; then
5244   withval=$with_bonjour;
5245   case $withval in
5246     yes)
5247
5248 cat >>confdefs.h <<\_ACEOF
5249 #define USE_BONJOUR 1
5250 _ACEOF
5251
5252       ;;
5253     no)
5254       :
5255       ;;
5256     *)
5257       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
5258 $as_echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
5259    { (exit 1); exit 1; }; }
5260       ;;
5261   esac
5262
5263 else
5264   with_bonjour=no
5265
5266 fi
5267
5268
5269 { $as_echo "$as_me:$LINENO: result: $with_bonjour" >&5
5270 $as_echo "$with_bonjour" >&6; }
5271
5272
5273
5274 #
5275 # OpenSSL
5276 #
5277 { $as_echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
5278 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
5279
5280
5281
5282 # Check whether --with-openssl was given.
5283 if test "${with_openssl+set}" = set; then
5284   withval=$with_openssl;
5285   case $withval in
5286     yes)
5287
5288 cat >>confdefs.h <<\_ACEOF
5289 #define USE_SSL 1
5290 _ACEOF
5291
5292       ;;
5293     no)
5294       :
5295       ;;
5296     *)
5297       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
5298 $as_echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
5299    { (exit 1); exit 1; }; }
5300       ;;
5301   esac
5302
5303 else
5304   with_openssl=no
5305
5306 fi
5307
5308
5309 { $as_echo "$as_me:$LINENO: result: $with_openssl" >&5
5310 $as_echo "$with_openssl" >&6; }
5311
5312
5313
5314 #
5315 # Readline
5316 #
5317
5318
5319
5320 # Check whether --with-readline was given.
5321 if test "${with_readline+set}" = set; then
5322   withval=$with_readline;
5323   case $withval in
5324     yes)
5325       :
5326       ;;
5327     no)
5328       :
5329       ;;
5330     *)
5331       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
5332 $as_echo "$as_me: error: no argument expected for --with-readline option" >&2;}
5333    { (exit 1); exit 1; }; }
5334       ;;
5335   esac
5336
5337 else
5338   with_readline=yes
5339
5340 fi
5341
5342
5343 # readline on MinGW has problems with backslashes in psql and other bugs.
5344 # This is particularly a problem with non-US code pages.
5345 # Therefore disable its use until we understand the cause. 2004-07-20
5346 if test "$PORTNAME" = "win32"; then
5347   if test "$with_readline" = yes; then
5348     { $as_echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
5349 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
5350     with_readline=no
5351   fi
5352 fi
5353
5354
5355 #
5356 # Prefer libedit
5357 #
5358
5359
5360
5361 # Check whether --with-libedit-preferred was given.
5362 if test "${with_libedit_preferred+set}" = set; then
5363   withval=$with_libedit_preferred;
5364   case $withval in
5365     yes)
5366       :
5367       ;;
5368     no)
5369       :
5370       ;;
5371     *)
5372       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
5373 $as_echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
5374    { (exit 1); exit 1; }; }
5375       ;;
5376   esac
5377
5378 else
5379   with_libedit_preferred=no
5380
5381 fi
5382
5383
5384
5385
5386 #
5387 # OSSP UUID library
5388 #
5389
5390
5391
5392 # Check whether --with-ossp-uuid was given.
5393 if test "${with_ossp_uuid+set}" = set; then
5394   withval=$with_ossp_uuid;
5395   case $withval in
5396     yes)
5397       :
5398       ;;
5399     no)
5400       :
5401       ;;
5402     *)
5403       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ossp-uuid option" >&5
5404 $as_echo "$as_me: error: no argument expected for --with-ossp-uuid option" >&2;}
5405    { (exit 1); exit 1; }; }
5406       ;;
5407   esac
5408
5409 else
5410   with_ossp_uuid=no
5411
5412 fi
5413
5414
5415
5416
5417
5418 #
5419 # XML
5420 #
5421
5422
5423
5424 # Check whether --with-libxml was given.
5425 if test "${with_libxml+set}" = set; then
5426   withval=$with_libxml;
5427   case $withval in
5428     yes)
5429
5430 cat >>confdefs.h <<\_ACEOF
5431 #define USE_LIBXML 1
5432 _ACEOF
5433
5434       ;;
5435     no)
5436       :
5437       ;;
5438     *)
5439       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxml option" >&5
5440 $as_echo "$as_me: error: no argument expected for --with-libxml option" >&2;}
5441    { (exit 1); exit 1; }; }
5442       ;;
5443   esac
5444
5445 else
5446   with_libxml=no
5447
5448 fi
5449
5450
5451
5452 if test "$with_libxml" = yes ; then
5453   for ac_prog in xml2-config
5454 do
5455   # Extract the first word of "$ac_prog", so it can be a program name with args.
5456 set dummy $ac_prog; ac_word=$2
5457 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5458 $as_echo_n "checking for $ac_word... " >&6; }
5459 if test "${ac_cv_prog_XML2_CONFIG+set}" = set; then
5460   $as_echo_n "(cached) " >&6
5461 else
5462   if test -n "$XML2_CONFIG"; then
5463   ac_cv_prog_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test.
5464 else
5465 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5466 for as_dir in $PATH
5467 do
5468   IFS=$as_save_IFS
5469   test -z "$as_dir" && as_dir=.
5470   for ac_exec_ext in '' $ac_executable_extensions; do
5471   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5472     ac_cv_prog_XML2_CONFIG="$ac_prog"
5473     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5474     break 2
5475   fi
5476 done
5477 done
5478 IFS=$as_save_IFS
5479
5480 fi
5481 fi
5482 XML2_CONFIG=$ac_cv_prog_XML2_CONFIG
5483 if test -n "$XML2_CONFIG"; then
5484   { $as_echo "$as_me:$LINENO: result: $XML2_CONFIG" >&5
5485 $as_echo "$XML2_CONFIG" >&6; }
5486 else
5487   { $as_echo "$as_me:$LINENO: result: no" >&5
5488 $as_echo "no" >&6; }
5489 fi
5490
5491
5492   test -n "$XML2_CONFIG" && break
5493 done
5494
5495   if test -n "$XML2_CONFIG"; then
5496     for pgac_option in `$XML2_CONFIG --cflags`; do
5497       case $pgac_option in
5498         -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
5499       esac
5500     done
5501     for pgac_option in `$XML2_CONFIG --libs`; do
5502       case $pgac_option in
5503         -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5504       esac
5505     done
5506   fi
5507 fi
5508
5509
5510
5511 #
5512 # XSLT
5513 #
5514
5515
5516
5517 # Check whether --with-libxslt was given.
5518 if test "${with_libxslt+set}" = set; then
5519   withval=$with_libxslt;
5520   case $withval in
5521     yes)
5522
5523 cat >>confdefs.h <<\_ACEOF
5524 #define USE_LIBXSLT 1
5525 _ACEOF
5526
5527       ;;
5528     no)
5529       :
5530       ;;
5531     *)
5532       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxslt option" >&5
5533 $as_echo "$as_me: error: no argument expected for --with-libxslt option" >&2;}
5534    { (exit 1); exit 1; }; }
5535       ;;
5536   esac
5537
5538 else
5539   with_libxslt=no
5540
5541 fi
5542
5543
5544
5545
5546
5547
5548 #
5549 # tzdata
5550 #
5551
5552
5553
5554 # Check whether --with-system-tzdata was given.
5555 if test "${with_system_tzdata+set}" = set; then
5556   withval=$with_system_tzdata;
5557   case $withval in
5558     yes)
5559       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5560 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5561    { (exit 1); exit 1; }; }
5562       ;;
5563     no)
5564       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5565 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5566    { (exit 1); exit 1; }; }
5567       ;;
5568     *)
5569
5570       ;;
5571   esac
5572
5573 fi
5574
5575
5576
5577
5578 #
5579 # Zlib
5580 #
5581
5582
5583
5584 # Check whether --with-zlib was given.
5585 if test "${with_zlib+set}" = set; then
5586   withval=$with_zlib;
5587   case $withval in
5588     yes)
5589       :
5590       ;;
5591     no)
5592       :
5593       ;;
5594     *)
5595       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
5596 $as_echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
5597    { (exit 1); exit 1; }; }
5598       ;;
5599   esac
5600
5601 else
5602   with_zlib=yes
5603
5604 fi
5605
5606
5607
5608
5609 #
5610 # Elf
5611 #
5612
5613 # Assume system is ELF if it predefines __ELF__ as 1,
5614 # otherwise believe host_os based default.
5615 case $host_os in
5616     freebsd1*|freebsd2*) elf=no;;
5617     freebsd3*|freebsd4*) elf=yes;;
5618 esac
5619
5620
5621 { $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
5622 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5623 if test "${ac_cv_path_GREP+set}" = set; then
5624   $as_echo_n "(cached) " >&6
5625 else
5626   if test -z "$GREP"; then
5627   ac_path_GREP_found=false
5628   # Loop through the user's path and test for each of PROGNAME-LIST
5629   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5630 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5631 do
5632   IFS=$as_save_IFS
5633   test -z "$as_dir" && as_dir=.
5634   for ac_prog in grep ggrep; do
5635     for ac_exec_ext in '' $ac_executable_extensions; do
5636       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5637       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5638 # Check for GNU ac_path_GREP and select it if it is found.
5639   # Check for GNU $ac_path_GREP
5640 case `"$ac_path_GREP" --version 2>&1` in
5641 *GNU*)
5642   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5643 *)
5644   ac_count=0
5645   $as_echo_n 0123456789 >"conftest.in"
5646   while :
5647   do
5648     cat "conftest.in" "conftest.in" >"conftest.tmp"
5649     mv "conftest.tmp" "conftest.in"
5650     cp "conftest.in" "conftest.nl"
5651     $as_echo 'GREP' >> "conftest.nl"
5652     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5653     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5654     ac_count=`expr $ac_count + 1`
5655     if test $ac_count -gt ${ac_path_GREP_max-0}; then
5656       # Best one so far, save it but keep looking for a better one
5657       ac_cv_path_GREP="$ac_path_GREP"
5658       ac_path_GREP_max=$ac_count
5659     fi
5660     # 10*(2^10) chars as input seems more than enough
5661     test $ac_count -gt 10 && break
5662   done
5663   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5664 esac
5665
5666       $ac_path_GREP_found && break 3
5667     done
5668   done
5669 done
5670 IFS=$as_save_IFS
5671   if test -z "$ac_cv_path_GREP"; then
5672     { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5673 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5674    { (exit 1); exit 1; }; }
5675   fi
5676 else
5677   ac_cv_path_GREP=$GREP
5678 fi
5679
5680 fi
5681 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
5682 $as_echo "$ac_cv_path_GREP" >&6; }
5683  GREP="$ac_cv_path_GREP"
5684
5685
5686 { $as_echo "$as_me:$LINENO: checking for egrep" >&5
5687 $as_echo_n "checking for egrep... " >&6; }
5688 if test "${ac_cv_path_EGREP+set}" = set; then
5689   $as_echo_n "(cached) " >&6
5690 else
5691   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5692    then ac_cv_path_EGREP="$GREP -E"
5693    else
5694      if test -z "$EGREP"; then
5695   ac_path_EGREP_found=false
5696   # Loop through the user's path and test for each of PROGNAME-LIST
5697   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5698 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5699 do
5700   IFS=$as_save_IFS
5701   test -z "$as_dir" && as_dir=.
5702   for ac_prog in egrep; do
5703     for ac_exec_ext in '' $ac_executable_extensions; do
5704       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5705       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5706 # Check for GNU ac_path_EGREP and select it if it is found.
5707   # Check for GNU $ac_path_EGREP
5708 case `"$ac_path_EGREP" --version 2>&1` in
5709 *GNU*)
5710   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5711 *)
5712   ac_count=0
5713   $as_echo_n 0123456789 >"conftest.in"
5714   while :
5715   do
5716     cat "conftest.in" "conftest.in" >"conftest.tmp"
5717     mv "conftest.tmp" "conftest.in"
5718     cp "conftest.in" "conftest.nl"
5719     $as_echo 'EGREP' >> "conftest.nl"
5720     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5721     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5722     ac_count=`expr $ac_count + 1`
5723     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5724       # Best one so far, save it but keep looking for a better one
5725       ac_cv_path_EGREP="$ac_path_EGREP"
5726       ac_path_EGREP_max=$ac_count
5727     fi
5728     # 10*(2^10) chars as input seems more than enough
5729     test $ac_count -gt 10 && break
5730   done
5731   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5732 esac
5733
5734       $ac_path_EGREP_found && break 3
5735     done
5736   done
5737 done
5738 IFS=$as_save_IFS
5739   if test -z "$ac_cv_path_EGREP"; then
5740     { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5741 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5742    { (exit 1); exit 1; }; }
5743   fi
5744 else
5745   ac_cv_path_EGREP=$EGREP
5746 fi
5747
5748    fi
5749 fi
5750 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
5751 $as_echo "$ac_cv_path_EGREP" >&6; }
5752  EGREP="$ac_cv_path_EGREP"
5753
5754
5755 cat >conftest.$ac_ext <<_ACEOF
5756 /* confdefs.h.  */
5757 _ACEOF
5758 cat confdefs.h >>conftest.$ac_ext
5759 cat >>conftest.$ac_ext <<_ACEOF
5760 /* end confdefs.h.  */
5761 #if __ELF__
5762   yes
5763 #endif
5764
5765 _ACEOF
5766 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5767   $EGREP "yes" >/dev/null 2>&1; then
5768   ELF_SYS=true
5769 else
5770   if test "X$elf" = "Xyes" ; then
5771   ELF_SYS=true
5772 else
5773   ELF_SYS=
5774 fi
5775 fi
5776 rm -f conftest*
5777
5778
5779
5780 #
5781 # Assignments
5782 #
5783
5784 CPPFLAGS="$CPPFLAGS $INCLUDES"
5785 LDFLAGS="$LDFLAGS $LIBDIRS"
5786
5787
5788
5789
5790 # Check whether --with-gnu-ld was given.
5791 if test "${with_gnu_ld+set}" = set; then
5792   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
5793 else
5794   with_gnu_ld=no
5795 fi
5796
5797 ac_prog=ld
5798 if test "$GCC" = yes; then
5799   # Check if gcc -print-prog-name=ld gives a path.
5800   { $as_echo "$as_me:$LINENO: checking for ld used by GCC" >&5
5801 $as_echo_n "checking for ld used by GCC... " >&6; }
5802   case $host in
5803   *-*-mingw*)
5804     # gcc leaves a trailing carriage return which upsets mingw
5805     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5806   *)
5807     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5808   esac
5809   case "$ac_prog" in
5810     # Accept absolute paths.
5811     [\\/]* | [A-Za-z]:[\\/]*)
5812       re_direlt='/[^/][^/]*/\.\./'
5813       # Canonicalize the path of ld
5814       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
5815       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5816         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
5817       done
5818       test -z "$LD" && LD="$ac_prog"
5819       ;;
5820   "")
5821     # If it fails, then pretend we aren't using GCC.
5822     ac_prog=ld
5823     ;;
5824   *)
5825     # If it is relative, then search for the first ld in PATH.
5826     with_gnu_ld=unknown
5827     ;;
5828   esac
5829 elif test "$with_gnu_ld" = yes; then
5830   { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
5831 $as_echo_n "checking for GNU ld... " >&6; }
5832 else
5833   { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5834 $as_echo_n "checking for non-GNU ld... " >&6; }
5835 fi
5836 if test "${ac_cv_path_LD+set}" = set; then
5837   $as_echo_n "(cached) " >&6
5838 else
5839   if test -z "$LD"; then
5840   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
5841   for ac_dir in $PATH; do
5842     test -z "$ac_dir" && ac_dir=.
5843     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5844       ac_cv_path_LD="$ac_dir/$ac_prog"
5845       # Check to see if the program is GNU ld.  I'd rather use --version,
5846       # but apparently some GNU ld's only accept -v.
5847       # Break only if it was the GNU/non-GNU ld that we prefer.
5848       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
5849         test "$with_gnu_ld" != no && break
5850       else
5851         test "$with_gnu_ld" != yes && break
5852       fi
5853     fi
5854   done
5855   IFS="$ac_save_ifs"
5856 else
5857   ac_cv_path_LD="$LD" # Let the user override the test with a path.
5858 fi
5859 fi
5860
5861 LD="$ac_cv_path_LD"
5862 if test -n "$LD"; then
5863   { $as_echo "$as_me:$LINENO: result: $LD" >&5
5864 $as_echo "$LD" >&6; }
5865 else
5866   { $as_echo "$as_me:$LINENO: result: no" >&5
5867 $as_echo "no" >&6; }
5868 fi
5869 test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5870 $as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5871    { (exit 1); exit 1; }; }
5872 { $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5873 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
5874 if test "${ac_cv_prog_gnu_ld+set}" = set; then
5875   $as_echo_n "(cached) " >&6
5876 else
5877   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
5878 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
5879   ac_cv_prog_gnu_ld=yes
5880 else
5881   ac_cv_prog_gnu_ld=no
5882 fi
5883 fi
5884 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
5885 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
5886 with_gnu_ld=$ac_cv_prog_gnu_ld
5887
5888
5889
5890
5891 case $host_os in sysv5*)
5892   { $as_echo "$as_me:$LINENO: checking whether ld -R works" >&5
5893 $as_echo_n "checking whether ld -R works... " >&6; }
5894 if test "${pgac_cv_prog_ld_R+set}" = set; then
5895   $as_echo_n "(cached) " >&6
5896 else
5897
5898     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
5899     cat >conftest.$ac_ext <<_ACEOF
5900 /* confdefs.h.  */
5901 _ACEOF
5902 cat confdefs.h >>conftest.$ac_ext
5903 cat >>conftest.$ac_ext <<_ACEOF
5904 /* end confdefs.h.  */
5905
5906 int
5907 main ()
5908 {
5909
5910   ;
5911   return 0;
5912 }
5913 _ACEOF
5914 rm -f conftest.$ac_objext conftest$ac_exeext
5915 if { (ac_try="$ac_link"
5916 case "(($ac_try" in
5917   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5918   *) ac_try_echo=$ac_try;;
5919 esac
5920 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5921 $as_echo "$ac_try_echo") >&5
5922   (eval "$ac_link") 2>conftest.er1
5923   ac_status=$?
5924   grep -v '^ *+' conftest.er1 >conftest.err
5925   rm -f conftest.er1
5926   cat conftest.err >&5
5927   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5928   (exit $ac_status); } && {
5929          test -z "$ac_c_werror_flag" ||
5930          test ! -s conftest.err
5931        } && test -s conftest$ac_exeext && {
5932          test "$cross_compiling" = yes ||
5933          $as_test_x conftest$ac_exeext
5934        }; then
5935   pgac_cv_prog_ld_R=yes
5936 else
5937   $as_echo "$as_me: failed program was:" >&5
5938 sed 's/^/| /' conftest.$ac_ext >&5
5939
5940         pgac_cv_prog_ld_R=no
5941 fi
5942
5943 rm -rf conftest.dSYM
5944 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
5945       conftest$ac_exeext conftest.$ac_ext
5946     LDFLAGS=$pgac_save_LDFLAGS
5947
5948 fi
5949 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
5950 $as_echo "$pgac_cv_prog_ld_R" >&6; }
5951   ld_R_works=$pgac_cv_prog_ld_R
5952
5953 esac
5954 if test -n "$ac_tool_prefix"; then
5955   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5956 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5957 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5958 $as_echo_n "checking for $ac_word... " >&6; }
5959 if test "${ac_cv_prog_RANLIB+set}" = set; then
5960   $as_echo_n "(cached) " >&6
5961 else
5962   if test -n "$RANLIB"; then
5963   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5964 else
5965 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5966 for as_dir in $PATH
5967 do
5968   IFS=$as_save_IFS
5969   test -z "$as_dir" && as_dir=.
5970   for ac_exec_ext in '' $ac_executable_extensions; do
5971   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5972     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5973     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5974     break 2
5975   fi
5976 done
5977 done
5978 IFS=$as_save_IFS
5979
5980 fi
5981 fi
5982 RANLIB=$ac_cv_prog_RANLIB
5983 if test -n "$RANLIB"; then
5984   { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
5985 $as_echo "$RANLIB" >&6; }
5986 else
5987   { $as_echo "$as_me:$LINENO: result: no" >&5
5988 $as_echo "no" >&6; }
5989 fi
5990
5991
5992 fi
5993 if test -z "$ac_cv_prog_RANLIB"; then
5994   ac_ct_RANLIB=$RANLIB
5995   # Extract the first word of "ranlib", so it can be a program name with args.
5996 set dummy ranlib; ac_word=$2
5997 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5998 $as_echo_n "checking for $ac_word... " >&6; }
5999 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
6000   $as_echo_n "(cached) " >&6
6001 else
6002   if test -n "$ac_ct_RANLIB"; then
6003   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6004 else
6005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6006 for as_dir in $PATH
6007 do
6008   IFS=$as_save_IFS
6009   test -z "$as_dir" && as_dir=.
6010   for ac_exec_ext in '' $ac_executable_extensions; do
6011   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6012     ac_cv_prog_ac_ct_RANLIB="ranlib"
6013     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6014     break 2
6015   fi
6016 done
6017 done
6018 IFS=$as_save_IFS
6019
6020 fi
6021 fi
6022 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6023 if test -n "$ac_ct_RANLIB"; then
6024   { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
6025 $as_echo "$ac_ct_RANLIB" >&6; }
6026 else
6027   { $as_echo "$as_me:$LINENO: result: no" >&5
6028 $as_echo "no" >&6; }
6029 fi
6030
6031   if test "x$ac_ct_RANLIB" = x; then
6032     RANLIB=":"
6033   else
6034     case $cross_compiling:$ac_tool_warned in
6035 yes:)
6036 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6037 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6038 ac_tool_warned=yes ;;
6039 esac
6040     RANLIB=$ac_ct_RANLIB
6041   fi
6042 else
6043   RANLIB="$ac_cv_prog_RANLIB"
6044 fi
6045
6046
6047   if test -n "$ac_tool_prefix"; then
6048   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6049 set dummy ${ac_tool_prefix}strip; ac_word=$2
6050 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6051 $as_echo_n "checking for $ac_word... " >&6; }
6052 if test "${ac_cv_prog_STRIP+set}" = set; then
6053   $as_echo_n "(cached) " >&6
6054 else
6055   if test -n "$STRIP"; then
6056   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6057 else
6058 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6059 for as_dir in $PATH
6060 do
6061   IFS=$as_save_IFS
6062   test -z "$as_dir" && as_dir=.
6063   for ac_exec_ext in '' $ac_executable_extensions; do
6064   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6065     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6066     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6067     break 2
6068   fi
6069 done
6070 done
6071 IFS=$as_save_IFS
6072
6073 fi
6074 fi
6075 STRIP=$ac_cv_prog_STRIP
6076 if test -n "$STRIP"; then
6077   { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
6078 $as_echo "$STRIP" >&6; }
6079 else
6080   { $as_echo "$as_me:$LINENO: result: no" >&5
6081 $as_echo "no" >&6; }
6082 fi
6083
6084
6085 fi
6086 if test -z "$ac_cv_prog_STRIP"; then
6087   ac_ct_STRIP=$STRIP
6088   # Extract the first word of "strip", so it can be a program name with args.
6089 set dummy strip; ac_word=$2
6090 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6091 $as_echo_n "checking for $ac_word... " >&6; }
6092 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
6093   $as_echo_n "(cached) " >&6
6094 else
6095   if test -n "$ac_ct_STRIP"; then
6096   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6097 else
6098 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6099 for as_dir in $PATH
6100 do
6101   IFS=$as_save_IFS
6102   test -z "$as_dir" && as_dir=.
6103   for ac_exec_ext in '' $ac_executable_extensions; do
6104   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6105     ac_cv_prog_ac_ct_STRIP="strip"
6106     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6107     break 2
6108   fi
6109 done
6110 done
6111 IFS=$as_save_IFS
6112
6113 fi
6114 fi
6115 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6116 if test -n "$ac_ct_STRIP"; then
6117   { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
6118 $as_echo "$ac_ct_STRIP" >&6; }
6119 else
6120   { $as_echo "$as_me:$LINENO: result: no" >&5
6121 $as_echo "no" >&6; }
6122 fi
6123
6124   if test "x$ac_ct_STRIP" = x; then
6125     STRIP=":"
6126   else
6127     case $cross_compiling:$ac_tool_warned in
6128 yes:)
6129 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6130 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6131 ac_tool_warned=yes ;;
6132 esac
6133     STRIP=$ac_ct_STRIP
6134   fi
6135 else
6136   STRIP="$ac_cv_prog_STRIP"
6137 fi
6138
6139
6140   { $as_echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
6141 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
6142   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
6143     STRIP_STATIC_LIB="$STRIP -x"
6144     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
6145     { $as_echo "$as_me:$LINENO: result: yes" >&5
6146 $as_echo "yes" >&6; }
6147   else
6148     STRIP_STATIC_LIB=:
6149     STRIP_SHARED_LIB=:
6150     { $as_echo "$as_me:$LINENO: result: no" >&5
6151 $as_echo "no" >&6; }
6152   fi
6153
6154
6155
6156 if test -n "$ac_tool_prefix"; then
6157   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6158 set dummy ${ac_tool_prefix}ar; ac_word=$2
6159 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6160 $as_echo_n "checking for $ac_word... " >&6; }
6161 if test "${ac_cv_prog_AR+set}" = set; then
6162   $as_echo_n "(cached) " >&6
6163 else
6164   if test -n "$AR"; then
6165   ac_cv_prog_AR="$AR" # Let the user override the test.
6166 else
6167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6168 for as_dir in $PATH
6169 do
6170   IFS=$as_save_IFS
6171   test -z "$as_dir" && as_dir=.
6172   for ac_exec_ext in '' $ac_executable_extensions; do
6173   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6174     ac_cv_prog_AR="${ac_tool_prefix}ar"
6175     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6176     break 2
6177   fi
6178 done
6179 done
6180 IFS=$as_save_IFS
6181
6182 fi
6183 fi
6184 AR=$ac_cv_prog_AR
6185 if test -n "$AR"; then
6186   { $as_echo "$as_me:$LINENO: result: $AR" >&5
6187 $as_echo "$AR" >&6; }
6188 else
6189   { $as_echo "$as_me:$LINENO: result: no" >&5
6190 $as_echo "no" >&6; }
6191 fi
6192
6193
6194 fi
6195 if test -z "$ac_cv_prog_AR"; then
6196   ac_ct_AR=$AR
6197   # Extract the first word of "ar", so it can be a program name with args.
6198 set dummy ar; ac_word=$2
6199 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6200 $as_echo_n "checking for $ac_word... " >&6; }
6201 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
6202   $as_echo_n "(cached) " >&6
6203 else
6204   if test -n "$ac_ct_AR"; then
6205   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6206 else
6207 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6208 for as_dir in $PATH
6209 do
6210   IFS=$as_save_IFS
6211   test -z "$as_dir" && as_dir=.
6212   for ac_exec_ext in '' $ac_executable_extensions; do
6213   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6214     ac_cv_prog_ac_ct_AR="ar"
6215     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6216     break 2
6217   fi
6218 done
6219 done
6220 IFS=$as_save_IFS
6221
6222 fi
6223 fi
6224 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6225 if test -n "$ac_ct_AR"; then
6226   { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
6227 $as_echo "$ac_ct_AR" >&6; }
6228 else
6229   { $as_echo "$as_me:$LINENO: result: no" >&5
6230 $as_echo "no" >&6; }
6231 fi
6232
6233   if test "x$ac_ct_AR" = x; then
6234     AR="ar"
6235   else
6236     case $cross_compiling:$ac_tool_warned in
6237 yes:)
6238 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6239 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6240 ac_tool_warned=yes ;;
6241 esac
6242     AR=$ac_ct_AR
6243   fi
6244 else
6245   AR="$ac_cv_prog_AR"
6246 fi
6247
6248 if test "$PORTNAME" = "win32"; then
6249   if test -n "$ac_tool_prefix"; then
6250   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
6251 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
6252 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6253 $as_echo_n "checking for $ac_word... " >&6; }
6254 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
6255   $as_echo_n "(cached) " >&6
6256 else
6257   if test -n "$DLLTOOL"; then
6258   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
6259 else
6260 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6261 for as_dir in $PATH
6262 do
6263   IFS=$as_save_IFS
6264   test -z "$as_dir" && as_dir=.
6265   for ac_exec_ext in '' $ac_executable_extensions; do
6266   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6267     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
6268     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6269     break 2
6270   fi
6271 done
6272 done
6273 IFS=$as_save_IFS
6274
6275 fi
6276 fi
6277 DLLTOOL=$ac_cv_prog_DLLTOOL
6278 if test -n "$DLLTOOL"; then
6279   { $as_echo "$as_me:$LINENO: result: $DLLTOOL" >&5
6280 $as_echo "$DLLTOOL" >&6; }
6281 else
6282   { $as_echo "$as_me:$LINENO: result: no" >&5
6283 $as_echo "no" >&6; }
6284 fi
6285
6286
6287 fi
6288 if test -z "$ac_cv_prog_DLLTOOL"; then
6289   ac_ct_DLLTOOL=$DLLTOOL
6290   # Extract the first word of "dlltool", so it can be a program name with args.
6291 set dummy dlltool; ac_word=$2
6292 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6293 $as_echo_n "checking for $ac_word... " >&6; }
6294 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
6295   $as_echo_n "(cached) " >&6
6296 else
6297   if test -n "$ac_ct_DLLTOOL"; then
6298   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
6299 else
6300 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6301 for as_dir in $PATH
6302 do
6303   IFS=$as_save_IFS
6304   test -z "$as_dir" && as_dir=.
6305   for ac_exec_ext in '' $ac_executable_extensions; do
6306   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6307     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
6308     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6309     break 2
6310   fi
6311 done
6312 done
6313 IFS=$as_save_IFS
6314
6315 fi
6316 fi
6317 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
6318 if test -n "$ac_ct_DLLTOOL"; then
6319   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
6320 $as_echo "$ac_ct_DLLTOOL" >&6; }
6321 else
6322   { $as_echo "$as_me:$LINENO: result: no" >&5
6323 $as_echo "no" >&6; }
6324 fi
6325
6326   if test "x$ac_ct_DLLTOOL" = x; then
6327     DLLTOOL="dlltool"
6328   else
6329     case $cross_compiling:$ac_tool_warned in
6330 yes:)
6331 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6332 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6333 ac_tool_warned=yes ;;
6334 esac
6335     DLLTOOL=$ac_ct_DLLTOOL
6336   fi
6337 else
6338   DLLTOOL="$ac_cv_prog_DLLTOOL"
6339 fi
6340
6341   if test -n "$ac_tool_prefix"; then
6342   # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
6343 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
6344 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6345 $as_echo_n "checking for $ac_word... " >&6; }
6346 if test "${ac_cv_prog_DLLWRAP+set}" = set; then
6347   $as_echo_n "(cached) " >&6
6348 else
6349   if test -n "$DLLWRAP"; then
6350   ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
6351 else
6352 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6353 for as_dir in $PATH
6354 do
6355   IFS=$as_save_IFS
6356   test -z "$as_dir" && as_dir=.
6357   for ac_exec_ext in '' $ac_executable_extensions; do
6358   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6359     ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
6360     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6361     break 2
6362   fi
6363 done
6364 done
6365 IFS=$as_save_IFS
6366
6367 fi
6368 fi
6369 DLLWRAP=$ac_cv_prog_DLLWRAP
6370 if test -n "$DLLWRAP"; then
6371   { $as_echo "$as_me:$LINENO: result: $DLLWRAP" >&5
6372 $as_echo "$DLLWRAP" >&6; }
6373 else
6374   { $as_echo "$as_me:$LINENO: result: no" >&5
6375 $as_echo "no" >&6; }
6376 fi
6377
6378
6379 fi
6380 if test -z "$ac_cv_prog_DLLWRAP"; then
6381   ac_ct_DLLWRAP=$DLLWRAP
6382   # Extract the first word of "dllwrap", so it can be a program name with args.
6383 set dummy dllwrap; ac_word=$2
6384 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6385 $as_echo_n "checking for $ac_word... " >&6; }
6386 if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then
6387   $as_echo_n "(cached) " >&6
6388 else
6389   if test -n "$ac_ct_DLLWRAP"; then
6390   ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
6391 else
6392 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6393 for as_dir in $PATH
6394 do
6395   IFS=$as_save_IFS
6396   test -z "$as_dir" && as_dir=.
6397   for ac_exec_ext in '' $ac_executable_extensions; do
6398   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6399     ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
6400     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6401     break 2
6402   fi
6403 done
6404 done
6405 IFS=$as_save_IFS
6406
6407 fi
6408 fi
6409 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
6410 if test -n "$ac_ct_DLLWRAP"; then
6411   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
6412 $as_echo "$ac_ct_DLLWRAP" >&6; }
6413 else
6414   { $as_echo "$as_me:$LINENO: result: no" >&5
6415 $as_echo "no" >&6; }
6416 fi
6417
6418   if test "x$ac_ct_DLLWRAP" = x; then
6419     DLLWRAP="dllwrap"
6420   else
6421     case $cross_compiling:$ac_tool_warned in
6422 yes:)
6423 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6424 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6425 ac_tool_warned=yes ;;
6426 esac
6427     DLLWRAP=$ac_ct_DLLWRAP
6428   fi
6429 else
6430   DLLWRAP="$ac_cv_prog_DLLWRAP"
6431 fi
6432
6433   if test -n "$ac_tool_prefix"; then
6434   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
6435 set dummy ${ac_tool_prefix}windres; ac_word=$2
6436 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6437 $as_echo_n "checking for $ac_word... " >&6; }
6438 if test "${ac_cv_prog_WINDRES+set}" = set; then
6439   $as_echo_n "(cached) " >&6
6440 else
6441   if test -n "$WINDRES"; then
6442   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
6443 else
6444 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6445 for as_dir in $PATH
6446 do
6447   IFS=$as_save_IFS
6448   test -z "$as_dir" && as_dir=.
6449   for ac_exec_ext in '' $ac_executable_extensions; do
6450   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6451     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
6452     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6453     break 2
6454   fi
6455 done
6456 done
6457 IFS=$as_save_IFS
6458
6459 fi
6460 fi
6461 WINDRES=$ac_cv_prog_WINDRES
6462 if test -n "$WINDRES"; then
6463   { $as_echo "$as_me:$LINENO: result: $WINDRES" >&5
6464 $as_echo "$WINDRES" >&6; }
6465 else
6466   { $as_echo "$as_me:$LINENO: result: no" >&5
6467 $as_echo "no" >&6; }
6468 fi
6469
6470
6471 fi
6472 if test -z "$ac_cv_prog_WINDRES"; then
6473   ac_ct_WINDRES=$WINDRES
6474   # Extract the first word of "windres", so it can be a program name with args.
6475 set dummy windres; ac_word=$2
6476 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6477 $as_echo_n "checking for $ac_word... " >&6; }
6478 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then
6479   $as_echo_n "(cached) " >&6
6480 else
6481   if test -n "$ac_ct_WINDRES"; then
6482   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
6483 else
6484 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6485 for as_dir in $PATH
6486 do
6487   IFS=$as_save_IFS
6488   test -z "$as_dir" && as_dir=.
6489   for ac_exec_ext in '' $ac_executable_extensions; do
6490   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6491     ac_cv_prog_ac_ct_WINDRES="windres"
6492     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6493     break 2
6494   fi
6495 done
6496 done
6497 IFS=$as_save_IFS
6498
6499 fi
6500 fi
6501 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
6502 if test -n "$ac_ct_WINDRES"; then
6503   { $as_echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5
6504 $as_echo "$ac_ct_WINDRES" >&6; }
6505 else
6506   { $as_echo "$as_me:$LINENO: result: no" >&5
6507 $as_echo "no" >&6; }
6508 fi
6509
6510   if test "x$ac_ct_WINDRES" = x; then
6511     WINDRES="windres"
6512   else
6513     case $cross_compiling:$ac_tool_warned in
6514 yes:)
6515 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6516 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6517 ac_tool_warned=yes ;;
6518 esac
6519     WINDRES=$ac_ct_WINDRES
6520   fi
6521 else
6522   WINDRES="$ac_cv_prog_WINDRES"
6523 fi
6524
6525 fi
6526
6527 # Extract the first word of "tar", so it can be a program name with args.
6528 set dummy tar; ac_word=$2
6529 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6530 $as_echo_n "checking for $ac_word... " >&6; }
6531 if test "${ac_cv_path_TAR+set}" = set; then
6532   $as_echo_n "(cached) " >&6
6533 else
6534   case $TAR in
6535   [\\/]* | ?:[\\/]*)
6536   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
6537   ;;
6538   *)
6539   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6540 for as_dir in $PATH
6541 do
6542   IFS=$as_save_IFS
6543   test -z "$as_dir" && as_dir=.
6544   for ac_exec_ext in '' $ac_executable_extensions; do
6545   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6546     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
6547     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6548     break 2
6549   fi
6550 done
6551 done
6552 IFS=$as_save_IFS
6553
6554   ;;
6555 esac
6556 fi
6557 TAR=$ac_cv_path_TAR
6558 if test -n "$TAR"; then
6559   { $as_echo "$as_me:$LINENO: result: $TAR" >&5
6560 $as_echo "$TAR" >&6; }
6561 else
6562   { $as_echo "$as_me:$LINENO: result: no" >&5
6563 $as_echo "no" >&6; }
6564 fi
6565
6566
6567 { $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5
6568 $as_echo_n "checking whether ln -s works... " >&6; }
6569 LN_S=$as_ln_s
6570 if test "$LN_S" = "ln -s"; then
6571   { $as_echo "$as_me:$LINENO: result: yes" >&5
6572 $as_echo "yes" >&6; }
6573 else
6574   { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
6575 $as_echo "no, using $LN_S" >&6; }
6576 fi
6577
6578 for ac_prog in gawk mawk nawk awk
6579 do
6580   # Extract the first word of "$ac_prog", so it can be a program name with args.
6581 set dummy $ac_prog; ac_word=$2
6582 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6583 $as_echo_n "checking for $ac_word... " >&6; }
6584 if test "${ac_cv_prog_AWK+set}" = set; then
6585   $as_echo_n "(cached) " >&6
6586 else
6587   if test -n "$AWK"; then
6588   ac_cv_prog_AWK="$AWK" # Let the user override the test.
6589 else
6590 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6591 for as_dir in $PATH
6592 do
6593   IFS=$as_save_IFS
6594   test -z "$as_dir" && as_dir=.
6595   for ac_exec_ext in '' $ac_executable_extensions; do
6596   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6597     ac_cv_prog_AWK="$ac_prog"
6598     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6599     break 2
6600   fi
6601 done
6602 done
6603 IFS=$as_save_IFS
6604
6605 fi
6606 fi
6607 AWK=$ac_cv_prog_AWK
6608 if test -n "$AWK"; then
6609   { $as_echo "$as_me:$LINENO: result: $AWK" >&5
6610 $as_echo "$AWK" >&6; }
6611 else
6612   { $as_echo "$as_me:$LINENO: result: no" >&5
6613 $as_echo "no" >&6; }
6614 fi
6615
6616
6617   test -n "$AWK" && break
6618 done
6619
6620 { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
6621 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
6622 if test -z "$MKDIR_P"; then
6623   if test "${ac_cv_path_mkdir+set}" = set; then
6624   $as_echo_n "(cached) " >&6
6625 else
6626   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6627 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
6628 do
6629   IFS=$as_save_IFS
6630   test -z "$as_dir" && as_dir=.
6631   for ac_prog in mkdir gmkdir; do
6632          for ac_exec_ext in '' $ac_executable_extensions; do
6633            { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
6634            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
6635              'mkdir (GNU coreutils) '* | \
6636              'mkdir (coreutils) '* | \
6637              'mkdir (fileutils) '4.1*)
6638                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
6639                break 3;;
6640            esac
6641          done
6642        done
6643 done
6644 IFS=$as_save_IFS
6645
6646 fi
6647
6648   if test "${ac_cv_path_mkdir+set}" = set; then
6649     MKDIR_P="$ac_cv_path_mkdir -p"
6650   else
6651     # As a last resort, use the slow shell script.  Don't cache a
6652     # value for MKDIR_P within a source directory, because that will
6653     # break other packages using the cache if that directory is
6654     # removed, or if the value is a relative name.
6655     test -d ./--version && rmdir ./--version
6656     MKDIR_P="$ac_install_sh -d"
6657   fi
6658 fi
6659 { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
6660 $as_echo "$MKDIR_P" >&6; }
6661
6662 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
6663 # a relative path to it in each makefile where it subsitutes it. This clashes
6664 # with our Makefile.global concept. This workaround helps.
6665 case $MKDIR_P in
6666   *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
6667 esac
6668
6669 # Let the user override the search
6670 if test -z "$BISON"; then
6671   for ac_prog in bison
6672 do
6673   # Extract the first word of "$ac_prog", so it can be a program name with args.
6674 set dummy $ac_prog; ac_word=$2
6675 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6676 $as_echo_n "checking for $ac_word... " >&6; }
6677 if test "${ac_cv_path_BISON+set}" = set; then
6678   $as_echo_n "(cached) " >&6
6679 else
6680   case $BISON in
6681   [\\/]* | ?:[\\/]*)
6682   ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
6683   ;;
6684   *)
6685   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6686 for as_dir in $PATH
6687 do
6688   IFS=$as_save_IFS
6689   test -z "$as_dir" && as_dir=.
6690   for ac_exec_ext in '' $ac_executable_extensions; do
6691   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6692     ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
6693     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6694     break 2
6695   fi
6696 done
6697 done
6698 IFS=$as_save_IFS
6699
6700   ;;
6701 esac
6702 fi
6703 BISON=$ac_cv_path_BISON
6704 if test -n "$BISON"; then
6705   { $as_echo "$as_me:$LINENO: result: $BISON" >&5
6706 $as_echo "$BISON" >&6; }
6707 else
6708   { $as_echo "$as_me:$LINENO: result: no" >&5
6709 $as_echo "no" >&6; }
6710 fi
6711
6712
6713   test -n "$BISON" && break
6714 done
6715
6716 fi
6717
6718 if test "$BISON"; then
6719   pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
6720   { $as_echo "$as_me:$LINENO: using $pgac_bison_version" >&5
6721 $as_echo "$as_me: using $pgac_bison_version" >&6;}
6722   if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
6723   then
6724     { $as_echo "$as_me:$LINENO: WARNING:
6725 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6726 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
6727 $as_echo "$as_me: WARNING:
6728 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6729 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
6730     BISON=""
6731   fi
6732 fi
6733
6734 if test -z "$BISON"; then
6735   { $as_echo "$as_me:$LINENO: WARNING:
6736 *** Without Bison you will not be able to build PostgreSQL from CVS nor
6737 *** change any of the parser definition files.  You can obtain Bison from
6738 *** a GNU mirror site.  (If you are using the official distribution of
6739 *** PostgreSQL then you do not need to worry about this, because the Bison
6740 *** output is pre-generated.)" >&5
6741 $as_echo "$as_me: WARNING:
6742 *** Without Bison you will not be able to build PostgreSQL from CVS nor
6743 *** change any of the parser definition files.  You can obtain Bison from
6744 *** a GNU mirror site.  (If you are using the official distribution of
6745 *** PostgreSQL then you do not need to worry about this, because the Bison
6746 *** output is pre-generated.)" >&2;}
6747 fi
6748 # We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
6749
6750
6751 { $as_echo "$as_me:$LINENO: checking for flex" >&5
6752 $as_echo_n "checking for flex... " >&6; }
6753 if test "${pgac_cv_path_flex+set}" = set; then
6754   $as_echo_n "(cached) " >&6
6755 else
6756   # Let the user override the test
6757 if test -n "$FLEX"; then
6758   pgac_cv_path_flex=$FLEX
6759 else
6760   pgac_save_IFS=$IFS
6761   IFS=$PATH_SEPARATOR
6762   for pgac_dir in $PATH; do
6763     IFS=$pgac_save_IFS
6764     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
6765       pgac_dir=`pwd`
6766     fi
6767     for pgac_prog in flex lex; do
6768       pgac_candidate="$pgac_dir/$pgac_prog"
6769       if test -f "$pgac_candidate" \
6770         && $pgac_candidate --version </dev/null >/dev/null 2>&1
6771       then
6772         echo '%%'  > conftest.l
6773         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
6774           pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
6775           if echo "$pgac_flex_version" | sed 's/[.a-z]/ /g' | $AWK '{ if ($1 = 2 && $2 = 5 && $3 >= 31) exit 0; else exit 1;}'
6776           then
6777             pgac_cv_path_flex=$pgac_candidate
6778             break 2
6779           else
6780             { $as_echo "$as_me:$LINENO: WARNING:
6781 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6782 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
6783 $as_echo "$as_me: WARNING:
6784 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6785 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
6786           fi
6787         fi
6788       fi
6789     done
6790   done
6791   rm -f conftest.l lex.yy.c
6792   : ${pgac_cv_path_flex=no}
6793 fi
6794
6795 fi
6796 { $as_echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
6797 $as_echo "$pgac_cv_path_flex" >&6; }
6798 if test x"$pgac_cv_path_flex" = x"no"; then
6799   { $as_echo "$as_me:$LINENO: WARNING:
6800 *** Without Flex you will not be able to build PostgreSQL from CVS nor
6801 *** change any of the scanner definition files.  You can obtain Flex from
6802 *** a GNU mirror site.  (If you are using the official distribution of
6803 *** PostgreSQL then you do not need to worry about this because the Flex
6804 *** output is pre-generated.)" >&5
6805 $as_echo "$as_me: WARNING:
6806 *** Without Flex you will not be able to build PostgreSQL from CVS nor
6807 *** change any of the scanner definition files.  You can obtain Flex from
6808 *** a GNU mirror site.  (If you are using the official distribution of
6809 *** PostgreSQL then you do not need to worry about this because the Flex
6810 *** output is pre-generated.)" >&2;}
6811
6812   FLEX=
6813 else
6814   FLEX=$pgac_cv_path_flex
6815   pgac_flex_version=`$FLEX --version 2>/dev/null`
6816   { $as_echo "$as_me:$LINENO: using $pgac_flex_version" >&5
6817 $as_echo "$as_me: using $pgac_flex_version" >&6;}
6818 fi
6819
6820
6821
6822
6823
6824 # Extract the first word of "perl", so it can be a program name with args.
6825 set dummy perl; ac_word=$2
6826 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6827 $as_echo_n "checking for $ac_word... " >&6; }
6828 if test "${ac_cv_path_PERL+set}" = set; then
6829   $as_echo_n "(cached) " >&6
6830 else
6831   case $PERL in
6832   [\\/]* | ?:[\\/]*)
6833   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
6834   ;;
6835   *)
6836   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6837 for as_dir in $PATH
6838 do
6839   IFS=$as_save_IFS
6840   test -z "$as_dir" && as_dir=.
6841   for ac_exec_ext in '' $ac_executable_extensions; do
6842   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6843     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
6844     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6845     break 2
6846   fi
6847 done
6848 done
6849 IFS=$as_save_IFS
6850
6851   ;;
6852 esac
6853 fi
6854 PERL=$ac_cv_path_PERL
6855 if test -n "$PERL"; then
6856   { $as_echo "$as_me:$LINENO: result: $PERL" >&5
6857 $as_echo "$PERL" >&6; }
6858 else
6859   { $as_echo "$as_me:$LINENO: result: no" >&5
6860 $as_echo "no" >&6; }
6861 fi
6862
6863
6864 if test "$with_perl" = yes; then
6865
6866 { $as_echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
6867 $as_echo_n "checking for Perl archlibexp... " >&6; }
6868 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
6869 { $as_echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
6870 $as_echo "$perl_archlibexp" >&6; }
6871 { $as_echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
6872 $as_echo_n "checking for Perl privlibexp... " >&6; }
6873 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
6874 { $as_echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
6875 $as_echo "$perl_privlibexp" >&6; }
6876 { $as_echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
6877 $as_echo_n "checking for Perl useshrplib... " >&6; }
6878 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
6879 { $as_echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
6880 $as_echo "$perl_useshrplib" >&6; }
6881
6882 { $as_echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
6883 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
6884 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
6885 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
6886 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
6887 if test -z "$perl_embed_ldflags" ; then
6888         { $as_echo "$as_me:$LINENO: result: no" >&5
6889 $as_echo "no" >&6; }
6890         { { $as_echo "$as_me:$LINENO: error: could not determine flags for linking embedded Perl.
6891 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
6892 installed." >&5
6893 $as_echo "$as_me: error: could not determine flags for linking embedded Perl.
6894 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
6895 installed." >&2;}
6896    { (exit 1); exit 1; }; }
6897 else
6898         { $as_echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
6899 $as_echo "$perl_embed_ldflags" >&6; }
6900 fi
6901
6902 fi
6903
6904 if test "$with_python" = yes; then
6905   # Extract the first word of "python", so it can be a program name with args.
6906 set dummy python; ac_word=$2
6907 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6908 $as_echo_n "checking for $ac_word... " >&6; }
6909 if test "${ac_cv_path_PYTHON+set}" = set; then
6910   $as_echo_n "(cached) " >&6
6911 else
6912   case $PYTHON in
6913   [\\/]* | ?:[\\/]*)
6914   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
6915   ;;
6916   *)
6917   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6918 for as_dir in $PATH
6919 do
6920   IFS=$as_save_IFS
6921   test -z "$as_dir" && as_dir=.
6922   for ac_exec_ext in '' $ac_executable_extensions; do
6923   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6924     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
6925     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6926     break 2
6927   fi
6928 done
6929 done
6930 IFS=$as_save_IFS
6931
6932   ;;
6933 esac
6934 fi
6935 PYTHON=$ac_cv_path_PYTHON
6936 if test -n "$PYTHON"; then
6937   { $as_echo "$as_me:$LINENO: result: $PYTHON" >&5
6938 $as_echo "$PYTHON" >&6; }
6939 else
6940   { $as_echo "$as_me:$LINENO: result: no" >&5
6941 $as_echo "no" >&6; }
6942 fi
6943
6944
6945 if test x"$PYTHON" = x""; then
6946   { { $as_echo "$as_me:$LINENO: error: Python not found" >&5
6947 $as_echo "$as_me: error: Python not found" >&2;}
6948    { (exit 1); exit 1; }; }
6949 fi
6950
6951
6952 { $as_echo "$as_me:$LINENO: checking for Python distutils module" >&5
6953 $as_echo_n "checking for Python distutils module... " >&6; }
6954 if "${PYTHON}" -c 'import distutils' 2>&5
6955 then
6956     { $as_echo "$as_me:$LINENO: result: yes" >&5
6957 $as_echo "yes" >&6; }
6958 else
6959     { $as_echo "$as_me:$LINENO: result: no" >&5
6960 $as_echo "no" >&6; }
6961     { { $as_echo "$as_me:$LINENO: error: distutils module not found" >&5
6962 $as_echo "$as_me: error: distutils module not found" >&2;}
6963    { (exit 1); exit 1; }; }
6964 fi
6965 { $as_echo "$as_me:$LINENO: checking Python configuration directory" >&5
6966 $as_echo_n "checking Python configuration directory... " >&6; }
6967 python_version=`${PYTHON} -c "import sys; print(sys.version[:3])"`
6968 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'))"`
6969 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print('-I'+distutils.sysconfig.get_python_inc())"`
6970
6971 # This should be enough of a message.
6972 { $as_echo "$as_me:$LINENO: result: $python_configdir" >&5
6973 $as_echo "$python_configdir" >&6; }
6974
6975
6976 { $as_echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
6977 $as_echo_n "checking how to link an embedded Python application... " >&6; }
6978
6979 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
6980 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
6981 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('SO'))))"`
6982 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
6983
6984 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
6985 then
6986         # New way: use the official shared library
6987         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
6988         python_libspec="-L${python_libdir} -l${ldlibrary}"
6989 else
6990         # Old way: use libpython from python_configdir
6991         python_libdir="${python_configdir}"
6992         python_libspec="-L${python_libdir} -lpython${python_version}"
6993 fi
6994
6995 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','LOCALMODLIBS','BASEMODLIBS'))))"`
6996
6997 { $as_echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
6998 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
6999
7000
7001 # threaded python is not supported on bsd's
7002 { $as_echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
7003 $as_echo_n "checking whether Python is compiled with thread support... " >&6; }
7004 pythreads=`${PYTHON} -c "import sys; print(int('thread' in sys.builtin_module_names))"`
7005 if test "$pythreads" = "1"; then
7006   { $as_echo "$as_me:$LINENO: result: yes" >&5
7007 $as_echo "yes" >&6; }
7008   case $host_os in
7009   openbsd*|freebsd*)
7010     { { $as_echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
7011 $as_echo "$as_me: error: threaded Python not supported on this platform" >&2;}
7012    { (exit 1); exit 1; }; }
7013     ;;
7014   esac
7015 else
7016   { $as_echo "$as_me:$LINENO: result: no" >&5
7017 $as_echo "no" >&6; }
7018 fi
7019
7020
7021 fi
7022
7023 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
7024   # Extract the first word of "zic", so it can be a program name with args.
7025 set dummy zic; ac_word=$2
7026 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7027 $as_echo_n "checking for $ac_word... " >&6; }
7028 if test "${ac_cv_path_ZIC+set}" = set; then
7029   $as_echo_n "(cached) " >&6
7030 else
7031   case $ZIC in
7032   [\\/]* | ?:[\\/]*)
7033   ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
7034   ;;
7035   *)
7036   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7037 for as_dir in $PATH
7038 do
7039   IFS=$as_save_IFS
7040   test -z "$as_dir" && as_dir=.
7041   for ac_exec_ext in '' $ac_executable_extensions; do
7042   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7043     ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
7044     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7045     break 2
7046   fi
7047 done
7048 done
7049 IFS=$as_save_IFS
7050
7051   ;;
7052 esac
7053 fi
7054 ZIC=$ac_cv_path_ZIC
7055 if test -n "$ZIC"; then
7056   { $as_echo "$as_me:$LINENO: result: $ZIC" >&5
7057 $as_echo "$ZIC" >&6; }
7058 else
7059   { $as_echo "$as_me:$LINENO: result: no" >&5
7060 $as_echo "no" >&6; }
7061 fi
7062
7063
7064   if test -z "$ZIC"; then
7065     { { $as_echo "$as_me:$LINENO: error:
7066 When cross-compiling, either use the option --with-system-tzdata to use
7067 existing time-zone data, or set the environment variable ZIC to a zic
7068 program to use during the build." >&5
7069 $as_echo "$as_me: error:
7070 When cross-compiling, either use the option --with-system-tzdata to use
7071 existing time-zone data, or set the environment variable ZIC to a zic
7072 program to use during the build." >&2;}
7073    { (exit 1); exit 1; }; }
7074   fi
7075 fi
7076
7077
7078 ##
7079 ## Libraries
7080 ##
7081 ## Most libraries are included only if they demonstrably provide a function
7082 ## we need, but libm is an exception: always include it, because there are
7083 ## too many compilers that play cute optimization games that will break
7084 ## probes for standard functions such as pow().
7085 ##
7086
7087
7088 { $as_echo "$as_me:$LINENO: checking for main in -lm" >&5
7089 $as_echo_n "checking for main in -lm... " >&6; }
7090 if test "${ac_cv_lib_m_main+set}" = set; then
7091   $as_echo_n "(cached) " >&6
7092 else
7093   ac_check_lib_save_LIBS=$LIBS
7094 LIBS="-lm  $LIBS"
7095 cat >conftest.$ac_ext <<_ACEOF
7096 /* confdefs.h.  */
7097 _ACEOF
7098 cat confdefs.h >>conftest.$ac_ext
7099 cat >>conftest.$ac_ext <<_ACEOF
7100 /* end confdefs.h.  */
7101
7102
7103 int
7104 main ()
7105 {
7106 return main ();
7107   ;
7108   return 0;
7109 }
7110 _ACEOF
7111 rm -f conftest.$ac_objext conftest$ac_exeext
7112 if { (ac_try="$ac_link"
7113 case "(($ac_try" in
7114   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7115   *) ac_try_echo=$ac_try;;
7116 esac
7117 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7118 $as_echo "$ac_try_echo") >&5
7119   (eval "$ac_link") 2>conftest.er1
7120   ac_status=$?
7121   grep -v '^ *+' conftest.er1 >conftest.err
7122   rm -f conftest.er1
7123   cat conftest.err >&5
7124   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7125   (exit $ac_status); } && {
7126          test -z "$ac_c_werror_flag" ||
7127          test ! -s conftest.err
7128        } && test -s conftest$ac_exeext && {
7129          test "$cross_compiling" = yes ||
7130          $as_test_x conftest$ac_exeext
7131        }; then
7132   ac_cv_lib_m_main=yes
7133 else
7134   $as_echo "$as_me: failed program was:" >&5
7135 sed 's/^/| /' conftest.$ac_ext >&5
7136
7137         ac_cv_lib_m_main=no
7138 fi
7139
7140 rm -rf conftest.dSYM
7141 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7142       conftest$ac_exeext conftest.$ac_ext
7143 LIBS=$ac_check_lib_save_LIBS
7144 fi
7145 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
7146 $as_echo "$ac_cv_lib_m_main" >&6; }
7147 if test "x$ac_cv_lib_m_main" = x""yes; then
7148   cat >>confdefs.h <<_ACEOF
7149 #define HAVE_LIBM 1
7150 _ACEOF
7151
7152   LIBS="-lm $LIBS"
7153
7154 fi
7155
7156 { $as_echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
7157 $as_echo_n "checking for library containing setproctitle... " >&6; }
7158 if test "${ac_cv_search_setproctitle+set}" = set; then
7159   $as_echo_n "(cached) " >&6
7160 else
7161   ac_func_search_save_LIBS=$LIBS
7162 cat >conftest.$ac_ext <<_ACEOF
7163 /* confdefs.h.  */
7164 _ACEOF
7165 cat confdefs.h >>conftest.$ac_ext
7166 cat >>conftest.$ac_ext <<_ACEOF
7167 /* end confdefs.h.  */
7168
7169 /* Override any GCC internal prototype to avoid an error.
7170    Use char because int might match the return type of a GCC
7171    builtin and then its argument prototype would still apply.  */
7172 #ifdef __cplusplus
7173 extern "C"
7174 #endif
7175 char setproctitle ();
7176 int
7177 main ()
7178 {
7179 return setproctitle ();
7180   ;
7181   return 0;
7182 }
7183 _ACEOF
7184 for ac_lib in '' util; do
7185   if test -z "$ac_lib"; then
7186     ac_res="none required"
7187   else
7188     ac_res=-l$ac_lib
7189     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7190   fi
7191   rm -f conftest.$ac_objext conftest$ac_exeext
7192 if { (ac_try="$ac_link"
7193 case "(($ac_try" in
7194   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7195   *) ac_try_echo=$ac_try;;
7196 esac
7197 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7198 $as_echo "$ac_try_echo") >&5
7199   (eval "$ac_link") 2>conftest.er1
7200   ac_status=$?
7201   grep -v '^ *+' conftest.er1 >conftest.err
7202   rm -f conftest.er1
7203   cat conftest.err >&5
7204   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7205   (exit $ac_status); } && {
7206          test -z "$ac_c_werror_flag" ||
7207          test ! -s conftest.err
7208        } && test -s conftest$ac_exeext && {
7209          test "$cross_compiling" = yes ||
7210          $as_test_x conftest$ac_exeext
7211        }; then
7212   ac_cv_search_setproctitle=$ac_res
7213 else
7214   $as_echo "$as_me: failed program was:" >&5
7215 sed 's/^/| /' conftest.$ac_ext >&5
7216
7217
7218 fi
7219
7220 rm -rf conftest.dSYM
7221 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7222       conftest$ac_exeext
7223   if test "${ac_cv_search_setproctitle+set}" = set; then
7224   break
7225 fi
7226 done
7227 if test "${ac_cv_search_setproctitle+set}" = set; then
7228   :
7229 else
7230   ac_cv_search_setproctitle=no
7231 fi
7232 rm conftest.$ac_ext
7233 LIBS=$ac_func_search_save_LIBS
7234 fi
7235 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
7236 $as_echo "$ac_cv_search_setproctitle" >&6; }
7237 ac_res=$ac_cv_search_setproctitle
7238 if test "$ac_res" != no; then
7239   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7240
7241 fi
7242
7243 { $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5
7244 $as_echo_n "checking for library containing dlopen... " >&6; }
7245 if test "${ac_cv_search_dlopen+set}" = set; then
7246   $as_echo_n "(cached) " >&6
7247 else
7248   ac_func_search_save_LIBS=$LIBS
7249 cat >conftest.$ac_ext <<_ACEOF
7250 /* confdefs.h.  */
7251 _ACEOF
7252 cat confdefs.h >>conftest.$ac_ext
7253 cat >>conftest.$ac_ext <<_ACEOF
7254 /* end confdefs.h.  */
7255
7256 /* Override any GCC internal prototype to avoid an error.
7257    Use char because int might match the return type of a GCC
7258    builtin and then its argument prototype would still apply.  */
7259 #ifdef __cplusplus
7260 extern "C"
7261 #endif
7262 char dlopen ();
7263 int
7264 main ()
7265 {
7266 return dlopen ();
7267   ;
7268   return 0;
7269 }
7270 _ACEOF
7271 for ac_lib in '' dl; do
7272   if test -z "$ac_lib"; then
7273     ac_res="none required"
7274   else
7275     ac_res=-l$ac_lib
7276     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7277   fi
7278   rm -f conftest.$ac_objext conftest$ac_exeext
7279 if { (ac_try="$ac_link"
7280 case "(($ac_try" in
7281   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7282   *) ac_try_echo=$ac_try;;
7283 esac
7284 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7285 $as_echo "$ac_try_echo") >&5
7286   (eval "$ac_link") 2>conftest.er1
7287   ac_status=$?
7288   grep -v '^ *+' conftest.er1 >conftest.err
7289   rm -f conftest.er1
7290   cat conftest.err >&5
7291   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7292   (exit $ac_status); } && {
7293          test -z "$ac_c_werror_flag" ||
7294          test ! -s conftest.err
7295        } && test -s conftest$ac_exeext && {
7296          test "$cross_compiling" = yes ||
7297          $as_test_x conftest$ac_exeext
7298        }; then
7299   ac_cv_search_dlopen=$ac_res
7300 else
7301   $as_echo "$as_me: failed program was:" >&5
7302 sed 's/^/| /' conftest.$ac_ext >&5
7303
7304
7305 fi
7306
7307 rm -rf conftest.dSYM
7308 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7309       conftest$ac_exeext
7310   if test "${ac_cv_search_dlopen+set}" = set; then
7311   break
7312 fi
7313 done
7314 if test "${ac_cv_search_dlopen+set}" = set; then
7315   :
7316 else
7317   ac_cv_search_dlopen=no
7318 fi
7319 rm conftest.$ac_ext
7320 LIBS=$ac_func_search_save_LIBS
7321 fi
7322 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
7323 $as_echo "$ac_cv_search_dlopen" >&6; }
7324 ac_res=$ac_cv_search_dlopen
7325 if test "$ac_res" != no; then
7326   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7327
7328 fi
7329
7330 { $as_echo "$as_me:$LINENO: checking for library containing socket" >&5
7331 $as_echo_n "checking for library containing socket... " >&6; }
7332 if test "${ac_cv_search_socket+set}" = set; then
7333   $as_echo_n "(cached) " >&6
7334 else
7335   ac_func_search_save_LIBS=$LIBS
7336 cat >conftest.$ac_ext <<_ACEOF
7337 /* confdefs.h.  */
7338 _ACEOF
7339 cat confdefs.h >>conftest.$ac_ext
7340 cat >>conftest.$ac_ext <<_ACEOF
7341 /* end confdefs.h.  */
7342
7343 /* Override any GCC internal prototype to avoid an error.
7344    Use char because int might match the return type of a GCC
7345    builtin and then its argument prototype would still apply.  */
7346 #ifdef __cplusplus
7347 extern "C"
7348 #endif
7349 char socket ();
7350 int
7351 main ()
7352 {
7353 return socket ();
7354   ;
7355   return 0;
7356 }
7357 _ACEOF
7358 for ac_lib in '' socket wsock32; do
7359   if test -z "$ac_lib"; then
7360     ac_res="none required"
7361   else
7362     ac_res=-l$ac_lib
7363     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7364   fi
7365   rm -f conftest.$ac_objext conftest$ac_exeext
7366 if { (ac_try="$ac_link"
7367 case "(($ac_try" in
7368   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7369   *) ac_try_echo=$ac_try;;
7370 esac
7371 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7372 $as_echo "$ac_try_echo") >&5
7373   (eval "$ac_link") 2>conftest.er1
7374   ac_status=$?
7375   grep -v '^ *+' conftest.er1 >conftest.err
7376   rm -f conftest.er1
7377   cat conftest.err >&5
7378   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7379   (exit $ac_status); } && {
7380          test -z "$ac_c_werror_flag" ||
7381          test ! -s conftest.err
7382        } && test -s conftest$ac_exeext && {
7383          test "$cross_compiling" = yes ||
7384          $as_test_x conftest$ac_exeext
7385        }; then
7386   ac_cv_search_socket=$ac_res
7387 else
7388   $as_echo "$as_me: failed program was:" >&5
7389 sed 's/^/| /' conftest.$ac_ext >&5
7390
7391
7392 fi
7393
7394 rm -rf conftest.dSYM
7395 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7396       conftest$ac_exeext
7397   if test "${ac_cv_search_socket+set}" = set; then
7398   break
7399 fi
7400 done
7401 if test "${ac_cv_search_socket+set}" = set; then
7402   :
7403 else
7404   ac_cv_search_socket=no
7405 fi
7406 rm conftest.$ac_ext
7407 LIBS=$ac_func_search_save_LIBS
7408 fi
7409 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
7410 $as_echo "$ac_cv_search_socket" >&6; }
7411 ac_res=$ac_cv_search_socket
7412 if test "$ac_res" != no; then
7413   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7414
7415 fi
7416
7417 { $as_echo "$as_me:$LINENO: checking for library containing shl_load" >&5
7418 $as_echo_n "checking for library containing shl_load... " >&6; }
7419 if test "${ac_cv_search_shl_load+set}" = set; then
7420   $as_echo_n "(cached) " >&6
7421 else
7422   ac_func_search_save_LIBS=$LIBS
7423 cat >conftest.$ac_ext <<_ACEOF
7424 /* confdefs.h.  */
7425 _ACEOF
7426 cat confdefs.h >>conftest.$ac_ext
7427 cat >>conftest.$ac_ext <<_ACEOF
7428 /* end confdefs.h.  */
7429
7430 /* Override any GCC internal prototype to avoid an error.
7431    Use char because int might match the return type of a GCC
7432    builtin and then its argument prototype would still apply.  */
7433 #ifdef __cplusplus
7434 extern "C"
7435 #endif
7436 char shl_load ();
7437 int
7438 main ()
7439 {
7440 return shl_load ();
7441   ;
7442   return 0;
7443 }
7444 _ACEOF
7445 for ac_lib in '' dld; do
7446   if test -z "$ac_lib"; then
7447     ac_res="none required"
7448   else
7449     ac_res=-l$ac_lib
7450     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7451   fi
7452   rm -f conftest.$ac_objext conftest$ac_exeext
7453 if { (ac_try="$ac_link"
7454 case "(($ac_try" in
7455   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7456   *) ac_try_echo=$ac_try;;
7457 esac
7458 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7459 $as_echo "$ac_try_echo") >&5
7460   (eval "$ac_link") 2>conftest.er1
7461   ac_status=$?
7462   grep -v '^ *+' conftest.er1 >conftest.err
7463   rm -f conftest.er1
7464   cat conftest.err >&5
7465   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7466   (exit $ac_status); } && {
7467          test -z "$ac_c_werror_flag" ||
7468          test ! -s conftest.err
7469        } && test -s conftest$ac_exeext && {
7470          test "$cross_compiling" = yes ||
7471          $as_test_x conftest$ac_exeext
7472        }; then
7473   ac_cv_search_shl_load=$ac_res
7474 else
7475   $as_echo "$as_me: failed program was:" >&5
7476 sed 's/^/| /' conftest.$ac_ext >&5
7477
7478
7479 fi
7480
7481 rm -rf conftest.dSYM
7482 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7483       conftest$ac_exeext
7484   if test "${ac_cv_search_shl_load+set}" = set; then
7485   break
7486 fi
7487 done
7488 if test "${ac_cv_search_shl_load+set}" = set; then
7489   :
7490 else
7491   ac_cv_search_shl_load=no
7492 fi
7493 rm conftest.$ac_ext
7494 LIBS=$ac_func_search_save_LIBS
7495 fi
7496 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
7497 $as_echo "$ac_cv_search_shl_load" >&6; }
7498 ac_res=$ac_cv_search_shl_load
7499 if test "$ac_res" != no; then
7500   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7501
7502 fi
7503
7504 # We only use libld in port/dynloader/aix.c
7505 case $host_os in
7506      aix*)
7507         { $as_echo "$as_me:$LINENO: checking for library containing ldopen" >&5
7508 $as_echo_n "checking for library containing ldopen... " >&6; }
7509 if test "${ac_cv_search_ldopen+set}" = set; then
7510   $as_echo_n "(cached) " >&6
7511 else
7512   ac_func_search_save_LIBS=$LIBS
7513 cat >conftest.$ac_ext <<_ACEOF
7514 /* confdefs.h.  */
7515 _ACEOF
7516 cat confdefs.h >>conftest.$ac_ext
7517 cat >>conftest.$ac_ext <<_ACEOF
7518 /* end confdefs.h.  */
7519
7520 /* Override any GCC internal prototype to avoid an error.
7521    Use char because int might match the return type of a GCC
7522    builtin and then its argument prototype would still apply.  */
7523 #ifdef __cplusplus
7524 extern "C"
7525 #endif
7526 char ldopen ();
7527 int
7528 main ()
7529 {
7530 return ldopen ();
7531   ;
7532   return 0;
7533 }
7534 _ACEOF
7535 for ac_lib in '' ld; do
7536   if test -z "$ac_lib"; then
7537     ac_res="none required"
7538   else
7539     ac_res=-l$ac_lib
7540     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7541   fi
7542   rm -f conftest.$ac_objext conftest$ac_exeext
7543 if { (ac_try="$ac_link"
7544 case "(($ac_try" in
7545   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7546   *) ac_try_echo=$ac_try;;
7547 esac
7548 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7549 $as_echo "$ac_try_echo") >&5
7550   (eval "$ac_link") 2>conftest.er1
7551   ac_status=$?
7552   grep -v '^ *+' conftest.er1 >conftest.err
7553   rm -f conftest.er1
7554   cat conftest.err >&5
7555   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7556   (exit $ac_status); } && {
7557          test -z "$ac_c_werror_flag" ||
7558          test ! -s conftest.err
7559        } && test -s conftest$ac_exeext && {
7560          test "$cross_compiling" = yes ||
7561          $as_test_x conftest$ac_exeext
7562        }; then
7563   ac_cv_search_ldopen=$ac_res
7564 else
7565   $as_echo "$as_me: failed program was:" >&5
7566 sed 's/^/| /' conftest.$ac_ext >&5
7567
7568
7569 fi
7570
7571 rm -rf conftest.dSYM
7572 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7573       conftest$ac_exeext
7574   if test "${ac_cv_search_ldopen+set}" = set; then
7575   break
7576 fi
7577 done
7578 if test "${ac_cv_search_ldopen+set}" = set; then
7579   :
7580 else
7581   ac_cv_search_ldopen=no
7582 fi
7583 rm conftest.$ac_ext
7584 LIBS=$ac_func_search_save_LIBS
7585 fi
7586 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
7587 $as_echo "$ac_cv_search_ldopen" >&6; }
7588 ac_res=$ac_cv_search_ldopen
7589 if test "$ac_res" != no; then
7590   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7591
7592 fi
7593
7594         ;;
7595 esac
7596 { $as_echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
7597 $as_echo_n "checking for library containing getopt_long... " >&6; }
7598 if test "${ac_cv_search_getopt_long+set}" = set; then
7599   $as_echo_n "(cached) " >&6
7600 else
7601   ac_func_search_save_LIBS=$LIBS
7602 cat >conftest.$ac_ext <<_ACEOF
7603 /* confdefs.h.  */
7604 _ACEOF
7605 cat confdefs.h >>conftest.$ac_ext
7606 cat >>conftest.$ac_ext <<_ACEOF
7607 /* end confdefs.h.  */
7608
7609 /* Override any GCC internal prototype to avoid an error.
7610    Use char because int might match the return type of a GCC
7611    builtin and then its argument prototype would still apply.  */
7612 #ifdef __cplusplus
7613 extern "C"
7614 #endif
7615 char getopt_long ();
7616 int
7617 main ()
7618 {
7619 return getopt_long ();
7620   ;
7621   return 0;
7622 }
7623 _ACEOF
7624 for ac_lib in '' getopt gnugetopt; do
7625   if test -z "$ac_lib"; then
7626     ac_res="none required"
7627   else
7628     ac_res=-l$ac_lib
7629     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7630   fi
7631   rm -f conftest.$ac_objext conftest$ac_exeext
7632 if { (ac_try="$ac_link"
7633 case "(($ac_try" in
7634   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7635   *) ac_try_echo=$ac_try;;
7636 esac
7637 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7638 $as_echo "$ac_try_echo") >&5
7639   (eval "$ac_link") 2>conftest.er1
7640   ac_status=$?
7641   grep -v '^ *+' conftest.er1 >conftest.err
7642   rm -f conftest.er1
7643   cat conftest.err >&5
7644   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7645   (exit $ac_status); } && {
7646          test -z "$ac_c_werror_flag" ||
7647          test ! -s conftest.err
7648        } && test -s conftest$ac_exeext && {
7649          test "$cross_compiling" = yes ||
7650          $as_test_x conftest$ac_exeext
7651        }; then
7652   ac_cv_search_getopt_long=$ac_res
7653 else
7654   $as_echo "$as_me: failed program was:" >&5
7655 sed 's/^/| /' conftest.$ac_ext >&5
7656
7657
7658 fi
7659
7660 rm -rf conftest.dSYM
7661 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7662       conftest$ac_exeext
7663   if test "${ac_cv_search_getopt_long+set}" = set; then
7664   break
7665 fi
7666 done
7667 if test "${ac_cv_search_getopt_long+set}" = set; then
7668   :
7669 else
7670   ac_cv_search_getopt_long=no
7671 fi
7672 rm conftest.$ac_ext
7673 LIBS=$ac_func_search_save_LIBS
7674 fi
7675 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
7676 $as_echo "$ac_cv_search_getopt_long" >&6; }
7677 ac_res=$ac_cv_search_getopt_long
7678 if test "$ac_res" != no; then
7679   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7680
7681 fi
7682
7683 { $as_echo "$as_me:$LINENO: checking for library containing crypt" >&5
7684 $as_echo_n "checking for library containing crypt... " >&6; }
7685 if test "${ac_cv_search_crypt+set}" = set; then
7686   $as_echo_n "(cached) " >&6
7687 else
7688   ac_func_search_save_LIBS=$LIBS
7689 cat >conftest.$ac_ext <<_ACEOF
7690 /* confdefs.h.  */
7691 _ACEOF
7692 cat confdefs.h >>conftest.$ac_ext
7693 cat >>conftest.$ac_ext <<_ACEOF
7694 /* end confdefs.h.  */
7695
7696 /* Override any GCC internal prototype to avoid an error.
7697    Use char because int might match the return type of a GCC
7698    builtin and then its argument prototype would still apply.  */
7699 #ifdef __cplusplus
7700 extern "C"
7701 #endif
7702 char crypt ();
7703 int
7704 main ()
7705 {
7706 return crypt ();
7707   ;
7708   return 0;
7709 }
7710 _ACEOF
7711 for ac_lib in '' crypt; do
7712   if test -z "$ac_lib"; then
7713     ac_res="none required"
7714   else
7715     ac_res=-l$ac_lib
7716     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7717   fi
7718   rm -f conftest.$ac_objext conftest$ac_exeext
7719 if { (ac_try="$ac_link"
7720 case "(($ac_try" in
7721   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7722   *) ac_try_echo=$ac_try;;
7723 esac
7724 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7725 $as_echo "$ac_try_echo") >&5
7726   (eval "$ac_link") 2>conftest.er1
7727   ac_status=$?
7728   grep -v '^ *+' conftest.er1 >conftest.err
7729   rm -f conftest.er1
7730   cat conftest.err >&5
7731   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7732   (exit $ac_status); } && {
7733          test -z "$ac_c_werror_flag" ||
7734          test ! -s conftest.err
7735        } && test -s conftest$ac_exeext && {
7736          test "$cross_compiling" = yes ||
7737          $as_test_x conftest$ac_exeext
7738        }; then
7739   ac_cv_search_crypt=$ac_res
7740 else
7741   $as_echo "$as_me: failed program was:" >&5
7742 sed 's/^/| /' conftest.$ac_ext >&5
7743
7744
7745 fi
7746
7747 rm -rf conftest.dSYM
7748 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7749       conftest$ac_exeext
7750   if test "${ac_cv_search_crypt+set}" = set; then
7751   break
7752 fi
7753 done
7754 if test "${ac_cv_search_crypt+set}" = set; then
7755   :
7756 else
7757   ac_cv_search_crypt=no
7758 fi
7759 rm conftest.$ac_ext
7760 LIBS=$ac_func_search_save_LIBS
7761 fi
7762 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
7763 $as_echo "$ac_cv_search_crypt" >&6; }
7764 ac_res=$ac_cv_search_crypt
7765 if test "$ac_res" != no; then
7766   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7767
7768 fi
7769
7770 # Solaris:
7771 { $as_echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
7772 $as_echo_n "checking for library containing fdatasync... " >&6; }
7773 if test "${ac_cv_search_fdatasync+set}" = set; then
7774   $as_echo_n "(cached) " >&6
7775 else
7776   ac_func_search_save_LIBS=$LIBS
7777 cat >conftest.$ac_ext <<_ACEOF
7778 /* confdefs.h.  */
7779 _ACEOF
7780 cat confdefs.h >>conftest.$ac_ext
7781 cat >>conftest.$ac_ext <<_ACEOF
7782 /* end confdefs.h.  */
7783
7784 /* Override any GCC internal prototype to avoid an error.
7785    Use char because int might match the return type of a GCC
7786    builtin and then its argument prototype would still apply.  */
7787 #ifdef __cplusplus
7788 extern "C"
7789 #endif
7790 char fdatasync ();
7791 int
7792 main ()
7793 {
7794 return fdatasync ();
7795   ;
7796   return 0;
7797 }
7798 _ACEOF
7799 for ac_lib in '' rt posix4; do
7800   if test -z "$ac_lib"; then
7801     ac_res="none required"
7802   else
7803     ac_res=-l$ac_lib
7804     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7805   fi
7806   rm -f conftest.$ac_objext conftest$ac_exeext
7807 if { (ac_try="$ac_link"
7808 case "(($ac_try" in
7809   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7810   *) ac_try_echo=$ac_try;;
7811 esac
7812 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7813 $as_echo "$ac_try_echo") >&5
7814   (eval "$ac_link") 2>conftest.er1
7815   ac_status=$?
7816   grep -v '^ *+' conftest.er1 >conftest.err
7817   rm -f conftest.er1
7818   cat conftest.err >&5
7819   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7820   (exit $ac_status); } && {
7821          test -z "$ac_c_werror_flag" ||
7822          test ! -s conftest.err
7823        } && test -s conftest$ac_exeext && {
7824          test "$cross_compiling" = yes ||
7825          $as_test_x conftest$ac_exeext
7826        }; then
7827   ac_cv_search_fdatasync=$ac_res
7828 else
7829   $as_echo "$as_me: failed program was:" >&5
7830 sed 's/^/| /' conftest.$ac_ext >&5
7831
7832
7833 fi
7834
7835 rm -rf conftest.dSYM
7836 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7837       conftest$ac_exeext
7838   if test "${ac_cv_search_fdatasync+set}" = set; then
7839   break
7840 fi
7841 done
7842 if test "${ac_cv_search_fdatasync+set}" = set; then
7843   :
7844 else
7845   ac_cv_search_fdatasync=no
7846 fi
7847 rm conftest.$ac_ext
7848 LIBS=$ac_func_search_save_LIBS
7849 fi
7850 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
7851 $as_echo "$ac_cv_search_fdatasync" >&6; }
7852 ac_res=$ac_cv_search_fdatasync
7853 if test "$ac_res" != no; then
7854   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7855
7856 fi
7857
7858 # Required for thread_test.c on Solaris 2.5:
7859 # Other ports use it too (HP-UX) so test unconditionally
7860 { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname_r" >&5
7861 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
7862 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
7863   $as_echo_n "(cached) " >&6
7864 else
7865   ac_func_search_save_LIBS=$LIBS
7866 cat >conftest.$ac_ext <<_ACEOF
7867 /* confdefs.h.  */
7868 _ACEOF
7869 cat confdefs.h >>conftest.$ac_ext
7870 cat >>conftest.$ac_ext <<_ACEOF
7871 /* end confdefs.h.  */
7872
7873 /* Override any GCC internal prototype to avoid an error.
7874    Use char because int might match the return type of a GCC
7875    builtin and then its argument prototype would still apply.  */
7876 #ifdef __cplusplus
7877 extern "C"
7878 #endif
7879 char gethostbyname_r ();
7880 int
7881 main ()
7882 {
7883 return gethostbyname_r ();
7884   ;
7885   return 0;
7886 }
7887 _ACEOF
7888 for ac_lib in '' nsl; do
7889   if test -z "$ac_lib"; then
7890     ac_res="none required"
7891   else
7892     ac_res=-l$ac_lib
7893     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7894   fi
7895   rm -f conftest.$ac_objext conftest$ac_exeext
7896 if { (ac_try="$ac_link"
7897 case "(($ac_try" in
7898   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7899   *) ac_try_echo=$ac_try;;
7900 esac
7901 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7902 $as_echo "$ac_try_echo") >&5
7903   (eval "$ac_link") 2>conftest.er1
7904   ac_status=$?
7905   grep -v '^ *+' conftest.er1 >conftest.err
7906   rm -f conftest.er1
7907   cat conftest.err >&5
7908   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7909   (exit $ac_status); } && {
7910          test -z "$ac_c_werror_flag" ||
7911          test ! -s conftest.err
7912        } && test -s conftest$ac_exeext && {
7913          test "$cross_compiling" = yes ||
7914          $as_test_x conftest$ac_exeext
7915        }; then
7916   ac_cv_search_gethostbyname_r=$ac_res
7917 else
7918   $as_echo "$as_me: failed program was:" >&5
7919 sed 's/^/| /' conftest.$ac_ext >&5
7920
7921
7922 fi
7923
7924 rm -rf conftest.dSYM
7925 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7926       conftest$ac_exeext
7927   if test "${ac_cv_search_gethostbyname_r+set}" = set; then
7928   break
7929 fi
7930 done
7931 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
7932   :
7933 else
7934   ac_cv_search_gethostbyname_r=no
7935 fi
7936 rm conftest.$ac_ext
7937 LIBS=$ac_func_search_save_LIBS
7938 fi
7939 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname_r" >&5
7940 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
7941 ac_res=$ac_cv_search_gethostbyname_r
7942 if test "$ac_res" != no; then
7943   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7944
7945 fi
7946
7947 # Cygwin:
7948 { $as_echo "$as_me:$LINENO: checking for library containing shmget" >&5
7949 $as_echo_n "checking for library containing shmget... " >&6; }
7950 if test "${ac_cv_search_shmget+set}" = set; then
7951   $as_echo_n "(cached) " >&6
7952 else
7953   ac_func_search_save_LIBS=$LIBS
7954 cat >conftest.$ac_ext <<_ACEOF
7955 /* confdefs.h.  */
7956 _ACEOF
7957 cat confdefs.h >>conftest.$ac_ext
7958 cat >>conftest.$ac_ext <<_ACEOF
7959 /* end confdefs.h.  */
7960
7961 /* Override any GCC internal prototype to avoid an error.
7962    Use char because int might match the return type of a GCC
7963    builtin and then its argument prototype would still apply.  */
7964 #ifdef __cplusplus
7965 extern "C"
7966 #endif
7967 char shmget ();
7968 int
7969 main ()
7970 {
7971 return shmget ();
7972   ;
7973   return 0;
7974 }
7975 _ACEOF
7976 for ac_lib in '' cygipc; do
7977   if test -z "$ac_lib"; then
7978     ac_res="none required"
7979   else
7980     ac_res=-l$ac_lib
7981     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7982   fi
7983   rm -f conftest.$ac_objext conftest$ac_exeext
7984 if { (ac_try="$ac_link"
7985 case "(($ac_try" in
7986   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7987   *) ac_try_echo=$ac_try;;
7988 esac
7989 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7990 $as_echo "$ac_try_echo") >&5
7991   (eval "$ac_link") 2>conftest.er1
7992   ac_status=$?
7993   grep -v '^ *+' conftest.er1 >conftest.err
7994   rm -f conftest.er1
7995   cat conftest.err >&5
7996   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7997   (exit $ac_status); } && {
7998          test -z "$ac_c_werror_flag" ||
7999          test ! -s conftest.err
8000        } && test -s conftest$ac_exeext && {
8001          test "$cross_compiling" = yes ||
8002          $as_test_x conftest$ac_exeext
8003        }; then
8004   ac_cv_search_shmget=$ac_res
8005 else
8006   $as_echo "$as_me: failed program was:" >&5
8007 sed 's/^/| /' conftest.$ac_ext >&5
8008
8009
8010 fi
8011
8012 rm -rf conftest.dSYM
8013 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8014       conftest$ac_exeext
8015   if test "${ac_cv_search_shmget+set}" = set; then
8016   break
8017 fi
8018 done
8019 if test "${ac_cv_search_shmget+set}" = set; then
8020   :
8021 else
8022   ac_cv_search_shmget=no
8023 fi
8024 rm conftest.$ac_ext
8025 LIBS=$ac_func_search_save_LIBS
8026 fi
8027 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
8028 $as_echo "$ac_cv_search_shmget" >&6; }
8029 ac_res=$ac_cv_search_shmget
8030 if test "$ac_res" != no; then
8031   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8032
8033 fi
8034
8035
8036 if test "$with_readline" = yes; then
8037
8038
8039 if test "${pgac_cv_check_readline+set}" = set; then
8040   $as_echo_n "(cached) " >&6
8041 else
8042   pgac_cv_check_readline=no
8043 pgac_save_LIBS=$LIBS
8044 if test x"$with_libedit_preferred" != x"yes"
8045 then    READLINE_ORDER="-lreadline -ledit"
8046 else    READLINE_ORDER="-ledit -lreadline"
8047 fi
8048 for pgac_rllib in $READLINE_ORDER ; do
8049   { $as_echo "$as_me:$LINENO: checking for ${pgac_rllib}" >&5
8050 $as_echo_n "checking for ${pgac_rllib}... " >&6; }
8051   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
8052     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
8053     cat >conftest.$ac_ext <<_ACEOF
8054 /* confdefs.h.  */
8055 _ACEOF
8056 cat confdefs.h >>conftest.$ac_ext
8057 cat >>conftest.$ac_ext <<_ACEOF
8058 /* end confdefs.h.  */
8059
8060 /* Override any GCC internal prototype to avoid an error.
8061    Use char because int might match the return type of a GCC
8062    builtin and then its argument prototype would still apply.  */
8063 #ifdef __cplusplus
8064 extern "C"
8065 #endif
8066 char readline ();
8067 int
8068 main ()
8069 {
8070 return readline ();
8071   ;
8072   return 0;
8073 }
8074 _ACEOF
8075 rm -f conftest.$ac_objext conftest$ac_exeext
8076 if { (ac_try="$ac_link"
8077 case "(($ac_try" in
8078   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8079   *) ac_try_echo=$ac_try;;
8080 esac
8081 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8082 $as_echo "$ac_try_echo") >&5
8083   (eval "$ac_link") 2>conftest.er1
8084   ac_status=$?
8085   grep -v '^ *+' conftest.er1 >conftest.err
8086   rm -f conftest.er1
8087   cat conftest.err >&5
8088   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8089   (exit $ac_status); } && {
8090          test -z "$ac_c_werror_flag" ||
8091          test ! -s conftest.err
8092        } && test -s conftest$ac_exeext && {
8093          test "$cross_compiling" = yes ||
8094          $as_test_x conftest$ac_exeext
8095        }; then
8096
8097       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
8098       # recognize dependent libraries; assume curses is needed if we didn't
8099       # find any dependency.
8100       case $host_os in
8101         netbsd* | openbsd* | irix*)
8102           if test x"$pgac_lib" = x"" ; then
8103             pgac_lib=" -lcurses"
8104           fi ;;
8105       esac
8106
8107       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
8108       break
8109
8110 else
8111   $as_echo "$as_me: failed program was:" >&5
8112 sed 's/^/| /' conftest.$ac_ext >&5
8113
8114
8115 fi
8116
8117 rm -rf conftest.dSYM
8118 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8119       conftest$ac_exeext conftest.$ac_ext
8120   done
8121   if test "$pgac_cv_check_readline" != no ; then
8122     { $as_echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
8123 $as_echo "yes ($pgac_cv_check_readline)" >&6; }
8124     break
8125   else
8126     { $as_echo "$as_me:$LINENO: result: no" >&5
8127 $as_echo "no" >&6; }
8128   fi
8129 done
8130 LIBS=$pgac_save_LIBS
8131
8132 fi
8133
8134 if test "$pgac_cv_check_readline" != no ; then
8135   LIBS="$pgac_cv_check_readline $LIBS"
8136
8137 cat >>confdefs.h <<\_ACEOF
8138 #define HAVE_LIBREADLINE 1
8139 _ACEOF
8140
8141 fi
8142
8143
8144   if test x"$pgac_cv_check_readline" = x"no"; then
8145     { { $as_echo "$as_me:$LINENO: error: readline library not found
8146 If you have readline already installed, see config.log for details on the
8147 failure.  It is possible the compiler isn't looking in the proper directory.
8148 Use --without-readline to disable readline support." >&5
8149 $as_echo "$as_me: error: readline library not found
8150 If you have readline already installed, see config.log for details on the
8151 failure.  It is possible the compiler isn't looking in the proper directory.
8152 Use --without-readline to disable readline support." >&2;}
8153    { (exit 1); exit 1; }; }
8154   fi
8155 fi
8156
8157 if test "$with_zlib" = yes; then
8158
8159 { $as_echo "$as_me:$LINENO: checking for inflate in -lz" >&5
8160 $as_echo_n "checking for inflate in -lz... " >&6; }
8161 if test "${ac_cv_lib_z_inflate+set}" = set; then
8162   $as_echo_n "(cached) " >&6
8163 else
8164   ac_check_lib_save_LIBS=$LIBS
8165 LIBS="-lz  $LIBS"
8166 cat >conftest.$ac_ext <<_ACEOF
8167 /* confdefs.h.  */
8168 _ACEOF
8169 cat confdefs.h >>conftest.$ac_ext
8170 cat >>conftest.$ac_ext <<_ACEOF
8171 /* end confdefs.h.  */
8172
8173 /* Override any GCC internal prototype to avoid an error.
8174    Use char because int might match the return type of a GCC
8175    builtin and then its argument prototype would still apply.  */
8176 #ifdef __cplusplus
8177 extern "C"
8178 #endif
8179 char inflate ();
8180 int
8181 main ()
8182 {
8183 return inflate ();
8184   ;
8185   return 0;
8186 }
8187 _ACEOF
8188 rm -f conftest.$ac_objext conftest$ac_exeext
8189 if { (ac_try="$ac_link"
8190 case "(($ac_try" in
8191   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8192   *) ac_try_echo=$ac_try;;
8193 esac
8194 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8195 $as_echo "$ac_try_echo") >&5
8196   (eval "$ac_link") 2>conftest.er1
8197   ac_status=$?
8198   grep -v '^ *+' conftest.er1 >conftest.err
8199   rm -f conftest.er1
8200   cat conftest.err >&5
8201   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8202   (exit $ac_status); } && {
8203          test -z "$ac_c_werror_flag" ||
8204          test ! -s conftest.err
8205        } && test -s conftest$ac_exeext && {
8206          test "$cross_compiling" = yes ||
8207          $as_test_x conftest$ac_exeext
8208        }; then
8209   ac_cv_lib_z_inflate=yes
8210 else
8211   $as_echo "$as_me: failed program was:" >&5
8212 sed 's/^/| /' conftest.$ac_ext >&5
8213
8214         ac_cv_lib_z_inflate=no
8215 fi
8216
8217 rm -rf conftest.dSYM
8218 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8219       conftest$ac_exeext conftest.$ac_ext
8220 LIBS=$ac_check_lib_save_LIBS
8221 fi
8222 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
8223 $as_echo "$ac_cv_lib_z_inflate" >&6; }
8224 if test "x$ac_cv_lib_z_inflate" = x""yes; then
8225   cat >>confdefs.h <<_ACEOF
8226 #define HAVE_LIBZ 1
8227 _ACEOF
8228
8229   LIBS="-lz $LIBS"
8230
8231 else
8232   { { $as_echo "$as_me:$LINENO: error: zlib library not found
8233 If you have zlib already installed, see config.log for details on the
8234 failure.  It is possible the compiler isn't looking in the proper directory.
8235 Use --without-zlib to disable zlib support." >&5
8236 $as_echo "$as_me: error: zlib library not found
8237 If you have zlib already installed, see config.log for details on the
8238 failure.  It is possible the compiler isn't looking in the proper directory.
8239 Use --without-zlib to disable zlib support." >&2;}
8240    { (exit 1); exit 1; }; }
8241 fi
8242
8243 fi
8244
8245 if test "$enable_spinlocks" = yes; then
8246
8247 cat >>confdefs.h <<\_ACEOF
8248 #define HAVE_SPINLOCKS 1
8249 _ACEOF
8250
8251 else
8252   { $as_echo "$as_me:$LINENO: WARNING:
8253 *** Not using spinlocks will cause poor performance." >&5
8254 $as_echo "$as_me: WARNING:
8255 *** Not using spinlocks will cause poor performance." >&2;}
8256 fi
8257
8258 if test "$with_gssapi" = yes ; then
8259   if test "$PORTNAME" != "win32"; then
8260     { $as_echo "$as_me:$LINENO: checking for library containing gss_init_sec_context" >&5
8261 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
8262 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8263   $as_echo_n "(cached) " >&6
8264 else
8265   ac_func_search_save_LIBS=$LIBS
8266 cat >conftest.$ac_ext <<_ACEOF
8267 /* confdefs.h.  */
8268 _ACEOF
8269 cat confdefs.h >>conftest.$ac_ext
8270 cat >>conftest.$ac_ext <<_ACEOF
8271 /* end confdefs.h.  */
8272
8273 /* Override any GCC internal prototype to avoid an error.
8274    Use char because int might match the return type of a GCC
8275    builtin and then its argument prototype would still apply.  */
8276 #ifdef __cplusplus
8277 extern "C"
8278 #endif
8279 char gss_init_sec_context ();
8280 int
8281 main ()
8282 {
8283 return gss_init_sec_context ();
8284   ;
8285   return 0;
8286 }
8287 _ACEOF
8288 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
8289   if test -z "$ac_lib"; then
8290     ac_res="none required"
8291   else
8292     ac_res=-l$ac_lib
8293     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8294   fi
8295   rm -f conftest.$ac_objext conftest$ac_exeext
8296 if { (ac_try="$ac_link"
8297 case "(($ac_try" in
8298   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8299   *) ac_try_echo=$ac_try;;
8300 esac
8301 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8302 $as_echo "$ac_try_echo") >&5
8303   (eval "$ac_link") 2>conftest.er1
8304   ac_status=$?
8305   grep -v '^ *+' conftest.er1 >conftest.err
8306   rm -f conftest.er1
8307   cat conftest.err >&5
8308   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8309   (exit $ac_status); } && {
8310          test -z "$ac_c_werror_flag" ||
8311          test ! -s conftest.err
8312        } && test -s conftest$ac_exeext && {
8313          test "$cross_compiling" = yes ||
8314          $as_test_x conftest$ac_exeext
8315        }; then
8316   ac_cv_search_gss_init_sec_context=$ac_res
8317 else
8318   $as_echo "$as_me: failed program was:" >&5
8319 sed 's/^/| /' conftest.$ac_ext >&5
8320
8321
8322 fi
8323
8324 rm -rf conftest.dSYM
8325 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8326       conftest$ac_exeext
8327   if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8328   break
8329 fi
8330 done
8331 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8332   :
8333 else
8334   ac_cv_search_gss_init_sec_context=no
8335 fi
8336 rm conftest.$ac_ext
8337 LIBS=$ac_func_search_save_LIBS
8338 fi
8339 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gss_init_sec_context" >&5
8340 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
8341 ac_res=$ac_cv_search_gss_init_sec_context
8342 if test "$ac_res" != no; then
8343   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8344
8345 else
8346   { { $as_echo "$as_me:$LINENO: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&5
8347 $as_echo "$as_me: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&2;}
8348    { (exit 1); exit 1; }; }
8349 fi
8350
8351   else
8352     LIBS="$LIBS -lgssapi32"
8353   fi
8354 fi
8355
8356 if test "$with_krb5" = yes ; then
8357   if test "$PORTNAME" != "win32"; then
8358      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8359 $as_echo_n "checking for library containing com_err... " >&6; }
8360 if test "${ac_cv_search_com_err+set}" = set; then
8361   $as_echo_n "(cached) " >&6
8362 else
8363   ac_func_search_save_LIBS=$LIBS
8364 cat >conftest.$ac_ext <<_ACEOF
8365 /* confdefs.h.  */
8366 _ACEOF
8367 cat confdefs.h >>conftest.$ac_ext
8368 cat >>conftest.$ac_ext <<_ACEOF
8369 /* end confdefs.h.  */
8370
8371 /* Override any GCC internal prototype to avoid an error.
8372    Use char because int might match the return type of a GCC
8373    builtin and then its argument prototype would still apply.  */
8374 #ifdef __cplusplus
8375 extern "C"
8376 #endif
8377 char com_err ();
8378 int
8379 main ()
8380 {
8381 return com_err ();
8382   ;
8383   return 0;
8384 }
8385 _ACEOF
8386 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken' com_err 'com_err -lssl -lcrypto'; do
8387   if test -z "$ac_lib"; then
8388     ac_res="none required"
8389   else
8390     ac_res=-l$ac_lib
8391     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8392   fi
8393   rm -f conftest.$ac_objext conftest$ac_exeext
8394 if { (ac_try="$ac_link"
8395 case "(($ac_try" in
8396   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8397   *) ac_try_echo=$ac_try;;
8398 esac
8399 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8400 $as_echo "$ac_try_echo") >&5
8401   (eval "$ac_link") 2>conftest.er1
8402   ac_status=$?
8403   grep -v '^ *+' conftest.er1 >conftest.err
8404   rm -f conftest.er1
8405   cat conftest.err >&5
8406   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8407   (exit $ac_status); } && {
8408          test -z "$ac_c_werror_flag" ||
8409          test ! -s conftest.err
8410        } && test -s conftest$ac_exeext && {
8411          test "$cross_compiling" = yes ||
8412          $as_test_x conftest$ac_exeext
8413        }; then
8414   ac_cv_search_com_err=$ac_res
8415 else
8416   $as_echo "$as_me: failed program was:" >&5
8417 sed 's/^/| /' conftest.$ac_ext >&5
8418
8419
8420 fi
8421
8422 rm -rf conftest.dSYM
8423 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8424       conftest$ac_exeext
8425   if test "${ac_cv_search_com_err+set}" = set; then
8426   break
8427 fi
8428 done
8429 if test "${ac_cv_search_com_err+set}" = set; then
8430   :
8431 else
8432   ac_cv_search_com_err=no
8433 fi
8434 rm conftest.$ac_ext
8435 LIBS=$ac_func_search_save_LIBS
8436 fi
8437 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8438 $as_echo "$ac_cv_search_com_err" >&6; }
8439 ac_res=$ac_cv_search_com_err
8440 if test "$ac_res" != no; then
8441   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8442
8443 else
8444   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8445 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8446    { (exit 1); exit 1; }; }
8447 fi
8448
8449      { $as_echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
8450 $as_echo_n "checking for library containing krb5_sendauth... " >&6; }
8451 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8452   $as_echo_n "(cached) " >&6
8453 else
8454   ac_func_search_save_LIBS=$LIBS
8455 cat >conftest.$ac_ext <<_ACEOF
8456 /* confdefs.h.  */
8457 _ACEOF
8458 cat confdefs.h >>conftest.$ac_ext
8459 cat >>conftest.$ac_ext <<_ACEOF
8460 /* end confdefs.h.  */
8461
8462 /* Override any GCC internal prototype to avoid an error.
8463    Use char because int might match the return type of a GCC
8464    builtin and then its argument prototype would still apply.  */
8465 #ifdef __cplusplus
8466 extern "C"
8467 #endif
8468 char krb5_sendauth ();
8469 int
8470 main ()
8471 {
8472 return krb5_sendauth ();
8473   ;
8474   return 0;
8475 }
8476 _ACEOF
8477 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken'; do
8478   if test -z "$ac_lib"; then
8479     ac_res="none required"
8480   else
8481     ac_res=-l$ac_lib
8482     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8483   fi
8484   rm -f conftest.$ac_objext conftest$ac_exeext
8485 if { (ac_try="$ac_link"
8486 case "(($ac_try" in
8487   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8488   *) ac_try_echo=$ac_try;;
8489 esac
8490 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8491 $as_echo "$ac_try_echo") >&5
8492   (eval "$ac_link") 2>conftest.er1
8493   ac_status=$?
8494   grep -v '^ *+' conftest.er1 >conftest.err
8495   rm -f conftest.er1
8496   cat conftest.err >&5
8497   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8498   (exit $ac_status); } && {
8499          test -z "$ac_c_werror_flag" ||
8500          test ! -s conftest.err
8501        } && test -s conftest$ac_exeext && {
8502          test "$cross_compiling" = yes ||
8503          $as_test_x conftest$ac_exeext
8504        }; then
8505   ac_cv_search_krb5_sendauth=$ac_res
8506 else
8507   $as_echo "$as_me: failed program was:" >&5
8508 sed 's/^/| /' conftest.$ac_ext >&5
8509
8510
8511 fi
8512
8513 rm -rf conftest.dSYM
8514 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8515       conftest$ac_exeext
8516   if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8517   break
8518 fi
8519 done
8520 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8521   :
8522 else
8523   ac_cv_search_krb5_sendauth=no
8524 fi
8525 rm conftest.$ac_ext
8526 LIBS=$ac_func_search_save_LIBS
8527 fi
8528 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
8529 $as_echo "$ac_cv_search_krb5_sendauth" >&6; }
8530 ac_res=$ac_cv_search_krb5_sendauth
8531 if test "$ac_res" != no; then
8532   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8533
8534 else
8535   { { $as_echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
8536 $as_echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
8537    { (exit 1); exit 1; }; }
8538 fi
8539
8540   else
8541      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8542 $as_echo_n "checking for library containing com_err... " >&6; }
8543 if test "${ac_cv_search_com_err+set}" = set; then
8544   $as_echo_n "(cached) " >&6
8545 else
8546   ac_func_search_save_LIBS=$LIBS
8547 cat >conftest.$ac_ext <<_ACEOF
8548 /* confdefs.h.  */
8549 _ACEOF
8550 cat confdefs.h >>conftest.$ac_ext
8551 cat >>conftest.$ac_ext <<_ACEOF
8552 /* end confdefs.h.  */
8553
8554 /* Override any GCC internal prototype to avoid an error.
8555    Use char because int might match the return type of a GCC
8556    builtin and then its argument prototype would still apply.  */
8557 #ifdef __cplusplus
8558 extern "C"
8559 #endif
8560 char com_err ();
8561 int
8562 main ()
8563 {
8564 return com_err ();
8565   ;
8566   return 0;
8567 }
8568 _ACEOF
8569 for ac_lib in '' 'comerr32 -lkrb5_32'; do
8570   if test -z "$ac_lib"; then
8571     ac_res="none required"
8572   else
8573     ac_res=-l$ac_lib
8574     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8575   fi
8576   rm -f conftest.$ac_objext conftest$ac_exeext
8577 if { (ac_try="$ac_link"
8578 case "(($ac_try" in
8579   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8580   *) ac_try_echo=$ac_try;;
8581 esac
8582 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8583 $as_echo "$ac_try_echo") >&5
8584   (eval "$ac_link") 2>conftest.er1
8585   ac_status=$?
8586   grep -v '^ *+' conftest.er1 >conftest.err
8587   rm -f conftest.er1
8588   cat conftest.err >&5
8589   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8590   (exit $ac_status); } && {
8591          test -z "$ac_c_werror_flag" ||
8592          test ! -s conftest.err
8593        } && test -s conftest$ac_exeext && {
8594          test "$cross_compiling" = yes ||
8595          $as_test_x conftest$ac_exeext
8596        }; then
8597   ac_cv_search_com_err=$ac_res
8598 else
8599   $as_echo "$as_me: failed program was:" >&5
8600 sed 's/^/| /' conftest.$ac_ext >&5
8601
8602
8603 fi
8604
8605 rm -rf conftest.dSYM
8606 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8607       conftest$ac_exeext
8608   if test "${ac_cv_search_com_err+set}" = set; then
8609   break
8610 fi
8611 done
8612 if test "${ac_cv_search_com_err+set}" = set; then
8613   :
8614 else
8615   ac_cv_search_com_err=no
8616 fi
8617 rm conftest.$ac_ext
8618 LIBS=$ac_func_search_save_LIBS
8619 fi
8620 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8621 $as_echo "$ac_cv_search_com_err" >&6; }
8622 ac_res=$ac_cv_search_com_err
8623 if test "$ac_res" != no; then
8624   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8625
8626 else
8627   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8628 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8629    { (exit 1); exit 1; }; }
8630 fi
8631
8632   fi
8633 fi
8634
8635 if test "$with_openssl" = yes ; then
8636     if test "$PORTNAME" != "win32"; then
8637
8638 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
8639 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
8640 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
8641   $as_echo_n "(cached) " >&6
8642 else
8643   ac_check_lib_save_LIBS=$LIBS
8644 LIBS="-lcrypto  $LIBS"
8645 cat >conftest.$ac_ext <<_ACEOF
8646 /* confdefs.h.  */
8647 _ACEOF
8648 cat confdefs.h >>conftest.$ac_ext
8649 cat >>conftest.$ac_ext <<_ACEOF
8650 /* end confdefs.h.  */
8651
8652 /* Override any GCC internal prototype to avoid an error.
8653    Use char because int might match the return type of a GCC
8654    builtin and then its argument prototype would still apply.  */
8655 #ifdef __cplusplus
8656 extern "C"
8657 #endif
8658 char CRYPTO_new_ex_data ();
8659 int
8660 main ()
8661 {
8662 return CRYPTO_new_ex_data ();
8663   ;
8664   return 0;
8665 }
8666 _ACEOF
8667 rm -f conftest.$ac_objext conftest$ac_exeext
8668 if { (ac_try="$ac_link"
8669 case "(($ac_try" in
8670   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8671   *) ac_try_echo=$ac_try;;
8672 esac
8673 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8674 $as_echo "$ac_try_echo") >&5
8675   (eval "$ac_link") 2>conftest.er1
8676   ac_status=$?
8677   grep -v '^ *+' conftest.er1 >conftest.err
8678   rm -f conftest.er1
8679   cat conftest.err >&5
8680   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8681   (exit $ac_status); } && {
8682          test -z "$ac_c_werror_flag" ||
8683          test ! -s conftest.err
8684        } && test -s conftest$ac_exeext && {
8685          test "$cross_compiling" = yes ||
8686          $as_test_x conftest$ac_exeext
8687        }; then
8688   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
8689 else
8690   $as_echo "$as_me: failed program was:" >&5
8691 sed 's/^/| /' conftest.$ac_ext >&5
8692
8693         ac_cv_lib_crypto_CRYPTO_new_ex_data=no
8694 fi
8695
8696 rm -rf conftest.dSYM
8697 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8698       conftest$ac_exeext conftest.$ac_ext
8699 LIBS=$ac_check_lib_save_LIBS
8700 fi
8701 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
8702 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
8703 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = x""yes; then
8704   cat >>confdefs.h <<_ACEOF
8705 #define HAVE_LIBCRYPTO 1
8706 _ACEOF
8707
8708   LIBS="-lcrypto $LIBS"
8709
8710 else
8711   { { $as_echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
8712 $as_echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
8713    { (exit 1); exit 1; }; }
8714 fi
8715
8716
8717 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
8718 $as_echo_n "checking for SSL_library_init in -lssl... " >&6; }
8719 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
8720   $as_echo_n "(cached) " >&6
8721 else
8722   ac_check_lib_save_LIBS=$LIBS
8723 LIBS="-lssl  $LIBS"
8724 cat >conftest.$ac_ext <<_ACEOF
8725 /* confdefs.h.  */
8726 _ACEOF
8727 cat confdefs.h >>conftest.$ac_ext
8728 cat >>conftest.$ac_ext <<_ACEOF
8729 /* end confdefs.h.  */
8730
8731 /* Override any GCC internal prototype to avoid an error.
8732    Use char because int might match the return type of a GCC
8733    builtin and then its argument prototype would still apply.  */
8734 #ifdef __cplusplus
8735 extern "C"
8736 #endif
8737 char SSL_library_init ();
8738 int
8739 main ()
8740 {
8741 return SSL_library_init ();
8742   ;
8743   return 0;
8744 }
8745 _ACEOF
8746 rm -f conftest.$ac_objext conftest$ac_exeext
8747 if { (ac_try="$ac_link"
8748 case "(($ac_try" in
8749   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8750   *) ac_try_echo=$ac_try;;
8751 esac
8752 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8753 $as_echo "$ac_try_echo") >&5
8754   (eval "$ac_link") 2>conftest.er1
8755   ac_status=$?
8756   grep -v '^ *+' conftest.er1 >conftest.err
8757   rm -f conftest.er1
8758   cat conftest.err >&5
8759   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8760   (exit $ac_status); } && {
8761          test -z "$ac_c_werror_flag" ||
8762          test ! -s conftest.err
8763        } && test -s conftest$ac_exeext && {
8764          test "$cross_compiling" = yes ||
8765          $as_test_x conftest$ac_exeext
8766        }; then
8767   ac_cv_lib_ssl_SSL_library_init=yes
8768 else
8769   $as_echo "$as_me: failed program was:" >&5
8770 sed 's/^/| /' conftest.$ac_ext >&5
8771
8772         ac_cv_lib_ssl_SSL_library_init=no
8773 fi
8774
8775 rm -rf conftest.dSYM
8776 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8777       conftest$ac_exeext conftest.$ac_ext
8778 LIBS=$ac_check_lib_save_LIBS
8779 fi
8780 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
8781 $as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; }
8782 if test "x$ac_cv_lib_ssl_SSL_library_init" = x""yes; then
8783   cat >>confdefs.h <<_ACEOF
8784 #define HAVE_LIBSSL 1
8785 _ACEOF
8786
8787   LIBS="-lssl $LIBS"
8788
8789 else
8790   { { $as_echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
8791 $as_echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
8792    { (exit 1); exit 1; }; }
8793 fi
8794
8795   else
8796
8797 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
8798 $as_echo_n "checking for CRYPTO_new_ex_data in -leay32... " >&6; }
8799 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
8800   $as_echo_n "(cached) " >&6
8801 else
8802   ac_check_lib_save_LIBS=$LIBS
8803 LIBS="-leay32  $LIBS"
8804 cat >conftest.$ac_ext <<_ACEOF
8805 /* confdefs.h.  */
8806 _ACEOF
8807 cat confdefs.h >>conftest.$ac_ext
8808 cat >>conftest.$ac_ext <<_ACEOF
8809 /* end confdefs.h.  */
8810
8811 /* Override any GCC internal prototype to avoid an error.
8812    Use char because int might match the return type of a GCC
8813    builtin and then its argument prototype would still apply.  */
8814 #ifdef __cplusplus
8815 extern "C"
8816 #endif
8817 char CRYPTO_new_ex_data ();
8818 int
8819 main ()
8820 {
8821 return CRYPTO_new_ex_data ();
8822   ;
8823   return 0;
8824 }
8825 _ACEOF
8826 rm -f conftest.$ac_objext conftest$ac_exeext
8827 if { (ac_try="$ac_link"
8828 case "(($ac_try" in
8829   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8830   *) ac_try_echo=$ac_try;;
8831 esac
8832 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8833 $as_echo "$ac_try_echo") >&5
8834   (eval "$ac_link") 2>conftest.er1
8835   ac_status=$?
8836   grep -v '^ *+' conftest.er1 >conftest.err
8837   rm -f conftest.er1
8838   cat conftest.err >&5
8839   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8840   (exit $ac_status); } && {
8841          test -z "$ac_c_werror_flag" ||
8842          test ! -s conftest.err
8843        } && test -s conftest$ac_exeext && {
8844          test "$cross_compiling" = yes ||
8845          $as_test_x conftest$ac_exeext
8846        }; then
8847   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
8848 else
8849   $as_echo "$as_me: failed program was:" >&5
8850 sed 's/^/| /' conftest.$ac_ext >&5
8851
8852         ac_cv_lib_eay32_CRYPTO_new_ex_data=no
8853 fi
8854
8855 rm -rf conftest.dSYM
8856 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8857       conftest$ac_exeext conftest.$ac_ext
8858 LIBS=$ac_check_lib_save_LIBS
8859 fi
8860 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
8861 $as_echo "$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6; }
8862 if test "x$ac_cv_lib_eay32_CRYPTO_new_ex_data" = x""yes; then
8863   cat >>confdefs.h <<_ACEOF
8864 #define HAVE_LIBEAY32 1
8865 _ACEOF
8866
8867   LIBS="-leay32 $LIBS"
8868
8869 else
8870   { { $as_echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
8871 $as_echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
8872    { (exit 1); exit 1; }; }
8873 fi
8874
8875
8876 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
8877 $as_echo_n "checking for SSL_library_init in -lssleay32... " >&6; }
8878 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
8879   $as_echo_n "(cached) " >&6
8880 else
8881   ac_check_lib_save_LIBS=$LIBS
8882 LIBS="-lssleay32  $LIBS"
8883 cat >conftest.$ac_ext <<_ACEOF
8884 /* confdefs.h.  */
8885 _ACEOF
8886 cat confdefs.h >>conftest.$ac_ext
8887 cat >>conftest.$ac_ext <<_ACEOF
8888 /* end confdefs.h.  */
8889
8890 /* Override any GCC internal prototype to avoid an error.
8891    Use char because int might match the return type of a GCC
8892    builtin and then its argument prototype would still apply.  */
8893 #ifdef __cplusplus
8894 extern "C"
8895 #endif
8896 char SSL_library_init ();
8897 int
8898 main ()
8899 {
8900 return SSL_library_init ();
8901   ;
8902   return 0;
8903 }
8904 _ACEOF
8905 rm -f conftest.$ac_objext conftest$ac_exeext
8906 if { (ac_try="$ac_link"
8907 case "(($ac_try" in
8908   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8909   *) ac_try_echo=$ac_try;;
8910 esac
8911 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8912 $as_echo "$ac_try_echo") >&5
8913   (eval "$ac_link") 2>conftest.er1
8914   ac_status=$?
8915   grep -v '^ *+' conftest.er1 >conftest.err
8916   rm -f conftest.er1
8917   cat conftest.err >&5
8918   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8919   (exit $ac_status); } && {
8920          test -z "$ac_c_werror_flag" ||
8921          test ! -s conftest.err
8922        } && test -s conftest$ac_exeext && {
8923          test "$cross_compiling" = yes ||
8924          $as_test_x conftest$ac_exeext
8925        }; then
8926   ac_cv_lib_ssleay32_SSL_library_init=yes
8927 else
8928   $as_echo "$as_me: failed program was:" >&5
8929 sed 's/^/| /' conftest.$ac_ext >&5
8930
8931         ac_cv_lib_ssleay32_SSL_library_init=no
8932 fi
8933
8934 rm -rf conftest.dSYM
8935 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8936       conftest$ac_exeext conftest.$ac_ext
8937 LIBS=$ac_check_lib_save_LIBS
8938 fi
8939 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
8940 $as_echo "$ac_cv_lib_ssleay32_SSL_library_init" >&6; }
8941 if test "x$ac_cv_lib_ssleay32_SSL_library_init" = x""yes; then
8942   cat >>confdefs.h <<_ACEOF
8943 #define HAVE_LIBSSLEAY32 1
8944 _ACEOF
8945
8946   LIBS="-lssleay32 $LIBS"
8947
8948 else
8949   { { $as_echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
8950 $as_echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
8951    { (exit 1); exit 1; }; }
8952 fi
8953
8954   fi
8955 fi
8956
8957 if test "$with_pam" = yes ; then
8958
8959 { $as_echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
8960 $as_echo_n "checking for pam_start in -lpam... " >&6; }
8961 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
8962   $as_echo_n "(cached) " >&6
8963 else
8964   ac_check_lib_save_LIBS=$LIBS
8965 LIBS="-lpam  $LIBS"
8966 cat >conftest.$ac_ext <<_ACEOF
8967 /* confdefs.h.  */
8968 _ACEOF
8969 cat confdefs.h >>conftest.$ac_ext
8970 cat >>conftest.$ac_ext <<_ACEOF
8971 /* end confdefs.h.  */
8972
8973 /* Override any GCC internal prototype to avoid an error.
8974    Use char because int might match the return type of a GCC
8975    builtin and then its argument prototype would still apply.  */
8976 #ifdef __cplusplus
8977 extern "C"
8978 #endif
8979 char pam_start ();
8980 int
8981 main ()
8982 {
8983 return pam_start ();
8984   ;
8985   return 0;
8986 }
8987 _ACEOF
8988 rm -f conftest.$ac_objext conftest$ac_exeext
8989 if { (ac_try="$ac_link"
8990 case "(($ac_try" in
8991   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8992   *) ac_try_echo=$ac_try;;
8993 esac
8994 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8995 $as_echo "$ac_try_echo") >&5
8996   (eval "$ac_link") 2>conftest.er1
8997   ac_status=$?
8998   grep -v '^ *+' conftest.er1 >conftest.err
8999   rm -f conftest.er1
9000   cat conftest.err >&5
9001   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9002   (exit $ac_status); } && {
9003          test -z "$ac_c_werror_flag" ||
9004          test ! -s conftest.err
9005        } && test -s conftest$ac_exeext && {
9006          test "$cross_compiling" = yes ||
9007          $as_test_x conftest$ac_exeext
9008        }; then
9009   ac_cv_lib_pam_pam_start=yes
9010 else
9011   $as_echo "$as_me: failed program was:" >&5
9012 sed 's/^/| /' conftest.$ac_ext >&5
9013
9014         ac_cv_lib_pam_pam_start=no
9015 fi
9016
9017 rm -rf conftest.dSYM
9018 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9019       conftest$ac_exeext conftest.$ac_ext
9020 LIBS=$ac_check_lib_save_LIBS
9021 fi
9022 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
9023 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
9024 if test "x$ac_cv_lib_pam_pam_start" = x""yes; then
9025   cat >>confdefs.h <<_ACEOF
9026 #define HAVE_LIBPAM 1
9027 _ACEOF
9028
9029   LIBS="-lpam $LIBS"
9030
9031 else
9032   { { $as_echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
9033 $as_echo "$as_me: error: library 'pam' is required for PAM" >&2;}
9034    { (exit 1); exit 1; }; }
9035 fi
9036
9037 fi
9038
9039 if test "$with_libxml" = yes ; then
9040
9041 { $as_echo "$as_me:$LINENO: checking for xmlSaveToBuffer in -lxml2" >&5
9042 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
9043 if test "${ac_cv_lib_xml2_xmlSaveToBuffer+set}" = set; then
9044   $as_echo_n "(cached) " >&6
9045 else
9046   ac_check_lib_save_LIBS=$LIBS
9047 LIBS="-lxml2  $LIBS"
9048 cat >conftest.$ac_ext <<_ACEOF
9049 /* confdefs.h.  */
9050 _ACEOF
9051 cat confdefs.h >>conftest.$ac_ext
9052 cat >>conftest.$ac_ext <<_ACEOF
9053 /* end confdefs.h.  */
9054
9055 /* Override any GCC internal prototype to avoid an error.
9056    Use char because int might match the return type of a GCC
9057    builtin and then its argument prototype would still apply.  */
9058 #ifdef __cplusplus
9059 extern "C"
9060 #endif
9061 char xmlSaveToBuffer ();
9062 int
9063 main ()
9064 {
9065 return xmlSaveToBuffer ();
9066   ;
9067   return 0;
9068 }
9069 _ACEOF
9070 rm -f conftest.$ac_objext conftest$ac_exeext
9071 if { (ac_try="$ac_link"
9072 case "(($ac_try" in
9073   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9074   *) ac_try_echo=$ac_try;;
9075 esac
9076 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9077 $as_echo "$ac_try_echo") >&5
9078   (eval "$ac_link") 2>conftest.er1
9079   ac_status=$?
9080   grep -v '^ *+' conftest.er1 >conftest.err
9081   rm -f conftest.er1
9082   cat conftest.err >&5
9083   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9084   (exit $ac_status); } && {
9085          test -z "$ac_c_werror_flag" ||
9086          test ! -s conftest.err
9087        } && test -s conftest$ac_exeext && {
9088          test "$cross_compiling" = yes ||
9089          $as_test_x conftest$ac_exeext
9090        }; then
9091   ac_cv_lib_xml2_xmlSaveToBuffer=yes
9092 else
9093   $as_echo "$as_me: failed program was:" >&5
9094 sed 's/^/| /' conftest.$ac_ext >&5
9095
9096         ac_cv_lib_xml2_xmlSaveToBuffer=no
9097 fi
9098
9099 rm -rf conftest.dSYM
9100 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9101       conftest$ac_exeext conftest.$ac_ext
9102 LIBS=$ac_check_lib_save_LIBS
9103 fi
9104 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
9105 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
9106 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = x""yes; then
9107   cat >>confdefs.h <<_ACEOF
9108 #define HAVE_LIBXML2 1
9109 _ACEOF
9110
9111   LIBS="-lxml2 $LIBS"
9112
9113 else
9114   { { $as_echo "$as_me:$LINENO: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&5
9115 $as_echo "$as_me: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&2;}
9116    { (exit 1); exit 1; }; }
9117 fi
9118
9119 fi
9120
9121 if test "$with_libxslt" = yes ; then
9122
9123 { $as_echo "$as_me:$LINENO: checking for xsltCleanupGlobals in -lxslt" >&5
9124 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
9125 if test "${ac_cv_lib_xslt_xsltCleanupGlobals+set}" = set; then
9126   $as_echo_n "(cached) " >&6
9127 else
9128   ac_check_lib_save_LIBS=$LIBS
9129 LIBS="-lxslt  $LIBS"
9130 cat >conftest.$ac_ext <<_ACEOF
9131 /* confdefs.h.  */
9132 _ACEOF
9133 cat confdefs.h >>conftest.$ac_ext
9134 cat >>conftest.$ac_ext <<_ACEOF
9135 /* end confdefs.h.  */
9136
9137 /* Override any GCC internal prototype to avoid an error.
9138    Use char because int might match the return type of a GCC
9139    builtin and then its argument prototype would still apply.  */
9140 #ifdef __cplusplus
9141 extern "C"
9142 #endif
9143 char xsltCleanupGlobals ();
9144 int
9145 main ()
9146 {
9147 return xsltCleanupGlobals ();
9148   ;
9149   return 0;
9150 }
9151 _ACEOF
9152 rm -f conftest.$ac_objext conftest$ac_exeext
9153 if { (ac_try="$ac_link"
9154 case "(($ac_try" in
9155   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9156   *) ac_try_echo=$ac_try;;
9157 esac
9158 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9159 $as_echo "$ac_try_echo") >&5
9160   (eval "$ac_link") 2>conftest.er1
9161   ac_status=$?
9162   grep -v '^ *+' conftest.er1 >conftest.err
9163   rm -f conftest.er1
9164   cat conftest.err >&5
9165   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9166   (exit $ac_status); } && {
9167          test -z "$ac_c_werror_flag" ||
9168          test ! -s conftest.err
9169        } && test -s conftest$ac_exeext && {
9170          test "$cross_compiling" = yes ||
9171          $as_test_x conftest$ac_exeext
9172        }; then
9173   ac_cv_lib_xslt_xsltCleanupGlobals=yes
9174 else
9175   $as_echo "$as_me: failed program was:" >&5
9176 sed 's/^/| /' conftest.$ac_ext >&5
9177
9178         ac_cv_lib_xslt_xsltCleanupGlobals=no
9179 fi
9180
9181 rm -rf conftest.dSYM
9182 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9183       conftest$ac_exeext conftest.$ac_ext
9184 LIBS=$ac_check_lib_save_LIBS
9185 fi
9186 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
9187 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
9188 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = x""yes; then
9189   cat >>confdefs.h <<_ACEOF
9190 #define HAVE_LIBXSLT 1
9191 _ACEOF
9192
9193   LIBS="-lxslt $LIBS"
9194
9195 else
9196   { { $as_echo "$as_me:$LINENO: error: library 'xslt' is required for XSLT support" >&5
9197 $as_echo "$as_me: error: library 'xslt' is required for XSLT support" >&2;}
9198    { (exit 1); exit 1; }; }
9199 fi
9200
9201 fi
9202
9203 # for contrib/uuid-ossp
9204 if test "$with_ossp_uuid" = yes ; then
9205   { $as_echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5
9206 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
9207 if test "${ac_cv_lib_ossp_uuid_uuid_export+set}" = set; then
9208   $as_echo_n "(cached) " >&6
9209 else
9210   ac_check_lib_save_LIBS=$LIBS
9211 LIBS="-lossp-uuid  $LIBS"
9212 cat >conftest.$ac_ext <<_ACEOF
9213 /* confdefs.h.  */
9214 _ACEOF
9215 cat confdefs.h >>conftest.$ac_ext
9216 cat >>conftest.$ac_ext <<_ACEOF
9217 /* end confdefs.h.  */
9218
9219 /* Override any GCC internal prototype to avoid an error.
9220    Use char because int might match the return type of a GCC
9221    builtin and then its argument prototype would still apply.  */
9222 #ifdef __cplusplus
9223 extern "C"
9224 #endif
9225 char uuid_export ();
9226 int
9227 main ()
9228 {
9229 return uuid_export ();
9230   ;
9231   return 0;
9232 }
9233 _ACEOF
9234 rm -f conftest.$ac_objext conftest$ac_exeext
9235 if { (ac_try="$ac_link"
9236 case "(($ac_try" in
9237   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9238   *) ac_try_echo=$ac_try;;
9239 esac
9240 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9241 $as_echo "$ac_try_echo") >&5
9242   (eval "$ac_link") 2>conftest.er1
9243   ac_status=$?
9244   grep -v '^ *+' conftest.er1 >conftest.err
9245   rm -f conftest.er1
9246   cat conftest.err >&5
9247   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9248   (exit $ac_status); } && {
9249          test -z "$ac_c_werror_flag" ||
9250          test ! -s conftest.err
9251        } && test -s conftest$ac_exeext && {
9252          test "$cross_compiling" = yes ||
9253          $as_test_x conftest$ac_exeext
9254        }; then
9255   ac_cv_lib_ossp_uuid_uuid_export=yes
9256 else
9257   $as_echo "$as_me: failed program was:" >&5
9258 sed 's/^/| /' conftest.$ac_ext >&5
9259
9260         ac_cv_lib_ossp_uuid_uuid_export=no
9261 fi
9262
9263 rm -rf conftest.dSYM
9264 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9265       conftest$ac_exeext conftest.$ac_ext
9266 LIBS=$ac_check_lib_save_LIBS
9267 fi
9268 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
9269 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
9270 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = x""yes; then
9271   OSSP_UUID_LIBS="-lossp-uuid"
9272 else
9273   { $as_echo "$as_me:$LINENO: checking for uuid_export in -luuid" >&5
9274 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
9275 if test "${ac_cv_lib_uuid_uuid_export+set}" = set; then
9276   $as_echo_n "(cached) " >&6
9277 else
9278   ac_check_lib_save_LIBS=$LIBS
9279 LIBS="-luuid  $LIBS"
9280 cat >conftest.$ac_ext <<_ACEOF
9281 /* confdefs.h.  */
9282 _ACEOF
9283 cat confdefs.h >>conftest.$ac_ext
9284 cat >>conftest.$ac_ext <<_ACEOF
9285 /* end confdefs.h.  */
9286
9287 /* Override any GCC internal prototype to avoid an error.
9288    Use char because int might match the return type of a GCC
9289    builtin and then its argument prototype would still apply.  */
9290 #ifdef __cplusplus
9291 extern "C"
9292 #endif
9293 char uuid_export ();
9294 int
9295 main ()
9296 {
9297 return uuid_export ();
9298   ;
9299   return 0;
9300 }
9301 _ACEOF
9302 rm -f conftest.$ac_objext conftest$ac_exeext
9303 if { (ac_try="$ac_link"
9304 case "(($ac_try" in
9305   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9306   *) ac_try_echo=$ac_try;;
9307 esac
9308 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9309 $as_echo "$ac_try_echo") >&5
9310   (eval "$ac_link") 2>conftest.er1
9311   ac_status=$?
9312   grep -v '^ *+' conftest.er1 >conftest.err
9313   rm -f conftest.er1
9314   cat conftest.err >&5
9315   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9316   (exit $ac_status); } && {
9317          test -z "$ac_c_werror_flag" ||
9318          test ! -s conftest.err
9319        } && test -s conftest$ac_exeext && {
9320          test "$cross_compiling" = yes ||
9321          $as_test_x conftest$ac_exeext
9322        }; then
9323   ac_cv_lib_uuid_uuid_export=yes
9324 else
9325   $as_echo "$as_me: failed program was:" >&5
9326 sed 's/^/| /' conftest.$ac_ext >&5
9327
9328         ac_cv_lib_uuid_uuid_export=no
9329 fi
9330
9331 rm -rf conftest.dSYM
9332 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9333       conftest$ac_exeext conftest.$ac_ext
9334 LIBS=$ac_check_lib_save_LIBS
9335 fi
9336 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_export" >&5
9337 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
9338 if test "x$ac_cv_lib_uuid_uuid_export" = x""yes; then
9339   OSSP_UUID_LIBS="-luuid"
9340 else
9341   { { $as_echo "$as_me:$LINENO: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&5
9342 $as_echo "$as_me: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&2;}
9343    { (exit 1); exit 1; }; }
9344 fi
9345
9346 fi
9347
9348 fi
9349
9350
9351
9352 ##
9353 ## Header files
9354 ##
9355
9356 { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
9357 $as_echo_n "checking for ANSI C header files... " >&6; }
9358 if test "${ac_cv_header_stdc+set}" = set; then
9359   $as_echo_n "(cached) " >&6
9360 else
9361   cat >conftest.$ac_ext <<_ACEOF
9362 /* confdefs.h.  */
9363 _ACEOF
9364 cat confdefs.h >>conftest.$ac_ext
9365 cat >>conftest.$ac_ext <<_ACEOF
9366 /* end confdefs.h.  */
9367 #include <stdlib.h>
9368 #include <stdarg.h>
9369 #include <string.h>
9370 #include <float.h>
9371
9372 int
9373 main ()
9374 {
9375
9376   ;
9377   return 0;
9378 }
9379 _ACEOF
9380 rm -f conftest.$ac_objext
9381 if { (ac_try="$ac_compile"
9382 case "(($ac_try" in
9383   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9384   *) ac_try_echo=$ac_try;;
9385 esac
9386 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9387 $as_echo "$ac_try_echo") >&5
9388   (eval "$ac_compile") 2>conftest.er1
9389   ac_status=$?
9390   grep -v '^ *+' conftest.er1 >conftest.err
9391   rm -f conftest.er1
9392   cat conftest.err >&5
9393   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9394   (exit $ac_status); } && {
9395          test -z "$ac_c_werror_flag" ||
9396          test ! -s conftest.err
9397        } && test -s conftest.$ac_objext; then
9398   ac_cv_header_stdc=yes
9399 else
9400   $as_echo "$as_me: failed program was:" >&5
9401 sed 's/^/| /' conftest.$ac_ext >&5
9402
9403         ac_cv_header_stdc=no
9404 fi
9405
9406 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9407
9408 if test $ac_cv_header_stdc = yes; then
9409   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
9410   cat >conftest.$ac_ext <<_ACEOF
9411 /* confdefs.h.  */
9412 _ACEOF
9413 cat confdefs.h >>conftest.$ac_ext
9414 cat >>conftest.$ac_ext <<_ACEOF
9415 /* end confdefs.h.  */
9416 #include <string.h>
9417
9418 _ACEOF
9419 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9420   $EGREP "memchr" >/dev/null 2>&1; then
9421   :
9422 else
9423   ac_cv_header_stdc=no
9424 fi
9425 rm -f conftest*
9426
9427 fi
9428
9429 if test $ac_cv_header_stdc = yes; then
9430   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
9431   cat >conftest.$ac_ext <<_ACEOF
9432 /* confdefs.h.  */
9433 _ACEOF
9434 cat confdefs.h >>conftest.$ac_ext
9435 cat >>conftest.$ac_ext <<_ACEOF
9436 /* end confdefs.h.  */
9437 #include <stdlib.h>
9438
9439 _ACEOF
9440 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9441   $EGREP "free" >/dev/null 2>&1; then
9442   :
9443 else
9444   ac_cv_header_stdc=no
9445 fi
9446 rm -f conftest*
9447
9448 fi
9449
9450 if test $ac_cv_header_stdc = yes; then
9451   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
9452   if test "$cross_compiling" = yes; then
9453   :
9454 else
9455   cat >conftest.$ac_ext <<_ACEOF
9456 /* confdefs.h.  */
9457 _ACEOF
9458 cat confdefs.h >>conftest.$ac_ext
9459 cat >>conftest.$ac_ext <<_ACEOF
9460 /* end confdefs.h.  */
9461 #include <ctype.h>
9462 #include <stdlib.h>
9463 #if ((' ' & 0x0FF) == 0x020)
9464 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
9465 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
9466 #else
9467 # define ISLOWER(c) \
9468                    (('a' <= (c) && (c) <= 'i') \
9469                      || ('j' <= (c) && (c) <= 'r') \
9470                      || ('s' <= (c) && (c) <= 'z'))
9471 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
9472 #endif
9473
9474 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
9475 int
9476 main ()
9477 {
9478   int i;
9479   for (i = 0; i < 256; i++)
9480     if (XOR (islower (i), ISLOWER (i))
9481         || toupper (i) != TOUPPER (i))
9482       return 2;
9483   return 0;
9484 }
9485 _ACEOF
9486 rm -f conftest$ac_exeext
9487 if { (ac_try="$ac_link"
9488 case "(($ac_try" in
9489   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9490   *) ac_try_echo=$ac_try;;
9491 esac
9492 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9493 $as_echo "$ac_try_echo") >&5
9494   (eval "$ac_link") 2>&5
9495   ac_status=$?
9496   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9497   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9498   { (case "(($ac_try" in
9499   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9500   *) ac_try_echo=$ac_try;;
9501 esac
9502 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9503 $as_echo "$ac_try_echo") >&5
9504   (eval "$ac_try") 2>&5
9505   ac_status=$?
9506   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9507   (exit $ac_status); }; }; then
9508   :
9509 else
9510   $as_echo "$as_me: program exited with status $ac_status" >&5
9511 $as_echo "$as_me: failed program was:" >&5
9512 sed 's/^/| /' conftest.$ac_ext >&5
9513
9514 ( exit $ac_status )
9515 ac_cv_header_stdc=no
9516 fi
9517 rm -rf conftest.dSYM
9518 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9519 fi
9520
9521
9522 fi
9523 fi
9524 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
9525 $as_echo "$ac_cv_header_stdc" >&6; }
9526 if test $ac_cv_header_stdc = yes; then
9527
9528 cat >>confdefs.h <<\_ACEOF
9529 #define STDC_HEADERS 1
9530 _ACEOF
9531
9532 fi
9533
9534 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
9535
9536
9537
9538
9539
9540
9541
9542
9543
9544 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
9545                   inttypes.h stdint.h unistd.h
9546 do
9547 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9548 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9549 $as_echo_n "checking for $ac_header... " >&6; }
9550 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9551   $as_echo_n "(cached) " >&6
9552 else
9553   cat >conftest.$ac_ext <<_ACEOF
9554 /* confdefs.h.  */
9555 _ACEOF
9556 cat confdefs.h >>conftest.$ac_ext
9557 cat >>conftest.$ac_ext <<_ACEOF
9558 /* end confdefs.h.  */
9559 $ac_includes_default
9560
9561 #include <$ac_header>
9562 _ACEOF
9563 rm -f conftest.$ac_objext
9564 if { (ac_try="$ac_compile"
9565 case "(($ac_try" in
9566   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9567   *) ac_try_echo=$ac_try;;
9568 esac
9569 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9570 $as_echo "$ac_try_echo") >&5
9571   (eval "$ac_compile") 2>conftest.er1
9572   ac_status=$?
9573   grep -v '^ *+' conftest.er1 >conftest.err
9574   rm -f conftest.er1
9575   cat conftest.err >&5
9576   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9577   (exit $ac_status); } && {
9578          test -z "$ac_c_werror_flag" ||
9579          test ! -s conftest.err
9580        } && test -s conftest.$ac_objext; then
9581   eval "$as_ac_Header=yes"
9582 else
9583   $as_echo "$as_me: failed program was:" >&5
9584 sed 's/^/| /' conftest.$ac_ext >&5
9585
9586         eval "$as_ac_Header=no"
9587 fi
9588
9589 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9590 fi
9591 ac_res=`eval 'as_val=${'$as_ac_Header'}
9592                  $as_echo "$as_val"'`
9593                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9594 $as_echo "$ac_res" >&6; }
9595 as_val=`eval 'as_val=${'$as_ac_Header'}
9596                  $as_echo "$as_val"'`
9597    if test "x$as_val" = x""yes; then
9598   cat >>confdefs.h <<_ACEOF
9599 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9600 _ACEOF
9601
9602 fi
9603
9604 done
9605
9606
9607
9608
9609
9610
9611
9612
9613
9614
9615
9616
9617
9618
9619
9620
9621
9622
9623
9624
9625
9626
9627
9628
9629
9630
9631
9632
9633
9634
9635
9636
9637 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
9638 do
9639 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9640 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9641   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9642 $as_echo_n "checking for $ac_header... " >&6; }
9643 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9644   $as_echo_n "(cached) " >&6
9645 fi
9646 ac_res=`eval 'as_val=${'$as_ac_Header'}
9647                  $as_echo "$as_val"'`
9648                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9649 $as_echo "$ac_res" >&6; }
9650 else
9651   # Is the header compilable?
9652 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
9653 $as_echo_n "checking $ac_header usability... " >&6; }
9654 cat >conftest.$ac_ext <<_ACEOF
9655 /* confdefs.h.  */
9656 _ACEOF
9657 cat confdefs.h >>conftest.$ac_ext
9658 cat >>conftest.$ac_ext <<_ACEOF
9659 /* end confdefs.h.  */
9660 $ac_includes_default
9661 #include <$ac_header>
9662 _ACEOF
9663 rm -f conftest.$ac_objext
9664 if { (ac_try="$ac_compile"
9665 case "(($ac_try" in
9666   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9667   *) ac_try_echo=$ac_try;;
9668 esac
9669 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9670 $as_echo "$ac_try_echo") >&5
9671   (eval "$ac_compile") 2>conftest.er1
9672   ac_status=$?
9673   grep -v '^ *+' conftest.er1 >conftest.err
9674   rm -f conftest.er1
9675   cat conftest.err >&5
9676   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9677   (exit $ac_status); } && {
9678          test -z "$ac_c_werror_flag" ||
9679          test ! -s conftest.err
9680        } && test -s conftest.$ac_objext; then
9681   ac_header_compiler=yes
9682 else
9683   $as_echo "$as_me: failed program was:" >&5
9684 sed 's/^/| /' conftest.$ac_ext >&5
9685
9686         ac_header_compiler=no
9687 fi
9688
9689 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9690 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9691 $as_echo "$ac_header_compiler" >&6; }
9692
9693 # Is the header present?
9694 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
9695 $as_echo_n "checking $ac_header presence... " >&6; }
9696 cat >conftest.$ac_ext <<_ACEOF
9697 /* confdefs.h.  */
9698 _ACEOF
9699 cat confdefs.h >>conftest.$ac_ext
9700 cat >>conftest.$ac_ext <<_ACEOF
9701 /* end confdefs.h.  */
9702 #include <$ac_header>
9703 _ACEOF
9704 if { (ac_try="$ac_cpp conftest.$ac_ext"
9705 case "(($ac_try" in
9706   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9707   *) ac_try_echo=$ac_try;;
9708 esac
9709 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9710 $as_echo "$ac_try_echo") >&5
9711   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9712   ac_status=$?
9713   grep -v '^ *+' conftest.er1 >conftest.err
9714   rm -f conftest.er1
9715   cat conftest.err >&5
9716   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9717   (exit $ac_status); } >/dev/null && {
9718          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9719          test ! -s conftest.err
9720        }; then
9721   ac_header_preproc=yes
9722 else
9723   $as_echo "$as_me: failed program was:" >&5
9724 sed 's/^/| /' conftest.$ac_ext >&5
9725
9726   ac_header_preproc=no
9727 fi
9728
9729 rm -f conftest.err conftest.$ac_ext
9730 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9731 $as_echo "$ac_header_preproc" >&6; }
9732
9733 # So?  What about this header?
9734 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9735   yes:no: )
9736     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9737 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9738     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9739 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9740     ac_header_preproc=yes
9741     ;;
9742   no:yes:* )
9743     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9744 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9745     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9746 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9747     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9748 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9749     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9750 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9751     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9752 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9753     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9754 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9755     ( cat <<\_ASBOX
9756 ## ---------------------------------------- ##
9757 ## Report this to pgsql-bugs@postgresql.org ##
9758 ## ---------------------------------------- ##
9759 _ASBOX
9760      ) | sed "s/^/$as_me: WARNING:     /" >&2
9761     ;;
9762 esac
9763 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9764 $as_echo_n "checking for $ac_header... " >&6; }
9765 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9766   $as_echo_n "(cached) " >&6
9767 else
9768   eval "$as_ac_Header=\$ac_header_preproc"
9769 fi
9770 ac_res=`eval 'as_val=${'$as_ac_Header'}
9771                  $as_echo "$as_val"'`
9772                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9773 $as_echo "$ac_res" >&6; }
9774
9775 fi
9776 as_val=`eval 'as_val=${'$as_ac_Header'}
9777                  $as_echo "$as_val"'`
9778    if test "x$as_val" = x""yes; then
9779   cat >>confdefs.h <<_ACEOF
9780 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9781 _ACEOF
9782
9783 fi
9784
9785 done
9786
9787
9788 # On BSD, cpp test for net/if.h will fail unless sys/socket.h
9789 # is included first.
9790
9791 for ac_header in net/if.h
9792 do
9793 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9794 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9795 $as_echo_n "checking for $ac_header... " >&6; }
9796 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9797   $as_echo_n "(cached) " >&6
9798 else
9799   cat >conftest.$ac_ext <<_ACEOF
9800 /* confdefs.h.  */
9801 _ACEOF
9802 cat confdefs.h >>conftest.$ac_ext
9803 cat >>conftest.$ac_ext <<_ACEOF
9804 /* end confdefs.h.  */
9805 $ac_includes_default
9806 #ifdef HAVE_SYS_SOCKET_H
9807 #include <sys/socket.h>
9808 #endif
9809
9810
9811 #include <$ac_header>
9812 _ACEOF
9813 rm -f conftest.$ac_objext
9814 if { (ac_try="$ac_compile"
9815 case "(($ac_try" in
9816   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9817   *) ac_try_echo=$ac_try;;
9818 esac
9819 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9820 $as_echo "$ac_try_echo") >&5
9821   (eval "$ac_compile") 2>conftest.er1
9822   ac_status=$?
9823   grep -v '^ *+' conftest.er1 >conftest.err
9824   rm -f conftest.er1
9825   cat conftest.err >&5
9826   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9827   (exit $ac_status); } && {
9828          test -z "$ac_c_werror_flag" ||
9829          test ! -s conftest.err
9830        } && test -s conftest.$ac_objext; then
9831   eval "$as_ac_Header=yes"
9832 else
9833   $as_echo "$as_me: failed program was:" >&5
9834 sed 's/^/| /' conftest.$ac_ext >&5
9835
9836         eval "$as_ac_Header=no"
9837 fi
9838
9839 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9840 fi
9841 ac_res=`eval 'as_val=${'$as_ac_Header'}
9842                  $as_echo "$as_val"'`
9843                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9844 $as_echo "$ac_res" >&6; }
9845 as_val=`eval 'as_val=${'$as_ac_Header'}
9846                  $as_echo "$as_val"'`
9847    if test "x$as_val" = x""yes; then
9848   cat >>confdefs.h <<_ACEOF
9849 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9850 _ACEOF
9851
9852 fi
9853
9854 done
9855
9856
9857 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
9858 # netinet/in.h is included first.
9859
9860 for ac_header in netinet/in.h
9861 do
9862 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9863 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9864   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9865 $as_echo_n "checking for $ac_header... " >&6; }
9866 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9867   $as_echo_n "(cached) " >&6
9868 fi
9869 ac_res=`eval 'as_val=${'$as_ac_Header'}
9870                  $as_echo "$as_val"'`
9871                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9872 $as_echo "$ac_res" >&6; }
9873 else
9874   # Is the header compilable?
9875 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
9876 $as_echo_n "checking $ac_header usability... " >&6; }
9877 cat >conftest.$ac_ext <<_ACEOF
9878 /* confdefs.h.  */
9879 _ACEOF
9880 cat confdefs.h >>conftest.$ac_ext
9881 cat >>conftest.$ac_ext <<_ACEOF
9882 /* end confdefs.h.  */
9883 $ac_includes_default
9884 #include <$ac_header>
9885 _ACEOF
9886 rm -f conftest.$ac_objext
9887 if { (ac_try="$ac_compile"
9888 case "(($ac_try" in
9889   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9890   *) ac_try_echo=$ac_try;;
9891 esac
9892 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9893 $as_echo "$ac_try_echo") >&5
9894   (eval "$ac_compile") 2>conftest.er1
9895   ac_status=$?
9896   grep -v '^ *+' conftest.er1 >conftest.err
9897   rm -f conftest.er1
9898   cat conftest.err >&5
9899   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9900   (exit $ac_status); } && {
9901          test -z "$ac_c_werror_flag" ||
9902          test ! -s conftest.err
9903        } && test -s conftest.$ac_objext; then
9904   ac_header_compiler=yes
9905 else
9906   $as_echo "$as_me: failed program was:" >&5
9907 sed 's/^/| /' conftest.$ac_ext >&5
9908
9909         ac_header_compiler=no
9910 fi
9911
9912 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9913 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9914 $as_echo "$ac_header_compiler" >&6; }
9915
9916 # Is the header present?
9917 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
9918 $as_echo_n "checking $ac_header presence... " >&6; }
9919 cat >conftest.$ac_ext <<_ACEOF
9920 /* confdefs.h.  */
9921 _ACEOF
9922 cat confdefs.h >>conftest.$ac_ext
9923 cat >>conftest.$ac_ext <<_ACEOF
9924 /* end confdefs.h.  */
9925 #include <$ac_header>
9926 _ACEOF
9927 if { (ac_try="$ac_cpp conftest.$ac_ext"
9928 case "(($ac_try" in
9929   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9930   *) ac_try_echo=$ac_try;;
9931 esac
9932 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9933 $as_echo "$ac_try_echo") >&5
9934   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9935   ac_status=$?
9936   grep -v '^ *+' conftest.er1 >conftest.err
9937   rm -f conftest.er1
9938   cat conftest.err >&5
9939   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9940   (exit $ac_status); } >/dev/null && {
9941          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9942          test ! -s conftest.err
9943        }; then
9944   ac_header_preproc=yes
9945 else
9946   $as_echo "$as_me: failed program was:" >&5
9947 sed 's/^/| /' conftest.$ac_ext >&5
9948
9949   ac_header_preproc=no
9950 fi
9951
9952 rm -f conftest.err conftest.$ac_ext
9953 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9954 $as_echo "$ac_header_preproc" >&6; }
9955
9956 # So?  What about this header?
9957 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9958   yes:no: )
9959     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9960 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9961     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9962 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9963     ac_header_preproc=yes
9964     ;;
9965   no:yes:* )
9966     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9967 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9968     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9969 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9970     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9971 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9972     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9973 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9974     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9975 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9976     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9977 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9978     ( cat <<\_ASBOX
9979 ## ---------------------------------------- ##
9980 ## Report this to pgsql-bugs@postgresql.org ##
9981 ## ---------------------------------------- ##
9982 _ASBOX
9983      ) | sed "s/^/$as_me: WARNING:     /" >&2
9984     ;;
9985 esac
9986 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9987 $as_echo_n "checking for $ac_header... " >&6; }
9988 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9989   $as_echo_n "(cached) " >&6
9990 else
9991   eval "$as_ac_Header=\$ac_header_preproc"
9992 fi
9993 ac_res=`eval 'as_val=${'$as_ac_Header'}
9994                  $as_echo "$as_val"'`
9995                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9996 $as_echo "$ac_res" >&6; }
9997
9998 fi
9999 as_val=`eval 'as_val=${'$as_ac_Header'}
10000                  $as_echo "$as_val"'`
10001    if test "x$as_val" = x""yes; then
10002   cat >>confdefs.h <<_ACEOF
10003 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10004 _ACEOF
10005
10006 fi
10007
10008 done
10009
10010
10011 for ac_header in netinet/tcp.h
10012 do
10013 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10014 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10015 $as_echo_n "checking for $ac_header... " >&6; }
10016 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10017   $as_echo_n "(cached) " >&6
10018 else
10019   cat >conftest.$ac_ext <<_ACEOF
10020 /* confdefs.h.  */
10021 _ACEOF
10022 cat confdefs.h >>conftest.$ac_ext
10023 cat >>conftest.$ac_ext <<_ACEOF
10024 /* end confdefs.h.  */
10025 $ac_includes_default
10026 #ifdef HAVE_NETINET_IN_H
10027 #include <netinet/in.h>
10028 #endif
10029
10030
10031 #include <$ac_header>
10032 _ACEOF
10033 rm -f conftest.$ac_objext
10034 if { (ac_try="$ac_compile"
10035 case "(($ac_try" in
10036   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10037   *) ac_try_echo=$ac_try;;
10038 esac
10039 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10040 $as_echo "$ac_try_echo") >&5
10041   (eval "$ac_compile") 2>conftest.er1
10042   ac_status=$?
10043   grep -v '^ *+' conftest.er1 >conftest.err
10044   rm -f conftest.er1
10045   cat conftest.err >&5
10046   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10047   (exit $ac_status); } && {
10048          test -z "$ac_c_werror_flag" ||
10049          test ! -s conftest.err
10050        } && test -s conftest.$ac_objext; then
10051   eval "$as_ac_Header=yes"
10052 else
10053   $as_echo "$as_me: failed program was:" >&5
10054 sed 's/^/| /' conftest.$ac_ext >&5
10055
10056         eval "$as_ac_Header=no"
10057 fi
10058
10059 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10060 fi
10061 ac_res=`eval 'as_val=${'$as_ac_Header'}
10062                  $as_echo "$as_val"'`
10063                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10064 $as_echo "$ac_res" >&6; }
10065 as_val=`eval 'as_val=${'$as_ac_Header'}
10066                  $as_echo "$as_val"'`
10067    if test "x$as_val" = x""yes; then
10068   cat >>confdefs.h <<_ACEOF
10069 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10070 _ACEOF
10071
10072 fi
10073
10074 done
10075
10076
10077 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
10078
10079 for ac_header in readline/readline.h
10080 do
10081 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10082 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10083   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10084 $as_echo_n "checking for $ac_header... " >&6; }
10085 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10086   $as_echo_n "(cached) " >&6
10087 fi
10088 ac_res=`eval 'as_val=${'$as_ac_Header'}
10089                  $as_echo "$as_val"'`
10090                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10091 $as_echo "$ac_res" >&6; }
10092 else
10093   # Is the header compilable?
10094 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10095 $as_echo_n "checking $ac_header usability... " >&6; }
10096 cat >conftest.$ac_ext <<_ACEOF
10097 /* confdefs.h.  */
10098 _ACEOF
10099 cat confdefs.h >>conftest.$ac_ext
10100 cat >>conftest.$ac_ext <<_ACEOF
10101 /* end confdefs.h.  */
10102 $ac_includes_default
10103 #include <$ac_header>
10104 _ACEOF
10105 rm -f conftest.$ac_objext
10106 if { (ac_try="$ac_compile"
10107 case "(($ac_try" in
10108   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10109   *) ac_try_echo=$ac_try;;
10110 esac
10111 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10112 $as_echo "$ac_try_echo") >&5
10113   (eval "$ac_compile") 2>conftest.er1
10114   ac_status=$?
10115   grep -v '^ *+' conftest.er1 >conftest.err
10116   rm -f conftest.er1
10117   cat conftest.err >&5
10118   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10119   (exit $ac_status); } && {
10120          test -z "$ac_c_werror_flag" ||
10121          test ! -s conftest.err
10122        } && test -s conftest.$ac_objext; then
10123   ac_header_compiler=yes
10124 else
10125   $as_echo "$as_me: failed program was:" >&5
10126 sed 's/^/| /' conftest.$ac_ext >&5
10127
10128         ac_header_compiler=no
10129 fi
10130
10131 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10132 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10133 $as_echo "$ac_header_compiler" >&6; }
10134
10135 # Is the header present?
10136 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10137 $as_echo_n "checking $ac_header presence... " >&6; }
10138 cat >conftest.$ac_ext <<_ACEOF
10139 /* confdefs.h.  */
10140 _ACEOF
10141 cat confdefs.h >>conftest.$ac_ext
10142 cat >>conftest.$ac_ext <<_ACEOF
10143 /* end confdefs.h.  */
10144 #include <$ac_header>
10145 _ACEOF
10146 if { (ac_try="$ac_cpp conftest.$ac_ext"
10147 case "(($ac_try" in
10148   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10149   *) ac_try_echo=$ac_try;;
10150 esac
10151 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10152 $as_echo "$ac_try_echo") >&5
10153   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10154   ac_status=$?
10155   grep -v '^ *+' conftest.er1 >conftest.err
10156   rm -f conftest.er1
10157   cat conftest.err >&5
10158   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10159   (exit $ac_status); } >/dev/null && {
10160          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10161          test ! -s conftest.err
10162        }; then
10163   ac_header_preproc=yes
10164 else
10165   $as_echo "$as_me: failed program was:" >&5
10166 sed 's/^/| /' conftest.$ac_ext >&5
10167
10168   ac_header_preproc=no
10169 fi
10170
10171 rm -f conftest.err conftest.$ac_ext
10172 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10173 $as_echo "$ac_header_preproc" >&6; }
10174
10175 # So?  What about this header?
10176 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10177   yes:no: )
10178     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10179 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10180     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10181 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10182     ac_header_preproc=yes
10183     ;;
10184   no:yes:* )
10185     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10186 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10187     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10188 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10189     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10190 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10191     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10192 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10193     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10194 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10195     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10196 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10197     ( cat <<\_ASBOX
10198 ## ---------------------------------------- ##
10199 ## Report this to pgsql-bugs@postgresql.org ##
10200 ## ---------------------------------------- ##
10201 _ASBOX
10202      ) | sed "s/^/$as_me: WARNING:     /" >&2
10203     ;;
10204 esac
10205 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10206 $as_echo_n "checking for $ac_header... " >&6; }
10207 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10208   $as_echo_n "(cached) " >&6
10209 else
10210   eval "$as_ac_Header=\$ac_header_preproc"
10211 fi
10212 ac_res=`eval 'as_val=${'$as_ac_Header'}
10213                  $as_echo "$as_val"'`
10214                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10215 $as_echo "$ac_res" >&6; }
10216
10217 fi
10218 as_val=`eval 'as_val=${'$as_ac_Header'}
10219                  $as_echo "$as_val"'`
10220    if test "x$as_val" = x""yes; then
10221   cat >>confdefs.h <<_ACEOF
10222 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10223 _ACEOF
10224
10225 else
10226
10227 for ac_header in readline.h
10228 do
10229 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10230 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10231   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10232 $as_echo_n "checking for $ac_header... " >&6; }
10233 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10234   $as_echo_n "(cached) " >&6
10235 fi
10236 ac_res=`eval 'as_val=${'$as_ac_Header'}
10237                  $as_echo "$as_val"'`
10238                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10239 $as_echo "$ac_res" >&6; }
10240 else
10241   # Is the header compilable?
10242 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10243 $as_echo_n "checking $ac_header usability... " >&6; }
10244 cat >conftest.$ac_ext <<_ACEOF
10245 /* confdefs.h.  */
10246 _ACEOF
10247 cat confdefs.h >>conftest.$ac_ext
10248 cat >>conftest.$ac_ext <<_ACEOF
10249 /* end confdefs.h.  */
10250 $ac_includes_default
10251 #include <$ac_header>
10252 _ACEOF
10253 rm -f conftest.$ac_objext
10254 if { (ac_try="$ac_compile"
10255 case "(($ac_try" in
10256   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10257   *) ac_try_echo=$ac_try;;
10258 esac
10259 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10260 $as_echo "$ac_try_echo") >&5
10261   (eval "$ac_compile") 2>conftest.er1
10262   ac_status=$?
10263   grep -v '^ *+' conftest.er1 >conftest.err
10264   rm -f conftest.er1
10265   cat conftest.err >&5
10266   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10267   (exit $ac_status); } && {
10268          test -z "$ac_c_werror_flag" ||
10269          test ! -s conftest.err
10270        } && test -s conftest.$ac_objext; then
10271   ac_header_compiler=yes
10272 else
10273   $as_echo "$as_me: failed program was:" >&5
10274 sed 's/^/| /' conftest.$ac_ext >&5
10275
10276         ac_header_compiler=no
10277 fi
10278
10279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10280 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10281 $as_echo "$ac_header_compiler" >&6; }
10282
10283 # Is the header present?
10284 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10285 $as_echo_n "checking $ac_header presence... " >&6; }
10286 cat >conftest.$ac_ext <<_ACEOF
10287 /* confdefs.h.  */
10288 _ACEOF
10289 cat confdefs.h >>conftest.$ac_ext
10290 cat >>conftest.$ac_ext <<_ACEOF
10291 /* end confdefs.h.  */
10292 #include <$ac_header>
10293 _ACEOF
10294 if { (ac_try="$ac_cpp conftest.$ac_ext"
10295 case "(($ac_try" in
10296   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10297   *) ac_try_echo=$ac_try;;
10298 esac
10299 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10300 $as_echo "$ac_try_echo") >&5
10301   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10302   ac_status=$?
10303   grep -v '^ *+' conftest.er1 >conftest.err
10304   rm -f conftest.er1
10305   cat conftest.err >&5
10306   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10307   (exit $ac_status); } >/dev/null && {
10308          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10309          test ! -s conftest.err
10310        }; then
10311   ac_header_preproc=yes
10312 else
10313   $as_echo "$as_me: failed program was:" >&5
10314 sed 's/^/| /' conftest.$ac_ext >&5
10315
10316   ac_header_preproc=no
10317 fi
10318
10319 rm -f conftest.err conftest.$ac_ext
10320 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10321 $as_echo "$ac_header_preproc" >&6; }
10322
10323 # So?  What about this header?
10324 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10325   yes:no: )
10326     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10327 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10328     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10329 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10330     ac_header_preproc=yes
10331     ;;
10332   no:yes:* )
10333     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10334 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10335     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10336 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10337     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10338 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10339     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10340 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10341     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10342 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10343     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10344 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10345     ( cat <<\_ASBOX
10346 ## ---------------------------------------- ##
10347 ## Report this to pgsql-bugs@postgresql.org ##
10348 ## ---------------------------------------- ##
10349 _ASBOX
10350      ) | sed "s/^/$as_me: WARNING:     /" >&2
10351     ;;
10352 esac
10353 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10354 $as_echo_n "checking for $ac_header... " >&6; }
10355 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10356   $as_echo_n "(cached) " >&6
10357 else
10358   eval "$as_ac_Header=\$ac_header_preproc"
10359 fi
10360 ac_res=`eval 'as_val=${'$as_ac_Header'}
10361                  $as_echo "$as_val"'`
10362                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10363 $as_echo "$ac_res" >&6; }
10364
10365 fi
10366 as_val=`eval 'as_val=${'$as_ac_Header'}
10367                  $as_echo "$as_val"'`
10368    if test "x$as_val" = x""yes; then
10369   cat >>confdefs.h <<_ACEOF
10370 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10371 _ACEOF
10372
10373 else
10374   { { $as_echo "$as_me:$LINENO: error: readline header not found
10375 If you have readline already installed, see config.log for details on the
10376 failure.  It is possible the compiler isn't looking in the proper directory.
10377 Use --without-readline to disable readline support." >&5
10378 $as_echo "$as_me: error: readline header not found
10379 If you have readline already installed, see config.log for details on the
10380 failure.  It is possible the compiler isn't looking in the proper directory.
10381 Use --without-readline to disable readline support." >&2;}
10382    { (exit 1); exit 1; }; }
10383 fi
10384
10385 done
10386
10387 fi
10388
10389 done
10390
10391
10392 for ac_header in readline/history.h
10393 do
10394 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10395 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10396   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10397 $as_echo_n "checking for $ac_header... " >&6; }
10398 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10399   $as_echo_n "(cached) " >&6
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 else
10406   # Is the header compilable?
10407 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10408 $as_echo_n "checking $ac_header usability... " >&6; }
10409 cat >conftest.$ac_ext <<_ACEOF
10410 /* confdefs.h.  */
10411 _ACEOF
10412 cat confdefs.h >>conftest.$ac_ext
10413 cat >>conftest.$ac_ext <<_ACEOF
10414 /* end confdefs.h.  */
10415 $ac_includes_default
10416 #include <$ac_header>
10417 _ACEOF
10418 rm -f conftest.$ac_objext
10419 if { (ac_try="$ac_compile"
10420 case "(($ac_try" in
10421   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10422   *) ac_try_echo=$ac_try;;
10423 esac
10424 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10425 $as_echo "$ac_try_echo") >&5
10426   (eval "$ac_compile") 2>conftest.er1
10427   ac_status=$?
10428   grep -v '^ *+' conftest.er1 >conftest.err
10429   rm -f conftest.er1
10430   cat conftest.err >&5
10431   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10432   (exit $ac_status); } && {
10433          test -z "$ac_c_werror_flag" ||
10434          test ! -s conftest.err
10435        } && test -s conftest.$ac_objext; then
10436   ac_header_compiler=yes
10437 else
10438   $as_echo "$as_me: failed program was:" >&5
10439 sed 's/^/| /' conftest.$ac_ext >&5
10440
10441         ac_header_compiler=no
10442 fi
10443
10444 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10445 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10446 $as_echo "$ac_header_compiler" >&6; }
10447
10448 # Is the header present?
10449 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10450 $as_echo_n "checking $ac_header presence... " >&6; }
10451 cat >conftest.$ac_ext <<_ACEOF
10452 /* confdefs.h.  */
10453 _ACEOF
10454 cat confdefs.h >>conftest.$ac_ext
10455 cat >>conftest.$ac_ext <<_ACEOF
10456 /* end confdefs.h.  */
10457 #include <$ac_header>
10458 _ACEOF
10459 if { (ac_try="$ac_cpp conftest.$ac_ext"
10460 case "(($ac_try" in
10461   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10462   *) ac_try_echo=$ac_try;;
10463 esac
10464 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10465 $as_echo "$ac_try_echo") >&5
10466   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10467   ac_status=$?
10468   grep -v '^ *+' conftest.er1 >conftest.err
10469   rm -f conftest.er1
10470   cat conftest.err >&5
10471   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10472   (exit $ac_status); } >/dev/null && {
10473          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10474          test ! -s conftest.err
10475        }; then
10476   ac_header_preproc=yes
10477 else
10478   $as_echo "$as_me: failed program was:" >&5
10479 sed 's/^/| /' conftest.$ac_ext >&5
10480
10481   ac_header_preproc=no
10482 fi
10483
10484 rm -f conftest.err conftest.$ac_ext
10485 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10486 $as_echo "$ac_header_preproc" >&6; }
10487
10488 # So?  What about this header?
10489 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10490   yes:no: )
10491     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10492 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10493     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10494 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10495     ac_header_preproc=yes
10496     ;;
10497   no:yes:* )
10498     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10499 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10500     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10501 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10502     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10503 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10504     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10505 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10506     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10507 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10508     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10509 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10510     ( cat <<\_ASBOX
10511 ## ---------------------------------------- ##
10512 ## Report this to pgsql-bugs@postgresql.org ##
10513 ## ---------------------------------------- ##
10514 _ASBOX
10515      ) | sed "s/^/$as_me: WARNING:     /" >&2
10516     ;;
10517 esac
10518 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10519 $as_echo_n "checking for $ac_header... " >&6; }
10520 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10521   $as_echo_n "(cached) " >&6
10522 else
10523   eval "$as_ac_Header=\$ac_header_preproc"
10524 fi
10525 ac_res=`eval 'as_val=${'$as_ac_Header'}
10526                  $as_echo "$as_val"'`
10527                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10528 $as_echo "$ac_res" >&6; }
10529
10530 fi
10531 as_val=`eval 'as_val=${'$as_ac_Header'}
10532                  $as_echo "$as_val"'`
10533    if test "x$as_val" = x""yes; then
10534   cat >>confdefs.h <<_ACEOF
10535 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10536 _ACEOF
10537
10538 else
10539
10540 for ac_header in history.h
10541 do
10542 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10543 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10544   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10545 $as_echo_n "checking for $ac_header... " >&6; }
10546 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10547   $as_echo_n "(cached) " >&6
10548 fi
10549 ac_res=`eval 'as_val=${'$as_ac_Header'}
10550                  $as_echo "$as_val"'`
10551                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10552 $as_echo "$ac_res" >&6; }
10553 else
10554   # Is the header compilable?
10555 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10556 $as_echo_n "checking $ac_header usability... " >&6; }
10557 cat >conftest.$ac_ext <<_ACEOF
10558 /* confdefs.h.  */
10559 _ACEOF
10560 cat confdefs.h >>conftest.$ac_ext
10561 cat >>conftest.$ac_ext <<_ACEOF
10562 /* end confdefs.h.  */
10563 $ac_includes_default
10564 #include <$ac_header>
10565 _ACEOF
10566 rm -f conftest.$ac_objext
10567 if { (ac_try="$ac_compile"
10568 case "(($ac_try" in
10569   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10570   *) ac_try_echo=$ac_try;;
10571 esac
10572 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10573 $as_echo "$ac_try_echo") >&5
10574   (eval "$ac_compile") 2>conftest.er1
10575   ac_status=$?
10576   grep -v '^ *+' conftest.er1 >conftest.err
10577   rm -f conftest.er1
10578   cat conftest.err >&5
10579   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10580   (exit $ac_status); } && {
10581          test -z "$ac_c_werror_flag" ||
10582          test ! -s conftest.err
10583        } && test -s conftest.$ac_objext; then
10584   ac_header_compiler=yes
10585 else
10586   $as_echo "$as_me: failed program was:" >&5
10587 sed 's/^/| /' conftest.$ac_ext >&5
10588
10589         ac_header_compiler=no
10590 fi
10591
10592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10593 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10594 $as_echo "$ac_header_compiler" >&6; }
10595
10596 # Is the header present?
10597 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10598 $as_echo_n "checking $ac_header presence... " >&6; }
10599 cat >conftest.$ac_ext <<_ACEOF
10600 /* confdefs.h.  */
10601 _ACEOF
10602 cat confdefs.h >>conftest.$ac_ext
10603 cat >>conftest.$ac_ext <<_ACEOF
10604 /* end confdefs.h.  */
10605 #include <$ac_header>
10606 _ACEOF
10607 if { (ac_try="$ac_cpp conftest.$ac_ext"
10608 case "(($ac_try" in
10609   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10610   *) ac_try_echo=$ac_try;;
10611 esac
10612 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10613 $as_echo "$ac_try_echo") >&5
10614   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10615   ac_status=$?
10616   grep -v '^ *+' conftest.er1 >conftest.err
10617   rm -f conftest.er1
10618   cat conftest.err >&5
10619   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10620   (exit $ac_status); } >/dev/null && {
10621          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10622          test ! -s conftest.err
10623        }; then
10624   ac_header_preproc=yes
10625 else
10626   $as_echo "$as_me: failed program was:" >&5
10627 sed 's/^/| /' conftest.$ac_ext >&5
10628
10629   ac_header_preproc=no
10630 fi
10631
10632 rm -f conftest.err conftest.$ac_ext
10633 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10634 $as_echo "$ac_header_preproc" >&6; }
10635
10636 # So?  What about this header?
10637 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10638   yes:no: )
10639     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10640 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10641     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10642 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10643     ac_header_preproc=yes
10644     ;;
10645   no:yes:* )
10646     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10647 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10648     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10649 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10650     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10651 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10652     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10653 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10654     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10655 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10656     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10657 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10658     ( cat <<\_ASBOX
10659 ## ---------------------------------------- ##
10660 ## Report this to pgsql-bugs@postgresql.org ##
10661 ## ---------------------------------------- ##
10662 _ASBOX
10663      ) | sed "s/^/$as_me: WARNING:     /" >&2
10664     ;;
10665 esac
10666 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10667 $as_echo_n "checking for $ac_header... " >&6; }
10668 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10669   $as_echo_n "(cached) " >&6
10670 else
10671   eval "$as_ac_Header=\$ac_header_preproc"
10672 fi
10673 ac_res=`eval 'as_val=${'$as_ac_Header'}
10674                  $as_echo "$as_val"'`
10675                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10676 $as_echo "$ac_res" >&6; }
10677
10678 fi
10679 as_val=`eval 'as_val=${'$as_ac_Header'}
10680                  $as_echo "$as_val"'`
10681    if test "x$as_val" = x""yes; then
10682   cat >>confdefs.h <<_ACEOF
10683 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10684 _ACEOF
10685
10686 else
10687   { { $as_echo "$as_me:$LINENO: error: history header not found
10688 If you have readline already installed, see config.log for details on the
10689 failure.  It is possible the compiler isn't looking in the proper directory.
10690 Use --without-readline to disable readline support." >&5
10691 $as_echo "$as_me: error: history header not found
10692 If you have readline already installed, see config.log for details on the
10693 failure.  It is possible the compiler isn't looking in the proper directory.
10694 Use --without-readline to disable readline support." >&2;}
10695    { (exit 1); exit 1; }; }
10696 fi
10697
10698 done
10699
10700 fi
10701
10702 done
10703
10704 fi
10705
10706 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
10707 # Some installations of libedit usurp /usr/include/readline/, which seems
10708 # bad practice, since in combined installations readline will have its headers
10709 # there.  We might have to resort to AC_EGREP checks to make sure we found
10710 # the proper header...
10711
10712 for ac_header in editline/readline.h
10713 do
10714 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10715 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10716   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10717 $as_echo_n "checking for $ac_header... " >&6; }
10718 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10719   $as_echo_n "(cached) " >&6
10720 fi
10721 ac_res=`eval 'as_val=${'$as_ac_Header'}
10722                  $as_echo "$as_val"'`
10723                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10724 $as_echo "$ac_res" >&6; }
10725 else
10726   # Is the header compilable?
10727 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10728 $as_echo_n "checking $ac_header usability... " >&6; }
10729 cat >conftest.$ac_ext <<_ACEOF
10730 /* confdefs.h.  */
10731 _ACEOF
10732 cat confdefs.h >>conftest.$ac_ext
10733 cat >>conftest.$ac_ext <<_ACEOF
10734 /* end confdefs.h.  */
10735 $ac_includes_default
10736 #include <$ac_header>
10737 _ACEOF
10738 rm -f conftest.$ac_objext
10739 if { (ac_try="$ac_compile"
10740 case "(($ac_try" in
10741   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10742   *) ac_try_echo=$ac_try;;
10743 esac
10744 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10745 $as_echo "$ac_try_echo") >&5
10746   (eval "$ac_compile") 2>conftest.er1
10747   ac_status=$?
10748   grep -v '^ *+' conftest.er1 >conftest.err
10749   rm -f conftest.er1
10750   cat conftest.err >&5
10751   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10752   (exit $ac_status); } && {
10753          test -z "$ac_c_werror_flag" ||
10754          test ! -s conftest.err
10755        } && test -s conftest.$ac_objext; then
10756   ac_header_compiler=yes
10757 else
10758   $as_echo "$as_me: failed program was:" >&5
10759 sed 's/^/| /' conftest.$ac_ext >&5
10760
10761         ac_header_compiler=no
10762 fi
10763
10764 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10765 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10766 $as_echo "$ac_header_compiler" >&6; }
10767
10768 # Is the header present?
10769 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10770 $as_echo_n "checking $ac_header presence... " >&6; }
10771 cat >conftest.$ac_ext <<_ACEOF
10772 /* confdefs.h.  */
10773 _ACEOF
10774 cat confdefs.h >>conftest.$ac_ext
10775 cat >>conftest.$ac_ext <<_ACEOF
10776 /* end confdefs.h.  */
10777 #include <$ac_header>
10778 _ACEOF
10779 if { (ac_try="$ac_cpp conftest.$ac_ext"
10780 case "(($ac_try" in
10781   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10782   *) ac_try_echo=$ac_try;;
10783 esac
10784 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10785 $as_echo "$ac_try_echo") >&5
10786   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10787   ac_status=$?
10788   grep -v '^ *+' conftest.er1 >conftest.err
10789   rm -f conftest.er1
10790   cat conftest.err >&5
10791   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10792   (exit $ac_status); } >/dev/null && {
10793          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10794          test ! -s conftest.err
10795        }; then
10796   ac_header_preproc=yes
10797 else
10798   $as_echo "$as_me: failed program was:" >&5
10799 sed 's/^/| /' conftest.$ac_ext >&5
10800
10801   ac_header_preproc=no
10802 fi
10803
10804 rm -f conftest.err conftest.$ac_ext
10805 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10806 $as_echo "$ac_header_preproc" >&6; }
10807
10808 # So?  What about this header?
10809 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10810   yes:no: )
10811     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10812 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10813     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10814 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10815     ac_header_preproc=yes
10816     ;;
10817   no:yes:* )
10818     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10819 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10820     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10821 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10822     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10823 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10824     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10825 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10826     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10827 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10828     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10829 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10830     ( cat <<\_ASBOX
10831 ## ---------------------------------------- ##
10832 ## Report this to pgsql-bugs@postgresql.org ##
10833 ## ---------------------------------------- ##
10834 _ASBOX
10835      ) | sed "s/^/$as_me: WARNING:     /" >&2
10836     ;;
10837 esac
10838 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10839 $as_echo_n "checking for $ac_header... " >&6; }
10840 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10841   $as_echo_n "(cached) " >&6
10842 else
10843   eval "$as_ac_Header=\$ac_header_preproc"
10844 fi
10845 ac_res=`eval 'as_val=${'$as_ac_Header'}
10846                  $as_echo "$as_val"'`
10847                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10848 $as_echo "$ac_res" >&6; }
10849
10850 fi
10851 as_val=`eval 'as_val=${'$as_ac_Header'}
10852                  $as_echo "$as_val"'`
10853    if test "x$as_val" = x""yes; then
10854   cat >>confdefs.h <<_ACEOF
10855 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10856 _ACEOF
10857
10858 else
10859
10860 for ac_header in readline.h
10861 do
10862 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10863 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10864   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10865 $as_echo_n "checking for $ac_header... " >&6; }
10866 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10867   $as_echo_n "(cached) " >&6
10868 fi
10869 ac_res=`eval 'as_val=${'$as_ac_Header'}
10870                  $as_echo "$as_val"'`
10871                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10872 $as_echo "$ac_res" >&6; }
10873 else
10874   # Is the header compilable?
10875 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10876 $as_echo_n "checking $ac_header usability... " >&6; }
10877 cat >conftest.$ac_ext <<_ACEOF
10878 /* confdefs.h.  */
10879 _ACEOF
10880 cat confdefs.h >>conftest.$ac_ext
10881 cat >>conftest.$ac_ext <<_ACEOF
10882 /* end confdefs.h.  */
10883 $ac_includes_default
10884 #include <$ac_header>
10885 _ACEOF
10886 rm -f conftest.$ac_objext
10887 if { (ac_try="$ac_compile"
10888 case "(($ac_try" in
10889   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10890   *) ac_try_echo=$ac_try;;
10891 esac
10892 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10893 $as_echo "$ac_try_echo") >&5
10894   (eval "$ac_compile") 2>conftest.er1
10895   ac_status=$?
10896   grep -v '^ *+' conftest.er1 >conftest.err
10897   rm -f conftest.er1
10898   cat conftest.err >&5
10899   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10900   (exit $ac_status); } && {
10901          test -z "$ac_c_werror_flag" ||
10902          test ! -s conftest.err
10903        } && test -s conftest.$ac_objext; then
10904   ac_header_compiler=yes
10905 else
10906   $as_echo "$as_me: failed program was:" >&5
10907 sed 's/^/| /' conftest.$ac_ext >&5
10908
10909         ac_header_compiler=no
10910 fi
10911
10912 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10913 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10914 $as_echo "$ac_header_compiler" >&6; }
10915
10916 # Is the header present?
10917 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10918 $as_echo_n "checking $ac_header presence... " >&6; }
10919 cat >conftest.$ac_ext <<_ACEOF
10920 /* confdefs.h.  */
10921 _ACEOF
10922 cat confdefs.h >>conftest.$ac_ext
10923 cat >>conftest.$ac_ext <<_ACEOF
10924 /* end confdefs.h.  */
10925 #include <$ac_header>
10926 _ACEOF
10927 if { (ac_try="$ac_cpp conftest.$ac_ext"
10928 case "(($ac_try" in
10929   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10930   *) ac_try_echo=$ac_try;;
10931 esac
10932 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10933 $as_echo "$ac_try_echo") >&5
10934   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10935   ac_status=$?
10936   grep -v '^ *+' conftest.er1 >conftest.err
10937   rm -f conftest.er1
10938   cat conftest.err >&5
10939   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10940   (exit $ac_status); } >/dev/null && {
10941          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10942          test ! -s conftest.err
10943        }; then
10944   ac_header_preproc=yes
10945 else
10946   $as_echo "$as_me: failed program was:" >&5
10947 sed 's/^/| /' conftest.$ac_ext >&5
10948
10949   ac_header_preproc=no
10950 fi
10951
10952 rm -f conftest.err conftest.$ac_ext
10953 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10954 $as_echo "$ac_header_preproc" >&6; }
10955
10956 # So?  What about this header?
10957 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10958   yes:no: )
10959     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10960 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10961     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10962 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10963     ac_header_preproc=yes
10964     ;;
10965   no:yes:* )
10966     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10967 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10968     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10969 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10970     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10971 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10972     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10973 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10974     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10975 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10976     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10977 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10978     ( cat <<\_ASBOX
10979 ## ---------------------------------------- ##
10980 ## Report this to pgsql-bugs@postgresql.org ##
10981 ## ---------------------------------------- ##
10982 _ASBOX
10983      ) | sed "s/^/$as_me: WARNING:     /" >&2
10984     ;;
10985 esac
10986 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10987 $as_echo_n "checking for $ac_header... " >&6; }
10988 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10989   $as_echo_n "(cached) " >&6
10990 else
10991   eval "$as_ac_Header=\$ac_header_preproc"
10992 fi
10993 ac_res=`eval 'as_val=${'$as_ac_Header'}
10994                  $as_echo "$as_val"'`
10995                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10996 $as_echo "$ac_res" >&6; }
10997
10998 fi
10999 as_val=`eval 'as_val=${'$as_ac_Header'}
11000                  $as_echo "$as_val"'`
11001    if test "x$as_val" = x""yes; then
11002   cat >>confdefs.h <<_ACEOF
11003 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11004 _ACEOF
11005
11006 else
11007
11008 for ac_header in readline/readline.h
11009 do
11010 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11011 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11012   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11013 $as_echo_n "checking for $ac_header... " >&6; }
11014 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11015   $as_echo_n "(cached) " >&6
11016 fi
11017 ac_res=`eval 'as_val=${'$as_ac_Header'}
11018                  $as_echo "$as_val"'`
11019                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11020 $as_echo "$ac_res" >&6; }
11021 else
11022   # Is the header compilable?
11023 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11024 $as_echo_n "checking $ac_header usability... " >&6; }
11025 cat >conftest.$ac_ext <<_ACEOF
11026 /* confdefs.h.  */
11027 _ACEOF
11028 cat confdefs.h >>conftest.$ac_ext
11029 cat >>conftest.$ac_ext <<_ACEOF
11030 /* end confdefs.h.  */
11031 $ac_includes_default
11032 #include <$ac_header>
11033 _ACEOF
11034 rm -f conftest.$ac_objext
11035 if { (ac_try="$ac_compile"
11036 case "(($ac_try" in
11037   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11038   *) ac_try_echo=$ac_try;;
11039 esac
11040 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11041 $as_echo "$ac_try_echo") >&5
11042   (eval "$ac_compile") 2>conftest.er1
11043   ac_status=$?
11044   grep -v '^ *+' conftest.er1 >conftest.err
11045   rm -f conftest.er1
11046   cat conftest.err >&5
11047   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11048   (exit $ac_status); } && {
11049          test -z "$ac_c_werror_flag" ||
11050          test ! -s conftest.err
11051        } && test -s conftest.$ac_objext; then
11052   ac_header_compiler=yes
11053 else
11054   $as_echo "$as_me: failed program was:" >&5
11055 sed 's/^/| /' conftest.$ac_ext >&5
11056
11057         ac_header_compiler=no
11058 fi
11059
11060 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11061 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11062 $as_echo "$ac_header_compiler" >&6; }
11063
11064 # Is the header present?
11065 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11066 $as_echo_n "checking $ac_header presence... " >&6; }
11067 cat >conftest.$ac_ext <<_ACEOF
11068 /* confdefs.h.  */
11069 _ACEOF
11070 cat confdefs.h >>conftest.$ac_ext
11071 cat >>conftest.$ac_ext <<_ACEOF
11072 /* end confdefs.h.  */
11073 #include <$ac_header>
11074 _ACEOF
11075 if { (ac_try="$ac_cpp conftest.$ac_ext"
11076 case "(($ac_try" in
11077   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11078   *) ac_try_echo=$ac_try;;
11079 esac
11080 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11081 $as_echo "$ac_try_echo") >&5
11082   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11083   ac_status=$?
11084   grep -v '^ *+' conftest.er1 >conftest.err
11085   rm -f conftest.er1
11086   cat conftest.err >&5
11087   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11088   (exit $ac_status); } >/dev/null && {
11089          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11090          test ! -s conftest.err
11091        }; then
11092   ac_header_preproc=yes
11093 else
11094   $as_echo "$as_me: failed program was:" >&5
11095 sed 's/^/| /' conftest.$ac_ext >&5
11096
11097   ac_header_preproc=no
11098 fi
11099
11100 rm -f conftest.err conftest.$ac_ext
11101 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11102 $as_echo "$ac_header_preproc" >&6; }
11103
11104 # So?  What about this header?
11105 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11106   yes:no: )
11107     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11108 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11109     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11110 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11111     ac_header_preproc=yes
11112     ;;
11113   no:yes:* )
11114     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11115 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11116     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11117 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11118     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11119 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11120     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11121 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11122     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11123 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11124     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11125 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11126     ( cat <<\_ASBOX
11127 ## ---------------------------------------- ##
11128 ## Report this to pgsql-bugs@postgresql.org ##
11129 ## ---------------------------------------- ##
11130 _ASBOX
11131      ) | sed "s/^/$as_me: WARNING:     /" >&2
11132     ;;
11133 esac
11134 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11135 $as_echo_n "checking for $ac_header... " >&6; }
11136 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11137   $as_echo_n "(cached) " >&6
11138 else
11139   eval "$as_ac_Header=\$ac_header_preproc"
11140 fi
11141 ac_res=`eval 'as_val=${'$as_ac_Header'}
11142                  $as_echo "$as_val"'`
11143                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11144 $as_echo "$ac_res" >&6; }
11145
11146 fi
11147 as_val=`eval 'as_val=${'$as_ac_Header'}
11148                  $as_echo "$as_val"'`
11149    if test "x$as_val" = x""yes; then
11150   cat >>confdefs.h <<_ACEOF
11151 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11152 _ACEOF
11153
11154 else
11155   { { $as_echo "$as_me:$LINENO: error: readline header not found
11156 If you have libedit already installed, see config.log for details on the
11157 failure.  It is possible the compiler isn't looking in the proper directory.
11158 Use --without-readline to disable libedit support." >&5
11159 $as_echo "$as_me: error: readline header not found
11160 If you have libedit already installed, see config.log for details on the
11161 failure.  It is possible the compiler isn't looking in the proper directory.
11162 Use --without-readline to disable libedit support." >&2;}
11163    { (exit 1); exit 1; }; }
11164 fi
11165
11166 done
11167
11168 fi
11169
11170 done
11171
11172 fi
11173
11174 done
11175
11176 # Note: in a libedit installation, history.h is sometimes a dummy, and may
11177 # not be there at all.  Hence, don't complain if not found.  We must check
11178 # though, since in yet other versions it is an independent header.
11179
11180 for ac_header in editline/history.h
11181 do
11182 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11183 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11184   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11185 $as_echo_n "checking for $ac_header... " >&6; }
11186 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11187   $as_echo_n "(cached) " >&6
11188 fi
11189 ac_res=`eval 'as_val=${'$as_ac_Header'}
11190                  $as_echo "$as_val"'`
11191                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11192 $as_echo "$ac_res" >&6; }
11193 else
11194   # Is the header compilable?
11195 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11196 $as_echo_n "checking $ac_header usability... " >&6; }
11197 cat >conftest.$ac_ext <<_ACEOF
11198 /* confdefs.h.  */
11199 _ACEOF
11200 cat confdefs.h >>conftest.$ac_ext
11201 cat >>conftest.$ac_ext <<_ACEOF
11202 /* end confdefs.h.  */
11203 $ac_includes_default
11204 #include <$ac_header>
11205 _ACEOF
11206 rm -f conftest.$ac_objext
11207 if { (ac_try="$ac_compile"
11208 case "(($ac_try" in
11209   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11210   *) ac_try_echo=$ac_try;;
11211 esac
11212 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11213 $as_echo "$ac_try_echo") >&5
11214   (eval "$ac_compile") 2>conftest.er1
11215   ac_status=$?
11216   grep -v '^ *+' conftest.er1 >conftest.err
11217   rm -f conftest.er1
11218   cat conftest.err >&5
11219   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11220   (exit $ac_status); } && {
11221          test -z "$ac_c_werror_flag" ||
11222          test ! -s conftest.err
11223        } && test -s conftest.$ac_objext; then
11224   ac_header_compiler=yes
11225 else
11226   $as_echo "$as_me: failed program was:" >&5
11227 sed 's/^/| /' conftest.$ac_ext >&5
11228
11229         ac_header_compiler=no
11230 fi
11231
11232 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11233 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11234 $as_echo "$ac_header_compiler" >&6; }
11235
11236 # Is the header present?
11237 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11238 $as_echo_n "checking $ac_header presence... " >&6; }
11239 cat >conftest.$ac_ext <<_ACEOF
11240 /* confdefs.h.  */
11241 _ACEOF
11242 cat confdefs.h >>conftest.$ac_ext
11243 cat >>conftest.$ac_ext <<_ACEOF
11244 /* end confdefs.h.  */
11245 #include <$ac_header>
11246 _ACEOF
11247 if { (ac_try="$ac_cpp conftest.$ac_ext"
11248 case "(($ac_try" in
11249   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11250   *) ac_try_echo=$ac_try;;
11251 esac
11252 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11253 $as_echo "$ac_try_echo") >&5
11254   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11255   ac_status=$?
11256   grep -v '^ *+' conftest.er1 >conftest.err
11257   rm -f conftest.er1
11258   cat conftest.err >&5
11259   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11260   (exit $ac_status); } >/dev/null && {
11261          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11262          test ! -s conftest.err
11263        }; then
11264   ac_header_preproc=yes
11265 else
11266   $as_echo "$as_me: failed program was:" >&5
11267 sed 's/^/| /' conftest.$ac_ext >&5
11268
11269   ac_header_preproc=no
11270 fi
11271
11272 rm -f conftest.err conftest.$ac_ext
11273 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11274 $as_echo "$ac_header_preproc" >&6; }
11275
11276 # So?  What about this header?
11277 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11278   yes:no: )
11279     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11280 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11281     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11282 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11283     ac_header_preproc=yes
11284     ;;
11285   no:yes:* )
11286     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11287 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11288     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11289 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11290     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11291 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11292     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11293 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11294     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11295 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11296     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11297 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11298     ( cat <<\_ASBOX
11299 ## ---------------------------------------- ##
11300 ## Report this to pgsql-bugs@postgresql.org ##
11301 ## ---------------------------------------- ##
11302 _ASBOX
11303      ) | sed "s/^/$as_me: WARNING:     /" >&2
11304     ;;
11305 esac
11306 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11307 $as_echo_n "checking for $ac_header... " >&6; }
11308 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11309   $as_echo_n "(cached) " >&6
11310 else
11311   eval "$as_ac_Header=\$ac_header_preproc"
11312 fi
11313 ac_res=`eval 'as_val=${'$as_ac_Header'}
11314                  $as_echo "$as_val"'`
11315                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11316 $as_echo "$ac_res" >&6; }
11317
11318 fi
11319 as_val=`eval 'as_val=${'$as_ac_Header'}
11320                  $as_echo "$as_val"'`
11321    if test "x$as_val" = x""yes; then
11322   cat >>confdefs.h <<_ACEOF
11323 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11324 _ACEOF
11325
11326 else
11327
11328 for ac_header in history.h
11329 do
11330 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11331 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11332   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11333 $as_echo_n "checking for $ac_header... " >&6; }
11334 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11335   $as_echo_n "(cached) " >&6
11336 fi
11337 ac_res=`eval 'as_val=${'$as_ac_Header'}
11338                  $as_echo "$as_val"'`
11339                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11340 $as_echo "$ac_res" >&6; }
11341 else
11342   # Is the header compilable?
11343 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11344 $as_echo_n "checking $ac_header usability... " >&6; }
11345 cat >conftest.$ac_ext <<_ACEOF
11346 /* confdefs.h.  */
11347 _ACEOF
11348 cat confdefs.h >>conftest.$ac_ext
11349 cat >>conftest.$ac_ext <<_ACEOF
11350 /* end confdefs.h.  */
11351 $ac_includes_default
11352 #include <$ac_header>
11353 _ACEOF
11354 rm -f conftest.$ac_objext
11355 if { (ac_try="$ac_compile"
11356 case "(($ac_try" in
11357   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11358   *) ac_try_echo=$ac_try;;
11359 esac
11360 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11361 $as_echo "$ac_try_echo") >&5
11362   (eval "$ac_compile") 2>conftest.er1
11363   ac_status=$?
11364   grep -v '^ *+' conftest.er1 >conftest.err
11365   rm -f conftest.er1
11366   cat conftest.err >&5
11367   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11368   (exit $ac_status); } && {
11369          test -z "$ac_c_werror_flag" ||
11370          test ! -s conftest.err
11371        } && test -s conftest.$ac_objext; then
11372   ac_header_compiler=yes
11373 else
11374   $as_echo "$as_me: failed program was:" >&5
11375 sed 's/^/| /' conftest.$ac_ext >&5
11376
11377         ac_header_compiler=no
11378 fi
11379
11380 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11381 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11382 $as_echo "$ac_header_compiler" >&6; }
11383
11384 # Is the header present?
11385 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11386 $as_echo_n "checking $ac_header presence... " >&6; }
11387 cat >conftest.$ac_ext <<_ACEOF
11388 /* confdefs.h.  */
11389 _ACEOF
11390 cat confdefs.h >>conftest.$ac_ext
11391 cat >>conftest.$ac_ext <<_ACEOF
11392 /* end confdefs.h.  */
11393 #include <$ac_header>
11394 _ACEOF
11395 if { (ac_try="$ac_cpp conftest.$ac_ext"
11396 case "(($ac_try" in
11397   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11398   *) ac_try_echo=$ac_try;;
11399 esac
11400 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11401 $as_echo "$ac_try_echo") >&5
11402   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11403   ac_status=$?
11404   grep -v '^ *+' conftest.er1 >conftest.err
11405   rm -f conftest.er1
11406   cat conftest.err >&5
11407   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11408   (exit $ac_status); } >/dev/null && {
11409          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11410          test ! -s conftest.err
11411        }; then
11412   ac_header_preproc=yes
11413 else
11414   $as_echo "$as_me: failed program was:" >&5
11415 sed 's/^/| /' conftest.$ac_ext >&5
11416
11417   ac_header_preproc=no
11418 fi
11419
11420 rm -f conftest.err conftest.$ac_ext
11421 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11422 $as_echo "$ac_header_preproc" >&6; }
11423
11424 # So?  What about this header?
11425 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11426   yes:no: )
11427     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11428 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11429     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11430 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11431     ac_header_preproc=yes
11432     ;;
11433   no:yes:* )
11434     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11435 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11436     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11437 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11438     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11439 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11440     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11441 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11442     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11443 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11444     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11445 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11446     ( cat <<\_ASBOX
11447 ## ---------------------------------------- ##
11448 ## Report this to pgsql-bugs@postgresql.org ##
11449 ## ---------------------------------------- ##
11450 _ASBOX
11451      ) | sed "s/^/$as_me: WARNING:     /" >&2
11452     ;;
11453 esac
11454 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11455 $as_echo_n "checking for $ac_header... " >&6; }
11456 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11457   $as_echo_n "(cached) " >&6
11458 else
11459   eval "$as_ac_Header=\$ac_header_preproc"
11460 fi
11461 ac_res=`eval 'as_val=${'$as_ac_Header'}
11462                  $as_echo "$as_val"'`
11463                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11464 $as_echo "$ac_res" >&6; }
11465
11466 fi
11467 as_val=`eval 'as_val=${'$as_ac_Header'}
11468                  $as_echo "$as_val"'`
11469    if test "x$as_val" = x""yes; then
11470   cat >>confdefs.h <<_ACEOF
11471 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11472 _ACEOF
11473
11474 else
11475
11476 for ac_header in readline/history.h
11477 do
11478 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11479 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11480   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11481 $as_echo_n "checking for $ac_header... " >&6; }
11482 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11483   $as_echo_n "(cached) " >&6
11484 fi
11485 ac_res=`eval 'as_val=${'$as_ac_Header'}
11486                  $as_echo "$as_val"'`
11487                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11488 $as_echo "$ac_res" >&6; }
11489 else
11490   # Is the header compilable?
11491 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11492 $as_echo_n "checking $ac_header usability... " >&6; }
11493 cat >conftest.$ac_ext <<_ACEOF
11494 /* confdefs.h.  */
11495 _ACEOF
11496 cat confdefs.h >>conftest.$ac_ext
11497 cat >>conftest.$ac_ext <<_ACEOF
11498 /* end confdefs.h.  */
11499 $ac_includes_default
11500 #include <$ac_header>
11501 _ACEOF
11502 rm -f conftest.$ac_objext
11503 if { (ac_try="$ac_compile"
11504 case "(($ac_try" in
11505   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11506   *) ac_try_echo=$ac_try;;
11507 esac
11508 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11509 $as_echo "$ac_try_echo") >&5
11510   (eval "$ac_compile") 2>conftest.er1
11511   ac_status=$?
11512   grep -v '^ *+' conftest.er1 >conftest.err
11513   rm -f conftest.er1
11514   cat conftest.err >&5
11515   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11516   (exit $ac_status); } && {
11517          test -z "$ac_c_werror_flag" ||
11518          test ! -s conftest.err
11519        } && test -s conftest.$ac_objext; then
11520   ac_header_compiler=yes
11521 else
11522   $as_echo "$as_me: failed program was:" >&5
11523 sed 's/^/| /' conftest.$ac_ext >&5
11524
11525         ac_header_compiler=no
11526 fi
11527
11528 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11529 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11530 $as_echo "$ac_header_compiler" >&6; }
11531
11532 # Is the header present?
11533 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11534 $as_echo_n "checking $ac_header presence... " >&6; }
11535 cat >conftest.$ac_ext <<_ACEOF
11536 /* confdefs.h.  */
11537 _ACEOF
11538 cat confdefs.h >>conftest.$ac_ext
11539 cat >>conftest.$ac_ext <<_ACEOF
11540 /* end confdefs.h.  */
11541 #include <$ac_header>
11542 _ACEOF
11543 if { (ac_try="$ac_cpp conftest.$ac_ext"
11544 case "(($ac_try" in
11545   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11546   *) ac_try_echo=$ac_try;;
11547 esac
11548 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11549 $as_echo "$ac_try_echo") >&5
11550   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11551   ac_status=$?
11552   grep -v '^ *+' conftest.er1 >conftest.err
11553   rm -f conftest.er1
11554   cat conftest.err >&5
11555   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11556   (exit $ac_status); } >/dev/null && {
11557          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11558          test ! -s conftest.err
11559        }; then
11560   ac_header_preproc=yes
11561 else
11562   $as_echo "$as_me: failed program was:" >&5
11563 sed 's/^/| /' conftest.$ac_ext >&5
11564
11565   ac_header_preproc=no
11566 fi
11567
11568 rm -f conftest.err conftest.$ac_ext
11569 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11570 $as_echo "$ac_header_preproc" >&6; }
11571
11572 # So?  What about this header?
11573 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11574   yes:no: )
11575     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11576 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11577     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11578 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11579     ac_header_preproc=yes
11580     ;;
11581   no:yes:* )
11582     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11583 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11584     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11585 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11586     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11587 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11588     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11589 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11590     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11591 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11592     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11593 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11594     ( cat <<\_ASBOX
11595 ## ---------------------------------------- ##
11596 ## Report this to pgsql-bugs@postgresql.org ##
11597 ## ---------------------------------------- ##
11598 _ASBOX
11599      ) | sed "s/^/$as_me: WARNING:     /" >&2
11600     ;;
11601 esac
11602 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11603 $as_echo_n "checking for $ac_header... " >&6; }
11604 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11605   $as_echo_n "(cached) " >&6
11606 else
11607   eval "$as_ac_Header=\$ac_header_preproc"
11608 fi
11609 ac_res=`eval 'as_val=${'$as_ac_Header'}
11610                  $as_echo "$as_val"'`
11611                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11612 $as_echo "$ac_res" >&6; }
11613
11614 fi
11615 as_val=`eval 'as_val=${'$as_ac_Header'}
11616                  $as_echo "$as_val"'`
11617    if test "x$as_val" = x""yes; then
11618   cat >>confdefs.h <<_ACEOF
11619 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11620 _ACEOF
11621
11622 fi
11623
11624 done
11625
11626 fi
11627
11628 done
11629
11630 fi
11631
11632 done
11633
11634 fi
11635
11636 if test "$with_zlib" = yes; then
11637   if test "${ac_cv_header_zlib_h+set}" = set; then
11638   { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
11639 $as_echo_n "checking for zlib.h... " >&6; }
11640 if test "${ac_cv_header_zlib_h+set}" = set; then
11641   $as_echo_n "(cached) " >&6
11642 fi
11643 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
11644 $as_echo "$ac_cv_header_zlib_h" >&6; }
11645 else
11646   # Is the header compilable?
11647 { $as_echo "$as_me:$LINENO: checking zlib.h usability" >&5
11648 $as_echo_n "checking zlib.h usability... " >&6; }
11649 cat >conftest.$ac_ext <<_ACEOF
11650 /* confdefs.h.  */
11651 _ACEOF
11652 cat confdefs.h >>conftest.$ac_ext
11653 cat >>conftest.$ac_ext <<_ACEOF
11654 /* end confdefs.h.  */
11655 $ac_includes_default
11656 #include <zlib.h>
11657 _ACEOF
11658 rm -f conftest.$ac_objext
11659 if { (ac_try="$ac_compile"
11660 case "(($ac_try" in
11661   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11662   *) ac_try_echo=$ac_try;;
11663 esac
11664 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11665 $as_echo "$ac_try_echo") >&5
11666   (eval "$ac_compile") 2>conftest.er1
11667   ac_status=$?
11668   grep -v '^ *+' conftest.er1 >conftest.err
11669   rm -f conftest.er1
11670   cat conftest.err >&5
11671   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11672   (exit $ac_status); } && {
11673          test -z "$ac_c_werror_flag" ||
11674          test ! -s conftest.err
11675        } && test -s conftest.$ac_objext; then
11676   ac_header_compiler=yes
11677 else
11678   $as_echo "$as_me: failed program was:" >&5
11679 sed 's/^/| /' conftest.$ac_ext >&5
11680
11681         ac_header_compiler=no
11682 fi
11683
11684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11685 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11686 $as_echo "$ac_header_compiler" >&6; }
11687
11688 # Is the header present?
11689 { $as_echo "$as_me:$LINENO: checking zlib.h presence" >&5
11690 $as_echo_n "checking zlib.h presence... " >&6; }
11691 cat >conftest.$ac_ext <<_ACEOF
11692 /* confdefs.h.  */
11693 _ACEOF
11694 cat confdefs.h >>conftest.$ac_ext
11695 cat >>conftest.$ac_ext <<_ACEOF
11696 /* end confdefs.h.  */
11697 #include <zlib.h>
11698 _ACEOF
11699 if { (ac_try="$ac_cpp conftest.$ac_ext"
11700 case "(($ac_try" in
11701   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11702   *) ac_try_echo=$ac_try;;
11703 esac
11704 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11705 $as_echo "$ac_try_echo") >&5
11706   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11707   ac_status=$?
11708   grep -v '^ *+' conftest.er1 >conftest.err
11709   rm -f conftest.er1
11710   cat conftest.err >&5
11711   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11712   (exit $ac_status); } >/dev/null && {
11713          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11714          test ! -s conftest.err
11715        }; then
11716   ac_header_preproc=yes
11717 else
11718   $as_echo "$as_me: failed program was:" >&5
11719 sed 's/^/| /' conftest.$ac_ext >&5
11720
11721   ac_header_preproc=no
11722 fi
11723
11724 rm -f conftest.err conftest.$ac_ext
11725 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11726 $as_echo "$ac_header_preproc" >&6; }
11727
11728 # So?  What about this header?
11729 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11730   yes:no: )
11731     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
11732 $as_echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11733     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
11734 $as_echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
11735     ac_header_preproc=yes
11736     ;;
11737   no:yes:* )
11738     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
11739 $as_echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
11740     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
11741 $as_echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
11742     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
11743 $as_echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
11744     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
11745 $as_echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11746     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
11747 $as_echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
11748     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
11749 $as_echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
11750     ( cat <<\_ASBOX
11751 ## ---------------------------------------- ##
11752 ## Report this to pgsql-bugs@postgresql.org ##
11753 ## ---------------------------------------- ##
11754 _ASBOX
11755      ) | sed "s/^/$as_me: WARNING:     /" >&2
11756     ;;
11757 esac
11758 { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
11759 $as_echo_n "checking for zlib.h... " >&6; }
11760 if test "${ac_cv_header_zlib_h+set}" = set; then
11761   $as_echo_n "(cached) " >&6
11762 else
11763   ac_cv_header_zlib_h=$ac_header_preproc
11764 fi
11765 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
11766 $as_echo "$ac_cv_header_zlib_h" >&6; }
11767
11768 fi
11769 if test "x$ac_cv_header_zlib_h" = x""yes; then
11770   :
11771 else
11772   { { $as_echo "$as_me:$LINENO: error: zlib header not found
11773 If you have zlib already installed, see config.log for details on the
11774 failure.  It is possible the compiler isn't looking in the proper directory.
11775 Use --without-zlib to disable zlib support." >&5
11776 $as_echo "$as_me: error: zlib header not found
11777 If you have zlib already installed, see config.log for details on the
11778 failure.  It is possible the compiler isn't looking in the proper directory.
11779 Use --without-zlib to disable zlib support." >&2;}
11780    { (exit 1); exit 1; }; }
11781 fi
11782
11783
11784 fi
11785
11786 if test "$with_gssapi" = yes ; then
11787
11788 for ac_header in gssapi/gssapi.h
11789 do
11790 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11791 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11792   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11793 $as_echo_n "checking for $ac_header... " >&6; }
11794 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11795   $as_echo_n "(cached) " >&6
11796 fi
11797 ac_res=`eval 'as_val=${'$as_ac_Header'}
11798                  $as_echo "$as_val"'`
11799                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11800 $as_echo "$ac_res" >&6; }
11801 else
11802   # Is the header compilable?
11803 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11804 $as_echo_n "checking $ac_header usability... " >&6; }
11805 cat >conftest.$ac_ext <<_ACEOF
11806 /* confdefs.h.  */
11807 _ACEOF
11808 cat confdefs.h >>conftest.$ac_ext
11809 cat >>conftest.$ac_ext <<_ACEOF
11810 /* end confdefs.h.  */
11811 $ac_includes_default
11812 #include <$ac_header>
11813 _ACEOF
11814 rm -f conftest.$ac_objext
11815 if { (ac_try="$ac_compile"
11816 case "(($ac_try" in
11817   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11818   *) ac_try_echo=$ac_try;;
11819 esac
11820 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11821 $as_echo "$ac_try_echo") >&5
11822   (eval "$ac_compile") 2>conftest.er1
11823   ac_status=$?
11824   grep -v '^ *+' conftest.er1 >conftest.err
11825   rm -f conftest.er1
11826   cat conftest.err >&5
11827   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11828   (exit $ac_status); } && {
11829          test -z "$ac_c_werror_flag" ||
11830          test ! -s conftest.err
11831        } && test -s conftest.$ac_objext; then
11832   ac_header_compiler=yes
11833 else
11834   $as_echo "$as_me: failed program was:" >&5
11835 sed 's/^/| /' conftest.$ac_ext >&5
11836
11837         ac_header_compiler=no
11838 fi
11839
11840 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11841 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11842 $as_echo "$ac_header_compiler" >&6; }
11843
11844 # Is the header present?
11845 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11846 $as_echo_n "checking $ac_header presence... " >&6; }
11847 cat >conftest.$ac_ext <<_ACEOF
11848 /* confdefs.h.  */
11849 _ACEOF
11850 cat confdefs.h >>conftest.$ac_ext
11851 cat >>conftest.$ac_ext <<_ACEOF
11852 /* end confdefs.h.  */
11853 #include <$ac_header>
11854 _ACEOF
11855 if { (ac_try="$ac_cpp conftest.$ac_ext"
11856 case "(($ac_try" in
11857   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11858   *) ac_try_echo=$ac_try;;
11859 esac
11860 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11861 $as_echo "$ac_try_echo") >&5
11862   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11863   ac_status=$?
11864   grep -v '^ *+' conftest.er1 >conftest.err
11865   rm -f conftest.er1
11866   cat conftest.err >&5
11867   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11868   (exit $ac_status); } >/dev/null && {
11869          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11870          test ! -s conftest.err
11871        }; then
11872   ac_header_preproc=yes
11873 else
11874   $as_echo "$as_me: failed program was:" >&5
11875 sed 's/^/| /' conftest.$ac_ext >&5
11876
11877   ac_header_preproc=no
11878 fi
11879
11880 rm -f conftest.err conftest.$ac_ext
11881 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11882 $as_echo "$ac_header_preproc" >&6; }
11883
11884 # So?  What about this header?
11885 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11886   yes:no: )
11887     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11888 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11889     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11890 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11891     ac_header_preproc=yes
11892     ;;
11893   no:yes:* )
11894     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11895 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11896     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11897 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11898     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11899 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11900     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11901 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11902     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11903 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11904     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11905 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11906     ( cat <<\_ASBOX
11907 ## ---------------------------------------- ##
11908 ## Report this to pgsql-bugs@postgresql.org ##
11909 ## ---------------------------------------- ##
11910 _ASBOX
11911      ) | sed "s/^/$as_me: WARNING:     /" >&2
11912     ;;
11913 esac
11914 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11915 $as_echo_n "checking for $ac_header... " >&6; }
11916 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11917   $as_echo_n "(cached) " >&6
11918 else
11919   eval "$as_ac_Header=\$ac_header_preproc"
11920 fi
11921 ac_res=`eval 'as_val=${'$as_ac_Header'}
11922                  $as_echo "$as_val"'`
11923                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11924 $as_echo "$ac_res" >&6; }
11925
11926 fi
11927 as_val=`eval 'as_val=${'$as_ac_Header'}
11928                  $as_echo "$as_val"'`
11929    if test "x$as_val" = x""yes; then
11930   cat >>confdefs.h <<_ACEOF
11931 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11932 _ACEOF
11933
11934 else
11935
11936 for ac_header in gssapi.h
11937 do
11938 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11939 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11940   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11941 $as_echo_n "checking for $ac_header... " >&6; }
11942 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11943   $as_echo_n "(cached) " >&6
11944 fi
11945 ac_res=`eval 'as_val=${'$as_ac_Header'}
11946                  $as_echo "$as_val"'`
11947                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11948 $as_echo "$ac_res" >&6; }
11949 else
11950   # Is the header compilable?
11951 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11952 $as_echo_n "checking $ac_header usability... " >&6; }
11953 cat >conftest.$ac_ext <<_ACEOF
11954 /* confdefs.h.  */
11955 _ACEOF
11956 cat confdefs.h >>conftest.$ac_ext
11957 cat >>conftest.$ac_ext <<_ACEOF
11958 /* end confdefs.h.  */
11959 $ac_includes_default
11960 #include <$ac_header>
11961 _ACEOF
11962 rm -f conftest.$ac_objext
11963 if { (ac_try="$ac_compile"
11964 case "(($ac_try" in
11965   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11966   *) ac_try_echo=$ac_try;;
11967 esac
11968 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11969 $as_echo "$ac_try_echo") >&5
11970   (eval "$ac_compile") 2>conftest.er1
11971   ac_status=$?
11972   grep -v '^ *+' conftest.er1 >conftest.err
11973   rm -f conftest.er1
11974   cat conftest.err >&5
11975   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11976   (exit $ac_status); } && {
11977          test -z "$ac_c_werror_flag" ||
11978          test ! -s conftest.err
11979        } && test -s conftest.$ac_objext; then
11980   ac_header_compiler=yes
11981 else
11982   $as_echo "$as_me: failed program was:" >&5
11983 sed 's/^/| /' conftest.$ac_ext >&5
11984
11985         ac_header_compiler=no
11986 fi
11987
11988 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11989 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11990 $as_echo "$ac_header_compiler" >&6; }
11991
11992 # Is the header present?
11993 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11994 $as_echo_n "checking $ac_header presence... " >&6; }
11995 cat >conftest.$ac_ext <<_ACEOF
11996 /* confdefs.h.  */
11997 _ACEOF
11998 cat confdefs.h >>conftest.$ac_ext
11999 cat >>conftest.$ac_ext <<_ACEOF
12000 /* end confdefs.h.  */
12001 #include <$ac_header>
12002 _ACEOF
12003 if { (ac_try="$ac_cpp conftest.$ac_ext"
12004 case "(($ac_try" in
12005   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12006   *) ac_try_echo=$ac_try;;
12007 esac
12008 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12009 $as_echo "$ac_try_echo") >&5
12010   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12011   ac_status=$?
12012   grep -v '^ *+' conftest.er1 >conftest.err
12013   rm -f conftest.er1
12014   cat conftest.err >&5
12015   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12016   (exit $ac_status); } >/dev/null && {
12017          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12018          test ! -s conftest.err
12019        }; then
12020   ac_header_preproc=yes
12021 else
12022   $as_echo "$as_me: failed program was:" >&5
12023 sed 's/^/| /' conftest.$ac_ext >&5
12024
12025   ac_header_preproc=no
12026 fi
12027
12028 rm -f conftest.err conftest.$ac_ext
12029 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12030 $as_echo "$ac_header_preproc" >&6; }
12031
12032 # So?  What about this header?
12033 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12034   yes:no: )
12035     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12036 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12037     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12038 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12039     ac_header_preproc=yes
12040     ;;
12041   no:yes:* )
12042     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12043 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12044     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12045 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12046     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12047 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12048     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12049 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12050     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12051 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12052     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12053 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12054     ( cat <<\_ASBOX
12055 ## ---------------------------------------- ##
12056 ## Report this to pgsql-bugs@postgresql.org ##
12057 ## ---------------------------------------- ##
12058 _ASBOX
12059      ) | sed "s/^/$as_me: WARNING:     /" >&2
12060     ;;
12061 esac
12062 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12063 $as_echo_n "checking for $ac_header... " >&6; }
12064 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12065   $as_echo_n "(cached) " >&6
12066 else
12067   eval "$as_ac_Header=\$ac_header_preproc"
12068 fi
12069 ac_res=`eval 'as_val=${'$as_ac_Header'}
12070                  $as_echo "$as_val"'`
12071                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12072 $as_echo "$ac_res" >&6; }
12073
12074 fi
12075 as_val=`eval 'as_val=${'$as_ac_Header'}
12076                  $as_echo "$as_val"'`
12077    if test "x$as_val" = x""yes; then
12078   cat >>confdefs.h <<_ACEOF
12079 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12080 _ACEOF
12081
12082 else
12083   { { $as_echo "$as_me:$LINENO: error: gssapi.h header file is required for GSSAPI" >&5
12084 $as_echo "$as_me: error: gssapi.h header file is required for GSSAPI" >&2;}
12085    { (exit 1); exit 1; }; }
12086 fi
12087
12088 done
12089
12090 fi
12091
12092 done
12093
12094 fi
12095
12096 if test "$with_krb5" = yes ; then
12097   if test "${ac_cv_header_krb5_h+set}" = set; then
12098   { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12099 $as_echo_n "checking for krb5.h... " >&6; }
12100 if test "${ac_cv_header_krb5_h+set}" = set; then
12101   $as_echo_n "(cached) " >&6
12102 fi
12103 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12104 $as_echo "$ac_cv_header_krb5_h" >&6; }
12105 else
12106   # Is the header compilable?
12107 { $as_echo "$as_me:$LINENO: checking krb5.h usability" >&5
12108 $as_echo_n "checking krb5.h usability... " >&6; }
12109 cat >conftest.$ac_ext <<_ACEOF
12110 /* confdefs.h.  */
12111 _ACEOF
12112 cat confdefs.h >>conftest.$ac_ext
12113 cat >>conftest.$ac_ext <<_ACEOF
12114 /* end confdefs.h.  */
12115 $ac_includes_default
12116 #include <krb5.h>
12117 _ACEOF
12118 rm -f conftest.$ac_objext
12119 if { (ac_try="$ac_compile"
12120 case "(($ac_try" in
12121   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12122   *) ac_try_echo=$ac_try;;
12123 esac
12124 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12125 $as_echo "$ac_try_echo") >&5
12126   (eval "$ac_compile") 2>conftest.er1
12127   ac_status=$?
12128   grep -v '^ *+' conftest.er1 >conftest.err
12129   rm -f conftest.er1
12130   cat conftest.err >&5
12131   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12132   (exit $ac_status); } && {
12133          test -z "$ac_c_werror_flag" ||
12134          test ! -s conftest.err
12135        } && test -s conftest.$ac_objext; then
12136   ac_header_compiler=yes
12137 else
12138   $as_echo "$as_me: failed program was:" >&5
12139 sed 's/^/| /' conftest.$ac_ext >&5
12140
12141         ac_header_compiler=no
12142 fi
12143
12144 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12145 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12146 $as_echo "$ac_header_compiler" >&6; }
12147
12148 # Is the header present?
12149 { $as_echo "$as_me:$LINENO: checking krb5.h presence" >&5
12150 $as_echo_n "checking krb5.h presence... " >&6; }
12151 cat >conftest.$ac_ext <<_ACEOF
12152 /* confdefs.h.  */
12153 _ACEOF
12154 cat confdefs.h >>conftest.$ac_ext
12155 cat >>conftest.$ac_ext <<_ACEOF
12156 /* end confdefs.h.  */
12157 #include <krb5.h>
12158 _ACEOF
12159 if { (ac_try="$ac_cpp conftest.$ac_ext"
12160 case "(($ac_try" in
12161   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12162   *) ac_try_echo=$ac_try;;
12163 esac
12164 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12165 $as_echo "$ac_try_echo") >&5
12166   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12167   ac_status=$?
12168   grep -v '^ *+' conftest.er1 >conftest.err
12169   rm -f conftest.er1
12170   cat conftest.err >&5
12171   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12172   (exit $ac_status); } >/dev/null && {
12173          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12174          test ! -s conftest.err
12175        }; then
12176   ac_header_preproc=yes
12177 else
12178   $as_echo "$as_me: failed program was:" >&5
12179 sed 's/^/| /' conftest.$ac_ext >&5
12180
12181   ac_header_preproc=no
12182 fi
12183
12184 rm -f conftest.err conftest.$ac_ext
12185 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12186 $as_echo "$ac_header_preproc" >&6; }
12187
12188 # So?  What about this header?
12189 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12190   yes:no: )
12191     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
12192 $as_echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12193     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
12194 $as_echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
12195     ac_header_preproc=yes
12196     ;;
12197   no:yes:* )
12198     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
12199 $as_echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
12200     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
12201 $as_echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
12202     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
12203 $as_echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
12204     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
12205 $as_echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12206     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
12207 $as_echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
12208     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
12209 $as_echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
12210     ( cat <<\_ASBOX
12211 ## ---------------------------------------- ##
12212 ## Report this to pgsql-bugs@postgresql.org ##
12213 ## ---------------------------------------- ##
12214 _ASBOX
12215      ) | sed "s/^/$as_me: WARNING:     /" >&2
12216     ;;
12217 esac
12218 { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12219 $as_echo_n "checking for krb5.h... " >&6; }
12220 if test "${ac_cv_header_krb5_h+set}" = set; then
12221   $as_echo_n "(cached) " >&6
12222 else
12223   ac_cv_header_krb5_h=$ac_header_preproc
12224 fi
12225 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12226 $as_echo "$ac_cv_header_krb5_h" >&6; }
12227
12228 fi
12229 if test "x$ac_cv_header_krb5_h" = x""yes; then
12230   :
12231 else
12232   { { $as_echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
12233 $as_echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
12234    { (exit 1); exit 1; }; }
12235 fi
12236
12237
12238 fi
12239
12240 if test "$with_openssl" = yes ; then
12241   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12242   { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12243 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12244 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12245   $as_echo_n "(cached) " >&6
12246 fi
12247 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12248 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12249 else
12250   # Is the header compilable?
12251 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
12252 $as_echo_n "checking openssl/ssl.h usability... " >&6; }
12253 cat >conftest.$ac_ext <<_ACEOF
12254 /* confdefs.h.  */
12255 _ACEOF
12256 cat confdefs.h >>conftest.$ac_ext
12257 cat >>conftest.$ac_ext <<_ACEOF
12258 /* end confdefs.h.  */
12259 $ac_includes_default
12260 #include <openssl/ssl.h>
12261 _ACEOF
12262 rm -f conftest.$ac_objext
12263 if { (ac_try="$ac_compile"
12264 case "(($ac_try" in
12265   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12266   *) ac_try_echo=$ac_try;;
12267 esac
12268 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12269 $as_echo "$ac_try_echo") >&5
12270   (eval "$ac_compile") 2>conftest.er1
12271   ac_status=$?
12272   grep -v '^ *+' conftest.er1 >conftest.err
12273   rm -f conftest.er1
12274   cat conftest.err >&5
12275   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12276   (exit $ac_status); } && {
12277          test -z "$ac_c_werror_flag" ||
12278          test ! -s conftest.err
12279        } && test -s conftest.$ac_objext; then
12280   ac_header_compiler=yes
12281 else
12282   $as_echo "$as_me: failed program was:" >&5
12283 sed 's/^/| /' conftest.$ac_ext >&5
12284
12285         ac_header_compiler=no
12286 fi
12287
12288 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12289 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12290 $as_echo "$ac_header_compiler" >&6; }
12291
12292 # Is the header present?
12293 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
12294 $as_echo_n "checking openssl/ssl.h presence... " >&6; }
12295 cat >conftest.$ac_ext <<_ACEOF
12296 /* confdefs.h.  */
12297 _ACEOF
12298 cat confdefs.h >>conftest.$ac_ext
12299 cat >>conftest.$ac_ext <<_ACEOF
12300 /* end confdefs.h.  */
12301 #include <openssl/ssl.h>
12302 _ACEOF
12303 if { (ac_try="$ac_cpp conftest.$ac_ext"
12304 case "(($ac_try" in
12305   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12306   *) ac_try_echo=$ac_try;;
12307 esac
12308 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12309 $as_echo "$ac_try_echo") >&5
12310   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12311   ac_status=$?
12312   grep -v '^ *+' conftest.er1 >conftest.err
12313   rm -f conftest.er1
12314   cat conftest.err >&5
12315   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12316   (exit $ac_status); } >/dev/null && {
12317          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12318          test ! -s conftest.err
12319        }; then
12320   ac_header_preproc=yes
12321 else
12322   $as_echo "$as_me: failed program was:" >&5
12323 sed 's/^/| /' conftest.$ac_ext >&5
12324
12325   ac_header_preproc=no
12326 fi
12327
12328 rm -f conftest.err conftest.$ac_ext
12329 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12330 $as_echo "$ac_header_preproc" >&6; }
12331
12332 # So?  What about this header?
12333 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12334   yes:no: )
12335     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
12336 $as_echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12337     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
12338 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
12339     ac_header_preproc=yes
12340     ;;
12341   no:yes:* )
12342     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
12343 $as_echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
12344     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
12345 $as_echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
12346     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
12347 $as_echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
12348     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
12349 $as_echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12350     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
12351 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
12352     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
12353 $as_echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
12354     ( cat <<\_ASBOX
12355 ## ---------------------------------------- ##
12356 ## Report this to pgsql-bugs@postgresql.org ##
12357 ## ---------------------------------------- ##
12358 _ASBOX
12359      ) | sed "s/^/$as_me: WARNING:     /" >&2
12360     ;;
12361 esac
12362 { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12363 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12364 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12365   $as_echo_n "(cached) " >&6
12366 else
12367   ac_cv_header_openssl_ssl_h=$ac_header_preproc
12368 fi
12369 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12370 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12371
12372 fi
12373 if test "x$ac_cv_header_openssl_ssl_h" = x""yes; then
12374   :
12375 else
12376   { { $as_echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
12377 $as_echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
12378    { (exit 1); exit 1; }; }
12379 fi
12380
12381
12382   if test "${ac_cv_header_openssl_err_h+set}" = set; then
12383   { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12384 $as_echo_n "checking for openssl/err.h... " >&6; }
12385 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12386   $as_echo_n "(cached) " >&6
12387 fi
12388 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12389 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12390 else
12391   # Is the header compilable?
12392 { $as_echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
12393 $as_echo_n "checking openssl/err.h usability... " >&6; }
12394 cat >conftest.$ac_ext <<_ACEOF
12395 /* confdefs.h.  */
12396 _ACEOF
12397 cat confdefs.h >>conftest.$ac_ext
12398 cat >>conftest.$ac_ext <<_ACEOF
12399 /* end confdefs.h.  */
12400 $ac_includes_default
12401 #include <openssl/err.h>
12402 _ACEOF
12403 rm -f conftest.$ac_objext
12404 if { (ac_try="$ac_compile"
12405 case "(($ac_try" in
12406   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12407   *) ac_try_echo=$ac_try;;
12408 esac
12409 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12410 $as_echo "$ac_try_echo") >&5
12411   (eval "$ac_compile") 2>conftest.er1
12412   ac_status=$?
12413   grep -v '^ *+' conftest.er1 >conftest.err
12414   rm -f conftest.er1
12415   cat conftest.err >&5
12416   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12417   (exit $ac_status); } && {
12418          test -z "$ac_c_werror_flag" ||
12419          test ! -s conftest.err
12420        } && test -s conftest.$ac_objext; then
12421   ac_header_compiler=yes
12422 else
12423   $as_echo "$as_me: failed program was:" >&5
12424 sed 's/^/| /' conftest.$ac_ext >&5
12425
12426         ac_header_compiler=no
12427 fi
12428
12429 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12430 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12431 $as_echo "$ac_header_compiler" >&6; }
12432
12433 # Is the header present?
12434 { $as_echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
12435 $as_echo_n "checking openssl/err.h presence... " >&6; }
12436 cat >conftest.$ac_ext <<_ACEOF
12437 /* confdefs.h.  */
12438 _ACEOF
12439 cat confdefs.h >>conftest.$ac_ext
12440 cat >>conftest.$ac_ext <<_ACEOF
12441 /* end confdefs.h.  */
12442 #include <openssl/err.h>
12443 _ACEOF
12444 if { (ac_try="$ac_cpp conftest.$ac_ext"
12445 case "(($ac_try" in
12446   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12447   *) ac_try_echo=$ac_try;;
12448 esac
12449 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12450 $as_echo "$ac_try_echo") >&5
12451   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12452   ac_status=$?
12453   grep -v '^ *+' conftest.er1 >conftest.err
12454   rm -f conftest.er1
12455   cat conftest.err >&5
12456   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12457   (exit $ac_status); } >/dev/null && {
12458          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12459          test ! -s conftest.err
12460        }; then
12461   ac_header_preproc=yes
12462 else
12463   $as_echo "$as_me: failed program was:" >&5
12464 sed 's/^/| /' conftest.$ac_ext >&5
12465
12466   ac_header_preproc=no
12467 fi
12468
12469 rm -f conftest.err conftest.$ac_ext
12470 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12471 $as_echo "$ac_header_preproc" >&6; }
12472
12473 # So?  What about this header?
12474 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12475   yes:no: )
12476     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
12477 $as_echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12478     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
12479 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
12480     ac_header_preproc=yes
12481     ;;
12482   no:yes:* )
12483     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
12484 $as_echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
12485     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
12486 $as_echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
12487     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
12488 $as_echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
12489     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
12490 $as_echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12491     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
12492 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
12493     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
12494 $as_echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
12495     ( cat <<\_ASBOX
12496 ## ---------------------------------------- ##
12497 ## Report this to pgsql-bugs@postgresql.org ##
12498 ## ---------------------------------------- ##
12499 _ASBOX
12500      ) | sed "s/^/$as_me: WARNING:     /" >&2
12501     ;;
12502 esac
12503 { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12504 $as_echo_n "checking for openssl/err.h... " >&6; }
12505 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12506   $as_echo_n "(cached) " >&6
12507 else
12508   ac_cv_header_openssl_err_h=$ac_header_preproc
12509 fi
12510 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12511 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12512
12513 fi
12514 if test "x$ac_cv_header_openssl_err_h" = x""yes; then
12515   :
12516 else
12517   { { $as_echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
12518 $as_echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
12519    { (exit 1); exit 1; }; }
12520 fi
12521
12522
12523
12524 for ac_func in ERR_set_mark
12525 do
12526 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12527 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
12528 $as_echo_n "checking for $ac_func... " >&6; }
12529 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
12530   $as_echo_n "(cached) " >&6
12531 else
12532   cat >conftest.$ac_ext <<_ACEOF
12533 /* confdefs.h.  */
12534 _ACEOF
12535 cat confdefs.h >>conftest.$ac_ext
12536 cat >>conftest.$ac_ext <<_ACEOF
12537 /* end confdefs.h.  */
12538 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12539    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
12540 #define $ac_func innocuous_$ac_func
12541
12542 /* System header to define __stub macros and hopefully few prototypes,
12543     which can conflict with char $ac_func (); below.
12544     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12545     <limits.h> exists even on freestanding compilers.  */
12546
12547 #ifdef __STDC__
12548 # include <limits.h>
12549 #else
12550 # include <assert.h>
12551 #endif
12552
12553 #undef $ac_func
12554
12555 /* Override any GCC internal prototype to avoid an error.
12556    Use char because int might match the return type of a GCC
12557    builtin and then its argument prototype would still apply.  */
12558 #ifdef __cplusplus
12559 extern "C"
12560 #endif
12561 char $ac_func ();
12562 /* The GNU C library defines this for functions which it implements
12563     to always fail with ENOSYS.  Some functions are actually named
12564     something starting with __ and the normal name is an alias.  */
12565 #if defined __stub_$ac_func || defined __stub___$ac_func
12566 choke me
12567 #endif
12568
12569 int
12570 main ()
12571 {
12572 return $ac_func ();
12573   ;
12574   return 0;
12575 }
12576 _ACEOF
12577 rm -f conftest.$ac_objext conftest$ac_exeext
12578 if { (ac_try="$ac_link"
12579 case "(($ac_try" in
12580   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12581   *) ac_try_echo=$ac_try;;
12582 esac
12583 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12584 $as_echo "$ac_try_echo") >&5
12585   (eval "$ac_link") 2>conftest.er1
12586   ac_status=$?
12587   grep -v '^ *+' conftest.er1 >conftest.err
12588   rm -f conftest.er1
12589   cat conftest.err >&5
12590   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12591   (exit $ac_status); } && {
12592          test -z "$ac_c_werror_flag" ||
12593          test ! -s conftest.err
12594        } && test -s conftest$ac_exeext && {
12595          test "$cross_compiling" = yes ||
12596          $as_test_x conftest$ac_exeext
12597        }; then
12598   eval "$as_ac_var=yes"
12599 else
12600   $as_echo "$as_me: failed program was:" >&5
12601 sed 's/^/| /' conftest.$ac_ext >&5
12602
12603         eval "$as_ac_var=no"
12604 fi
12605
12606 rm -rf conftest.dSYM
12607 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12608       conftest$ac_exeext conftest.$ac_ext
12609 fi
12610 ac_res=`eval 'as_val=${'$as_ac_var'}
12611                  $as_echo "$as_val"'`
12612                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12613 $as_echo "$ac_res" >&6; }
12614 as_val=`eval 'as_val=${'$as_ac_var'}
12615                  $as_echo "$as_val"'`
12616    if test "x$as_val" = x""yes; then
12617   cat >>confdefs.h <<_ACEOF
12618 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12619 _ACEOF
12620
12621 fi
12622 done
12623
12624 fi
12625
12626 if test "$with_pam" = yes ; then
12627
12628 for ac_header in security/pam_appl.h
12629 do
12630 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12631 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12632   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12633 $as_echo_n "checking for $ac_header... " >&6; }
12634 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12635   $as_echo_n "(cached) " >&6
12636 fi
12637 ac_res=`eval 'as_val=${'$as_ac_Header'}
12638                  $as_echo "$as_val"'`
12639                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12640 $as_echo "$ac_res" >&6; }
12641 else
12642   # Is the header compilable?
12643 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12644 $as_echo_n "checking $ac_header usability... " >&6; }
12645 cat >conftest.$ac_ext <<_ACEOF
12646 /* confdefs.h.  */
12647 _ACEOF
12648 cat confdefs.h >>conftest.$ac_ext
12649 cat >>conftest.$ac_ext <<_ACEOF
12650 /* end confdefs.h.  */
12651 $ac_includes_default
12652 #include <$ac_header>
12653 _ACEOF
12654 rm -f conftest.$ac_objext
12655 if { (ac_try="$ac_compile"
12656 case "(($ac_try" in
12657   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12658   *) ac_try_echo=$ac_try;;
12659 esac
12660 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12661 $as_echo "$ac_try_echo") >&5
12662   (eval "$ac_compile") 2>conftest.er1
12663   ac_status=$?
12664   grep -v '^ *+' conftest.er1 >conftest.err
12665   rm -f conftest.er1
12666   cat conftest.err >&5
12667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12668   (exit $ac_status); } && {
12669          test -z "$ac_c_werror_flag" ||
12670          test ! -s conftest.err
12671        } && test -s conftest.$ac_objext; then
12672   ac_header_compiler=yes
12673 else
12674   $as_echo "$as_me: failed program was:" >&5
12675 sed 's/^/| /' conftest.$ac_ext >&5
12676
12677         ac_header_compiler=no
12678 fi
12679
12680 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12681 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12682 $as_echo "$ac_header_compiler" >&6; }
12683
12684 # Is the header present?
12685 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12686 $as_echo_n "checking $ac_header presence... " >&6; }
12687 cat >conftest.$ac_ext <<_ACEOF
12688 /* confdefs.h.  */
12689 _ACEOF
12690 cat confdefs.h >>conftest.$ac_ext
12691 cat >>conftest.$ac_ext <<_ACEOF
12692 /* end confdefs.h.  */
12693 #include <$ac_header>
12694 _ACEOF
12695 if { (ac_try="$ac_cpp conftest.$ac_ext"
12696 case "(($ac_try" in
12697   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12698   *) ac_try_echo=$ac_try;;
12699 esac
12700 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12701 $as_echo "$ac_try_echo") >&5
12702   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12703   ac_status=$?
12704   grep -v '^ *+' conftest.er1 >conftest.err
12705   rm -f conftest.er1
12706   cat conftest.err >&5
12707   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12708   (exit $ac_status); } >/dev/null && {
12709          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12710          test ! -s conftest.err
12711        }; then
12712   ac_header_preproc=yes
12713 else
12714   $as_echo "$as_me: failed program was:" >&5
12715 sed 's/^/| /' conftest.$ac_ext >&5
12716
12717   ac_header_preproc=no
12718 fi
12719
12720 rm -f conftest.err conftest.$ac_ext
12721 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12722 $as_echo "$ac_header_preproc" >&6; }
12723
12724 # So?  What about this header?
12725 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12726   yes:no: )
12727     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12728 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12729     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12730 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12731     ac_header_preproc=yes
12732     ;;
12733   no:yes:* )
12734     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12735 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12736     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12737 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12738     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12739 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12740     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12741 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12742     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12743 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12744     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12745 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12746     ( cat <<\_ASBOX
12747 ## ---------------------------------------- ##
12748 ## Report this to pgsql-bugs@postgresql.org ##
12749 ## ---------------------------------------- ##
12750 _ASBOX
12751      ) | sed "s/^/$as_me: WARNING:     /" >&2
12752     ;;
12753 esac
12754 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12755 $as_echo_n "checking for $ac_header... " >&6; }
12756 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12757   $as_echo_n "(cached) " >&6
12758 else
12759   eval "$as_ac_Header=\$ac_header_preproc"
12760 fi
12761 ac_res=`eval 'as_val=${'$as_ac_Header'}
12762                  $as_echo "$as_val"'`
12763                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12764 $as_echo "$ac_res" >&6; }
12765
12766 fi
12767 as_val=`eval 'as_val=${'$as_ac_Header'}
12768                  $as_echo "$as_val"'`
12769    if test "x$as_val" = x""yes; then
12770   cat >>confdefs.h <<_ACEOF
12771 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12772 _ACEOF
12773
12774 else
12775
12776 for ac_header in pam/pam_appl.h
12777 do
12778 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12779 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12780   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12781 $as_echo_n "checking for $ac_header... " >&6; }
12782 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12783   $as_echo_n "(cached) " >&6
12784 fi
12785 ac_res=`eval 'as_val=${'$as_ac_Header'}
12786                  $as_echo "$as_val"'`
12787                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12788 $as_echo "$ac_res" >&6; }
12789 else
12790   # Is the header compilable?
12791 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12792 $as_echo_n "checking $ac_header usability... " >&6; }
12793 cat >conftest.$ac_ext <<_ACEOF
12794 /* confdefs.h.  */
12795 _ACEOF
12796 cat confdefs.h >>conftest.$ac_ext
12797 cat >>conftest.$ac_ext <<_ACEOF
12798 /* end confdefs.h.  */
12799 $ac_includes_default
12800 #include <$ac_header>
12801 _ACEOF
12802 rm -f conftest.$ac_objext
12803 if { (ac_try="$ac_compile"
12804 case "(($ac_try" in
12805   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12806   *) ac_try_echo=$ac_try;;
12807 esac
12808 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12809 $as_echo "$ac_try_echo") >&5
12810   (eval "$ac_compile") 2>conftest.er1
12811   ac_status=$?
12812   grep -v '^ *+' conftest.er1 >conftest.err
12813   rm -f conftest.er1
12814   cat conftest.err >&5
12815   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12816   (exit $ac_status); } && {
12817          test -z "$ac_c_werror_flag" ||
12818          test ! -s conftest.err
12819        } && test -s conftest.$ac_objext; then
12820   ac_header_compiler=yes
12821 else
12822   $as_echo "$as_me: failed program was:" >&5
12823 sed 's/^/| /' conftest.$ac_ext >&5
12824
12825         ac_header_compiler=no
12826 fi
12827
12828 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12829 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12830 $as_echo "$ac_header_compiler" >&6; }
12831
12832 # Is the header present?
12833 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12834 $as_echo_n "checking $ac_header presence... " >&6; }
12835 cat >conftest.$ac_ext <<_ACEOF
12836 /* confdefs.h.  */
12837 _ACEOF
12838 cat confdefs.h >>conftest.$ac_ext
12839 cat >>conftest.$ac_ext <<_ACEOF
12840 /* end confdefs.h.  */
12841 #include <$ac_header>
12842 _ACEOF
12843 if { (ac_try="$ac_cpp conftest.$ac_ext"
12844 case "(($ac_try" in
12845   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12846   *) ac_try_echo=$ac_try;;
12847 esac
12848 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12849 $as_echo "$ac_try_echo") >&5
12850   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12851   ac_status=$?
12852   grep -v '^ *+' conftest.er1 >conftest.err
12853   rm -f conftest.er1
12854   cat conftest.err >&5
12855   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12856   (exit $ac_status); } >/dev/null && {
12857          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12858          test ! -s conftest.err
12859        }; then
12860   ac_header_preproc=yes
12861 else
12862   $as_echo "$as_me: failed program was:" >&5
12863 sed 's/^/| /' conftest.$ac_ext >&5
12864
12865   ac_header_preproc=no
12866 fi
12867
12868 rm -f conftest.err conftest.$ac_ext
12869 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12870 $as_echo "$ac_header_preproc" >&6; }
12871
12872 # So?  What about this header?
12873 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12874   yes:no: )
12875     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12876 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12877     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12878 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12879     ac_header_preproc=yes
12880     ;;
12881   no:yes:* )
12882     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12883 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12884     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12885 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12886     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12887 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12888     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12889 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12890     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12891 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12892     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12893 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12894     ( cat <<\_ASBOX
12895 ## ---------------------------------------- ##
12896 ## Report this to pgsql-bugs@postgresql.org ##
12897 ## ---------------------------------------- ##
12898 _ASBOX
12899      ) | sed "s/^/$as_me: WARNING:     /" >&2
12900     ;;
12901 esac
12902 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12903 $as_echo_n "checking for $ac_header... " >&6; }
12904 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12905   $as_echo_n "(cached) " >&6
12906 else
12907   eval "$as_ac_Header=\$ac_header_preproc"
12908 fi
12909 ac_res=`eval 'as_val=${'$as_ac_Header'}
12910                  $as_echo "$as_val"'`
12911                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12912 $as_echo "$ac_res" >&6; }
12913
12914 fi
12915 as_val=`eval 'as_val=${'$as_ac_Header'}
12916                  $as_echo "$as_val"'`
12917    if test "x$as_val" = x""yes; then
12918   cat >>confdefs.h <<_ACEOF
12919 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12920 _ACEOF
12921
12922 else
12923   { { $as_echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
12924 $as_echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
12925    { (exit 1); exit 1; }; }
12926 fi
12927
12928 done
12929
12930 fi
12931
12932 done
12933
12934 fi
12935
12936 if test "$with_libxml" = yes ; then
12937   if test "${ac_cv_header_libxml_parser_h+set}" = set; then
12938   { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
12939 $as_echo_n "checking for libxml/parser.h... " >&6; }
12940 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
12941   $as_echo_n "(cached) " >&6
12942 fi
12943 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
12944 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
12945 else
12946   # Is the header compilable?
12947 { $as_echo "$as_me:$LINENO: checking libxml/parser.h usability" >&5
12948 $as_echo_n "checking libxml/parser.h usability... " >&6; }
12949 cat >conftest.$ac_ext <<_ACEOF
12950 /* confdefs.h.  */
12951 _ACEOF
12952 cat confdefs.h >>conftest.$ac_ext
12953 cat >>conftest.$ac_ext <<_ACEOF
12954 /* end confdefs.h.  */
12955 $ac_includes_default
12956 #include <libxml/parser.h>
12957 _ACEOF
12958 rm -f conftest.$ac_objext
12959 if { (ac_try="$ac_compile"
12960 case "(($ac_try" in
12961   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12962   *) ac_try_echo=$ac_try;;
12963 esac
12964 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12965 $as_echo "$ac_try_echo") >&5
12966   (eval "$ac_compile") 2>conftest.er1
12967   ac_status=$?
12968   grep -v '^ *+' conftest.er1 >conftest.err
12969   rm -f conftest.er1
12970   cat conftest.err >&5
12971   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12972   (exit $ac_status); } && {
12973          test -z "$ac_c_werror_flag" ||
12974          test ! -s conftest.err
12975        } && test -s conftest.$ac_objext; then
12976   ac_header_compiler=yes
12977 else
12978   $as_echo "$as_me: failed program was:" >&5
12979 sed 's/^/| /' conftest.$ac_ext >&5
12980
12981         ac_header_compiler=no
12982 fi
12983
12984 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12985 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12986 $as_echo "$ac_header_compiler" >&6; }
12987
12988 # Is the header present?
12989 { $as_echo "$as_me:$LINENO: checking libxml/parser.h presence" >&5
12990 $as_echo_n "checking libxml/parser.h presence... " >&6; }
12991 cat >conftest.$ac_ext <<_ACEOF
12992 /* confdefs.h.  */
12993 _ACEOF
12994 cat confdefs.h >>conftest.$ac_ext
12995 cat >>conftest.$ac_ext <<_ACEOF
12996 /* end confdefs.h.  */
12997 #include <libxml/parser.h>
12998 _ACEOF
12999 if { (ac_try="$ac_cpp conftest.$ac_ext"
13000 case "(($ac_try" in
13001   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13002   *) ac_try_echo=$ac_try;;
13003 esac
13004 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13005 $as_echo "$ac_try_echo") >&5
13006   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13007   ac_status=$?
13008   grep -v '^ *+' conftest.er1 >conftest.err
13009   rm -f conftest.er1
13010   cat conftest.err >&5
13011   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13012   (exit $ac_status); } >/dev/null && {
13013          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13014          test ! -s conftest.err
13015        }; then
13016   ac_header_preproc=yes
13017 else
13018   $as_echo "$as_me: failed program was:" >&5
13019 sed 's/^/| /' conftest.$ac_ext >&5
13020
13021   ac_header_preproc=no
13022 fi
13023
13024 rm -f conftest.err conftest.$ac_ext
13025 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13026 $as_echo "$ac_header_preproc" >&6; }
13027
13028 # So?  What about this header?
13029 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13030   yes:no: )
13031     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&5
13032 $as_echo "$as_me: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13033     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the compiler's result" >&5
13034 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the compiler's result" >&2;}
13035     ac_header_preproc=yes
13036     ;;
13037   no:yes:* )
13038     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: present but cannot be compiled" >&5
13039 $as_echo "$as_me: WARNING: libxml/parser.h: present but cannot be compiled" >&2;}
13040     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&5
13041 $as_echo "$as_me: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&2;}
13042     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: see the Autoconf documentation" >&5
13043 $as_echo "$as_me: WARNING: libxml/parser.h: see the Autoconf documentation" >&2;}
13044     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&5
13045 $as_echo "$as_me: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13046     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&5
13047 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&2;}
13048     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&5
13049 $as_echo "$as_me: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&2;}
13050     ( cat <<\_ASBOX
13051 ## ---------------------------------------- ##
13052 ## Report this to pgsql-bugs@postgresql.org ##
13053 ## ---------------------------------------- ##
13054 _ASBOX
13055      ) | sed "s/^/$as_me: WARNING:     /" >&2
13056     ;;
13057 esac
13058 { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13059 $as_echo_n "checking for libxml/parser.h... " >&6; }
13060 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13061   $as_echo_n "(cached) " >&6
13062 else
13063   ac_cv_header_libxml_parser_h=$ac_header_preproc
13064 fi
13065 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13066 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13067
13068 fi
13069 if test "x$ac_cv_header_libxml_parser_h" = x""yes; then
13070   :
13071 else
13072   { { $as_echo "$as_me:$LINENO: error: header file <libxml/parser.h> is required for XML support" >&5
13073 $as_echo "$as_me: error: header file <libxml/parser.h> is required for XML support" >&2;}
13074    { (exit 1); exit 1; }; }
13075 fi
13076
13077
13078 fi
13079
13080 if test "$with_libxslt" = yes ; then
13081   if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13082   { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13083 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13084 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13085   $as_echo_n "(cached) " >&6
13086 fi
13087 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13088 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13089 else
13090   # Is the header compilable?
13091 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h usability" >&5
13092 $as_echo_n "checking libxslt/xslt.h usability... " >&6; }
13093 cat >conftest.$ac_ext <<_ACEOF
13094 /* confdefs.h.  */
13095 _ACEOF
13096 cat confdefs.h >>conftest.$ac_ext
13097 cat >>conftest.$ac_ext <<_ACEOF
13098 /* end confdefs.h.  */
13099 $ac_includes_default
13100 #include <libxslt/xslt.h>
13101 _ACEOF
13102 rm -f conftest.$ac_objext
13103 if { (ac_try="$ac_compile"
13104 case "(($ac_try" in
13105   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13106   *) ac_try_echo=$ac_try;;
13107 esac
13108 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13109 $as_echo "$ac_try_echo") >&5
13110   (eval "$ac_compile") 2>conftest.er1
13111   ac_status=$?
13112   grep -v '^ *+' conftest.er1 >conftest.err
13113   rm -f conftest.er1
13114   cat conftest.err >&5
13115   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13116   (exit $ac_status); } && {
13117          test -z "$ac_c_werror_flag" ||
13118          test ! -s conftest.err
13119        } && test -s conftest.$ac_objext; then
13120   ac_header_compiler=yes
13121 else
13122   $as_echo "$as_me: failed program was:" >&5
13123 sed 's/^/| /' conftest.$ac_ext >&5
13124
13125         ac_header_compiler=no
13126 fi
13127
13128 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13129 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13130 $as_echo "$ac_header_compiler" >&6; }
13131
13132 # Is the header present?
13133 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h presence" >&5
13134 $as_echo_n "checking libxslt/xslt.h presence... " >&6; }
13135 cat >conftest.$ac_ext <<_ACEOF
13136 /* confdefs.h.  */
13137 _ACEOF
13138 cat confdefs.h >>conftest.$ac_ext
13139 cat >>conftest.$ac_ext <<_ACEOF
13140 /* end confdefs.h.  */
13141 #include <libxslt/xslt.h>
13142 _ACEOF
13143 if { (ac_try="$ac_cpp conftest.$ac_ext"
13144 case "(($ac_try" in
13145   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13146   *) ac_try_echo=$ac_try;;
13147 esac
13148 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13149 $as_echo "$ac_try_echo") >&5
13150   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13151   ac_status=$?
13152   grep -v '^ *+' conftest.er1 >conftest.err
13153   rm -f conftest.er1
13154   cat conftest.err >&5
13155   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13156   (exit $ac_status); } >/dev/null && {
13157          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13158          test ! -s conftest.err
13159        }; then
13160   ac_header_preproc=yes
13161 else
13162   $as_echo "$as_me: failed program was:" >&5
13163 sed 's/^/| /' conftest.$ac_ext >&5
13164
13165   ac_header_preproc=no
13166 fi
13167
13168 rm -f conftest.err conftest.$ac_ext
13169 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13170 $as_echo "$ac_header_preproc" >&6; }
13171
13172 # So?  What about this header?
13173 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13174   yes:no: )
13175     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&5
13176 $as_echo "$as_me: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13177     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&5
13178 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&2;}
13179     ac_header_preproc=yes
13180     ;;
13181   no:yes:* )
13182     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: present but cannot be compiled" >&5
13183 $as_echo "$as_me: WARNING: libxslt/xslt.h: present but cannot be compiled" >&2;}
13184     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&5
13185 $as_echo "$as_me: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&2;}
13186     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&5
13187 $as_echo "$as_me: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&2;}
13188     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&5
13189 $as_echo "$as_me: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13190     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&5
13191 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&2;}
13192     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&5
13193 $as_echo "$as_me: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&2;}
13194     ( cat <<\_ASBOX
13195 ## ---------------------------------------- ##
13196 ## Report this to pgsql-bugs@postgresql.org ##
13197 ## ---------------------------------------- ##
13198 _ASBOX
13199      ) | sed "s/^/$as_me: WARNING:     /" >&2
13200     ;;
13201 esac
13202 { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13203 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13204 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13205   $as_echo_n "(cached) " >&6
13206 else
13207   ac_cv_header_libxslt_xslt_h=$ac_header_preproc
13208 fi
13209 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13210 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13211
13212 fi
13213 if test "x$ac_cv_header_libxslt_xslt_h" = x""yes; then
13214   :
13215 else
13216   { { $as_echo "$as_me:$LINENO: error: header file <libxslt/xslt.h> is required for XSLT support" >&5
13217 $as_echo "$as_me: error: header file <libxslt/xslt.h> is required for XSLT support" >&2;}
13218    { (exit 1); exit 1; }; }
13219 fi
13220
13221
13222 fi
13223
13224 if test "$with_ldap" = yes ; then
13225   if test "$PORTNAME" != "win32"; then
13226
13227 for ac_header in ldap.h
13228 do
13229 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13230 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13231   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13232 $as_echo_n "checking for $ac_header... " >&6; }
13233 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13234   $as_echo_n "(cached) " >&6
13235 fi
13236 ac_res=`eval 'as_val=${'$as_ac_Header'}
13237                  $as_echo "$as_val"'`
13238                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13239 $as_echo "$ac_res" >&6; }
13240 else
13241   # Is the header compilable?
13242 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13243 $as_echo_n "checking $ac_header usability... " >&6; }
13244 cat >conftest.$ac_ext <<_ACEOF
13245 /* confdefs.h.  */
13246 _ACEOF
13247 cat confdefs.h >>conftest.$ac_ext
13248 cat >>conftest.$ac_ext <<_ACEOF
13249 /* end confdefs.h.  */
13250 $ac_includes_default
13251 #include <$ac_header>
13252 _ACEOF
13253 rm -f conftest.$ac_objext
13254 if { (ac_try="$ac_compile"
13255 case "(($ac_try" in
13256   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13257   *) ac_try_echo=$ac_try;;
13258 esac
13259 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13260 $as_echo "$ac_try_echo") >&5
13261   (eval "$ac_compile") 2>conftest.er1
13262   ac_status=$?
13263   grep -v '^ *+' conftest.er1 >conftest.err
13264   rm -f conftest.er1
13265   cat conftest.err >&5
13266   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13267   (exit $ac_status); } && {
13268          test -z "$ac_c_werror_flag" ||
13269          test ! -s conftest.err
13270        } && test -s conftest.$ac_objext; then
13271   ac_header_compiler=yes
13272 else
13273   $as_echo "$as_me: failed program was:" >&5
13274 sed 's/^/| /' conftest.$ac_ext >&5
13275
13276         ac_header_compiler=no
13277 fi
13278
13279 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13280 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13281 $as_echo "$ac_header_compiler" >&6; }
13282
13283 # Is the header present?
13284 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13285 $as_echo_n "checking $ac_header presence... " >&6; }
13286 cat >conftest.$ac_ext <<_ACEOF
13287 /* confdefs.h.  */
13288 _ACEOF
13289 cat confdefs.h >>conftest.$ac_ext
13290 cat >>conftest.$ac_ext <<_ACEOF
13291 /* end confdefs.h.  */
13292 #include <$ac_header>
13293 _ACEOF
13294 if { (ac_try="$ac_cpp conftest.$ac_ext"
13295 case "(($ac_try" in
13296   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13297   *) ac_try_echo=$ac_try;;
13298 esac
13299 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13300 $as_echo "$ac_try_echo") >&5
13301   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13302   ac_status=$?
13303   grep -v '^ *+' conftest.er1 >conftest.err
13304   rm -f conftest.er1
13305   cat conftest.err >&5
13306   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13307   (exit $ac_status); } >/dev/null && {
13308          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13309          test ! -s conftest.err
13310        }; then
13311   ac_header_preproc=yes
13312 else
13313   $as_echo "$as_me: failed program was:" >&5
13314 sed 's/^/| /' conftest.$ac_ext >&5
13315
13316   ac_header_preproc=no
13317 fi
13318
13319 rm -f conftest.err conftest.$ac_ext
13320 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13321 $as_echo "$ac_header_preproc" >&6; }
13322
13323 # So?  What about this header?
13324 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13325   yes:no: )
13326     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13327 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13328     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13329 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13330     ac_header_preproc=yes
13331     ;;
13332   no:yes:* )
13333     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13334 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13335     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13336 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13337     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13338 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13339     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13340 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13341     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13342 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13343     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13344 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13345     ( cat <<\_ASBOX
13346 ## ---------------------------------------- ##
13347 ## Report this to pgsql-bugs@postgresql.org ##
13348 ## ---------------------------------------- ##
13349 _ASBOX
13350      ) | sed "s/^/$as_me: WARNING:     /" >&2
13351     ;;
13352 esac
13353 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13354 $as_echo_n "checking for $ac_header... " >&6; }
13355 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13356   $as_echo_n "(cached) " >&6
13357 else
13358   eval "$as_ac_Header=\$ac_header_preproc"
13359 fi
13360 ac_res=`eval 'as_val=${'$as_ac_Header'}
13361                  $as_echo "$as_val"'`
13362                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13363 $as_echo "$ac_res" >&6; }
13364
13365 fi
13366 as_val=`eval 'as_val=${'$as_ac_Header'}
13367                  $as_echo "$as_val"'`
13368    if test "x$as_val" = x""yes; then
13369   cat >>confdefs.h <<_ACEOF
13370 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13371 _ACEOF
13372
13373 else
13374   { { $as_echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
13375 $as_echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
13376    { (exit 1); exit 1; }; }
13377 fi
13378
13379 done
13380
13381   else
13382
13383 for ac_header in winldap.h
13384 do
13385 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13386 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13387 $as_echo_n "checking for $ac_header... " >&6; }
13388 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13389   $as_echo_n "(cached) " >&6
13390 else
13391   cat >conftest.$ac_ext <<_ACEOF
13392 /* confdefs.h.  */
13393 _ACEOF
13394 cat confdefs.h >>conftest.$ac_ext
13395 cat >>conftest.$ac_ext <<_ACEOF
13396 /* end confdefs.h.  */
13397 $ac_includes_default
13398 #include <windows.h>
13399
13400
13401 #include <$ac_header>
13402 _ACEOF
13403 rm -f conftest.$ac_objext
13404 if { (ac_try="$ac_compile"
13405 case "(($ac_try" in
13406   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13407   *) ac_try_echo=$ac_try;;
13408 esac
13409 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13410 $as_echo "$ac_try_echo") >&5
13411   (eval "$ac_compile") 2>conftest.er1
13412   ac_status=$?
13413   grep -v '^ *+' conftest.er1 >conftest.err
13414   rm -f conftest.er1
13415   cat conftest.err >&5
13416   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13417   (exit $ac_status); } && {
13418          test -z "$ac_c_werror_flag" ||
13419          test ! -s conftest.err
13420        } && test -s conftest.$ac_objext; then
13421   eval "$as_ac_Header=yes"
13422 else
13423   $as_echo "$as_me: failed program was:" >&5
13424 sed 's/^/| /' conftest.$ac_ext >&5
13425
13426         eval "$as_ac_Header=no"
13427 fi
13428
13429 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13430 fi
13431 ac_res=`eval 'as_val=${'$as_ac_Header'}
13432                  $as_echo "$as_val"'`
13433                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13434 $as_echo "$ac_res" >&6; }
13435 as_val=`eval 'as_val=${'$as_ac_Header'}
13436                  $as_echo "$as_val"'`
13437    if test "x$as_val" = x""yes; then
13438   cat >>confdefs.h <<_ACEOF
13439 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13440 _ACEOF
13441
13442 else
13443   { { $as_echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
13444 $as_echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
13445    { (exit 1); exit 1; }; }
13446 fi
13447
13448 done
13449
13450   fi
13451 fi
13452
13453 if test "$with_bonjour" = yes ; then
13454   if test "${ac_cv_header_dns_sd_h+set}" = set; then
13455   { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13456 $as_echo_n "checking for dns_sd.h... " >&6; }
13457 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13458   $as_echo_n "(cached) " >&6
13459 fi
13460 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13461 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13462 else
13463   # Is the header compilable?
13464 { $as_echo "$as_me:$LINENO: checking dns_sd.h usability" >&5
13465 $as_echo_n "checking dns_sd.h usability... " >&6; }
13466 cat >conftest.$ac_ext <<_ACEOF
13467 /* confdefs.h.  */
13468 _ACEOF
13469 cat confdefs.h >>conftest.$ac_ext
13470 cat >>conftest.$ac_ext <<_ACEOF
13471 /* end confdefs.h.  */
13472 $ac_includes_default
13473 #include <dns_sd.h>
13474 _ACEOF
13475 rm -f conftest.$ac_objext
13476 if { (ac_try="$ac_compile"
13477 case "(($ac_try" in
13478   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13479   *) ac_try_echo=$ac_try;;
13480 esac
13481 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13482 $as_echo "$ac_try_echo") >&5
13483   (eval "$ac_compile") 2>conftest.er1
13484   ac_status=$?
13485   grep -v '^ *+' conftest.er1 >conftest.err
13486   rm -f conftest.er1
13487   cat conftest.err >&5
13488   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13489   (exit $ac_status); } && {
13490          test -z "$ac_c_werror_flag" ||
13491          test ! -s conftest.err
13492        } && test -s conftest.$ac_objext; then
13493   ac_header_compiler=yes
13494 else
13495   $as_echo "$as_me: failed program was:" >&5
13496 sed 's/^/| /' conftest.$ac_ext >&5
13497
13498         ac_header_compiler=no
13499 fi
13500
13501 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13502 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13503 $as_echo "$ac_header_compiler" >&6; }
13504
13505 # Is the header present?
13506 { $as_echo "$as_me:$LINENO: checking dns_sd.h presence" >&5
13507 $as_echo_n "checking dns_sd.h presence... " >&6; }
13508 cat >conftest.$ac_ext <<_ACEOF
13509 /* confdefs.h.  */
13510 _ACEOF
13511 cat confdefs.h >>conftest.$ac_ext
13512 cat >>conftest.$ac_ext <<_ACEOF
13513 /* end confdefs.h.  */
13514 #include <dns_sd.h>
13515 _ACEOF
13516 if { (ac_try="$ac_cpp conftest.$ac_ext"
13517 case "(($ac_try" in
13518   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13519   *) ac_try_echo=$ac_try;;
13520 esac
13521 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13522 $as_echo "$ac_try_echo") >&5
13523   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13524   ac_status=$?
13525   grep -v '^ *+' conftest.er1 >conftest.err
13526   rm -f conftest.er1
13527   cat conftest.err >&5
13528   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13529   (exit $ac_status); } >/dev/null && {
13530          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13531          test ! -s conftest.err
13532        }; then
13533   ac_header_preproc=yes
13534 else
13535   $as_echo "$as_me: failed program was:" >&5
13536 sed 's/^/| /' conftest.$ac_ext >&5
13537
13538   ac_header_preproc=no
13539 fi
13540
13541 rm -f conftest.err conftest.$ac_ext
13542 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13543 $as_echo "$ac_header_preproc" >&6; }
13544
13545 # So?  What about this header?
13546 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13547   yes:no: )
13548     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&5
13549 $as_echo "$as_me: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13550     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the compiler's result" >&5
13551 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the compiler's result" >&2;}
13552     ac_header_preproc=yes
13553     ;;
13554   no:yes:* )
13555     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: present but cannot be compiled" >&5
13556 $as_echo "$as_me: WARNING: dns_sd.h: present but cannot be compiled" >&2;}
13557     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&5
13558 $as_echo "$as_me: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&2;}
13559     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: see the Autoconf documentation" >&5
13560 $as_echo "$as_me: WARNING: dns_sd.h: see the Autoconf documentation" >&2;}
13561     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&5
13562 $as_echo "$as_me: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13563     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&5
13564 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&2;}
13565     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&5
13566 $as_echo "$as_me: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&2;}
13567     ( cat <<\_ASBOX
13568 ## ---------------------------------------- ##
13569 ## Report this to pgsql-bugs@postgresql.org ##
13570 ## ---------------------------------------- ##
13571 _ASBOX
13572      ) | sed "s/^/$as_me: WARNING:     /" >&2
13573     ;;
13574 esac
13575 { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13576 $as_echo_n "checking for dns_sd.h... " >&6; }
13577 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13578   $as_echo_n "(cached) " >&6
13579 else
13580   ac_cv_header_dns_sd_h=$ac_header_preproc
13581 fi
13582 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13583 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13584
13585 fi
13586 if test "x$ac_cv_header_dns_sd_h" = x""yes; then
13587   :
13588 else
13589   { { $as_echo "$as_me:$LINENO: error: header file <dns_sd.h> is required for Bonjour" >&5
13590 $as_echo "$as_me: error: header file <dns_sd.h> is required for Bonjour" >&2;}
13591    { (exit 1); exit 1; }; }
13592 fi
13593
13594
13595 fi
13596
13597 # for contrib/uuid-ossp
13598 if test "$with_ossp_uuid" = yes ; then
13599
13600 for ac_header in ossp/uuid.h
13601 do
13602 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13603 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13604   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13605 $as_echo_n "checking for $ac_header... " >&6; }
13606 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13607   $as_echo_n "(cached) " >&6
13608 fi
13609 ac_res=`eval 'as_val=${'$as_ac_Header'}
13610                  $as_echo "$as_val"'`
13611                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13612 $as_echo "$ac_res" >&6; }
13613 else
13614   # Is the header compilable?
13615 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13616 $as_echo_n "checking $ac_header usability... " >&6; }
13617 cat >conftest.$ac_ext <<_ACEOF
13618 /* confdefs.h.  */
13619 _ACEOF
13620 cat confdefs.h >>conftest.$ac_ext
13621 cat >>conftest.$ac_ext <<_ACEOF
13622 /* end confdefs.h.  */
13623 $ac_includes_default
13624 #include <$ac_header>
13625 _ACEOF
13626 rm -f conftest.$ac_objext
13627 if { (ac_try="$ac_compile"
13628 case "(($ac_try" in
13629   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13630   *) ac_try_echo=$ac_try;;
13631 esac
13632 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13633 $as_echo "$ac_try_echo") >&5
13634   (eval "$ac_compile") 2>conftest.er1
13635   ac_status=$?
13636   grep -v '^ *+' conftest.er1 >conftest.err
13637   rm -f conftest.er1
13638   cat conftest.err >&5
13639   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13640   (exit $ac_status); } && {
13641          test -z "$ac_c_werror_flag" ||
13642          test ! -s conftest.err
13643        } && test -s conftest.$ac_objext; then
13644   ac_header_compiler=yes
13645 else
13646   $as_echo "$as_me: failed program was:" >&5
13647 sed 's/^/| /' conftest.$ac_ext >&5
13648
13649         ac_header_compiler=no
13650 fi
13651
13652 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13653 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13654 $as_echo "$ac_header_compiler" >&6; }
13655
13656 # Is the header present?
13657 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13658 $as_echo_n "checking $ac_header presence... " >&6; }
13659 cat >conftest.$ac_ext <<_ACEOF
13660 /* confdefs.h.  */
13661 _ACEOF
13662 cat confdefs.h >>conftest.$ac_ext
13663 cat >>conftest.$ac_ext <<_ACEOF
13664 /* end confdefs.h.  */
13665 #include <$ac_header>
13666 _ACEOF
13667 if { (ac_try="$ac_cpp conftest.$ac_ext"
13668 case "(($ac_try" in
13669   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13670   *) ac_try_echo=$ac_try;;
13671 esac
13672 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13673 $as_echo "$ac_try_echo") >&5
13674   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13675   ac_status=$?
13676   grep -v '^ *+' conftest.er1 >conftest.err
13677   rm -f conftest.er1
13678   cat conftest.err >&5
13679   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13680   (exit $ac_status); } >/dev/null && {
13681          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13682          test ! -s conftest.err
13683        }; then
13684   ac_header_preproc=yes
13685 else
13686   $as_echo "$as_me: failed program was:" >&5
13687 sed 's/^/| /' conftest.$ac_ext >&5
13688
13689   ac_header_preproc=no
13690 fi
13691
13692 rm -f conftest.err conftest.$ac_ext
13693 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13694 $as_echo "$ac_header_preproc" >&6; }
13695
13696 # So?  What about this header?
13697 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13698   yes:no: )
13699     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13700 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13701     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13702 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13703     ac_header_preproc=yes
13704     ;;
13705   no:yes:* )
13706     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13707 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13708     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13709 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13710     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13711 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13712     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13713 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13714     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13715 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13716     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13717 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13718     ( cat <<\_ASBOX
13719 ## ---------------------------------------- ##
13720 ## Report this to pgsql-bugs@postgresql.org ##
13721 ## ---------------------------------------- ##
13722 _ASBOX
13723      ) | sed "s/^/$as_me: WARNING:     /" >&2
13724     ;;
13725 esac
13726 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13727 $as_echo_n "checking for $ac_header... " >&6; }
13728 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13729   $as_echo_n "(cached) " >&6
13730 else
13731   eval "$as_ac_Header=\$ac_header_preproc"
13732 fi
13733 ac_res=`eval 'as_val=${'$as_ac_Header'}
13734                  $as_echo "$as_val"'`
13735                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13736 $as_echo "$ac_res" >&6; }
13737
13738 fi
13739 as_val=`eval 'as_val=${'$as_ac_Header'}
13740                  $as_echo "$as_val"'`
13741    if test "x$as_val" = x""yes; then
13742   cat >>confdefs.h <<_ACEOF
13743 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13744 _ACEOF
13745
13746 else
13747
13748
13749 for ac_header in uuid.h
13750 do
13751 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13752 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13753   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13754 $as_echo_n "checking for $ac_header... " >&6; }
13755 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13756   $as_echo_n "(cached) " >&6
13757 fi
13758 ac_res=`eval 'as_val=${'$as_ac_Header'}
13759                  $as_echo "$as_val"'`
13760                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13761 $as_echo "$ac_res" >&6; }
13762 else
13763   # Is the header compilable?
13764 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13765 $as_echo_n "checking $ac_header usability... " >&6; }
13766 cat >conftest.$ac_ext <<_ACEOF
13767 /* confdefs.h.  */
13768 _ACEOF
13769 cat confdefs.h >>conftest.$ac_ext
13770 cat >>conftest.$ac_ext <<_ACEOF
13771 /* end confdefs.h.  */
13772 $ac_includes_default
13773 #include <$ac_header>
13774 _ACEOF
13775 rm -f conftest.$ac_objext
13776 if { (ac_try="$ac_compile"
13777 case "(($ac_try" in
13778   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13779   *) ac_try_echo=$ac_try;;
13780 esac
13781 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13782 $as_echo "$ac_try_echo") >&5
13783   (eval "$ac_compile") 2>conftest.er1
13784   ac_status=$?
13785   grep -v '^ *+' conftest.er1 >conftest.err
13786   rm -f conftest.er1
13787   cat conftest.err >&5
13788   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13789   (exit $ac_status); } && {
13790          test -z "$ac_c_werror_flag" ||
13791          test ! -s conftest.err
13792        } && test -s conftest.$ac_objext; then
13793   ac_header_compiler=yes
13794 else
13795   $as_echo "$as_me: failed program was:" >&5
13796 sed 's/^/| /' conftest.$ac_ext >&5
13797
13798         ac_header_compiler=no
13799 fi
13800
13801 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13802 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13803 $as_echo "$ac_header_compiler" >&6; }
13804
13805 # Is the header present?
13806 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13807 $as_echo_n "checking $ac_header presence... " >&6; }
13808 cat >conftest.$ac_ext <<_ACEOF
13809 /* confdefs.h.  */
13810 _ACEOF
13811 cat confdefs.h >>conftest.$ac_ext
13812 cat >>conftest.$ac_ext <<_ACEOF
13813 /* end confdefs.h.  */
13814 #include <$ac_header>
13815 _ACEOF
13816 if { (ac_try="$ac_cpp conftest.$ac_ext"
13817 case "(($ac_try" in
13818   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13819   *) ac_try_echo=$ac_try;;
13820 esac
13821 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13822 $as_echo "$ac_try_echo") >&5
13823   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13824   ac_status=$?
13825   grep -v '^ *+' conftest.er1 >conftest.err
13826   rm -f conftest.er1
13827   cat conftest.err >&5
13828   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13829   (exit $ac_status); } >/dev/null && {
13830          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13831          test ! -s conftest.err
13832        }; then
13833   ac_header_preproc=yes
13834 else
13835   $as_echo "$as_me: failed program was:" >&5
13836 sed 's/^/| /' conftest.$ac_ext >&5
13837
13838   ac_header_preproc=no
13839 fi
13840
13841 rm -f conftest.err conftest.$ac_ext
13842 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13843 $as_echo "$ac_header_preproc" >&6; }
13844
13845 # So?  What about this header?
13846 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13847   yes:no: )
13848     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13849 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13850     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13851 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13852     ac_header_preproc=yes
13853     ;;
13854   no:yes:* )
13855     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13856 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13857     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13858 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13859     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13860 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13861     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13862 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13863     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13864 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13865     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13866 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13867     ( cat <<\_ASBOX
13868 ## ---------------------------------------- ##
13869 ## Report this to pgsql-bugs@postgresql.org ##
13870 ## ---------------------------------------- ##
13871 _ASBOX
13872      ) | sed "s/^/$as_me: WARNING:     /" >&2
13873     ;;
13874 esac
13875 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13876 $as_echo_n "checking for $ac_header... " >&6; }
13877 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13878   $as_echo_n "(cached) " >&6
13879 else
13880   eval "$as_ac_Header=\$ac_header_preproc"
13881 fi
13882 ac_res=`eval 'as_val=${'$as_ac_Header'}
13883                  $as_echo "$as_val"'`
13884                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13885 $as_echo "$ac_res" >&6; }
13886
13887 fi
13888 as_val=`eval 'as_val=${'$as_ac_Header'}
13889                  $as_echo "$as_val"'`
13890    if test "x$as_val" = x""yes; then
13891   cat >>confdefs.h <<_ACEOF
13892 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13893 _ACEOF
13894
13895 else
13896   { { $as_echo "$as_me:$LINENO: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&5
13897 $as_echo "$as_me: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&2;}
13898    { (exit 1); exit 1; }; }
13899 fi
13900
13901 done
13902
13903 fi
13904
13905 done
13906
13907 fi
13908
13909
13910 ##
13911 ## Types, structures, compiler characteristics
13912 ##
13913
13914
13915  { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
13916 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
13917 if test "${ac_cv_c_bigendian+set}" = set; then
13918   $as_echo_n "(cached) " >&6
13919 else
13920   ac_cv_c_bigendian=unknown
13921     # See if we're dealing with a universal compiler.
13922     cat >conftest.$ac_ext <<_ACEOF
13923 /* confdefs.h.  */
13924 _ACEOF
13925 cat confdefs.h >>conftest.$ac_ext
13926 cat >>conftest.$ac_ext <<_ACEOF
13927 /* end confdefs.h.  */
13928 #ifndef __APPLE_CC__
13929                not a universal capable compiler
13930              #endif
13931              typedef int dummy;
13932
13933 _ACEOF
13934 rm -f conftest.$ac_objext
13935 if { (ac_try="$ac_compile"
13936 case "(($ac_try" in
13937   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13938   *) ac_try_echo=$ac_try;;
13939 esac
13940 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13941 $as_echo "$ac_try_echo") >&5
13942   (eval "$ac_compile") 2>conftest.er1
13943   ac_status=$?
13944   grep -v '^ *+' conftest.er1 >conftest.err
13945   rm -f conftest.er1
13946   cat conftest.err >&5
13947   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13948   (exit $ac_status); } && {
13949          test -z "$ac_c_werror_flag" ||
13950          test ! -s conftest.err
13951        } && test -s conftest.$ac_objext; then
13952
13953         # Check for potential -arch flags.  It is not universal unless
13954         # there are some -arch flags.  Note that *ppc* also matches
13955         # ppc64.  This check is also rather less than ideal.
13956         case "${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" in  #(
13957           *-arch*ppc*|*-arch*i386*|*-arch*x86_64*) ac_cv_c_bigendian=universal;;
13958         esac
13959 else
13960   $as_echo "$as_me: failed program was:" >&5
13961 sed 's/^/| /' conftest.$ac_ext >&5
13962
13963
13964 fi
13965
13966 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13967     if test $ac_cv_c_bigendian = unknown; then
13968       # See if sys/param.h defines the BYTE_ORDER macro.
13969       cat >conftest.$ac_ext <<_ACEOF
13970 /* confdefs.h.  */
13971 _ACEOF
13972 cat confdefs.h >>conftest.$ac_ext
13973 cat >>conftest.$ac_ext <<_ACEOF
13974 /* end confdefs.h.  */
13975 #include <sys/types.h>
13976              #include <sys/param.h>
13977
13978 int
13979 main ()
13980 {
13981 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
13982                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
13983                      && LITTLE_ENDIAN)
13984               bogus endian macros
13985              #endif
13986
13987   ;
13988   return 0;
13989 }
13990 _ACEOF
13991 rm -f conftest.$ac_objext
13992 if { (ac_try="$ac_compile"
13993 case "(($ac_try" in
13994   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13995   *) ac_try_echo=$ac_try;;
13996 esac
13997 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13998 $as_echo "$ac_try_echo") >&5
13999   (eval "$ac_compile") 2>conftest.er1
14000   ac_status=$?
14001   grep -v '^ *+' conftest.er1 >conftest.err
14002   rm -f conftest.er1
14003   cat conftest.err >&5
14004   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14005   (exit $ac_status); } && {
14006          test -z "$ac_c_werror_flag" ||
14007          test ! -s conftest.err
14008        } && test -s conftest.$ac_objext; then
14009   # It does; now see whether it defined to BIG_ENDIAN or not.
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 BYTE_ORDER != BIG_ENDIAN
14023                  not big endian
14024                 #endif
14025
14026   ;
14027   return 0;
14028 }
14029 _ACEOF
14030 rm -f conftest.$ac_objext
14031 if { (ac_try="$ac_compile"
14032 case "(($ac_try" in
14033   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14034   *) ac_try_echo=$ac_try;;
14035 esac
14036 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14037 $as_echo "$ac_try_echo") >&5
14038   (eval "$ac_compile") 2>conftest.er1
14039   ac_status=$?
14040   grep -v '^ *+' conftest.er1 >conftest.err
14041   rm -f conftest.er1
14042   cat conftest.err >&5
14043   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14044   (exit $ac_status); } && {
14045          test -z "$ac_c_werror_flag" ||
14046          test ! -s conftest.err
14047        } && test -s conftest.$ac_objext; then
14048   ac_cv_c_bigendian=yes
14049 else
14050   $as_echo "$as_me: failed program was:" >&5
14051 sed 's/^/| /' conftest.$ac_ext >&5
14052
14053         ac_cv_c_bigendian=no
14054 fi
14055
14056 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14057 else
14058   $as_echo "$as_me: failed program was:" >&5
14059 sed 's/^/| /' conftest.$ac_ext >&5
14060
14061
14062 fi
14063
14064 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14065     fi
14066     if test $ac_cv_c_bigendian = unknown; then
14067       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
14068       cat >conftest.$ac_ext <<_ACEOF
14069 /* confdefs.h.  */
14070 _ACEOF
14071 cat confdefs.h >>conftest.$ac_ext
14072 cat >>conftest.$ac_ext <<_ACEOF
14073 /* end confdefs.h.  */
14074 #include <limits.h>
14075
14076 int
14077 main ()
14078 {
14079 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
14080               bogus endian macros
14081              #endif
14082
14083   ;
14084   return 0;
14085 }
14086 _ACEOF
14087 rm -f conftest.$ac_objext
14088 if { (ac_try="$ac_compile"
14089 case "(($ac_try" in
14090   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14091   *) ac_try_echo=$ac_try;;
14092 esac
14093 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14094 $as_echo "$ac_try_echo") >&5
14095   (eval "$ac_compile") 2>conftest.er1
14096   ac_status=$?
14097   grep -v '^ *+' conftest.er1 >conftest.err
14098   rm -f conftest.er1
14099   cat conftest.err >&5
14100   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14101   (exit $ac_status); } && {
14102          test -z "$ac_c_werror_flag" ||
14103          test ! -s conftest.err
14104        } && test -s conftest.$ac_objext; then
14105   # It does; now see whether it defined to _BIG_ENDIAN or not.
14106          cat >conftest.$ac_ext <<_ACEOF
14107 /* confdefs.h.  */
14108 _ACEOF
14109 cat confdefs.h >>conftest.$ac_ext
14110 cat >>conftest.$ac_ext <<_ACEOF
14111 /* end confdefs.h.  */
14112 #include <limits.h>
14113
14114 int
14115 main ()
14116 {
14117 #ifndef _BIG_ENDIAN
14118                  not big endian
14119                 #endif
14120
14121   ;
14122   return 0;
14123 }
14124 _ACEOF
14125 rm -f conftest.$ac_objext
14126 if { (ac_try="$ac_compile"
14127 case "(($ac_try" in
14128   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14129   *) ac_try_echo=$ac_try;;
14130 esac
14131 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14132 $as_echo "$ac_try_echo") >&5
14133   (eval "$ac_compile") 2>conftest.er1
14134   ac_status=$?
14135   grep -v '^ *+' conftest.er1 >conftest.err
14136   rm -f conftest.er1
14137   cat conftest.err >&5
14138   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14139   (exit $ac_status); } && {
14140          test -z "$ac_c_werror_flag" ||
14141          test ! -s conftest.err
14142        } && test -s conftest.$ac_objext; then
14143   ac_cv_c_bigendian=yes
14144 else
14145   $as_echo "$as_me: failed program was:" >&5
14146 sed 's/^/| /' conftest.$ac_ext >&5
14147
14148         ac_cv_c_bigendian=no
14149 fi
14150
14151 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14152 else
14153   $as_echo "$as_me: failed program was:" >&5
14154 sed 's/^/| /' conftest.$ac_ext >&5
14155
14156
14157 fi
14158
14159 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14160     fi
14161     if test $ac_cv_c_bigendian = unknown; then
14162       # Compile a test program.
14163       if test "$cross_compiling" = yes; then
14164   # Try to guess by grepping values from an object file.
14165          cat >conftest.$ac_ext <<_ACEOF
14166 /* confdefs.h.  */
14167 _ACEOF
14168 cat confdefs.h >>conftest.$ac_ext
14169 cat >>conftest.$ac_ext <<_ACEOF
14170 /* end confdefs.h.  */
14171 short int ascii_mm[] =
14172                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
14173                 short int ascii_ii[] =
14174                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
14175                 int use_ascii (int i) {
14176                   return ascii_mm[i] + ascii_ii[i];
14177                 }
14178                 short int ebcdic_ii[] =
14179                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
14180                 short int ebcdic_mm[] =
14181                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
14182                 int use_ebcdic (int i) {
14183                   return ebcdic_mm[i] + ebcdic_ii[i];
14184                 }
14185                 extern int foo;
14186
14187 int
14188 main ()
14189 {
14190 return use_ascii (foo) == use_ebcdic (foo);
14191   ;
14192   return 0;
14193 }
14194 _ACEOF
14195 rm -f conftest.$ac_objext
14196 if { (ac_try="$ac_compile"
14197 case "(($ac_try" in
14198   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14199   *) ac_try_echo=$ac_try;;
14200 esac
14201 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14202 $as_echo "$ac_try_echo") >&5
14203   (eval "$ac_compile") 2>conftest.er1
14204   ac_status=$?
14205   grep -v '^ *+' conftest.er1 >conftest.err
14206   rm -f conftest.er1
14207   cat conftest.err >&5
14208   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14209   (exit $ac_status); } && {
14210          test -z "$ac_c_werror_flag" ||
14211          test ! -s conftest.err
14212        } && test -s conftest.$ac_objext; then
14213   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
14214               ac_cv_c_bigendian=yes
14215             fi
14216             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
14217               if test "$ac_cv_c_bigendian" = unknown; then
14218                 ac_cv_c_bigendian=no
14219               else
14220                 # finding both strings is unlikely to happen, but who knows?
14221                 ac_cv_c_bigendian=unknown
14222               fi
14223             fi
14224 else
14225   $as_echo "$as_me: failed program was:" >&5
14226 sed 's/^/| /' conftest.$ac_ext >&5
14227
14228
14229 fi
14230
14231 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14232 else
14233   cat >conftest.$ac_ext <<_ACEOF
14234 /* confdefs.h.  */
14235 _ACEOF
14236 cat confdefs.h >>conftest.$ac_ext
14237 cat >>conftest.$ac_ext <<_ACEOF
14238 /* end confdefs.h.  */
14239 $ac_includes_default
14240 int
14241 main ()
14242 {
14243
14244              /* Are we little or big endian?  From Harbison&Steele.  */
14245              union
14246              {
14247                long int l;
14248                char c[sizeof (long int)];
14249              } u;
14250              u.l = 1;
14251              return u.c[sizeof (long int) - 1] == 1;
14252
14253   ;
14254   return 0;
14255 }
14256 _ACEOF
14257 rm -f conftest$ac_exeext
14258 if { (ac_try="$ac_link"
14259 case "(($ac_try" in
14260   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14261   *) ac_try_echo=$ac_try;;
14262 esac
14263 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14264 $as_echo "$ac_try_echo") >&5
14265   (eval "$ac_link") 2>&5
14266   ac_status=$?
14267   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14268   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14269   { (case "(($ac_try" in
14270   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14271   *) ac_try_echo=$ac_try;;
14272 esac
14273 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14274 $as_echo "$ac_try_echo") >&5
14275   (eval "$ac_try") 2>&5
14276   ac_status=$?
14277   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14278   (exit $ac_status); }; }; then
14279   ac_cv_c_bigendian=no
14280 else
14281   $as_echo "$as_me: program exited with status $ac_status" >&5
14282 $as_echo "$as_me: failed program was:" >&5
14283 sed 's/^/| /' conftest.$ac_ext >&5
14284
14285 ( exit $ac_status )
14286 ac_cv_c_bigendian=yes
14287 fi
14288 rm -rf conftest.dSYM
14289 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14290 fi
14291
14292
14293     fi
14294 fi
14295 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
14296 $as_echo "$ac_cv_c_bigendian" >&6; }
14297  case $ac_cv_c_bigendian in #(
14298    yes)
14299      cat >>confdefs.h <<\_ACEOF
14300 #define WORDS_BIGENDIAN 1
14301 _ACEOF
14302 ;; #(
14303    no)
14304       ;; #(
14305    universal)
14306
14307 cat >>confdefs.h <<\_ACEOF
14308 #define AC_APPLE_UNIVERSAL_BUILD 1
14309 _ACEOF
14310
14311      ;; #(
14312    *)
14313      { { $as_echo "$as_me:$LINENO: error: unknown endianness
14314  presetting ac_cv_c_bigendian=no (or yes) will help" >&5
14315 $as_echo "$as_me: error: unknown endianness
14316  presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
14317    { (exit 1); exit 1; }; } ;;
14318  esac
14319
14320 { $as_echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14321 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
14322 if test "${ac_cv_c_const+set}" = set; then
14323   $as_echo_n "(cached) " >&6
14324 else
14325   cat >conftest.$ac_ext <<_ACEOF
14326 /* confdefs.h.  */
14327 _ACEOF
14328 cat confdefs.h >>conftest.$ac_ext
14329 cat >>conftest.$ac_ext <<_ACEOF
14330 /* end confdefs.h.  */
14331
14332 int
14333 main ()
14334 {
14335 /* FIXME: Include the comments suggested by Paul. */
14336 #ifndef __cplusplus
14337   /* Ultrix mips cc rejects this.  */
14338   typedef int charset[2];
14339   const charset cs;
14340   /* SunOS 4.1.1 cc rejects this.  */
14341   char const *const *pcpcc;
14342   char **ppc;
14343   /* NEC SVR4.0.2 mips cc rejects this.  */
14344   struct point {int x, y;};
14345   static struct point const zero = {0,0};
14346   /* AIX XL C 1.02.0.0 rejects this.
14347      It does not let you subtract one const X* pointer from another in
14348      an arm of an if-expression whose if-part is not a constant
14349      expression */
14350   const char *g = "string";
14351   pcpcc = &g + (g ? g-g : 0);
14352   /* HPUX 7.0 cc rejects these. */
14353   ++pcpcc;
14354   ppc = (char**) pcpcc;
14355   pcpcc = (char const *const *) ppc;
14356   { /* SCO 3.2v4 cc rejects this.  */
14357     char *t;
14358     char const *s = 0 ? (char *) 0 : (char const *) 0;
14359
14360     *t++ = 0;
14361     if (s) return 0;
14362   }
14363   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
14364     int x[] = {25, 17};
14365     const int *foo = &x[0];
14366     ++foo;
14367   }
14368   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14369     typedef const int *iptr;
14370     iptr p = 0;
14371     ++p;
14372   }
14373   { /* AIX XL C 1.02.0.0 rejects this saying
14374        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14375     struct s { int j; const int *ap[3]; };
14376     struct s *b; b->j = 5;
14377   }
14378   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14379     const int foo = 10;
14380     if (!foo) return 0;
14381   }
14382   return !cs[0] && !zero.x;
14383 #endif
14384
14385   ;
14386   return 0;
14387 }
14388 _ACEOF
14389 rm -f conftest.$ac_objext
14390 if { (ac_try="$ac_compile"
14391 case "(($ac_try" in
14392   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14393   *) ac_try_echo=$ac_try;;
14394 esac
14395 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14396 $as_echo "$ac_try_echo") >&5
14397   (eval "$ac_compile") 2>conftest.er1
14398   ac_status=$?
14399   grep -v '^ *+' conftest.er1 >conftest.err
14400   rm -f conftest.er1
14401   cat conftest.err >&5
14402   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14403   (exit $ac_status); } && {
14404          test -z "$ac_c_werror_flag" ||
14405          test ! -s conftest.err
14406        } && test -s conftest.$ac_objext; then
14407   ac_cv_c_const=yes
14408 else
14409   $as_echo "$as_me: failed program was:" >&5
14410 sed 's/^/| /' conftest.$ac_ext >&5
14411
14412         ac_cv_c_const=no
14413 fi
14414
14415 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14416 fi
14417 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
14418 $as_echo "$ac_cv_c_const" >&6; }
14419 if test $ac_cv_c_const = no; then
14420
14421 cat >>confdefs.h <<\_ACEOF
14422 #define const /**/
14423 _ACEOF
14424
14425 fi
14426
14427 { $as_echo "$as_me:$LINENO: checking for inline" >&5
14428 $as_echo_n "checking for inline... " >&6; }
14429 if test "${ac_cv_c_inline+set}" = set; then
14430   $as_echo_n "(cached) " >&6
14431 else
14432   ac_cv_c_inline=no
14433 for ac_kw in inline __inline__ __inline; do
14434   cat >conftest.$ac_ext <<_ACEOF
14435 /* confdefs.h.  */
14436 _ACEOF
14437 cat confdefs.h >>conftest.$ac_ext
14438 cat >>conftest.$ac_ext <<_ACEOF
14439 /* end confdefs.h.  */
14440 #ifndef __cplusplus
14441 typedef int foo_t;
14442 static $ac_kw foo_t static_foo () {return 0; }
14443 $ac_kw foo_t foo () {return 0; }
14444 #endif
14445
14446 _ACEOF
14447 rm -f conftest.$ac_objext
14448 if { (ac_try="$ac_compile"
14449 case "(($ac_try" in
14450   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14451   *) ac_try_echo=$ac_try;;
14452 esac
14453 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14454 $as_echo "$ac_try_echo") >&5
14455   (eval "$ac_compile") 2>conftest.er1
14456   ac_status=$?
14457   grep -v '^ *+' conftest.er1 >conftest.err
14458   rm -f conftest.er1
14459   cat conftest.err >&5
14460   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14461   (exit $ac_status); } && {
14462          test -z "$ac_c_werror_flag" ||
14463          test ! -s conftest.err
14464        } && test -s conftest.$ac_objext; then
14465   ac_cv_c_inline=$ac_kw
14466 else
14467   $as_echo "$as_me: failed program was:" >&5
14468 sed 's/^/| /' conftest.$ac_ext >&5
14469
14470
14471 fi
14472
14473 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14474   test "$ac_cv_c_inline" != no && break
14475 done
14476
14477 fi
14478 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
14479 $as_echo "$ac_cv_c_inline" >&6; }
14480
14481
14482 case $ac_cv_c_inline in
14483   inline | yes) ;;
14484   *)
14485     case $ac_cv_c_inline in
14486       no) ac_val=;;
14487       *) ac_val=$ac_cv_c_inline;;
14488     esac
14489     cat >>confdefs.h <<_ACEOF
14490 #ifndef __cplusplus
14491 #define inline $ac_val
14492 #endif
14493 _ACEOF
14494     ;;
14495 esac
14496
14497 { $as_echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
14498 $as_echo_n "checking for preprocessor stringizing operator... " >&6; }
14499 if test "${ac_cv_c_stringize+set}" = set; then
14500   $as_echo_n "(cached) " >&6
14501 else
14502   cat >conftest.$ac_ext <<_ACEOF
14503 /* confdefs.h.  */
14504 _ACEOF
14505 cat confdefs.h >>conftest.$ac_ext
14506 cat >>conftest.$ac_ext <<_ACEOF
14507 /* end confdefs.h.  */
14508 #define x(y) #y
14509
14510 char *s = x(teststring);
14511 _ACEOF
14512 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14513   $EGREP "#teststring" >/dev/null 2>&1; then
14514   ac_cv_c_stringize=no
14515 else
14516   ac_cv_c_stringize=yes
14517 fi
14518 rm -f conftest*
14519
14520 fi
14521 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
14522 $as_echo "$ac_cv_c_stringize" >&6; }
14523 if test $ac_cv_c_stringize = yes; then
14524
14525 cat >>confdefs.h <<\_ACEOF
14526 #define HAVE_STRINGIZE 1
14527 _ACEOF
14528
14529 fi
14530
14531 { $as_echo "$as_me:$LINENO: checking for signed types" >&5
14532 $as_echo_n "checking for signed types... " >&6; }
14533 if test "${pgac_cv_c_signed+set}" = set; then
14534   $as_echo_n "(cached) " >&6
14535 else
14536   cat >conftest.$ac_ext <<_ACEOF
14537 /* confdefs.h.  */
14538 _ACEOF
14539 cat confdefs.h >>conftest.$ac_ext
14540 cat >>conftest.$ac_ext <<_ACEOF
14541 /* end confdefs.h.  */
14542
14543 int
14544 main ()
14545 {
14546 signed char c; signed short s; signed int i;
14547   ;
14548   return 0;
14549 }
14550 _ACEOF
14551 rm -f conftest.$ac_objext
14552 if { (ac_try="$ac_compile"
14553 case "(($ac_try" in
14554   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14555   *) ac_try_echo=$ac_try;;
14556 esac
14557 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14558 $as_echo "$ac_try_echo") >&5
14559   (eval "$ac_compile") 2>conftest.er1
14560   ac_status=$?
14561   grep -v '^ *+' conftest.er1 >conftest.err
14562   rm -f conftest.er1
14563   cat conftest.err >&5
14564   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14565   (exit $ac_status); } && {
14566          test -z "$ac_c_werror_flag" ||
14567          test ! -s conftest.err
14568        } && test -s conftest.$ac_objext; then
14569   pgac_cv_c_signed=yes
14570 else
14571   $as_echo "$as_me: failed program was:" >&5
14572 sed 's/^/| /' conftest.$ac_ext >&5
14573
14574         pgac_cv_c_signed=no
14575 fi
14576
14577 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14578 fi
14579 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
14580 $as_echo "$pgac_cv_c_signed" >&6; }
14581 if test x"$pgac_cv_c_signed" = xno ; then
14582
14583 cat >>confdefs.h <<\_ACEOF
14584 #define signed /**/
14585 _ACEOF
14586
14587 fi
14588 { $as_echo "$as_me:$LINENO: checking for working volatile" >&5
14589 $as_echo_n "checking for working volatile... " >&6; }
14590 if test "${ac_cv_c_volatile+set}" = set; then
14591   $as_echo_n "(cached) " >&6
14592 else
14593   cat >conftest.$ac_ext <<_ACEOF
14594 /* confdefs.h.  */
14595 _ACEOF
14596 cat confdefs.h >>conftest.$ac_ext
14597 cat >>conftest.$ac_ext <<_ACEOF
14598 /* end confdefs.h.  */
14599
14600 int
14601 main ()
14602 {
14603
14604 volatile int x;
14605 int * volatile y = (int *) 0;
14606 return !x && !y;
14607   ;
14608   return 0;
14609 }
14610 _ACEOF
14611 rm -f conftest.$ac_objext
14612 if { (ac_try="$ac_compile"
14613 case "(($ac_try" in
14614   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14615   *) ac_try_echo=$ac_try;;
14616 esac
14617 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14618 $as_echo "$ac_try_echo") >&5
14619   (eval "$ac_compile") 2>conftest.er1
14620   ac_status=$?
14621   grep -v '^ *+' conftest.er1 >conftest.err
14622   rm -f conftest.er1
14623   cat conftest.err >&5
14624   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14625   (exit $ac_status); } && {
14626          test -z "$ac_c_werror_flag" ||
14627          test ! -s conftest.err
14628        } && test -s conftest.$ac_objext; then
14629   ac_cv_c_volatile=yes
14630 else
14631   $as_echo "$as_me: failed program was:" >&5
14632 sed 's/^/| /' conftest.$ac_ext >&5
14633
14634         ac_cv_c_volatile=no
14635 fi
14636
14637 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14638 fi
14639 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
14640 $as_echo "$ac_cv_c_volatile" >&6; }
14641 if test $ac_cv_c_volatile = no; then
14642
14643 cat >>confdefs.h <<\_ACEOF
14644 #define volatile /**/
14645 _ACEOF
14646
14647 fi
14648
14649 { $as_echo "$as_me:$LINENO: checking for __func__" >&5
14650 $as_echo_n "checking for __func__... " >&6; }
14651 if test "${pgac_cv_funcname_func_support+set}" = set; then
14652   $as_echo_n "(cached) " >&6
14653 else
14654   cat >conftest.$ac_ext <<_ACEOF
14655 /* confdefs.h.  */
14656 _ACEOF
14657 cat confdefs.h >>conftest.$ac_ext
14658 cat >>conftest.$ac_ext <<_ACEOF
14659 /* end confdefs.h.  */
14660 #include <stdio.h>
14661 int
14662 main ()
14663 {
14664 printf("%s\n", __func__);
14665   ;
14666   return 0;
14667 }
14668 _ACEOF
14669 rm -f conftest.$ac_objext
14670 if { (ac_try="$ac_compile"
14671 case "(($ac_try" in
14672   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14673   *) ac_try_echo=$ac_try;;
14674 esac
14675 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14676 $as_echo "$ac_try_echo") >&5
14677   (eval "$ac_compile") 2>conftest.er1
14678   ac_status=$?
14679   grep -v '^ *+' conftest.er1 >conftest.err
14680   rm -f conftest.er1
14681   cat conftest.err >&5
14682   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14683   (exit $ac_status); } && {
14684          test -z "$ac_c_werror_flag" ||
14685          test ! -s conftest.err
14686        } && test -s conftest.$ac_objext; then
14687   pgac_cv_funcname_func_support=yes
14688 else
14689   $as_echo "$as_me: failed program was:" >&5
14690 sed 's/^/| /' conftest.$ac_ext >&5
14691
14692         pgac_cv_funcname_func_support=no
14693 fi
14694
14695 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14696 fi
14697 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
14698 $as_echo "$pgac_cv_funcname_func_support" >&6; }
14699 if test x"$pgac_cv_funcname_func_support" = xyes ; then
14700
14701 cat >>confdefs.h <<\_ACEOF
14702 #define HAVE_FUNCNAME__FUNC 1
14703 _ACEOF
14704
14705 else
14706 { $as_echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
14707 $as_echo_n "checking for __FUNCTION__... " >&6; }
14708 if test "${pgac_cv_funcname_function_support+set}" = set; then
14709   $as_echo_n "(cached) " >&6
14710 else
14711   cat >conftest.$ac_ext <<_ACEOF
14712 /* confdefs.h.  */
14713 _ACEOF
14714 cat confdefs.h >>conftest.$ac_ext
14715 cat >>conftest.$ac_ext <<_ACEOF
14716 /* end confdefs.h.  */
14717 #include <stdio.h>
14718 int
14719 main ()
14720 {
14721 printf("%s\n", __FUNCTION__);
14722   ;
14723   return 0;
14724 }
14725 _ACEOF
14726 rm -f conftest.$ac_objext
14727 if { (ac_try="$ac_compile"
14728 case "(($ac_try" in
14729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14730   *) ac_try_echo=$ac_try;;
14731 esac
14732 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14733 $as_echo "$ac_try_echo") >&5
14734   (eval "$ac_compile") 2>conftest.er1
14735   ac_status=$?
14736   grep -v '^ *+' conftest.er1 >conftest.err
14737   rm -f conftest.er1
14738   cat conftest.err >&5
14739   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14740   (exit $ac_status); } && {
14741          test -z "$ac_c_werror_flag" ||
14742          test ! -s conftest.err
14743        } && test -s conftest.$ac_objext; then
14744   pgac_cv_funcname_function_support=yes
14745 else
14746   $as_echo "$as_me: failed program was:" >&5
14747 sed 's/^/| /' conftest.$ac_ext >&5
14748
14749         pgac_cv_funcname_function_support=no
14750 fi
14751
14752 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14753 fi
14754 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
14755 $as_echo "$pgac_cv_funcname_function_support" >&6; }
14756 if test x"$pgac_cv_funcname_function_support" = xyes ; then
14757
14758 cat >>confdefs.h <<\_ACEOF
14759 #define HAVE_FUNCNAME__FUNCTION 1
14760 _ACEOF
14761
14762 fi
14763 fi
14764 { $as_echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
14765 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
14766 if test "${ac_cv_struct_tm+set}" = set; then
14767   $as_echo_n "(cached) " >&6
14768 else
14769   cat >conftest.$ac_ext <<_ACEOF
14770 /* confdefs.h.  */
14771 _ACEOF
14772 cat confdefs.h >>conftest.$ac_ext
14773 cat >>conftest.$ac_ext <<_ACEOF
14774 /* end confdefs.h.  */
14775 #include <sys/types.h>
14776 #include <time.h>
14777
14778 int
14779 main ()
14780 {
14781 struct tm tm;
14782                                      int *p = &tm.tm_sec;
14783                                      return !p;
14784   ;
14785   return 0;
14786 }
14787 _ACEOF
14788 rm -f conftest.$ac_objext
14789 if { (ac_try="$ac_compile"
14790 case "(($ac_try" in
14791   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14792   *) ac_try_echo=$ac_try;;
14793 esac
14794 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14795 $as_echo "$ac_try_echo") >&5
14796   (eval "$ac_compile") 2>conftest.er1
14797   ac_status=$?
14798   grep -v '^ *+' conftest.er1 >conftest.err
14799   rm -f conftest.er1
14800   cat conftest.err >&5
14801   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14802   (exit $ac_status); } && {
14803          test -z "$ac_c_werror_flag" ||
14804          test ! -s conftest.err
14805        } && test -s conftest.$ac_objext; then
14806   ac_cv_struct_tm=time.h
14807 else
14808   $as_echo "$as_me: failed program was:" >&5
14809 sed 's/^/| /' conftest.$ac_ext >&5
14810
14811         ac_cv_struct_tm=sys/time.h
14812 fi
14813
14814 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14815 fi
14816 { $as_echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
14817 $as_echo "$ac_cv_struct_tm" >&6; }
14818 if test $ac_cv_struct_tm = sys/time.h; then
14819
14820 cat >>confdefs.h <<\_ACEOF
14821 #define TM_IN_SYS_TIME 1
14822 _ACEOF
14823
14824 fi
14825
14826 { $as_echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
14827 $as_echo_n "checking for struct tm.tm_zone... " >&6; }
14828 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
14829   $as_echo_n "(cached) " >&6
14830 else
14831   cat >conftest.$ac_ext <<_ACEOF
14832 /* confdefs.h.  */
14833 _ACEOF
14834 cat confdefs.h >>conftest.$ac_ext
14835 cat >>conftest.$ac_ext <<_ACEOF
14836 /* end confdefs.h.  */
14837 #include <sys/types.h>
14838 #include <$ac_cv_struct_tm>
14839
14840
14841 int
14842 main ()
14843 {
14844 static struct tm ac_aggr;
14845 if (ac_aggr.tm_zone)
14846 return 0;
14847   ;
14848   return 0;
14849 }
14850 _ACEOF
14851 rm -f conftest.$ac_objext
14852 if { (ac_try="$ac_compile"
14853 case "(($ac_try" in
14854   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14855   *) ac_try_echo=$ac_try;;
14856 esac
14857 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14858 $as_echo "$ac_try_echo") >&5
14859   (eval "$ac_compile") 2>conftest.er1
14860   ac_status=$?
14861   grep -v '^ *+' conftest.er1 >conftest.err
14862   rm -f conftest.er1
14863   cat conftest.err >&5
14864   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14865   (exit $ac_status); } && {
14866          test -z "$ac_c_werror_flag" ||
14867          test ! -s conftest.err
14868        } && test -s conftest.$ac_objext; then
14869   ac_cv_member_struct_tm_tm_zone=yes
14870 else
14871   $as_echo "$as_me: failed program was:" >&5
14872 sed 's/^/| /' conftest.$ac_ext >&5
14873
14874         cat >conftest.$ac_ext <<_ACEOF
14875 /* confdefs.h.  */
14876 _ACEOF
14877 cat confdefs.h >>conftest.$ac_ext
14878 cat >>conftest.$ac_ext <<_ACEOF
14879 /* end confdefs.h.  */
14880 #include <sys/types.h>
14881 #include <$ac_cv_struct_tm>
14882
14883
14884 int
14885 main ()
14886 {
14887 static struct tm ac_aggr;
14888 if (sizeof ac_aggr.tm_zone)
14889 return 0;
14890   ;
14891   return 0;
14892 }
14893 _ACEOF
14894 rm -f conftest.$ac_objext
14895 if { (ac_try="$ac_compile"
14896 case "(($ac_try" in
14897   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14898   *) ac_try_echo=$ac_try;;
14899 esac
14900 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14901 $as_echo "$ac_try_echo") >&5
14902   (eval "$ac_compile") 2>conftest.er1
14903   ac_status=$?
14904   grep -v '^ *+' conftest.er1 >conftest.err
14905   rm -f conftest.er1
14906   cat conftest.err >&5
14907   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14908   (exit $ac_status); } && {
14909          test -z "$ac_c_werror_flag" ||
14910          test ! -s conftest.err
14911        } && test -s conftest.$ac_objext; then
14912   ac_cv_member_struct_tm_tm_zone=yes
14913 else
14914   $as_echo "$as_me: failed program was:" >&5
14915 sed 's/^/| /' conftest.$ac_ext >&5
14916
14917         ac_cv_member_struct_tm_tm_zone=no
14918 fi
14919
14920 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14921 fi
14922
14923 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14924 fi
14925 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
14926 $as_echo "$ac_cv_member_struct_tm_tm_zone" >&6; }
14927 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then
14928
14929 cat >>confdefs.h <<_ACEOF
14930 #define HAVE_STRUCT_TM_TM_ZONE 1
14931 _ACEOF
14932
14933
14934 fi
14935
14936 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
14937
14938 cat >>confdefs.h <<\_ACEOF
14939 #define HAVE_TM_ZONE 1
14940 _ACEOF
14941
14942 fi
14943 { $as_echo "$as_me:$LINENO: checking for tzname" >&5
14944 $as_echo_n "checking for tzname... " >&6; }
14945 if test "${ac_cv_var_tzname+set}" = set; then
14946   $as_echo_n "(cached) " >&6
14947 else
14948   cat >conftest.$ac_ext <<_ACEOF
14949 /* confdefs.h.  */
14950 _ACEOF
14951 cat confdefs.h >>conftest.$ac_ext
14952 cat >>conftest.$ac_ext <<_ACEOF
14953 /* end confdefs.h.  */
14954 #include <time.h>
14955 #ifndef tzname /* For SGI.  */
14956 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
14957 #endif
14958
14959 int
14960 main ()
14961 {
14962 atoi(*tzname);
14963   ;
14964   return 0;
14965 }
14966 _ACEOF
14967 rm -f conftest.$ac_objext conftest$ac_exeext
14968 if { (ac_try="$ac_link"
14969 case "(($ac_try" in
14970   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14971   *) ac_try_echo=$ac_try;;
14972 esac
14973 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14974 $as_echo "$ac_try_echo") >&5
14975   (eval "$ac_link") 2>conftest.er1
14976   ac_status=$?
14977   grep -v '^ *+' conftest.er1 >conftest.err
14978   rm -f conftest.er1
14979   cat conftest.err >&5
14980   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14981   (exit $ac_status); } && {
14982          test -z "$ac_c_werror_flag" ||
14983          test ! -s conftest.err
14984        } && test -s conftest$ac_exeext && {
14985          test "$cross_compiling" = yes ||
14986          $as_test_x conftest$ac_exeext
14987        }; then
14988   ac_cv_var_tzname=yes
14989 else
14990   $as_echo "$as_me: failed program was:" >&5
14991 sed 's/^/| /' conftest.$ac_ext >&5
14992
14993         ac_cv_var_tzname=no
14994 fi
14995
14996 rm -rf conftest.dSYM
14997 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14998       conftest$ac_exeext conftest.$ac_ext
14999 fi
15000 { $as_echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
15001 $as_echo "$ac_cv_var_tzname" >&6; }
15002 if test $ac_cv_var_tzname = yes; then
15003
15004 cat >>confdefs.h <<\_ACEOF
15005 #define HAVE_TZNAME 1
15006 _ACEOF
15007
15008 fi
15009
15010 { $as_echo "$as_me:$LINENO: checking for union semun" >&5
15011 $as_echo_n "checking for union semun... " >&6; }
15012 if test "${ac_cv_type_union_semun+set}" = set; then
15013   $as_echo_n "(cached) " >&6
15014 else
15015   ac_cv_type_union_semun=no
15016 cat >conftest.$ac_ext <<_ACEOF
15017 /* confdefs.h.  */
15018 _ACEOF
15019 cat confdefs.h >>conftest.$ac_ext
15020 cat >>conftest.$ac_ext <<_ACEOF
15021 /* end confdefs.h.  */
15022 #include <sys/types.h>
15023 #include <sys/ipc.h>
15024 #include <sys/sem.h>
15025
15026 int
15027 main ()
15028 {
15029 if (sizeof (union semun))
15030        return 0;
15031   ;
15032   return 0;
15033 }
15034 _ACEOF
15035 rm -f conftest.$ac_objext
15036 if { (ac_try="$ac_compile"
15037 case "(($ac_try" in
15038   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15039   *) ac_try_echo=$ac_try;;
15040 esac
15041 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15042 $as_echo "$ac_try_echo") >&5
15043   (eval "$ac_compile") 2>conftest.er1
15044   ac_status=$?
15045   grep -v '^ *+' conftest.er1 >conftest.err
15046   rm -f conftest.er1
15047   cat conftest.err >&5
15048   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15049   (exit $ac_status); } && {
15050          test -z "$ac_c_werror_flag" ||
15051          test ! -s conftest.err
15052        } && test -s conftest.$ac_objext; then
15053   cat >conftest.$ac_ext <<_ACEOF
15054 /* confdefs.h.  */
15055 _ACEOF
15056 cat confdefs.h >>conftest.$ac_ext
15057 cat >>conftest.$ac_ext <<_ACEOF
15058 /* end confdefs.h.  */
15059 #include <sys/types.h>
15060 #include <sys/ipc.h>
15061 #include <sys/sem.h>
15062
15063 int
15064 main ()
15065 {
15066 if (sizeof ((union semun)))
15067           return 0;
15068   ;
15069   return 0;
15070 }
15071 _ACEOF
15072 rm -f conftest.$ac_objext
15073 if { (ac_try="$ac_compile"
15074 case "(($ac_try" in
15075   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15076   *) ac_try_echo=$ac_try;;
15077 esac
15078 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15079 $as_echo "$ac_try_echo") >&5
15080   (eval "$ac_compile") 2>conftest.er1
15081   ac_status=$?
15082   grep -v '^ *+' conftest.er1 >conftest.err
15083   rm -f conftest.er1
15084   cat conftest.err >&5
15085   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15086   (exit $ac_status); } && {
15087          test -z "$ac_c_werror_flag" ||
15088          test ! -s conftest.err
15089        } && test -s conftest.$ac_objext; then
15090   :
15091 else
15092   $as_echo "$as_me: failed program was:" >&5
15093 sed 's/^/| /' conftest.$ac_ext >&5
15094
15095         ac_cv_type_union_semun=yes
15096 fi
15097
15098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15099 else
15100   $as_echo "$as_me: failed program was:" >&5
15101 sed 's/^/| /' conftest.$ac_ext >&5
15102
15103
15104 fi
15105
15106 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15107 fi
15108 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
15109 $as_echo "$ac_cv_type_union_semun" >&6; }
15110 if test "x$ac_cv_type_union_semun" = x""yes; then
15111
15112 cat >>confdefs.h <<_ACEOF
15113 #define HAVE_UNION_SEMUN 1
15114 _ACEOF
15115
15116
15117 fi
15118
15119 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
15120 $as_echo_n "checking for struct sockaddr_un... " >&6; }
15121 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
15122   $as_echo_n "(cached) " >&6
15123 else
15124   ac_cv_type_struct_sockaddr_un=no
15125 cat >conftest.$ac_ext <<_ACEOF
15126 /* confdefs.h.  */
15127 _ACEOF
15128 cat confdefs.h >>conftest.$ac_ext
15129 cat >>conftest.$ac_ext <<_ACEOF
15130 /* end confdefs.h.  */
15131 #include <sys/types.h>
15132 #ifdef HAVE_SYS_UN_H
15133 #include <sys/un.h>
15134 #endif
15135
15136
15137 int
15138 main ()
15139 {
15140 if (sizeof (struct sockaddr_un))
15141        return 0;
15142   ;
15143   return 0;
15144 }
15145 _ACEOF
15146 rm -f conftest.$ac_objext
15147 if { (ac_try="$ac_compile"
15148 case "(($ac_try" in
15149   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15150   *) ac_try_echo=$ac_try;;
15151 esac
15152 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15153 $as_echo "$ac_try_echo") >&5
15154   (eval "$ac_compile") 2>conftest.er1
15155   ac_status=$?
15156   grep -v '^ *+' conftest.er1 >conftest.err
15157   rm -f conftest.er1
15158   cat conftest.err >&5
15159   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15160   (exit $ac_status); } && {
15161          test -z "$ac_c_werror_flag" ||
15162          test ! -s conftest.err
15163        } && test -s conftest.$ac_objext; then
15164   cat >conftest.$ac_ext <<_ACEOF
15165 /* confdefs.h.  */
15166 _ACEOF
15167 cat confdefs.h >>conftest.$ac_ext
15168 cat >>conftest.$ac_ext <<_ACEOF
15169 /* end confdefs.h.  */
15170 #include <sys/types.h>
15171 #ifdef HAVE_SYS_UN_H
15172 #include <sys/un.h>
15173 #endif
15174
15175
15176 int
15177 main ()
15178 {
15179 if (sizeof ((struct sockaddr_un)))
15180           return 0;
15181   ;
15182   return 0;
15183 }
15184 _ACEOF
15185 rm -f conftest.$ac_objext
15186 if { (ac_try="$ac_compile"
15187 case "(($ac_try" in
15188   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15189   *) ac_try_echo=$ac_try;;
15190 esac
15191 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15192 $as_echo "$ac_try_echo") >&5
15193   (eval "$ac_compile") 2>conftest.er1
15194   ac_status=$?
15195   grep -v '^ *+' conftest.er1 >conftest.err
15196   rm -f conftest.er1
15197   cat conftest.err >&5
15198   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15199   (exit $ac_status); } && {
15200          test -z "$ac_c_werror_flag" ||
15201          test ! -s conftest.err
15202        } && test -s conftest.$ac_objext; then
15203   :
15204 else
15205   $as_echo "$as_me: failed program was:" >&5
15206 sed 's/^/| /' conftest.$ac_ext >&5
15207
15208         ac_cv_type_struct_sockaddr_un=yes
15209 fi
15210
15211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15212 else
15213   $as_echo "$as_me: failed program was:" >&5
15214 sed 's/^/| /' conftest.$ac_ext >&5
15215
15216
15217 fi
15218
15219 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15220 fi
15221 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
15222 $as_echo "$ac_cv_type_struct_sockaddr_un" >&6; }
15223 if test "x$ac_cv_type_struct_sockaddr_un" = x""yes; then
15224
15225 cat >>confdefs.h <<_ACEOF
15226 #define HAVE_STRUCT_SOCKADDR_UN 1
15227 _ACEOF
15228
15229
15230 cat >>confdefs.h <<\_ACEOF
15231 #define HAVE_UNIX_SOCKETS 1
15232 _ACEOF
15233
15234 fi
15235
15236 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
15237 $as_echo_n "checking for struct sockaddr_storage... " >&6; }
15238 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
15239   $as_echo_n "(cached) " >&6
15240 else
15241   ac_cv_type_struct_sockaddr_storage=no
15242 cat >conftest.$ac_ext <<_ACEOF
15243 /* confdefs.h.  */
15244 _ACEOF
15245 cat confdefs.h >>conftest.$ac_ext
15246 cat >>conftest.$ac_ext <<_ACEOF
15247 /* end confdefs.h.  */
15248 #include <sys/types.h>
15249 #ifdef HAVE_SYS_SOCKET_H
15250 #include <sys/socket.h>
15251 #endif
15252
15253
15254 int
15255 main ()
15256 {
15257 if (sizeof (struct sockaddr_storage))
15258        return 0;
15259   ;
15260   return 0;
15261 }
15262 _ACEOF
15263 rm -f conftest.$ac_objext
15264 if { (ac_try="$ac_compile"
15265 case "(($ac_try" in
15266   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15267   *) ac_try_echo=$ac_try;;
15268 esac
15269 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15270 $as_echo "$ac_try_echo") >&5
15271   (eval "$ac_compile") 2>conftest.er1
15272   ac_status=$?
15273   grep -v '^ *+' conftest.er1 >conftest.err
15274   rm -f conftest.er1
15275   cat conftest.err >&5
15276   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15277   (exit $ac_status); } && {
15278          test -z "$ac_c_werror_flag" ||
15279          test ! -s conftest.err
15280        } && test -s conftest.$ac_objext; then
15281   cat >conftest.$ac_ext <<_ACEOF
15282 /* confdefs.h.  */
15283 _ACEOF
15284 cat confdefs.h >>conftest.$ac_ext
15285 cat >>conftest.$ac_ext <<_ACEOF
15286 /* end confdefs.h.  */
15287 #include <sys/types.h>
15288 #ifdef HAVE_SYS_SOCKET_H
15289 #include <sys/socket.h>
15290 #endif
15291
15292
15293 int
15294 main ()
15295 {
15296 if (sizeof ((struct sockaddr_storage)))
15297           return 0;
15298   ;
15299   return 0;
15300 }
15301 _ACEOF
15302 rm -f conftest.$ac_objext
15303 if { (ac_try="$ac_compile"
15304 case "(($ac_try" in
15305   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15306   *) ac_try_echo=$ac_try;;
15307 esac
15308 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15309 $as_echo "$ac_try_echo") >&5
15310   (eval "$ac_compile") 2>conftest.er1
15311   ac_status=$?
15312   grep -v '^ *+' conftest.er1 >conftest.err
15313   rm -f conftest.er1
15314   cat conftest.err >&5
15315   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15316   (exit $ac_status); } && {
15317          test -z "$ac_c_werror_flag" ||
15318          test ! -s conftest.err
15319        } && test -s conftest.$ac_objext; then
15320   :
15321 else
15322   $as_echo "$as_me: failed program was:" >&5
15323 sed 's/^/| /' conftest.$ac_ext >&5
15324
15325         ac_cv_type_struct_sockaddr_storage=yes
15326 fi
15327
15328 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15329 else
15330   $as_echo "$as_me: failed program was:" >&5
15331 sed 's/^/| /' conftest.$ac_ext >&5
15332
15333
15334 fi
15335
15336 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15337 fi
15338 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
15339 $as_echo "$ac_cv_type_struct_sockaddr_storage" >&6; }
15340 if test "x$ac_cv_type_struct_sockaddr_storage" = x""yes; then
15341
15342 cat >>confdefs.h <<_ACEOF
15343 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
15344 _ACEOF
15345
15346
15347 fi
15348
15349 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
15350 $as_echo_n "checking for struct sockaddr_storage.ss_family... " >&6; }
15351 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
15352   $as_echo_n "(cached) " >&6
15353 else
15354   cat >conftest.$ac_ext <<_ACEOF
15355 /* confdefs.h.  */
15356 _ACEOF
15357 cat confdefs.h >>conftest.$ac_ext
15358 cat >>conftest.$ac_ext <<_ACEOF
15359 /* end confdefs.h.  */
15360 #include <sys/types.h>
15361 #ifdef HAVE_SYS_SOCKET_H
15362 #include <sys/socket.h>
15363 #endif
15364
15365
15366 int
15367 main ()
15368 {
15369 static struct sockaddr_storage ac_aggr;
15370 if (ac_aggr.ss_family)
15371 return 0;
15372   ;
15373   return 0;
15374 }
15375 _ACEOF
15376 rm -f conftest.$ac_objext
15377 if { (ac_try="$ac_compile"
15378 case "(($ac_try" in
15379   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15380   *) ac_try_echo=$ac_try;;
15381 esac
15382 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15383 $as_echo "$ac_try_echo") >&5
15384   (eval "$ac_compile") 2>conftest.er1
15385   ac_status=$?
15386   grep -v '^ *+' conftest.er1 >conftest.err
15387   rm -f conftest.er1
15388   cat conftest.err >&5
15389   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15390   (exit $ac_status); } && {
15391          test -z "$ac_c_werror_flag" ||
15392          test ! -s conftest.err
15393        } && test -s conftest.$ac_objext; then
15394   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15395 else
15396   $as_echo "$as_me: failed program was:" >&5
15397 sed 's/^/| /' conftest.$ac_ext >&5
15398
15399         cat >conftest.$ac_ext <<_ACEOF
15400 /* confdefs.h.  */
15401 _ACEOF
15402 cat confdefs.h >>conftest.$ac_ext
15403 cat >>conftest.$ac_ext <<_ACEOF
15404 /* end confdefs.h.  */
15405 #include <sys/types.h>
15406 #ifdef HAVE_SYS_SOCKET_H
15407 #include <sys/socket.h>
15408 #endif
15409
15410
15411 int
15412 main ()
15413 {
15414 static struct sockaddr_storage ac_aggr;
15415 if (sizeof ac_aggr.ss_family)
15416 return 0;
15417   ;
15418   return 0;
15419 }
15420 _ACEOF
15421 rm -f conftest.$ac_objext
15422 if { (ac_try="$ac_compile"
15423 case "(($ac_try" in
15424   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15425   *) ac_try_echo=$ac_try;;
15426 esac
15427 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15428 $as_echo "$ac_try_echo") >&5
15429   (eval "$ac_compile") 2>conftest.er1
15430   ac_status=$?
15431   grep -v '^ *+' conftest.er1 >conftest.err
15432   rm -f conftest.er1
15433   cat conftest.err >&5
15434   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15435   (exit $ac_status); } && {
15436          test -z "$ac_c_werror_flag" ||
15437          test ! -s conftest.err
15438        } && test -s conftest.$ac_objext; then
15439   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15440 else
15441   $as_echo "$as_me: failed program was:" >&5
15442 sed 's/^/| /' conftest.$ac_ext >&5
15443
15444         ac_cv_member_struct_sockaddr_storage_ss_family=no
15445 fi
15446
15447 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15448 fi
15449
15450 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15451 fi
15452 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
15453 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_family" >&6; }
15454 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = x""yes; then
15455
15456 cat >>confdefs.h <<_ACEOF
15457 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
15458 _ACEOF
15459
15460
15461 fi
15462 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
15463 $as_echo_n "checking for struct sockaddr_storage.__ss_family... " >&6; }
15464 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
15465   $as_echo_n "(cached) " >&6
15466 else
15467   cat >conftest.$ac_ext <<_ACEOF
15468 /* confdefs.h.  */
15469 _ACEOF
15470 cat confdefs.h >>conftest.$ac_ext
15471 cat >>conftest.$ac_ext <<_ACEOF
15472 /* end confdefs.h.  */
15473 #include <sys/types.h>
15474 #ifdef HAVE_SYS_SOCKET_H
15475 #include <sys/socket.h>
15476 #endif
15477
15478
15479 int
15480 main ()
15481 {
15482 static struct sockaddr_storage ac_aggr;
15483 if (ac_aggr.__ss_family)
15484 return 0;
15485   ;
15486   return 0;
15487 }
15488 _ACEOF
15489 rm -f conftest.$ac_objext
15490 if { (ac_try="$ac_compile"
15491 case "(($ac_try" in
15492   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15493   *) ac_try_echo=$ac_try;;
15494 esac
15495 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15496 $as_echo "$ac_try_echo") >&5
15497   (eval "$ac_compile") 2>conftest.er1
15498   ac_status=$?
15499   grep -v '^ *+' conftest.er1 >conftest.err
15500   rm -f conftest.er1
15501   cat conftest.err >&5
15502   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15503   (exit $ac_status); } && {
15504          test -z "$ac_c_werror_flag" ||
15505          test ! -s conftest.err
15506        } && test -s conftest.$ac_objext; then
15507   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15508 else
15509   $as_echo "$as_me: failed program was:" >&5
15510 sed 's/^/| /' conftest.$ac_ext >&5
15511
15512         cat >conftest.$ac_ext <<_ACEOF
15513 /* confdefs.h.  */
15514 _ACEOF
15515 cat confdefs.h >>conftest.$ac_ext
15516 cat >>conftest.$ac_ext <<_ACEOF
15517 /* end confdefs.h.  */
15518 #include <sys/types.h>
15519 #ifdef HAVE_SYS_SOCKET_H
15520 #include <sys/socket.h>
15521 #endif
15522
15523
15524 int
15525 main ()
15526 {
15527 static struct sockaddr_storage ac_aggr;
15528 if (sizeof ac_aggr.__ss_family)
15529 return 0;
15530   ;
15531   return 0;
15532 }
15533 _ACEOF
15534 rm -f conftest.$ac_objext
15535 if { (ac_try="$ac_compile"
15536 case "(($ac_try" in
15537   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15538   *) ac_try_echo=$ac_try;;
15539 esac
15540 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15541 $as_echo "$ac_try_echo") >&5
15542   (eval "$ac_compile") 2>conftest.er1
15543   ac_status=$?
15544   grep -v '^ *+' conftest.er1 >conftest.err
15545   rm -f conftest.er1
15546   cat conftest.err >&5
15547   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15548   (exit $ac_status); } && {
15549          test -z "$ac_c_werror_flag" ||
15550          test ! -s conftest.err
15551        } && test -s conftest.$ac_objext; then
15552   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15553 else
15554   $as_echo "$as_me: failed program was:" >&5
15555 sed 's/^/| /' conftest.$ac_ext >&5
15556
15557         ac_cv_member_struct_sockaddr_storage___ss_family=no
15558 fi
15559
15560 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15561 fi
15562
15563 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15564 fi
15565 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
15566 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_family" >&6; }
15567 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = x""yes; then
15568
15569 cat >>confdefs.h <<_ACEOF
15570 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
15571 _ACEOF
15572
15573
15574 fi
15575 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
15576 $as_echo_n "checking for struct sockaddr_storage.ss_len... " >&6; }
15577 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
15578   $as_echo_n "(cached) " >&6
15579 else
15580   cat >conftest.$ac_ext <<_ACEOF
15581 /* confdefs.h.  */
15582 _ACEOF
15583 cat confdefs.h >>conftest.$ac_ext
15584 cat >>conftest.$ac_ext <<_ACEOF
15585 /* end confdefs.h.  */
15586 #include <sys/types.h>
15587 #ifdef HAVE_SYS_SOCKET_H
15588 #include <sys/socket.h>
15589 #endif
15590
15591
15592 int
15593 main ()
15594 {
15595 static struct sockaddr_storage ac_aggr;
15596 if (ac_aggr.ss_len)
15597 return 0;
15598   ;
15599   return 0;
15600 }
15601 _ACEOF
15602 rm -f conftest.$ac_objext
15603 if { (ac_try="$ac_compile"
15604 case "(($ac_try" in
15605   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15606   *) ac_try_echo=$ac_try;;
15607 esac
15608 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15609 $as_echo "$ac_try_echo") >&5
15610   (eval "$ac_compile") 2>conftest.er1
15611   ac_status=$?
15612   grep -v '^ *+' conftest.er1 >conftest.err
15613   rm -f conftest.er1
15614   cat conftest.err >&5
15615   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15616   (exit $ac_status); } && {
15617          test -z "$ac_c_werror_flag" ||
15618          test ! -s conftest.err
15619        } && test -s conftest.$ac_objext; then
15620   ac_cv_member_struct_sockaddr_storage_ss_len=yes
15621 else
15622   $as_echo "$as_me: failed program was:" >&5
15623 sed 's/^/| /' conftest.$ac_ext >&5
15624
15625         cat >conftest.$ac_ext <<_ACEOF
15626 /* confdefs.h.  */
15627 _ACEOF
15628 cat confdefs.h >>conftest.$ac_ext
15629 cat >>conftest.$ac_ext <<_ACEOF
15630 /* end confdefs.h.  */
15631 #include <sys/types.h>
15632 #ifdef HAVE_SYS_SOCKET_H
15633 #include <sys/socket.h>
15634 #endif
15635
15636
15637 int
15638 main ()
15639 {
15640 static struct sockaddr_storage ac_aggr;
15641 if (sizeof ac_aggr.ss_len)
15642 return 0;
15643   ;
15644   return 0;
15645 }
15646 _ACEOF
15647 rm -f conftest.$ac_objext
15648 if { (ac_try="$ac_compile"
15649 case "(($ac_try" in
15650   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15651   *) ac_try_echo=$ac_try;;
15652 esac
15653 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15654 $as_echo "$ac_try_echo") >&5
15655   (eval "$ac_compile") 2>conftest.er1
15656   ac_status=$?
15657   grep -v '^ *+' conftest.er1 >conftest.err
15658   rm -f conftest.er1
15659   cat conftest.err >&5
15660   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15661   (exit $ac_status); } && {
15662          test -z "$ac_c_werror_flag" ||
15663          test ! -s conftest.err
15664        } && test -s conftest.$ac_objext; then
15665   ac_cv_member_struct_sockaddr_storage_ss_len=yes
15666 else
15667   $as_echo "$as_me: failed program was:" >&5
15668 sed 's/^/| /' conftest.$ac_ext >&5
15669
15670         ac_cv_member_struct_sockaddr_storage_ss_len=no
15671 fi
15672
15673 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15674 fi
15675
15676 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15677 fi
15678 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
15679 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_len" >&6; }
15680 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = x""yes; then
15681
15682 cat >>confdefs.h <<_ACEOF
15683 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
15684 _ACEOF
15685
15686
15687 fi
15688 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
15689 $as_echo_n "checking for struct sockaddr_storage.__ss_len... " >&6; }
15690 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
15691   $as_echo_n "(cached) " >&6
15692 else
15693   cat >conftest.$ac_ext <<_ACEOF
15694 /* confdefs.h.  */
15695 _ACEOF
15696 cat confdefs.h >>conftest.$ac_ext
15697 cat >>conftest.$ac_ext <<_ACEOF
15698 /* end confdefs.h.  */
15699 #include <sys/types.h>
15700 #ifdef HAVE_SYS_SOCKET_H
15701 #include <sys/socket.h>
15702 #endif
15703
15704
15705 int
15706 main ()
15707 {
15708 static struct sockaddr_storage ac_aggr;
15709 if (ac_aggr.__ss_len)
15710 return 0;
15711   ;
15712   return 0;
15713 }
15714 _ACEOF
15715 rm -f conftest.$ac_objext
15716 if { (ac_try="$ac_compile"
15717 case "(($ac_try" in
15718   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15719   *) ac_try_echo=$ac_try;;
15720 esac
15721 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15722 $as_echo "$ac_try_echo") >&5
15723   (eval "$ac_compile") 2>conftest.er1
15724   ac_status=$?
15725   grep -v '^ *+' conftest.er1 >conftest.err
15726   rm -f conftest.er1
15727   cat conftest.err >&5
15728   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15729   (exit $ac_status); } && {
15730          test -z "$ac_c_werror_flag" ||
15731          test ! -s conftest.err
15732        } && test -s conftest.$ac_objext; then
15733   ac_cv_member_struct_sockaddr_storage___ss_len=yes
15734 else
15735   $as_echo "$as_me: failed program was:" >&5
15736 sed 's/^/| /' conftest.$ac_ext >&5
15737
15738         cat >conftest.$ac_ext <<_ACEOF
15739 /* confdefs.h.  */
15740 _ACEOF
15741 cat confdefs.h >>conftest.$ac_ext
15742 cat >>conftest.$ac_ext <<_ACEOF
15743 /* end confdefs.h.  */
15744 #include <sys/types.h>
15745 #ifdef HAVE_SYS_SOCKET_H
15746 #include <sys/socket.h>
15747 #endif
15748
15749
15750 int
15751 main ()
15752 {
15753 static struct sockaddr_storage ac_aggr;
15754 if (sizeof ac_aggr.__ss_len)
15755 return 0;
15756   ;
15757   return 0;
15758 }
15759 _ACEOF
15760 rm -f conftest.$ac_objext
15761 if { (ac_try="$ac_compile"
15762 case "(($ac_try" in
15763   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15764   *) ac_try_echo=$ac_try;;
15765 esac
15766 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15767 $as_echo "$ac_try_echo") >&5
15768   (eval "$ac_compile") 2>conftest.er1
15769   ac_status=$?
15770   grep -v '^ *+' conftest.er1 >conftest.err
15771   rm -f conftest.er1
15772   cat conftest.err >&5
15773   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15774   (exit $ac_status); } && {
15775          test -z "$ac_c_werror_flag" ||
15776          test ! -s conftest.err
15777        } && test -s conftest.$ac_objext; then
15778   ac_cv_member_struct_sockaddr_storage___ss_len=yes
15779 else
15780   $as_echo "$as_me: failed program was:" >&5
15781 sed 's/^/| /' conftest.$ac_ext >&5
15782
15783         ac_cv_member_struct_sockaddr_storage___ss_len=no
15784 fi
15785
15786 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15787 fi
15788
15789 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15790 fi
15791 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
15792 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_len" >&6; }
15793 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = x""yes; then
15794
15795 cat >>confdefs.h <<_ACEOF
15796 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
15797 _ACEOF
15798
15799
15800 fi
15801 { $as_echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
15802 $as_echo_n "checking for struct sockaddr.sa_len... " >&6; }
15803 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
15804   $as_echo_n "(cached) " >&6
15805 else
15806   cat >conftest.$ac_ext <<_ACEOF
15807 /* confdefs.h.  */
15808 _ACEOF
15809 cat confdefs.h >>conftest.$ac_ext
15810 cat >>conftest.$ac_ext <<_ACEOF
15811 /* end confdefs.h.  */
15812 #include <sys/types.h>
15813 #ifdef HAVE_SYS_SOCKET_H
15814 #include <sys/socket.h>
15815 #endif
15816
15817
15818 int
15819 main ()
15820 {
15821 static struct sockaddr ac_aggr;
15822 if (ac_aggr.sa_len)
15823 return 0;
15824   ;
15825   return 0;
15826 }
15827 _ACEOF
15828 rm -f conftest.$ac_objext
15829 if { (ac_try="$ac_compile"
15830 case "(($ac_try" in
15831   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15832   *) ac_try_echo=$ac_try;;
15833 esac
15834 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15835 $as_echo "$ac_try_echo") >&5
15836   (eval "$ac_compile") 2>conftest.er1
15837   ac_status=$?
15838   grep -v '^ *+' conftest.er1 >conftest.err
15839   rm -f conftest.er1
15840   cat conftest.err >&5
15841   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15842   (exit $ac_status); } && {
15843          test -z "$ac_c_werror_flag" ||
15844          test ! -s conftest.err
15845        } && test -s conftest.$ac_objext; then
15846   ac_cv_member_struct_sockaddr_sa_len=yes
15847 else
15848   $as_echo "$as_me: failed program was:" >&5
15849 sed 's/^/| /' conftest.$ac_ext >&5
15850
15851         cat >conftest.$ac_ext <<_ACEOF
15852 /* confdefs.h.  */
15853 _ACEOF
15854 cat confdefs.h >>conftest.$ac_ext
15855 cat >>conftest.$ac_ext <<_ACEOF
15856 /* end confdefs.h.  */
15857 #include <sys/types.h>
15858 #ifdef HAVE_SYS_SOCKET_H
15859 #include <sys/socket.h>
15860 #endif
15861
15862
15863 int
15864 main ()
15865 {
15866 static struct sockaddr ac_aggr;
15867 if (sizeof ac_aggr.sa_len)
15868 return 0;
15869   ;
15870   return 0;
15871 }
15872 _ACEOF
15873 rm -f conftest.$ac_objext
15874 if { (ac_try="$ac_compile"
15875 case "(($ac_try" in
15876   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15877   *) ac_try_echo=$ac_try;;
15878 esac
15879 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15880 $as_echo "$ac_try_echo") >&5
15881   (eval "$ac_compile") 2>conftest.er1
15882   ac_status=$?
15883   grep -v '^ *+' conftest.er1 >conftest.err
15884   rm -f conftest.er1
15885   cat conftest.err >&5
15886   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15887   (exit $ac_status); } && {
15888          test -z "$ac_c_werror_flag" ||
15889          test ! -s conftest.err
15890        } && test -s conftest.$ac_objext; then
15891   ac_cv_member_struct_sockaddr_sa_len=yes
15892 else
15893   $as_echo "$as_me: failed program was:" >&5
15894 sed 's/^/| /' conftest.$ac_ext >&5
15895
15896         ac_cv_member_struct_sockaddr_sa_len=no
15897 fi
15898
15899 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15900 fi
15901
15902 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15903 fi
15904 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
15905 $as_echo "$ac_cv_member_struct_sockaddr_sa_len" >&6; }
15906 if test "x$ac_cv_member_struct_sockaddr_sa_len" = x""yes; then
15907
15908 cat >>confdefs.h <<_ACEOF
15909 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
15910 _ACEOF
15911
15912
15913 fi
15914
15915 { $as_echo "$as_me:$LINENO: checking for struct addrinfo" >&5
15916 $as_echo_n "checking for struct addrinfo... " >&6; }
15917 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
15918   $as_echo_n "(cached) " >&6
15919 else
15920   ac_cv_type_struct_addrinfo=no
15921 cat >conftest.$ac_ext <<_ACEOF
15922 /* confdefs.h.  */
15923 _ACEOF
15924 cat confdefs.h >>conftest.$ac_ext
15925 cat >>conftest.$ac_ext <<_ACEOF
15926 /* end confdefs.h.  */
15927 #include <sys/types.h>
15928 #include <sys/socket.h>
15929 #include <netdb.h>
15930
15931
15932 int
15933 main ()
15934 {
15935 if (sizeof (struct addrinfo))
15936        return 0;
15937   ;
15938   return 0;
15939 }
15940 _ACEOF
15941 rm -f conftest.$ac_objext
15942 if { (ac_try="$ac_compile"
15943 case "(($ac_try" in
15944   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15945   *) ac_try_echo=$ac_try;;
15946 esac
15947 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15948 $as_echo "$ac_try_echo") >&5
15949   (eval "$ac_compile") 2>conftest.er1
15950   ac_status=$?
15951   grep -v '^ *+' conftest.er1 >conftest.err
15952   rm -f conftest.er1
15953   cat conftest.err >&5
15954   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15955   (exit $ac_status); } && {
15956          test -z "$ac_c_werror_flag" ||
15957          test ! -s conftest.err
15958        } && test -s conftest.$ac_objext; then
15959   cat >conftest.$ac_ext <<_ACEOF
15960 /* confdefs.h.  */
15961 _ACEOF
15962 cat confdefs.h >>conftest.$ac_ext
15963 cat >>conftest.$ac_ext <<_ACEOF
15964 /* end confdefs.h.  */
15965 #include <sys/types.h>
15966 #include <sys/socket.h>
15967 #include <netdb.h>
15968
15969
15970 int
15971 main ()
15972 {
15973 if (sizeof ((struct addrinfo)))
15974           return 0;
15975   ;
15976   return 0;
15977 }
15978 _ACEOF
15979 rm -f conftest.$ac_objext
15980 if { (ac_try="$ac_compile"
15981 case "(($ac_try" in
15982   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15983   *) ac_try_echo=$ac_try;;
15984 esac
15985 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15986 $as_echo "$ac_try_echo") >&5
15987   (eval "$ac_compile") 2>conftest.er1
15988   ac_status=$?
15989   grep -v '^ *+' conftest.er1 >conftest.err
15990   rm -f conftest.er1
15991   cat conftest.err >&5
15992   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15993   (exit $ac_status); } && {
15994          test -z "$ac_c_werror_flag" ||
15995          test ! -s conftest.err
15996        } && test -s conftest.$ac_objext; then
15997   :
15998 else
15999   $as_echo "$as_me: failed program was:" >&5
16000 sed 's/^/| /' conftest.$ac_ext >&5
16001
16002         ac_cv_type_struct_addrinfo=yes
16003 fi
16004
16005 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16006 else
16007   $as_echo "$as_me: failed program was:" >&5
16008 sed 's/^/| /' conftest.$ac_ext >&5
16009
16010
16011 fi
16012
16013 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16014 fi
16015 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
16016 $as_echo "$ac_cv_type_struct_addrinfo" >&6; }
16017 if test "x$ac_cv_type_struct_addrinfo" = x""yes; then
16018
16019 cat >>confdefs.h <<_ACEOF
16020 #define HAVE_STRUCT_ADDRINFO 1
16021 _ACEOF
16022
16023
16024 fi
16025
16026
16027 { $as_echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
16028 $as_echo_n "checking for struct cmsgcred... " >&6; }
16029 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
16030   $as_echo_n "(cached) " >&6
16031 else
16032   ac_cv_type_struct_cmsgcred=no
16033 cat >conftest.$ac_ext <<_ACEOF
16034 /* confdefs.h.  */
16035 _ACEOF
16036 cat confdefs.h >>conftest.$ac_ext
16037 cat >>conftest.$ac_ext <<_ACEOF
16038 /* end confdefs.h.  */
16039 #include <sys/param.h>
16040 #include <sys/types.h>
16041 #include <sys/socket.h>
16042 #include <sys/ucred.h>
16043
16044 int
16045 main ()
16046 {
16047 if (sizeof (struct cmsgcred))
16048        return 0;
16049   ;
16050   return 0;
16051 }
16052 _ACEOF
16053 rm -f conftest.$ac_objext
16054 if { (ac_try="$ac_compile"
16055 case "(($ac_try" in
16056   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16057   *) ac_try_echo=$ac_try;;
16058 esac
16059 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16060 $as_echo "$ac_try_echo") >&5
16061   (eval "$ac_compile") 2>conftest.er1
16062   ac_status=$?
16063   grep -v '^ *+' conftest.er1 >conftest.err
16064   rm -f conftest.er1
16065   cat conftest.err >&5
16066   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16067   (exit $ac_status); } && {
16068          test -z "$ac_c_werror_flag" ||
16069          test ! -s conftest.err
16070        } && test -s conftest.$ac_objext; then
16071   cat >conftest.$ac_ext <<_ACEOF
16072 /* confdefs.h.  */
16073 _ACEOF
16074 cat confdefs.h >>conftest.$ac_ext
16075 cat >>conftest.$ac_ext <<_ACEOF
16076 /* end confdefs.h.  */
16077 #include <sys/param.h>
16078 #include <sys/types.h>
16079 #include <sys/socket.h>
16080 #include <sys/ucred.h>
16081
16082 int
16083 main ()
16084 {
16085 if (sizeof ((struct cmsgcred)))
16086           return 0;
16087   ;
16088   return 0;
16089 }
16090 _ACEOF
16091 rm -f conftest.$ac_objext
16092 if { (ac_try="$ac_compile"
16093 case "(($ac_try" in
16094   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16095   *) ac_try_echo=$ac_try;;
16096 esac
16097 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16098 $as_echo "$ac_try_echo") >&5
16099   (eval "$ac_compile") 2>conftest.er1
16100   ac_status=$?
16101   grep -v '^ *+' conftest.er1 >conftest.err
16102   rm -f conftest.er1
16103   cat conftest.err >&5
16104   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16105   (exit $ac_status); } && {
16106          test -z "$ac_c_werror_flag" ||
16107          test ! -s conftest.err
16108        } && test -s conftest.$ac_objext; then
16109   :
16110 else
16111   $as_echo "$as_me: failed program was:" >&5
16112 sed 's/^/| /' conftest.$ac_ext >&5
16113
16114         ac_cv_type_struct_cmsgcred=yes
16115 fi
16116
16117 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16118 else
16119   $as_echo "$as_me: failed program was:" >&5
16120 sed 's/^/| /' conftest.$ac_ext >&5
16121
16122
16123 fi
16124
16125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16126 fi
16127 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
16128 $as_echo "$ac_cv_type_struct_cmsgcred" >&6; }
16129 if test "x$ac_cv_type_struct_cmsgcred" = x""yes; then
16130
16131 cat >>confdefs.h <<_ACEOF
16132 #define HAVE_STRUCT_CMSGCRED 1
16133 _ACEOF
16134
16135
16136 fi
16137 { $as_echo "$as_me:$LINENO: checking for struct fcred" >&5
16138 $as_echo_n "checking for struct fcred... " >&6; }
16139 if test "${ac_cv_type_struct_fcred+set}" = set; then
16140   $as_echo_n "(cached) " >&6
16141 else
16142   ac_cv_type_struct_fcred=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 #include <sys/param.h>
16150 #include <sys/types.h>
16151 #include <sys/socket.h>
16152 #include <sys/ucred.h>
16153
16154 int
16155 main ()
16156 {
16157 if (sizeof (struct fcred))
16158        return 0;
16159   ;
16160   return 0;
16161 }
16162 _ACEOF
16163 rm -f conftest.$ac_objext
16164 if { (ac_try="$ac_compile"
16165 case "(($ac_try" in
16166   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16167   *) ac_try_echo=$ac_try;;
16168 esac
16169 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16170 $as_echo "$ac_try_echo") >&5
16171   (eval "$ac_compile") 2>conftest.er1
16172   ac_status=$?
16173   grep -v '^ *+' conftest.er1 >conftest.err
16174   rm -f conftest.er1
16175   cat conftest.err >&5
16176   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16177   (exit $ac_status); } && {
16178          test -z "$ac_c_werror_flag" ||
16179          test ! -s conftest.err
16180        } && test -s conftest.$ac_objext; then
16181   cat >conftest.$ac_ext <<_ACEOF
16182 /* confdefs.h.  */
16183 _ACEOF
16184 cat confdefs.h >>conftest.$ac_ext
16185 cat >>conftest.$ac_ext <<_ACEOF
16186 /* end confdefs.h.  */
16187 #include <sys/param.h>
16188 #include <sys/types.h>
16189 #include <sys/socket.h>
16190 #include <sys/ucred.h>
16191
16192 int
16193 main ()
16194 {
16195 if (sizeof ((struct fcred)))
16196           return 0;
16197   ;
16198   return 0;
16199 }
16200 _ACEOF
16201 rm -f conftest.$ac_objext
16202 if { (ac_try="$ac_compile"
16203 case "(($ac_try" in
16204   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16205   *) ac_try_echo=$ac_try;;
16206 esac
16207 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16208 $as_echo "$ac_try_echo") >&5
16209   (eval "$ac_compile") 2>conftest.er1
16210   ac_status=$?
16211   grep -v '^ *+' conftest.er1 >conftest.err
16212   rm -f conftest.er1
16213   cat conftest.err >&5
16214   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16215   (exit $ac_status); } && {
16216          test -z "$ac_c_werror_flag" ||
16217          test ! -s conftest.err
16218        } && test -s conftest.$ac_objext; then
16219   :
16220 else
16221   $as_echo "$as_me: failed program was:" >&5
16222 sed 's/^/| /' conftest.$ac_ext >&5
16223
16224         ac_cv_type_struct_fcred=yes
16225 fi
16226
16227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16228 else
16229   $as_echo "$as_me: failed program was:" >&5
16230 sed 's/^/| /' conftest.$ac_ext >&5
16231
16232
16233 fi
16234
16235 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16236 fi
16237 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
16238 $as_echo "$ac_cv_type_struct_fcred" >&6; }
16239 if test "x$ac_cv_type_struct_fcred" = x""yes; then
16240
16241 cat >>confdefs.h <<_ACEOF
16242 #define HAVE_STRUCT_FCRED 1
16243 _ACEOF
16244
16245
16246 fi
16247 { $as_echo "$as_me:$LINENO: checking for struct sockcred" >&5
16248 $as_echo_n "checking for struct sockcred... " >&6; }
16249 if test "${ac_cv_type_struct_sockcred+set}" = set; then
16250   $as_echo_n "(cached) " >&6
16251 else
16252   ac_cv_type_struct_sockcred=no
16253 cat >conftest.$ac_ext <<_ACEOF
16254 /* confdefs.h.  */
16255 _ACEOF
16256 cat confdefs.h >>conftest.$ac_ext
16257 cat >>conftest.$ac_ext <<_ACEOF
16258 /* end confdefs.h.  */
16259 #include <sys/param.h>
16260 #include <sys/types.h>
16261 #include <sys/socket.h>
16262 #include <sys/ucred.h>
16263
16264 int
16265 main ()
16266 {
16267 if (sizeof (struct sockcred))
16268        return 0;
16269   ;
16270   return 0;
16271 }
16272 _ACEOF
16273 rm -f conftest.$ac_objext
16274 if { (ac_try="$ac_compile"
16275 case "(($ac_try" in
16276   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16277   *) ac_try_echo=$ac_try;;
16278 esac
16279 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16280 $as_echo "$ac_try_echo") >&5
16281   (eval "$ac_compile") 2>conftest.er1
16282   ac_status=$?
16283   grep -v '^ *+' conftest.er1 >conftest.err
16284   rm -f conftest.er1
16285   cat conftest.err >&5
16286   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16287   (exit $ac_status); } && {
16288          test -z "$ac_c_werror_flag" ||
16289          test ! -s conftest.err
16290        } && test -s conftest.$ac_objext; then
16291   cat >conftest.$ac_ext <<_ACEOF
16292 /* confdefs.h.  */
16293 _ACEOF
16294 cat confdefs.h >>conftest.$ac_ext
16295 cat >>conftest.$ac_ext <<_ACEOF
16296 /* end confdefs.h.  */
16297 #include <sys/param.h>
16298 #include <sys/types.h>
16299 #include <sys/socket.h>
16300 #include <sys/ucred.h>
16301
16302 int
16303 main ()
16304 {
16305 if (sizeof ((struct sockcred)))
16306           return 0;
16307   ;
16308   return 0;
16309 }
16310 _ACEOF
16311 rm -f conftest.$ac_objext
16312 if { (ac_try="$ac_compile"
16313 case "(($ac_try" in
16314   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16315   *) ac_try_echo=$ac_try;;
16316 esac
16317 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16318 $as_echo "$ac_try_echo") >&5
16319   (eval "$ac_compile") 2>conftest.er1
16320   ac_status=$?
16321   grep -v '^ *+' conftest.er1 >conftest.err
16322   rm -f conftest.er1
16323   cat conftest.err >&5
16324   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16325   (exit $ac_status); } && {
16326          test -z "$ac_c_werror_flag" ||
16327          test ! -s conftest.err
16328        } && test -s conftest.$ac_objext; then
16329   :
16330 else
16331   $as_echo "$as_me: failed program was:" >&5
16332 sed 's/^/| /' conftest.$ac_ext >&5
16333
16334         ac_cv_type_struct_sockcred=yes
16335 fi
16336
16337 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16338 else
16339   $as_echo "$as_me: failed program was:" >&5
16340 sed 's/^/| /' conftest.$ac_ext >&5
16341
16342
16343 fi
16344
16345 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16346 fi
16347 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
16348 $as_echo "$ac_cv_type_struct_sockcred" >&6; }
16349 if test "x$ac_cv_type_struct_sockcred" = x""yes; then
16350
16351 cat >>confdefs.h <<_ACEOF
16352 #define HAVE_STRUCT_SOCKCRED 1
16353 _ACEOF
16354
16355
16356 fi
16357
16358
16359 { $as_echo "$as_me:$LINENO: checking for struct option" >&5
16360 $as_echo_n "checking for struct option... " >&6; }
16361 if test "${ac_cv_type_struct_option+set}" = set; then
16362   $as_echo_n "(cached) " >&6
16363 else
16364   ac_cv_type_struct_option=no
16365 cat >conftest.$ac_ext <<_ACEOF
16366 /* confdefs.h.  */
16367 _ACEOF
16368 cat confdefs.h >>conftest.$ac_ext
16369 cat >>conftest.$ac_ext <<_ACEOF
16370 /* end confdefs.h.  */
16371 #ifdef HAVE_GETOPT_H
16372 #include <getopt.h>
16373 #endif
16374
16375 int
16376 main ()
16377 {
16378 if (sizeof (struct option))
16379        return 0;
16380   ;
16381   return 0;
16382 }
16383 _ACEOF
16384 rm -f conftest.$ac_objext
16385 if { (ac_try="$ac_compile"
16386 case "(($ac_try" in
16387   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16388   *) ac_try_echo=$ac_try;;
16389 esac
16390 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16391 $as_echo "$ac_try_echo") >&5
16392   (eval "$ac_compile") 2>conftest.er1
16393   ac_status=$?
16394   grep -v '^ *+' conftest.er1 >conftest.err
16395   rm -f conftest.er1
16396   cat conftest.err >&5
16397   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16398   (exit $ac_status); } && {
16399          test -z "$ac_c_werror_flag" ||
16400          test ! -s conftest.err
16401        } && test -s conftest.$ac_objext; then
16402   cat >conftest.$ac_ext <<_ACEOF
16403 /* confdefs.h.  */
16404 _ACEOF
16405 cat confdefs.h >>conftest.$ac_ext
16406 cat >>conftest.$ac_ext <<_ACEOF
16407 /* end confdefs.h.  */
16408 #ifdef HAVE_GETOPT_H
16409 #include <getopt.h>
16410 #endif
16411
16412 int
16413 main ()
16414 {
16415 if (sizeof ((struct option)))
16416           return 0;
16417   ;
16418   return 0;
16419 }
16420 _ACEOF
16421 rm -f conftest.$ac_objext
16422 if { (ac_try="$ac_compile"
16423 case "(($ac_try" in
16424   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16425   *) ac_try_echo=$ac_try;;
16426 esac
16427 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16428 $as_echo "$ac_try_echo") >&5
16429   (eval "$ac_compile") 2>conftest.er1
16430   ac_status=$?
16431   grep -v '^ *+' conftest.er1 >conftest.err
16432   rm -f conftest.er1
16433   cat conftest.err >&5
16434   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16435   (exit $ac_status); } && {
16436          test -z "$ac_c_werror_flag" ||
16437          test ! -s conftest.err
16438        } && test -s conftest.$ac_objext; then
16439   :
16440 else
16441   $as_echo "$as_me: failed program was:" >&5
16442 sed 's/^/| /' conftest.$ac_ext >&5
16443
16444         ac_cv_type_struct_option=yes
16445 fi
16446
16447 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16448 else
16449   $as_echo "$as_me: failed program was:" >&5
16450 sed 's/^/| /' conftest.$ac_ext >&5
16451
16452
16453 fi
16454
16455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16456 fi
16457 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
16458 $as_echo "$ac_cv_type_struct_option" >&6; }
16459 if test "x$ac_cv_type_struct_option" = x""yes; then
16460
16461 cat >>confdefs.h <<_ACEOF
16462 #define HAVE_STRUCT_OPTION 1
16463 _ACEOF
16464
16465
16466 fi
16467
16468
16469 if test "$with_zlib" = yes; then
16470   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
16471   # did not).  While we could work around the lack of z_streamp, it
16472   # seems unwise to encourage people to use such old zlib versions...
16473   { $as_echo "$as_me:$LINENO: checking for z_streamp" >&5
16474 $as_echo_n "checking for z_streamp... " >&6; }
16475 if test "${ac_cv_type_z_streamp+set}" = set; then
16476   $as_echo_n "(cached) " >&6
16477 else
16478   ac_cv_type_z_streamp=no
16479 cat >conftest.$ac_ext <<_ACEOF
16480 /* confdefs.h.  */
16481 _ACEOF
16482 cat confdefs.h >>conftest.$ac_ext
16483 cat >>conftest.$ac_ext <<_ACEOF
16484 /* end confdefs.h.  */
16485 #include <zlib.h>
16486
16487 int
16488 main ()
16489 {
16490 if (sizeof (z_streamp))
16491        return 0;
16492   ;
16493   return 0;
16494 }
16495 _ACEOF
16496 rm -f conftest.$ac_objext
16497 if { (ac_try="$ac_compile"
16498 case "(($ac_try" in
16499   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16500   *) ac_try_echo=$ac_try;;
16501 esac
16502 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16503 $as_echo "$ac_try_echo") >&5
16504   (eval "$ac_compile") 2>conftest.er1
16505   ac_status=$?
16506   grep -v '^ *+' conftest.er1 >conftest.err
16507   rm -f conftest.er1
16508   cat conftest.err >&5
16509   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16510   (exit $ac_status); } && {
16511          test -z "$ac_c_werror_flag" ||
16512          test ! -s conftest.err
16513        } && test -s conftest.$ac_objext; then
16514   cat >conftest.$ac_ext <<_ACEOF
16515 /* confdefs.h.  */
16516 _ACEOF
16517 cat confdefs.h >>conftest.$ac_ext
16518 cat >>conftest.$ac_ext <<_ACEOF
16519 /* end confdefs.h.  */
16520 #include <zlib.h>
16521
16522 int
16523 main ()
16524 {
16525 if (sizeof ((z_streamp)))
16526           return 0;
16527   ;
16528   return 0;
16529 }
16530 _ACEOF
16531 rm -f conftest.$ac_objext
16532 if { (ac_try="$ac_compile"
16533 case "(($ac_try" in
16534   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16535   *) ac_try_echo=$ac_try;;
16536 esac
16537 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16538 $as_echo "$ac_try_echo") >&5
16539   (eval "$ac_compile") 2>conftest.er1
16540   ac_status=$?
16541   grep -v '^ *+' conftest.er1 >conftest.err
16542   rm -f conftest.er1
16543   cat conftest.err >&5
16544   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16545   (exit $ac_status); } && {
16546          test -z "$ac_c_werror_flag" ||
16547          test ! -s conftest.err
16548        } && test -s conftest.$ac_objext; then
16549   :
16550 else
16551   $as_echo "$as_me: failed program was:" >&5
16552 sed 's/^/| /' conftest.$ac_ext >&5
16553
16554         ac_cv_type_z_streamp=yes
16555 fi
16556
16557 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16558 else
16559   $as_echo "$as_me: failed program was:" >&5
16560 sed 's/^/| /' conftest.$ac_ext >&5
16561
16562
16563 fi
16564
16565 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16566 fi
16567 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
16568 $as_echo "$ac_cv_type_z_streamp" >&6; }
16569 if test "x$ac_cv_type_z_streamp" = x""yes; then
16570   :
16571 else
16572   { { $as_echo "$as_me:$LINENO: error: zlib version is too old
16573 Use --without-zlib to disable zlib support." >&5
16574 $as_echo "$as_me: error: zlib version is too old
16575 Use --without-zlib to disable zlib support." >&2;}
16576    { (exit 1); exit 1; }; }
16577 fi
16578
16579 fi
16580
16581 if test "$with_krb5" = yes; then
16582 # Check for differences between MIT and Heimdal (KTH) releases
16583   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
16584 $as_echo_n "checking for krb5_ticket.enc_part2... " >&6; }
16585 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
16586   $as_echo_n "(cached) " >&6
16587 else
16588   cat >conftest.$ac_ext <<_ACEOF
16589 /* confdefs.h.  */
16590 _ACEOF
16591 cat confdefs.h >>conftest.$ac_ext
16592 cat >>conftest.$ac_ext <<_ACEOF
16593 /* end confdefs.h.  */
16594 #include <krb5.h>
16595
16596 int
16597 main ()
16598 {
16599 static krb5_ticket ac_aggr;
16600 if (ac_aggr.enc_part2)
16601 return 0;
16602   ;
16603   return 0;
16604 }
16605 _ACEOF
16606 rm -f conftest.$ac_objext
16607 if { (ac_try="$ac_compile"
16608 case "(($ac_try" in
16609   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16610   *) ac_try_echo=$ac_try;;
16611 esac
16612 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16613 $as_echo "$ac_try_echo") >&5
16614   (eval "$ac_compile") 2>conftest.er1
16615   ac_status=$?
16616   grep -v '^ *+' conftest.er1 >conftest.err
16617   rm -f conftest.er1
16618   cat conftest.err >&5
16619   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16620   (exit $ac_status); } && {
16621          test -z "$ac_c_werror_flag" ||
16622          test ! -s conftest.err
16623        } && test -s conftest.$ac_objext; then
16624   ac_cv_member_krb5_ticket_enc_part2=yes
16625 else
16626   $as_echo "$as_me: failed program was:" >&5
16627 sed 's/^/| /' conftest.$ac_ext >&5
16628
16629         cat >conftest.$ac_ext <<_ACEOF
16630 /* confdefs.h.  */
16631 _ACEOF
16632 cat confdefs.h >>conftest.$ac_ext
16633 cat >>conftest.$ac_ext <<_ACEOF
16634 /* end confdefs.h.  */
16635 #include <krb5.h>
16636
16637 int
16638 main ()
16639 {
16640 static krb5_ticket ac_aggr;
16641 if (sizeof ac_aggr.enc_part2)
16642 return 0;
16643   ;
16644   return 0;
16645 }
16646 _ACEOF
16647 rm -f conftest.$ac_objext
16648 if { (ac_try="$ac_compile"
16649 case "(($ac_try" in
16650   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16651   *) ac_try_echo=$ac_try;;
16652 esac
16653 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16654 $as_echo "$ac_try_echo") >&5
16655   (eval "$ac_compile") 2>conftest.er1
16656   ac_status=$?
16657   grep -v '^ *+' conftest.er1 >conftest.err
16658   rm -f conftest.er1
16659   cat conftest.err >&5
16660   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16661   (exit $ac_status); } && {
16662          test -z "$ac_c_werror_flag" ||
16663          test ! -s conftest.err
16664        } && test -s conftest.$ac_objext; then
16665   ac_cv_member_krb5_ticket_enc_part2=yes
16666 else
16667   $as_echo "$as_me: failed program was:" >&5
16668 sed 's/^/| /' conftest.$ac_ext >&5
16669
16670         ac_cv_member_krb5_ticket_enc_part2=no
16671 fi
16672
16673 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16674 fi
16675
16676 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16677 fi
16678 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
16679 $as_echo "$ac_cv_member_krb5_ticket_enc_part2" >&6; }
16680 if test "x$ac_cv_member_krb5_ticket_enc_part2" = x""yes; then
16681
16682 cat >>confdefs.h <<_ACEOF
16683 #define HAVE_KRB5_TICKET_ENC_PART2 1
16684 _ACEOF
16685
16686
16687 else
16688   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
16689 $as_echo_n "checking for krb5_ticket.client... " >&6; }
16690 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
16691   $as_echo_n "(cached) " >&6
16692 else
16693   cat >conftest.$ac_ext <<_ACEOF
16694 /* confdefs.h.  */
16695 _ACEOF
16696 cat confdefs.h >>conftest.$ac_ext
16697 cat >>conftest.$ac_ext <<_ACEOF
16698 /* end confdefs.h.  */
16699 #include <krb5.h>
16700
16701 int
16702 main ()
16703 {
16704 static krb5_ticket ac_aggr;
16705 if (ac_aggr.client)
16706 return 0;
16707   ;
16708   return 0;
16709 }
16710 _ACEOF
16711 rm -f conftest.$ac_objext
16712 if { (ac_try="$ac_compile"
16713 case "(($ac_try" in
16714   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16715   *) ac_try_echo=$ac_try;;
16716 esac
16717 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16718 $as_echo "$ac_try_echo") >&5
16719   (eval "$ac_compile") 2>conftest.er1
16720   ac_status=$?
16721   grep -v '^ *+' conftest.er1 >conftest.err
16722   rm -f conftest.er1
16723   cat conftest.err >&5
16724   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16725   (exit $ac_status); } && {
16726          test -z "$ac_c_werror_flag" ||
16727          test ! -s conftest.err
16728        } && test -s conftest.$ac_objext; then
16729   ac_cv_member_krb5_ticket_client=yes
16730 else
16731   $as_echo "$as_me: failed program was:" >&5
16732 sed 's/^/| /' conftest.$ac_ext >&5
16733
16734         cat >conftest.$ac_ext <<_ACEOF
16735 /* confdefs.h.  */
16736 _ACEOF
16737 cat confdefs.h >>conftest.$ac_ext
16738 cat >>conftest.$ac_ext <<_ACEOF
16739 /* end confdefs.h.  */
16740 #include <krb5.h>
16741
16742 int
16743 main ()
16744 {
16745 static krb5_ticket ac_aggr;
16746 if (sizeof ac_aggr.client)
16747 return 0;
16748   ;
16749   return 0;
16750 }
16751 _ACEOF
16752 rm -f conftest.$ac_objext
16753 if { (ac_try="$ac_compile"
16754 case "(($ac_try" in
16755   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16756   *) ac_try_echo=$ac_try;;
16757 esac
16758 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16759 $as_echo "$ac_try_echo") >&5
16760   (eval "$ac_compile") 2>conftest.er1
16761   ac_status=$?
16762   grep -v '^ *+' conftest.er1 >conftest.err
16763   rm -f conftest.er1
16764   cat conftest.err >&5
16765   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16766   (exit $ac_status); } && {
16767          test -z "$ac_c_werror_flag" ||
16768          test ! -s conftest.err
16769        } && test -s conftest.$ac_objext; then
16770   ac_cv_member_krb5_ticket_client=yes
16771 else
16772   $as_echo "$as_me: failed program was:" >&5
16773 sed 's/^/| /' conftest.$ac_ext >&5
16774
16775         ac_cv_member_krb5_ticket_client=no
16776 fi
16777
16778 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16779 fi
16780
16781 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16782 fi
16783 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
16784 $as_echo "$ac_cv_member_krb5_ticket_client" >&6; }
16785 if test "x$ac_cv_member_krb5_ticket_client" = x""yes; then
16786
16787 cat >>confdefs.h <<_ACEOF
16788 #define HAVE_KRB5_TICKET_CLIENT 1
16789 _ACEOF
16790
16791
16792 else
16793   { { $as_echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
16794 $as_echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
16795    { (exit 1); exit 1; }; }
16796 fi
16797
16798 fi
16799
16800   { $as_echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
16801 $as_echo_n "checking for krb5_error.text.data... " >&6; }
16802 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
16803   $as_echo_n "(cached) " >&6
16804 else
16805   cat >conftest.$ac_ext <<_ACEOF
16806 /* confdefs.h.  */
16807 _ACEOF
16808 cat confdefs.h >>conftest.$ac_ext
16809 cat >>conftest.$ac_ext <<_ACEOF
16810 /* end confdefs.h.  */
16811 #include <krb5.h>
16812
16813 int
16814 main ()
16815 {
16816 static krb5_error ac_aggr;
16817 if (ac_aggr.text.data)
16818 return 0;
16819   ;
16820   return 0;
16821 }
16822 _ACEOF
16823 rm -f conftest.$ac_objext
16824 if { (ac_try="$ac_compile"
16825 case "(($ac_try" in
16826   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16827   *) ac_try_echo=$ac_try;;
16828 esac
16829 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16830 $as_echo "$ac_try_echo") >&5
16831   (eval "$ac_compile") 2>conftest.er1
16832   ac_status=$?
16833   grep -v '^ *+' conftest.er1 >conftest.err
16834   rm -f conftest.er1
16835   cat conftest.err >&5
16836   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16837   (exit $ac_status); } && {
16838          test -z "$ac_c_werror_flag" ||
16839          test ! -s conftest.err
16840        } && test -s conftest.$ac_objext; then
16841   ac_cv_member_krb5_error_text_data=yes
16842 else
16843   $as_echo "$as_me: failed program was:" >&5
16844 sed 's/^/| /' conftest.$ac_ext >&5
16845
16846         cat >conftest.$ac_ext <<_ACEOF
16847 /* confdefs.h.  */
16848 _ACEOF
16849 cat confdefs.h >>conftest.$ac_ext
16850 cat >>conftest.$ac_ext <<_ACEOF
16851 /* end confdefs.h.  */
16852 #include <krb5.h>
16853
16854 int
16855 main ()
16856 {
16857 static krb5_error ac_aggr;
16858 if (sizeof ac_aggr.text.data)
16859 return 0;
16860   ;
16861   return 0;
16862 }
16863 _ACEOF
16864 rm -f conftest.$ac_objext
16865 if { (ac_try="$ac_compile"
16866 case "(($ac_try" in
16867   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16868   *) ac_try_echo=$ac_try;;
16869 esac
16870 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16871 $as_echo "$ac_try_echo") >&5
16872   (eval "$ac_compile") 2>conftest.er1
16873   ac_status=$?
16874   grep -v '^ *+' conftest.er1 >conftest.err
16875   rm -f conftest.er1
16876   cat conftest.err >&5
16877   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16878   (exit $ac_status); } && {
16879          test -z "$ac_c_werror_flag" ||
16880          test ! -s conftest.err
16881        } && test -s conftest.$ac_objext; then
16882   ac_cv_member_krb5_error_text_data=yes
16883 else
16884   $as_echo "$as_me: failed program was:" >&5
16885 sed 's/^/| /' conftest.$ac_ext >&5
16886
16887         ac_cv_member_krb5_error_text_data=no
16888 fi
16889
16890 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16891 fi
16892
16893 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16894 fi
16895 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
16896 $as_echo "$ac_cv_member_krb5_error_text_data" >&6; }
16897 if test "x$ac_cv_member_krb5_error_text_data" = x""yes; then
16898
16899 cat >>confdefs.h <<_ACEOF
16900 #define HAVE_KRB5_ERROR_TEXT_DATA 1
16901 _ACEOF
16902
16903
16904 else
16905   { $as_echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
16906 $as_echo_n "checking for krb5_error.e_data... " >&6; }
16907 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
16908   $as_echo_n "(cached) " >&6
16909 else
16910   cat >conftest.$ac_ext <<_ACEOF
16911 /* confdefs.h.  */
16912 _ACEOF
16913 cat confdefs.h >>conftest.$ac_ext
16914 cat >>conftest.$ac_ext <<_ACEOF
16915 /* end confdefs.h.  */
16916 #include <krb5.h>
16917
16918 int
16919 main ()
16920 {
16921 static krb5_error ac_aggr;
16922 if (ac_aggr.e_data)
16923 return 0;
16924   ;
16925   return 0;
16926 }
16927 _ACEOF
16928 rm -f conftest.$ac_objext
16929 if { (ac_try="$ac_compile"
16930 case "(($ac_try" in
16931   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16932   *) ac_try_echo=$ac_try;;
16933 esac
16934 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16935 $as_echo "$ac_try_echo") >&5
16936   (eval "$ac_compile") 2>conftest.er1
16937   ac_status=$?
16938   grep -v '^ *+' conftest.er1 >conftest.err
16939   rm -f conftest.er1
16940   cat conftest.err >&5
16941   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16942   (exit $ac_status); } && {
16943          test -z "$ac_c_werror_flag" ||
16944          test ! -s conftest.err
16945        } && test -s conftest.$ac_objext; then
16946   ac_cv_member_krb5_error_e_data=yes
16947 else
16948   $as_echo "$as_me: failed program was:" >&5
16949 sed 's/^/| /' conftest.$ac_ext >&5
16950
16951         cat >conftest.$ac_ext <<_ACEOF
16952 /* confdefs.h.  */
16953 _ACEOF
16954 cat confdefs.h >>conftest.$ac_ext
16955 cat >>conftest.$ac_ext <<_ACEOF
16956 /* end confdefs.h.  */
16957 #include <krb5.h>
16958
16959 int
16960 main ()
16961 {
16962 static krb5_error ac_aggr;
16963 if (sizeof ac_aggr.e_data)
16964 return 0;
16965   ;
16966   return 0;
16967 }
16968 _ACEOF
16969 rm -f conftest.$ac_objext
16970 if { (ac_try="$ac_compile"
16971 case "(($ac_try" in
16972   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16973   *) ac_try_echo=$ac_try;;
16974 esac
16975 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16976 $as_echo "$ac_try_echo") >&5
16977   (eval "$ac_compile") 2>conftest.er1
16978   ac_status=$?
16979   grep -v '^ *+' conftest.er1 >conftest.err
16980   rm -f conftest.er1
16981   cat conftest.err >&5
16982   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16983   (exit $ac_status); } && {
16984          test -z "$ac_c_werror_flag" ||
16985          test ! -s conftest.err
16986        } && test -s conftest.$ac_objext; then
16987   ac_cv_member_krb5_error_e_data=yes
16988 else
16989   $as_echo "$as_me: failed program was:" >&5
16990 sed 's/^/| /' conftest.$ac_ext >&5
16991
16992         ac_cv_member_krb5_error_e_data=no
16993 fi
16994
16995 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16996 fi
16997
16998 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16999 fi
17000 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
17001 $as_echo "$ac_cv_member_krb5_error_e_data" >&6; }
17002 if test "x$ac_cv_member_krb5_error_e_data" = x""yes; then
17003
17004 cat >>confdefs.h <<_ACEOF
17005 #define HAVE_KRB5_ERROR_E_DATA 1
17006 _ACEOF
17007
17008
17009 else
17010   { { $as_echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
17011 $as_echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
17012    { (exit 1); exit 1; }; }
17013 fi
17014
17015 fi
17016
17017
17018 # Win32 requires headers to be loaded for __stdcall, so can't use
17019 # AC_CHECK_FUNCS here.
17020   { $as_echo "$as_me:$LINENO: checking for krb5_free_unparsed_name" >&5
17021 $as_echo_n "checking for krb5_free_unparsed_name... " >&6; }
17022   cat >conftest.$ac_ext <<_ACEOF
17023 /* confdefs.h.  */
17024 _ACEOF
17025 cat confdefs.h >>conftest.$ac_ext
17026 cat >>conftest.$ac_ext <<_ACEOF
17027 /* end confdefs.h.  */
17028 #include <krb5.h>
17029 int
17030 main ()
17031 {
17032 krb5_free_unparsed_name(NULL,NULL);
17033   ;
17034   return 0;
17035 }
17036 _ACEOF
17037 rm -f conftest.$ac_objext conftest$ac_exeext
17038 if { (ac_try="$ac_link"
17039 case "(($ac_try" in
17040   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17041   *) ac_try_echo=$ac_try;;
17042 esac
17043 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17044 $as_echo "$ac_try_echo") >&5
17045   (eval "$ac_link") 2>conftest.er1
17046   ac_status=$?
17047   grep -v '^ *+' conftest.er1 >conftest.err
17048   rm -f conftest.er1
17049   cat conftest.err >&5
17050   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17051   (exit $ac_status); } && {
17052          test -z "$ac_c_werror_flag" ||
17053          test ! -s conftest.err
17054        } && test -s conftest$ac_exeext && {
17055          test "$cross_compiling" = yes ||
17056          $as_test_x conftest$ac_exeext
17057        }; then
17058
17059 cat >>confdefs.h <<\_ACEOF
17060 #define HAVE_KRB5_FREE_UNPARSED_NAME 1
17061 _ACEOF
17062
17063 { $as_echo "$as_me:$LINENO: result: yes" >&5
17064 $as_echo "yes" >&6; }
17065 else
17066   $as_echo "$as_me: failed program was:" >&5
17067 sed 's/^/| /' conftest.$ac_ext >&5
17068
17069         { $as_echo "$as_me:$LINENO: result: no" >&5
17070 $as_echo "no" >&6; }
17071 fi
17072
17073 rm -rf conftest.dSYM
17074 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17075       conftest$ac_exeext conftest.$ac_ext
17076 fi
17077
17078
17079 ##
17080 ## Functions, global variables
17081 ##
17082
17083 { $as_echo "$as_me:$LINENO: checking for int timezone" >&5
17084 $as_echo_n "checking for int timezone... " >&6; }
17085 if test "${pgac_cv_var_int_timezone+set}" = set; then
17086   $as_echo_n "(cached) " >&6
17087 else
17088   cat >conftest.$ac_ext <<_ACEOF
17089 /* confdefs.h.  */
17090 _ACEOF
17091 cat confdefs.h >>conftest.$ac_ext
17092 cat >>conftest.$ac_ext <<_ACEOF
17093 /* end confdefs.h.  */
17094 #include <time.h>
17095 int res;
17096 int
17097 main ()
17098 {
17099 #ifndef __CYGWIN__
17100 res = timezone / 60;
17101 #else
17102 res = _timezone / 60;
17103 #endif
17104   ;
17105   return 0;
17106 }
17107 _ACEOF
17108 rm -f conftest.$ac_objext conftest$ac_exeext
17109 if { (ac_try="$ac_link"
17110 case "(($ac_try" in
17111   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17112   *) ac_try_echo=$ac_try;;
17113 esac
17114 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17115 $as_echo "$ac_try_echo") >&5
17116   (eval "$ac_link") 2>conftest.er1
17117   ac_status=$?
17118   grep -v '^ *+' conftest.er1 >conftest.err
17119   rm -f conftest.er1
17120   cat conftest.err >&5
17121   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17122   (exit $ac_status); } && {
17123          test -z "$ac_c_werror_flag" ||
17124          test ! -s conftest.err
17125        } && test -s conftest$ac_exeext && {
17126          test "$cross_compiling" = yes ||
17127          $as_test_x conftest$ac_exeext
17128        }; then
17129   pgac_cv_var_int_timezone=yes
17130 else
17131   $as_echo "$as_me: failed program was:" >&5
17132 sed 's/^/| /' conftest.$ac_ext >&5
17133
17134         pgac_cv_var_int_timezone=no
17135 fi
17136
17137 rm -rf conftest.dSYM
17138 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17139       conftest$ac_exeext conftest.$ac_ext
17140 fi
17141 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
17142 $as_echo "$pgac_cv_var_int_timezone" >&6; }
17143 if test x"$pgac_cv_var_int_timezone" = xyes ; then
17144
17145 cat >>confdefs.h <<\_ACEOF
17146 #define HAVE_INT_TIMEZONE /**/
17147 _ACEOF
17148
17149 fi
17150 { $as_echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
17151 $as_echo_n "checking types of arguments for accept()... " >&6; }
17152  if test "${ac_cv_func_accept_return+set}" = set; then
17153   $as_echo_n "(cached) " >&6
17154 else
17155    if test "${ac_cv_func_accept_arg1+set}" = set; then
17156   $as_echo_n "(cached) " >&6
17157 else
17158     if test "${ac_cv_func_accept_arg2+set}" = set; then
17159   $as_echo_n "(cached) " >&6
17160 else
17161      if test "${ac_cv_func_accept_arg3+set}" = set; then
17162   $as_echo_n "(cached) " >&6
17163 else
17164       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
17165       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
17166        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
17167         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
17168          cat >conftest.$ac_ext <<_ACEOF
17169 /* confdefs.h.  */
17170 _ACEOF
17171 cat confdefs.h >>conftest.$ac_ext
17172 cat >>conftest.$ac_ext <<_ACEOF
17173 /* end confdefs.h.  */
17174 #ifdef HAVE_SYS_TYPES_H
17175 #include <sys/types.h>
17176 #endif
17177 #ifdef HAVE_SYS_SOCKET_H
17178 #include <sys/socket.h>
17179 #endif
17180 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
17181 int
17182 main ()
17183 {
17184
17185   ;
17186   return 0;
17187 }
17188 _ACEOF
17189 rm -f conftest.$ac_objext
17190 if { (ac_try="$ac_compile"
17191 case "(($ac_try" in
17192   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17193   *) ac_try_echo=$ac_try;;
17194 esac
17195 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17196 $as_echo "$ac_try_echo") >&5
17197   (eval "$ac_compile") 2>conftest.er1
17198   ac_status=$?
17199   grep -v '^ *+' conftest.er1 >conftest.err
17200   rm -f conftest.er1
17201   cat conftest.err >&5
17202   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17203   (exit $ac_status); } && {
17204          test -z "$ac_c_werror_flag" ||
17205          test ! -s conftest.err
17206        } && test -s conftest.$ac_objext; then
17207   ac_not_found=no; break 4
17208 else
17209   $as_echo "$as_me: failed program was:" >&5
17210 sed 's/^/| /' conftest.$ac_ext >&5
17211
17212         ac_not_found=yes
17213 fi
17214
17215 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17216        done
17217       done
17218      done
17219     done
17220     if test "$ac_not_found" = yes; then
17221       { { $as_echo "$as_me:$LINENO: error: could not determine argument types" >&5
17222 $as_echo "$as_me: error: could not determine argument types" >&2;}
17223    { (exit 1); exit 1; }; }
17224     fi
17225     if test "$ac_cv_func_accept_arg3" = "void"; then
17226       ac_cv_func_accept_arg3=int
17227     fi
17228
17229 fi
17230
17231 fi
17232
17233 fi
17234
17235 fi
17236  { $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
17237 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
17238
17239 cat >>confdefs.h <<_ACEOF
17240 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
17241 _ACEOF
17242
17243
17244 cat >>confdefs.h <<_ACEOF
17245 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
17246 _ACEOF
17247
17248
17249 cat >>confdefs.h <<_ACEOF
17250 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
17251 _ACEOF
17252
17253
17254 cat >>confdefs.h <<_ACEOF
17255 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
17256 _ACEOF
17257
17258
17259 { $as_echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
17260 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
17261 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
17262   $as_echo_n "(cached) " >&6
17263 else
17264   cat >conftest.$ac_ext <<_ACEOF
17265 /* confdefs.h.  */
17266 _ACEOF
17267 cat confdefs.h >>conftest.$ac_ext
17268 cat >>conftest.$ac_ext <<_ACEOF
17269 /* end confdefs.h.  */
17270 #include <sys/time.h>
17271 int
17272 main ()
17273 {
17274 struct timeval *tp;
17275 struct timezone *tzp;
17276 gettimeofday(tp,tzp);
17277   ;
17278   return 0;
17279 }
17280 _ACEOF
17281 rm -f conftest.$ac_objext
17282 if { (ac_try="$ac_compile"
17283 case "(($ac_try" in
17284   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17285   *) ac_try_echo=$ac_try;;
17286 esac
17287 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17288 $as_echo "$ac_try_echo") >&5
17289   (eval "$ac_compile") 2>conftest.er1
17290   ac_status=$?
17291   grep -v '^ *+' conftest.er1 >conftest.err
17292   rm -f conftest.er1
17293   cat conftest.err >&5
17294   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17295   (exit $ac_status); } && {
17296          test -z "$ac_c_werror_flag" ||
17297          test ! -s conftest.err
17298        } && test -s conftest.$ac_objext; then
17299   pgac_cv_func_gettimeofday_1arg=no
17300 else
17301   $as_echo "$as_me: failed program was:" >&5
17302 sed 's/^/| /' conftest.$ac_ext >&5
17303
17304         pgac_cv_func_gettimeofday_1arg=yes
17305 fi
17306
17307 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17308 fi
17309 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
17310 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
17311 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
17312
17313 cat >>confdefs.h <<\_ACEOF
17314 #define GETTIMEOFDAY_1ARG /**/
17315 _ACEOF
17316
17317 fi
17318
17319
17320
17321
17322
17323
17324
17325
17326
17327
17328
17329
17330
17331
17332
17333
17334
17335
17336
17337
17338
17339
17340
17341
17342
17343 for ac_func in cbrt dlopen fcvt fdatasync getifaddrs getpeereid getpeerucred getrlimit memmove poll pstat readlink setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
17344 do
17345 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17346 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
17347 $as_echo_n "checking for $ac_func... " >&6; }
17348 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17349   $as_echo_n "(cached) " >&6
17350 else
17351   cat >conftest.$ac_ext <<_ACEOF
17352 /* confdefs.h.  */
17353 _ACEOF
17354 cat confdefs.h >>conftest.$ac_ext
17355 cat >>conftest.$ac_ext <<_ACEOF
17356 /* end confdefs.h.  */
17357 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17358    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17359 #define $ac_func innocuous_$ac_func
17360
17361 /* System header to define __stub macros and hopefully few prototypes,
17362     which can conflict with char $ac_func (); below.
17363     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17364     <limits.h> exists even on freestanding compilers.  */
17365
17366 #ifdef __STDC__
17367 # include <limits.h>
17368 #else
17369 # include <assert.h>
17370 #endif
17371
17372 #undef $ac_func
17373
17374 /* Override any GCC internal prototype to avoid an error.
17375    Use char because int might match the return type of a GCC
17376    builtin and then its argument prototype would still apply.  */
17377 #ifdef __cplusplus
17378 extern "C"
17379 #endif
17380 char $ac_func ();
17381 /* The GNU C library defines this for functions which it implements
17382     to always fail with ENOSYS.  Some functions are actually named
17383     something starting with __ and the normal name is an alias.  */
17384 #if defined __stub_$ac_func || defined __stub___$ac_func
17385 choke me
17386 #endif
17387
17388 int
17389 main ()
17390 {
17391 return $ac_func ();
17392   ;
17393   return 0;
17394 }
17395 _ACEOF
17396 rm -f conftest.$ac_objext conftest$ac_exeext
17397 if { (ac_try="$ac_link"
17398 case "(($ac_try" in
17399   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17400   *) ac_try_echo=$ac_try;;
17401 esac
17402 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17403 $as_echo "$ac_try_echo") >&5
17404   (eval "$ac_link") 2>conftest.er1
17405   ac_status=$?
17406   grep -v '^ *+' conftest.er1 >conftest.err
17407   rm -f conftest.er1
17408   cat conftest.err >&5
17409   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17410   (exit $ac_status); } && {
17411          test -z "$ac_c_werror_flag" ||
17412          test ! -s conftest.err
17413        } && test -s conftest$ac_exeext && {
17414          test "$cross_compiling" = yes ||
17415          $as_test_x conftest$ac_exeext
17416        }; then
17417   eval "$as_ac_var=yes"
17418 else
17419   $as_echo "$as_me: failed program was:" >&5
17420 sed 's/^/| /' conftest.$ac_ext >&5
17421
17422         eval "$as_ac_var=no"
17423 fi
17424
17425 rm -rf conftest.dSYM
17426 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17427       conftest$ac_exeext conftest.$ac_ext
17428 fi
17429 ac_res=`eval 'as_val=${'$as_ac_var'}
17430                  $as_echo "$as_val"'`
17431                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
17432 $as_echo "$ac_res" >&6; }
17433 as_val=`eval 'as_val=${'$as_ac_var'}
17434                  $as_echo "$as_val"'`
17435    if test "x$as_val" = x""yes; then
17436   cat >>confdefs.h <<_ACEOF
17437 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17438 _ACEOF
17439
17440 fi
17441 done
17442
17443
17444 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
17445 # by calling it, 2009-04-02
17446 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
17447 if test "$PORTNAME" != "solaris"; then
17448
17449 for ac_func in posix_fadvise
17450 do
17451 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17452 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
17453 $as_echo_n "checking for $ac_func... " >&6; }
17454 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17455   $as_echo_n "(cached) " >&6
17456 else
17457   cat >conftest.$ac_ext <<_ACEOF
17458 /* confdefs.h.  */
17459 _ACEOF
17460 cat confdefs.h >>conftest.$ac_ext
17461 cat >>conftest.$ac_ext <<_ACEOF
17462 /* end confdefs.h.  */
17463 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17464    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17465 #define $ac_func innocuous_$ac_func
17466
17467 /* System header to define __stub macros and hopefully few prototypes,
17468     which can conflict with char $ac_func (); below.
17469     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17470     <limits.h> exists even on freestanding compilers.  */
17471
17472 #ifdef __STDC__
17473 # include <limits.h>
17474 #else
17475 # include <assert.h>
17476 #endif
17477
17478 #undef $ac_func
17479
17480 /* Override any GCC internal prototype to avoid an error.
17481    Use char because int might match the return type of a GCC
17482    builtin and then its argument prototype would still apply.  */
17483 #ifdef __cplusplus
17484 extern "C"
17485 #endif
17486 char $ac_func ();
17487 /* The GNU C library defines this for functions which it implements
17488     to always fail with ENOSYS.  Some functions are actually named
17489     something starting with __ and the normal name is an alias.  */
17490 #if defined __stub_$ac_func || defined __stub___$ac_func
17491 choke me
17492 #endif
17493
17494 int
17495 main ()
17496 {
17497 return $ac_func ();
17498   ;
17499   return 0;
17500 }
17501 _ACEOF
17502 rm -f conftest.$ac_objext conftest$ac_exeext
17503 if { (ac_try="$ac_link"
17504 case "(($ac_try" in
17505   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17506   *) ac_try_echo=$ac_try;;
17507 esac
17508 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17509 $as_echo "$ac_try_echo") >&5
17510   (eval "$ac_link") 2>conftest.er1
17511   ac_status=$?
17512   grep -v '^ *+' conftest.er1 >conftest.err
17513   rm -f conftest.er1
17514   cat conftest.err >&5
17515   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17516   (exit $ac_status); } && {
17517          test -z "$ac_c_werror_flag" ||
17518          test ! -s conftest.err
17519        } && test -s conftest$ac_exeext && {
17520          test "$cross_compiling" = yes ||
17521          $as_test_x conftest$ac_exeext
17522        }; then
17523   eval "$as_ac_var=yes"
17524 else
17525   $as_echo "$as_me: failed program was:" >&5
17526 sed 's/^/| /' conftest.$ac_ext >&5
17527
17528         eval "$as_ac_var=no"
17529 fi
17530
17531 rm -rf conftest.dSYM
17532 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17533       conftest$ac_exeext conftest.$ac_ext
17534 fi
17535 ac_res=`eval 'as_val=${'$as_ac_var'}
17536                  $as_echo "$as_val"'`
17537                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
17538 $as_echo "$ac_res" >&6; }
17539 as_val=`eval 'as_val=${'$as_ac_var'}
17540                  $as_echo "$as_val"'`
17541    if test "x$as_val" = x""yes; then
17542   cat >>confdefs.h <<_ACEOF
17543 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
17544 _ACEOF
17545
17546 fi
17547 done
17548
17549 { $as_echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
17550 $as_echo_n "checking whether posix_fadvise is declared... " >&6; }
17551 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
17552   $as_echo_n "(cached) " >&6
17553 else
17554   cat >conftest.$ac_ext <<_ACEOF
17555 /* confdefs.h.  */
17556 _ACEOF
17557 cat confdefs.h >>conftest.$ac_ext
17558 cat >>conftest.$ac_ext <<_ACEOF
17559 /* end confdefs.h.  */
17560 #include <fcntl.h>
17561
17562 int
17563 main ()
17564 {
17565 #ifndef posix_fadvise
17566   (void) posix_fadvise;
17567 #endif
17568
17569   ;
17570   return 0;
17571 }
17572 _ACEOF
17573 rm -f conftest.$ac_objext
17574 if { (ac_try="$ac_compile"
17575 case "(($ac_try" in
17576   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17577   *) ac_try_echo=$ac_try;;
17578 esac
17579 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17580 $as_echo "$ac_try_echo") >&5
17581   (eval "$ac_compile") 2>conftest.er1
17582   ac_status=$?
17583   grep -v '^ *+' conftest.er1 >conftest.err
17584   rm -f conftest.er1
17585   cat conftest.err >&5
17586   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17587   (exit $ac_status); } && {
17588          test -z "$ac_c_werror_flag" ||
17589          test ! -s conftest.err
17590        } && test -s conftest.$ac_objext; then
17591   ac_cv_have_decl_posix_fadvise=yes
17592 else
17593   $as_echo "$as_me: failed program was:" >&5
17594 sed 's/^/| /' conftest.$ac_ext >&5
17595
17596         ac_cv_have_decl_posix_fadvise=no
17597 fi
17598
17599 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17600 fi
17601 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
17602 $as_echo "$ac_cv_have_decl_posix_fadvise" >&6; }
17603 if test "x$ac_cv_have_decl_posix_fadvise" = x""yes; then
17604
17605 cat >>confdefs.h <<_ACEOF
17606 #define HAVE_DECL_POSIX_FADVISE 1
17607 _ACEOF
17608
17609
17610 else
17611   cat >>confdefs.h <<_ACEOF
17612 #define HAVE_DECL_POSIX_FADVISE 0
17613 _ACEOF
17614
17615
17616 fi
17617
17618
17619 fi
17620
17621 { $as_echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
17622 $as_echo_n "checking whether fdatasync is declared... " >&6; }
17623 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
17624   $as_echo_n "(cached) " >&6
17625 else
17626   cat >conftest.$ac_ext <<_ACEOF
17627 /* confdefs.h.  */
17628 _ACEOF
17629 cat confdefs.h >>conftest.$ac_ext
17630 cat >>conftest.$ac_ext <<_ACEOF
17631 /* end confdefs.h.  */
17632 #include <unistd.h>
17633
17634 int
17635 main ()
17636 {
17637 #ifndef fdatasync
17638   (void) fdatasync;
17639 #endif
17640
17641   ;
17642   return 0;
17643 }
17644 _ACEOF
17645 rm -f conftest.$ac_objext
17646 if { (ac_try="$ac_compile"
17647 case "(($ac_try" in
17648   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17649   *) ac_try_echo=$ac_try;;
17650 esac
17651 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17652 $as_echo "$ac_try_echo") >&5
17653   (eval "$ac_compile") 2>conftest.er1
17654   ac_status=$?
17655   grep -v '^ *+' conftest.er1 >conftest.err
17656   rm -f conftest.er1
17657   cat conftest.err >&5
17658   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17659   (exit $ac_status); } && {
17660          test -z "$ac_c_werror_flag" ||
17661          test ! -s conftest.err
17662        } && test -s conftest.$ac_objext; then
17663   ac_cv_have_decl_fdatasync=yes
17664 else
17665   $as_echo "$as_me: failed program was:" >&5
17666 sed 's/^/| /' conftest.$ac_ext >&5
17667
17668         ac_cv_have_decl_fdatasync=no
17669 fi
17670
17671 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17672 fi
17673 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
17674 $as_echo "$ac_cv_have_decl_fdatasync" >&6; }
17675 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then
17676
17677 cat >>confdefs.h <<_ACEOF
17678 #define HAVE_DECL_FDATASYNC 1
17679 _ACEOF
17680
17681
17682 else
17683   cat >>confdefs.h <<_ACEOF
17684 #define HAVE_DECL_FDATASYNC 0
17685 _ACEOF
17686
17687
17688 fi
17689
17690
17691 { $as_echo "$as_me:$LINENO: checking whether strlcat is declared" >&5
17692 $as_echo_n "checking whether strlcat is declared... " >&6; }
17693 if test "${ac_cv_have_decl_strlcat+set}" = set; then
17694   $as_echo_n "(cached) " >&6
17695 else
17696   cat >conftest.$ac_ext <<_ACEOF
17697 /* confdefs.h.  */
17698 _ACEOF
17699 cat confdefs.h >>conftest.$ac_ext
17700 cat >>conftest.$ac_ext <<_ACEOF
17701 /* end confdefs.h.  */
17702 $ac_includes_default
17703 int
17704 main ()
17705 {
17706 #ifndef strlcat
17707   (void) strlcat;
17708 #endif
17709
17710   ;
17711   return 0;
17712 }
17713 _ACEOF
17714 rm -f conftest.$ac_objext
17715 if { (ac_try="$ac_compile"
17716 case "(($ac_try" in
17717   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17718   *) ac_try_echo=$ac_try;;
17719 esac
17720 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17721 $as_echo "$ac_try_echo") >&5
17722   (eval "$ac_compile") 2>conftest.er1
17723   ac_status=$?
17724   grep -v '^ *+' conftest.er1 >conftest.err
17725   rm -f conftest.er1
17726   cat conftest.err >&5
17727   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17728   (exit $ac_status); } && {
17729          test -z "$ac_c_werror_flag" ||
17730          test ! -s conftest.err
17731        } && test -s conftest.$ac_objext; then
17732   ac_cv_have_decl_strlcat=yes
17733 else
17734   $as_echo "$as_me: failed program was:" >&5
17735 sed 's/^/| /' conftest.$ac_ext >&5
17736
17737         ac_cv_have_decl_strlcat=no
17738 fi
17739
17740 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17741 fi
17742 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcat" >&5
17743 $as_echo "$ac_cv_have_decl_strlcat" >&6; }
17744 if test "x$ac_cv_have_decl_strlcat" = x""yes; then
17745
17746 cat >>confdefs.h <<_ACEOF
17747 #define HAVE_DECL_STRLCAT 1
17748 _ACEOF
17749
17750
17751 else
17752   cat >>confdefs.h <<_ACEOF
17753 #define HAVE_DECL_STRLCAT 0
17754 _ACEOF
17755
17756
17757 fi
17758 { $as_echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
17759 $as_echo_n "checking whether strlcpy is declared... " >&6; }
17760 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
17761   $as_echo_n "(cached) " >&6
17762 else
17763   cat >conftest.$ac_ext <<_ACEOF
17764 /* confdefs.h.  */
17765 _ACEOF
17766 cat confdefs.h >>conftest.$ac_ext
17767 cat >>conftest.$ac_ext <<_ACEOF
17768 /* end confdefs.h.  */
17769 $ac_includes_default
17770 int
17771 main ()
17772 {
17773 #ifndef strlcpy
17774   (void) strlcpy;
17775 #endif
17776
17777   ;
17778   return 0;
17779 }
17780 _ACEOF
17781 rm -f conftest.$ac_objext
17782 if { (ac_try="$ac_compile"
17783 case "(($ac_try" in
17784   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17785   *) ac_try_echo=$ac_try;;
17786 esac
17787 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17788 $as_echo "$ac_try_echo") >&5
17789   (eval "$ac_compile") 2>conftest.er1
17790   ac_status=$?
17791   grep -v '^ *+' conftest.er1 >conftest.err
17792   rm -f conftest.er1
17793   cat conftest.err >&5
17794   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17795   (exit $ac_status); } && {
17796          test -z "$ac_c_werror_flag" ||
17797          test ! -s conftest.err
17798        } && test -s conftest.$ac_objext; then
17799   ac_cv_have_decl_strlcpy=yes
17800 else
17801   $as_echo "$as_me: failed program was:" >&5
17802 sed 's/^/| /' conftest.$ac_ext >&5
17803
17804         ac_cv_have_decl_strlcpy=no
17805 fi
17806
17807 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17808 fi
17809 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
17810 $as_echo "$ac_cv_have_decl_strlcpy" >&6; }
17811 if test "x$ac_cv_have_decl_strlcpy" = x""yes; then
17812
17813 cat >>confdefs.h <<_ACEOF
17814 #define HAVE_DECL_STRLCPY 1
17815 _ACEOF
17816
17817
17818 else
17819   cat >>confdefs.h <<_ACEOF
17820 #define HAVE_DECL_STRLCPY 0
17821 _ACEOF
17822
17823
17824 fi
17825
17826
17827 # This is probably only present on Darwin, but may as well check always
17828 { $as_echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
17829 $as_echo_n "checking whether F_FULLFSYNC is declared... " >&6; }
17830 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
17831   $as_echo_n "(cached) " >&6
17832 else
17833   cat >conftest.$ac_ext <<_ACEOF
17834 /* confdefs.h.  */
17835 _ACEOF
17836 cat confdefs.h >>conftest.$ac_ext
17837 cat >>conftest.$ac_ext <<_ACEOF
17838 /* end confdefs.h.  */
17839 #include <fcntl.h>
17840
17841 int
17842 main ()
17843 {
17844 #ifndef F_FULLFSYNC
17845   (void) F_FULLFSYNC;
17846 #endif
17847
17848   ;
17849   return 0;
17850 }
17851 _ACEOF
17852 rm -f conftest.$ac_objext
17853 if { (ac_try="$ac_compile"
17854 case "(($ac_try" in
17855   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17856   *) ac_try_echo=$ac_try;;
17857 esac
17858 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17859 $as_echo "$ac_try_echo") >&5
17860   (eval "$ac_compile") 2>conftest.er1
17861   ac_status=$?
17862   grep -v '^ *+' conftest.er1 >conftest.err
17863   rm -f conftest.er1
17864   cat conftest.err >&5
17865   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17866   (exit $ac_status); } && {
17867          test -z "$ac_c_werror_flag" ||
17868          test ! -s conftest.err
17869        } && test -s conftest.$ac_objext; then
17870   ac_cv_have_decl_F_FULLFSYNC=yes
17871 else
17872   $as_echo "$as_me: failed program was:" >&5
17873 sed 's/^/| /' conftest.$ac_ext >&5
17874
17875         ac_cv_have_decl_F_FULLFSYNC=no
17876 fi
17877
17878 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17879 fi
17880 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
17881 $as_echo "$ac_cv_have_decl_F_FULLFSYNC" >&6; }
17882 if test "x$ac_cv_have_decl_F_FULLFSYNC" = x""yes; then
17883
17884 cat >>confdefs.h <<_ACEOF
17885 #define HAVE_DECL_F_FULLFSYNC 1
17886 _ACEOF
17887
17888
17889 else
17890   cat >>confdefs.h <<_ACEOF
17891 #define HAVE_DECL_F_FULLFSYNC 0
17892 _ACEOF
17893
17894
17895 fi
17896
17897
17898
17899 HAVE_IPV6=no
17900 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
17901 $as_echo_n "checking for struct sockaddr_in6... " >&6; }
17902 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
17903   $as_echo_n "(cached) " >&6
17904 else
17905   ac_cv_type_struct_sockaddr_in6=no
17906 cat >conftest.$ac_ext <<_ACEOF
17907 /* confdefs.h.  */
17908 _ACEOF
17909 cat confdefs.h >>conftest.$ac_ext
17910 cat >>conftest.$ac_ext <<_ACEOF
17911 /* end confdefs.h.  */
17912 $ac_includes_default
17913 #include <netinet/in.h>
17914
17915 int
17916 main ()
17917 {
17918 if (sizeof (struct sockaddr_in6))
17919        return 0;
17920   ;
17921   return 0;
17922 }
17923 _ACEOF
17924 rm -f conftest.$ac_objext
17925 if { (ac_try="$ac_compile"
17926 case "(($ac_try" in
17927   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17928   *) ac_try_echo=$ac_try;;
17929 esac
17930 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17931 $as_echo "$ac_try_echo") >&5
17932   (eval "$ac_compile") 2>conftest.er1
17933   ac_status=$?
17934   grep -v '^ *+' conftest.er1 >conftest.err
17935   rm -f conftest.er1
17936   cat conftest.err >&5
17937   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17938   (exit $ac_status); } && {
17939          test -z "$ac_c_werror_flag" ||
17940          test ! -s conftest.err
17941        } && test -s conftest.$ac_objext; then
17942   cat >conftest.$ac_ext <<_ACEOF
17943 /* confdefs.h.  */
17944 _ACEOF
17945 cat confdefs.h >>conftest.$ac_ext
17946 cat >>conftest.$ac_ext <<_ACEOF
17947 /* end confdefs.h.  */
17948 $ac_includes_default
17949 #include <netinet/in.h>
17950
17951 int
17952 main ()
17953 {
17954 if (sizeof ((struct sockaddr_in6)))
17955           return 0;
17956   ;
17957   return 0;
17958 }
17959 _ACEOF
17960 rm -f conftest.$ac_objext
17961 if { (ac_try="$ac_compile"
17962 case "(($ac_try" in
17963   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17964   *) ac_try_echo=$ac_try;;
17965 esac
17966 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17967 $as_echo "$ac_try_echo") >&5
17968   (eval "$ac_compile") 2>conftest.er1
17969   ac_status=$?
17970   grep -v '^ *+' conftest.er1 >conftest.err
17971   rm -f conftest.er1
17972   cat conftest.err >&5
17973   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17974   (exit $ac_status); } && {
17975          test -z "$ac_c_werror_flag" ||
17976          test ! -s conftest.err
17977        } && test -s conftest.$ac_objext; then
17978   :
17979 else
17980   $as_echo "$as_me: failed program was:" >&5
17981 sed 's/^/| /' conftest.$ac_ext >&5
17982
17983         ac_cv_type_struct_sockaddr_in6=yes
17984 fi
17985
17986 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17987 else
17988   $as_echo "$as_me: failed program was:" >&5
17989 sed 's/^/| /' conftest.$ac_ext >&5
17990
17991
17992 fi
17993
17994 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17995 fi
17996 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
17997 $as_echo "$ac_cv_type_struct_sockaddr_in6" >&6; }
17998 if test "x$ac_cv_type_struct_sockaddr_in6" = x""yes; then
17999
18000 cat >>confdefs.h <<\_ACEOF
18001 #define HAVE_IPV6 1
18002 _ACEOF
18003
18004          HAVE_IPV6=yes
18005 fi
18006
18007
18008
18009 { $as_echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
18010 $as_echo_n "checking for PS_STRINGS... " >&6; }
18011 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
18012   $as_echo_n "(cached) " >&6
18013 else
18014   cat >conftest.$ac_ext <<_ACEOF
18015 /* confdefs.h.  */
18016 _ACEOF
18017 cat confdefs.h >>conftest.$ac_ext
18018 cat >>conftest.$ac_ext <<_ACEOF
18019 /* end confdefs.h.  */
18020 #include <machine/vmparam.h>
18021 #include <sys/exec.h>
18022
18023 int
18024 main ()
18025 {
18026 PS_STRINGS->ps_nargvstr = 1;
18027 PS_STRINGS->ps_argvstr = "foo";
18028   ;
18029   return 0;
18030 }
18031 _ACEOF
18032 rm -f conftest.$ac_objext conftest$ac_exeext
18033 if { (ac_try="$ac_link"
18034 case "(($ac_try" in
18035   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18036   *) ac_try_echo=$ac_try;;
18037 esac
18038 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18039 $as_echo "$ac_try_echo") >&5
18040   (eval "$ac_link") 2>conftest.er1
18041   ac_status=$?
18042   grep -v '^ *+' conftest.er1 >conftest.err
18043   rm -f conftest.er1
18044   cat conftest.err >&5
18045   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18046   (exit $ac_status); } && {
18047          test -z "$ac_c_werror_flag" ||
18048          test ! -s conftest.err
18049        } && test -s conftest$ac_exeext && {
18050          test "$cross_compiling" = yes ||
18051          $as_test_x conftest$ac_exeext
18052        }; then
18053   pgac_cv_var_PS_STRINGS=yes
18054 else
18055   $as_echo "$as_me: failed program was:" >&5
18056 sed 's/^/| /' conftest.$ac_ext >&5
18057
18058         pgac_cv_var_PS_STRINGS=no
18059 fi
18060
18061 rm -rf conftest.dSYM
18062 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18063       conftest$ac_exeext conftest.$ac_ext
18064 fi
18065 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
18066 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
18067 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
18068
18069 cat >>confdefs.h <<\_ACEOF
18070 #define HAVE_PS_STRINGS /**/
18071 _ACEOF
18072
18073 fi
18074
18075
18076 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
18077 # is missing.  Yes, there are machines that have only one.  We may
18078 # also decide to use snprintf.c if snprintf() is present but does not
18079 # have all the features we need --- see below.
18080
18081 if test "$PORTNAME" = "win32"; then
18082   # Win32 gets snprintf.c built unconditionally.
18083   #
18084   # To properly translate all NLS languages strings, we must support the
18085   # *printf() %$ format, which allows *printf() arguments to be selected
18086   # by position in the translated string.
18087   #
18088   # libintl versions < 0.13 use the native *printf() functions, and Win32
18089   # *printf() doesn't understand %$, so we must use our /port versions,
18090   # which do understand %$. libintl versions >= 0.13 include their own
18091   # *printf versions on Win32.  The libintl 0.13 release note text is:
18092   #
18093   #   C format strings with positions, as they arise when a translator
18094   #   needs to reorder a sentence, are now supported on all platforms.
18095   #   On those few platforms (NetBSD and Woe32) for which the native
18096   #   printf()/fprintf()/... functions don't support such format
18097   #   strings, replacements are provided through <libintl.h>.
18098   #
18099   # We could use libintl >= 0.13's *printf() if we were sure that we had
18100   # a litint >= 0.13 at runtime, but seeing that there is no clean way
18101   # to guarantee that, it is best to just use our own, so we are sure to
18102   # get %$ support. In include/port.h we disable the *printf() macros
18103   # that might have been defined by libintl.
18104   #
18105   # We do this unconditionally whether NLS is used or not so we are sure
18106   # that all Win32 libraries and binaries behave the same.
18107   pgac_need_repl_snprintf=yes
18108 else
18109   pgac_need_repl_snprintf=no
18110
18111 for ac_func in snprintf
18112 do
18113 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18114 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18115 $as_echo_n "checking for $ac_func... " >&6; }
18116 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18117   $as_echo_n "(cached) " >&6
18118 else
18119   cat >conftest.$ac_ext <<_ACEOF
18120 /* confdefs.h.  */
18121 _ACEOF
18122 cat confdefs.h >>conftest.$ac_ext
18123 cat >>conftest.$ac_ext <<_ACEOF
18124 /* end confdefs.h.  */
18125 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18126    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18127 #define $ac_func innocuous_$ac_func
18128
18129 /* System header to define __stub macros and hopefully few prototypes,
18130     which can conflict with char $ac_func (); below.
18131     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18132     <limits.h> exists even on freestanding compilers.  */
18133
18134 #ifdef __STDC__
18135 # include <limits.h>
18136 #else
18137 # include <assert.h>
18138 #endif
18139
18140 #undef $ac_func
18141
18142 /* Override any GCC internal prototype to avoid an error.
18143    Use char because int might match the return type of a GCC
18144    builtin and then its argument prototype would still apply.  */
18145 #ifdef __cplusplus
18146 extern "C"
18147 #endif
18148 char $ac_func ();
18149 /* The GNU C library defines this for functions which it implements
18150     to always fail with ENOSYS.  Some functions are actually named
18151     something starting with __ and the normal name is an alias.  */
18152 #if defined __stub_$ac_func || defined __stub___$ac_func
18153 choke me
18154 #endif
18155
18156 int
18157 main ()
18158 {
18159 return $ac_func ();
18160   ;
18161   return 0;
18162 }
18163 _ACEOF
18164 rm -f conftest.$ac_objext conftest$ac_exeext
18165 if { (ac_try="$ac_link"
18166 case "(($ac_try" in
18167   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18168   *) ac_try_echo=$ac_try;;
18169 esac
18170 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18171 $as_echo "$ac_try_echo") >&5
18172   (eval "$ac_link") 2>conftest.er1
18173   ac_status=$?
18174   grep -v '^ *+' conftest.er1 >conftest.err
18175   rm -f conftest.er1
18176   cat conftest.err >&5
18177   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18178   (exit $ac_status); } && {
18179          test -z "$ac_c_werror_flag" ||
18180          test ! -s conftest.err
18181        } && test -s conftest$ac_exeext && {
18182          test "$cross_compiling" = yes ||
18183          $as_test_x conftest$ac_exeext
18184        }; then
18185   eval "$as_ac_var=yes"
18186 else
18187   $as_echo "$as_me: failed program was:" >&5
18188 sed 's/^/| /' conftest.$ac_ext >&5
18189
18190         eval "$as_ac_var=no"
18191 fi
18192
18193 rm -rf conftest.dSYM
18194 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18195       conftest$ac_exeext conftest.$ac_ext
18196 fi
18197 ac_res=`eval 'as_val=${'$as_ac_var'}
18198                  $as_echo "$as_val"'`
18199                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18200 $as_echo "$ac_res" >&6; }
18201 as_val=`eval 'as_val=${'$as_ac_var'}
18202                  $as_echo "$as_val"'`
18203    if test "x$as_val" = x""yes; then
18204   cat >>confdefs.h <<_ACEOF
18205 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18206 _ACEOF
18207
18208 else
18209   pgac_need_repl_snprintf=yes
18210 fi
18211 done
18212
18213
18214 for ac_func in vsnprintf
18215 do
18216 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18217 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18218 $as_echo_n "checking for $ac_func... " >&6; }
18219 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18220   $as_echo_n "(cached) " >&6
18221 else
18222   cat >conftest.$ac_ext <<_ACEOF
18223 /* confdefs.h.  */
18224 _ACEOF
18225 cat confdefs.h >>conftest.$ac_ext
18226 cat >>conftest.$ac_ext <<_ACEOF
18227 /* end confdefs.h.  */
18228 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18229    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18230 #define $ac_func innocuous_$ac_func
18231
18232 /* System header to define __stub macros and hopefully few prototypes,
18233     which can conflict with char $ac_func (); below.
18234     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18235     <limits.h> exists even on freestanding compilers.  */
18236
18237 #ifdef __STDC__
18238 # include <limits.h>
18239 #else
18240 # include <assert.h>
18241 #endif
18242
18243 #undef $ac_func
18244
18245 /* Override any GCC internal prototype to avoid an error.
18246    Use char because int might match the return type of a GCC
18247    builtin and then its argument prototype would still apply.  */
18248 #ifdef __cplusplus
18249 extern "C"
18250 #endif
18251 char $ac_func ();
18252 /* The GNU C library defines this for functions which it implements
18253     to always fail with ENOSYS.  Some functions are actually named
18254     something starting with __ and the normal name is an alias.  */
18255 #if defined __stub_$ac_func || defined __stub___$ac_func
18256 choke me
18257 #endif
18258
18259 int
18260 main ()
18261 {
18262 return $ac_func ();
18263   ;
18264   return 0;
18265 }
18266 _ACEOF
18267 rm -f conftest.$ac_objext conftest$ac_exeext
18268 if { (ac_try="$ac_link"
18269 case "(($ac_try" in
18270   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18271   *) ac_try_echo=$ac_try;;
18272 esac
18273 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18274 $as_echo "$ac_try_echo") >&5
18275   (eval "$ac_link") 2>conftest.er1
18276   ac_status=$?
18277   grep -v '^ *+' conftest.er1 >conftest.err
18278   rm -f conftest.er1
18279   cat conftest.err >&5
18280   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18281   (exit $ac_status); } && {
18282          test -z "$ac_c_werror_flag" ||
18283          test ! -s conftest.err
18284        } && test -s conftest$ac_exeext && {
18285          test "$cross_compiling" = yes ||
18286          $as_test_x conftest$ac_exeext
18287        }; then
18288   eval "$as_ac_var=yes"
18289 else
18290   $as_echo "$as_me: failed program was:" >&5
18291 sed 's/^/| /' conftest.$ac_ext >&5
18292
18293         eval "$as_ac_var=no"
18294 fi
18295
18296 rm -rf conftest.dSYM
18297 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18298       conftest$ac_exeext conftest.$ac_ext
18299 fi
18300 ac_res=`eval 'as_val=${'$as_ac_var'}
18301                  $as_echo "$as_val"'`
18302                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18303 $as_echo "$ac_res" >&6; }
18304 as_val=`eval 'as_val=${'$as_ac_var'}
18305                  $as_echo "$as_val"'`
18306    if test "x$as_val" = x""yes; then
18307   cat >>confdefs.h <<_ACEOF
18308 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18309 _ACEOF
18310
18311 else
18312   pgac_need_repl_snprintf=yes
18313 fi
18314 done
18315
18316 fi
18317
18318
18319 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
18320 # include/c.h will provide declarations.  Note this is a separate test
18321 # from whether the functions exist in the C library --- there are
18322 # systems that have the functions but don't bother to declare them :-(
18323
18324 { $as_echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
18325 $as_echo_n "checking whether snprintf is declared... " >&6; }
18326 if test "${ac_cv_have_decl_snprintf+set}" = set; then
18327   $as_echo_n "(cached) " >&6
18328 else
18329   cat >conftest.$ac_ext <<_ACEOF
18330 /* confdefs.h.  */
18331 _ACEOF
18332 cat confdefs.h >>conftest.$ac_ext
18333 cat >>conftest.$ac_ext <<_ACEOF
18334 /* end confdefs.h.  */
18335 $ac_includes_default
18336 int
18337 main ()
18338 {
18339 #ifndef snprintf
18340   (void) snprintf;
18341 #endif
18342
18343   ;
18344   return 0;
18345 }
18346 _ACEOF
18347 rm -f conftest.$ac_objext
18348 if { (ac_try="$ac_compile"
18349 case "(($ac_try" in
18350   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18351   *) ac_try_echo=$ac_try;;
18352 esac
18353 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18354 $as_echo "$ac_try_echo") >&5
18355   (eval "$ac_compile") 2>conftest.er1
18356   ac_status=$?
18357   grep -v '^ *+' conftest.er1 >conftest.err
18358   rm -f conftest.er1
18359   cat conftest.err >&5
18360   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18361   (exit $ac_status); } && {
18362          test -z "$ac_c_werror_flag" ||
18363          test ! -s conftest.err
18364        } && test -s conftest.$ac_objext; then
18365   ac_cv_have_decl_snprintf=yes
18366 else
18367   $as_echo "$as_me: failed program was:" >&5
18368 sed 's/^/| /' conftest.$ac_ext >&5
18369
18370         ac_cv_have_decl_snprintf=no
18371 fi
18372
18373 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18374 fi
18375 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
18376 $as_echo "$ac_cv_have_decl_snprintf" >&6; }
18377 if test "x$ac_cv_have_decl_snprintf" = x""yes; then
18378
18379 cat >>confdefs.h <<_ACEOF
18380 #define HAVE_DECL_SNPRINTF 1
18381 _ACEOF
18382
18383
18384 else
18385   cat >>confdefs.h <<_ACEOF
18386 #define HAVE_DECL_SNPRINTF 0
18387 _ACEOF
18388
18389
18390 fi
18391 { $as_echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
18392 $as_echo_n "checking whether vsnprintf is declared... " >&6; }
18393 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
18394   $as_echo_n "(cached) " >&6
18395 else
18396   cat >conftest.$ac_ext <<_ACEOF
18397 /* confdefs.h.  */
18398 _ACEOF
18399 cat confdefs.h >>conftest.$ac_ext
18400 cat >>conftest.$ac_ext <<_ACEOF
18401 /* end confdefs.h.  */
18402 $ac_includes_default
18403 int
18404 main ()
18405 {
18406 #ifndef vsnprintf
18407   (void) vsnprintf;
18408 #endif
18409
18410   ;
18411   return 0;
18412 }
18413 _ACEOF
18414 rm -f conftest.$ac_objext
18415 if { (ac_try="$ac_compile"
18416 case "(($ac_try" in
18417   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18418   *) ac_try_echo=$ac_try;;
18419 esac
18420 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18421 $as_echo "$ac_try_echo") >&5
18422   (eval "$ac_compile") 2>conftest.er1
18423   ac_status=$?
18424   grep -v '^ *+' conftest.er1 >conftest.err
18425   rm -f conftest.er1
18426   cat conftest.err >&5
18427   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18428   (exit $ac_status); } && {
18429          test -z "$ac_c_werror_flag" ||
18430          test ! -s conftest.err
18431        } && test -s conftest.$ac_objext; then
18432   ac_cv_have_decl_vsnprintf=yes
18433 else
18434   $as_echo "$as_me: failed program was:" >&5
18435 sed 's/^/| /' conftest.$ac_ext >&5
18436
18437         ac_cv_have_decl_vsnprintf=no
18438 fi
18439
18440 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18441 fi
18442 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
18443 $as_echo "$ac_cv_have_decl_vsnprintf" >&6; }
18444 if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then
18445
18446 cat >>confdefs.h <<_ACEOF
18447 #define HAVE_DECL_VSNPRINTF 1
18448 _ACEOF
18449
18450
18451 else
18452   cat >>confdefs.h <<_ACEOF
18453 #define HAVE_DECL_VSNPRINTF 0
18454 _ACEOF
18455
18456
18457 fi
18458
18459
18460
18461
18462 { $as_echo "$as_me:$LINENO: checking for isinf" >&5
18463 $as_echo_n "checking for isinf... " >&6; }
18464 if test "${ac_cv_func_isinf+set}" = set; then
18465   $as_echo_n "(cached) " >&6
18466 else
18467   cat >conftest.$ac_ext <<_ACEOF
18468 /* confdefs.h.  */
18469 _ACEOF
18470 cat confdefs.h >>conftest.$ac_ext
18471 cat >>conftest.$ac_ext <<_ACEOF
18472 /* end confdefs.h.  */
18473
18474 #include <math.h>
18475 double glob_double;
18476
18477 int
18478 main ()
18479 {
18480 return isinf(glob_double) ? 0 : 1;
18481   ;
18482   return 0;
18483 }
18484 _ACEOF
18485 rm -f conftest.$ac_objext conftest$ac_exeext
18486 if { (ac_try="$ac_link"
18487 case "(($ac_try" in
18488   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18489   *) ac_try_echo=$ac_try;;
18490 esac
18491 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18492 $as_echo "$ac_try_echo") >&5
18493   (eval "$ac_link") 2>conftest.er1
18494   ac_status=$?
18495   grep -v '^ *+' conftest.er1 >conftest.err
18496   rm -f conftest.er1
18497   cat conftest.err >&5
18498   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18499   (exit $ac_status); } && {
18500          test -z "$ac_c_werror_flag" ||
18501          test ! -s conftest.err
18502        } && test -s conftest$ac_exeext && {
18503          test "$cross_compiling" = yes ||
18504          $as_test_x conftest$ac_exeext
18505        }; then
18506   ac_cv_func_isinf=yes
18507 else
18508   $as_echo "$as_me: failed program was:" >&5
18509 sed 's/^/| /' conftest.$ac_ext >&5
18510
18511         ac_cv_func_isinf=no
18512 fi
18513
18514 rm -rf conftest.dSYM
18515 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18516       conftest$ac_exeext conftest.$ac_ext
18517 fi
18518 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
18519 $as_echo "$ac_cv_func_isinf" >&6; }
18520
18521 if test $ac_cv_func_isinf = yes ; then
18522
18523 cat >>confdefs.h <<\_ACEOF
18524 #define HAVE_ISINF 1
18525 _ACEOF
18526
18527 else
18528   case " $LIBOBJS " in
18529   *" isinf.$ac_objext "* ) ;;
18530   *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
18531  ;;
18532 esac
18533
18534   # Look for a way to implement a substitute for isinf()
18535
18536
18537
18538
18539 for ac_func in fpclass fp_class fp_class_d class
18540 do
18541 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18542 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18543 $as_echo_n "checking for $ac_func... " >&6; }
18544 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18545   $as_echo_n "(cached) " >&6
18546 else
18547   cat >conftest.$ac_ext <<_ACEOF
18548 /* confdefs.h.  */
18549 _ACEOF
18550 cat confdefs.h >>conftest.$ac_ext
18551 cat >>conftest.$ac_ext <<_ACEOF
18552 /* end confdefs.h.  */
18553 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18554    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18555 #define $ac_func innocuous_$ac_func
18556
18557 /* System header to define __stub macros and hopefully few prototypes,
18558     which can conflict with char $ac_func (); below.
18559     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18560     <limits.h> exists even on freestanding compilers.  */
18561
18562 #ifdef __STDC__
18563 # include <limits.h>
18564 #else
18565 # include <assert.h>
18566 #endif
18567
18568 #undef $ac_func
18569
18570 /* Override any GCC internal prototype to avoid an error.
18571    Use char because int might match the return type of a GCC
18572    builtin and then its argument prototype would still apply.  */
18573 #ifdef __cplusplus
18574 extern "C"
18575 #endif
18576 char $ac_func ();
18577 /* The GNU C library defines this for functions which it implements
18578     to always fail with ENOSYS.  Some functions are actually named
18579     something starting with __ and the normal name is an alias.  */
18580 #if defined __stub_$ac_func || defined __stub___$ac_func
18581 choke me
18582 #endif
18583
18584 int
18585 main ()
18586 {
18587 return $ac_func ();
18588   ;
18589   return 0;
18590 }
18591 _ACEOF
18592 rm -f conftest.$ac_objext conftest$ac_exeext
18593 if { (ac_try="$ac_link"
18594 case "(($ac_try" in
18595   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18596   *) ac_try_echo=$ac_try;;
18597 esac
18598 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18599 $as_echo "$ac_try_echo") >&5
18600   (eval "$ac_link") 2>conftest.er1
18601   ac_status=$?
18602   grep -v '^ *+' conftest.er1 >conftest.err
18603   rm -f conftest.er1
18604   cat conftest.err >&5
18605   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18606   (exit $ac_status); } && {
18607          test -z "$ac_c_werror_flag" ||
18608          test ! -s conftest.err
18609        } && test -s conftest$ac_exeext && {
18610          test "$cross_compiling" = yes ||
18611          $as_test_x conftest$ac_exeext
18612        }; then
18613   eval "$as_ac_var=yes"
18614 else
18615   $as_echo "$as_me: failed program was:" >&5
18616 sed 's/^/| /' conftest.$ac_ext >&5
18617
18618         eval "$as_ac_var=no"
18619 fi
18620
18621 rm -rf conftest.dSYM
18622 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18623       conftest$ac_exeext conftest.$ac_ext
18624 fi
18625 ac_res=`eval 'as_val=${'$as_ac_var'}
18626                  $as_echo "$as_val"'`
18627                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18628 $as_echo "$ac_res" >&6; }
18629 as_val=`eval 'as_val=${'$as_ac_var'}
18630                  $as_echo "$as_val"'`
18631    if test "x$as_val" = x""yes; then
18632   cat >>confdefs.h <<_ACEOF
18633 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18634 _ACEOF
18635  break
18636 fi
18637 done
18638
18639 fi
18640
18641 # Some versions of libedit contain strlcpy(); so disregard that library while
18642 # checking for these standard libc functions.
18643 pgac_save_LIBS="$LIBS"
18644 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
18645
18646
18647
18648
18649
18650
18651
18652
18653
18654
18655
18656
18657
18658
18659
18660 for ac_func in crypt erand48 getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul
18661 do
18662 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18663 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18664 $as_echo_n "checking for $ac_func... " >&6; }
18665 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18666   $as_echo_n "(cached) " >&6
18667 else
18668   cat >conftest.$ac_ext <<_ACEOF
18669 /* confdefs.h.  */
18670 _ACEOF
18671 cat confdefs.h >>conftest.$ac_ext
18672 cat >>conftest.$ac_ext <<_ACEOF
18673 /* end confdefs.h.  */
18674 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18675    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18676 #define $ac_func innocuous_$ac_func
18677
18678 /* System header to define __stub macros and hopefully few prototypes,
18679     which can conflict with char $ac_func (); below.
18680     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18681     <limits.h> exists even on freestanding compilers.  */
18682
18683 #ifdef __STDC__
18684 # include <limits.h>
18685 #else
18686 # include <assert.h>
18687 #endif
18688
18689 #undef $ac_func
18690
18691 /* Override any GCC internal prototype to avoid an error.
18692    Use char because int might match the return type of a GCC
18693    builtin and then its argument prototype would still apply.  */
18694 #ifdef __cplusplus
18695 extern "C"
18696 #endif
18697 char $ac_func ();
18698 /* The GNU C library defines this for functions which it implements
18699     to always fail with ENOSYS.  Some functions are actually named
18700     something starting with __ and the normal name is an alias.  */
18701 #if defined __stub_$ac_func || defined __stub___$ac_func
18702 choke me
18703 #endif
18704
18705 int
18706 main ()
18707 {
18708 return $ac_func ();
18709   ;
18710   return 0;
18711 }
18712 _ACEOF
18713 rm -f conftest.$ac_objext conftest$ac_exeext
18714 if { (ac_try="$ac_link"
18715 case "(($ac_try" in
18716   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18717   *) ac_try_echo=$ac_try;;
18718 esac
18719 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18720 $as_echo "$ac_try_echo") >&5
18721   (eval "$ac_link") 2>conftest.er1
18722   ac_status=$?
18723   grep -v '^ *+' conftest.er1 >conftest.err
18724   rm -f conftest.er1
18725   cat conftest.err >&5
18726   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18727   (exit $ac_status); } && {
18728          test -z "$ac_c_werror_flag" ||
18729          test ! -s conftest.err
18730        } && test -s conftest$ac_exeext && {
18731          test "$cross_compiling" = yes ||
18732          $as_test_x conftest$ac_exeext
18733        }; then
18734   eval "$as_ac_var=yes"
18735 else
18736   $as_echo "$as_me: failed program was:" >&5
18737 sed 's/^/| /' conftest.$ac_ext >&5
18738
18739         eval "$as_ac_var=no"
18740 fi
18741
18742 rm -rf conftest.dSYM
18743 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18744       conftest$ac_exeext conftest.$ac_ext
18745 fi
18746 ac_res=`eval 'as_val=${'$as_ac_var'}
18747                  $as_echo "$as_val"'`
18748                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18749 $as_echo "$ac_res" >&6; }
18750 as_val=`eval 'as_val=${'$as_ac_var'}
18751                  $as_echo "$as_val"'`
18752    if test "x$as_val" = x""yes; then
18753   cat >>confdefs.h <<_ACEOF
18754 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18755 _ACEOF
18756
18757 else
18758   case " $LIBOBJS " in
18759   *" $ac_func.$ac_objext "* ) ;;
18760   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
18761  ;;
18762 esac
18763
18764 fi
18765 done
18766
18767
18768
18769 case $host_os in
18770
18771         # Windows uses a specialised env handler
18772         mingw*)
18773
18774 cat >>confdefs.h <<\_ACEOF
18775 #define HAVE_UNSETENV 1
18776 _ACEOF
18777
18778                 ac_cv_func_unsetenv=yes;;
18779         *)
18780
18781 for ac_func in unsetenv
18782 do
18783 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18784 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18785 $as_echo_n "checking for $ac_func... " >&6; }
18786 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18787   $as_echo_n "(cached) " >&6
18788 else
18789   cat >conftest.$ac_ext <<_ACEOF
18790 /* confdefs.h.  */
18791 _ACEOF
18792 cat confdefs.h >>conftest.$ac_ext
18793 cat >>conftest.$ac_ext <<_ACEOF
18794 /* end confdefs.h.  */
18795 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18796    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18797 #define $ac_func innocuous_$ac_func
18798
18799 /* System header to define __stub macros and hopefully few prototypes,
18800     which can conflict with char $ac_func (); below.
18801     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18802     <limits.h> exists even on freestanding compilers.  */
18803
18804 #ifdef __STDC__
18805 # include <limits.h>
18806 #else
18807 # include <assert.h>
18808 #endif
18809
18810 #undef $ac_func
18811
18812 /* Override any GCC internal prototype to avoid an error.
18813    Use char because int might match the return type of a GCC
18814    builtin and then its argument prototype would still apply.  */
18815 #ifdef __cplusplus
18816 extern "C"
18817 #endif
18818 char $ac_func ();
18819 /* The GNU C library defines this for functions which it implements
18820     to always fail with ENOSYS.  Some functions are actually named
18821     something starting with __ and the normal name is an alias.  */
18822 #if defined __stub_$ac_func || defined __stub___$ac_func
18823 choke me
18824 #endif
18825
18826 int
18827 main ()
18828 {
18829 return $ac_func ();
18830   ;
18831   return 0;
18832 }
18833 _ACEOF
18834 rm -f conftest.$ac_objext conftest$ac_exeext
18835 if { (ac_try="$ac_link"
18836 case "(($ac_try" in
18837   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18838   *) ac_try_echo=$ac_try;;
18839 esac
18840 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18841 $as_echo "$ac_try_echo") >&5
18842   (eval "$ac_link") 2>conftest.er1
18843   ac_status=$?
18844   grep -v '^ *+' conftest.er1 >conftest.err
18845   rm -f conftest.er1
18846   cat conftest.err >&5
18847   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18848   (exit $ac_status); } && {
18849          test -z "$ac_c_werror_flag" ||
18850          test ! -s conftest.err
18851        } && test -s conftest$ac_exeext && {
18852          test "$cross_compiling" = yes ||
18853          $as_test_x conftest$ac_exeext
18854        }; then
18855   eval "$as_ac_var=yes"
18856 else
18857   $as_echo "$as_me: failed program was:" >&5
18858 sed 's/^/| /' conftest.$ac_ext >&5
18859
18860         eval "$as_ac_var=no"
18861 fi
18862
18863 rm -rf conftest.dSYM
18864 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18865       conftest$ac_exeext conftest.$ac_ext
18866 fi
18867 ac_res=`eval 'as_val=${'$as_ac_var'}
18868                  $as_echo "$as_val"'`
18869                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18870 $as_echo "$ac_res" >&6; }
18871 as_val=`eval 'as_val=${'$as_ac_var'}
18872                  $as_echo "$as_val"'`
18873    if test "x$as_val" = x""yes; then
18874   cat >>confdefs.h <<_ACEOF
18875 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18876 _ACEOF
18877
18878 else
18879   case " $LIBOBJS " in
18880   *" $ac_func.$ac_objext "* ) ;;
18881   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
18882  ;;
18883 esac
18884
18885 fi
18886 done
18887
18888
18889                 ;;
18890 esac
18891
18892
18893 LIBS="$pgac_save_LIBS"
18894
18895 # System's version of getaddrinfo(), if any, may be used only if we found
18896 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
18897 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
18898 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
18899 # because we want to use our own getaddrinfo.c on Windows anyway.)
18900 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
18901
18902 for ac_func in getaddrinfo
18903 do
18904 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18905 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18906 $as_echo_n "checking for $ac_func... " >&6; }
18907 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18908   $as_echo_n "(cached) " >&6
18909 else
18910   cat >conftest.$ac_ext <<_ACEOF
18911 /* confdefs.h.  */
18912 _ACEOF
18913 cat confdefs.h >>conftest.$ac_ext
18914 cat >>conftest.$ac_ext <<_ACEOF
18915 /* end confdefs.h.  */
18916 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18917    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18918 #define $ac_func innocuous_$ac_func
18919
18920 /* System header to define __stub macros and hopefully few prototypes,
18921     which can conflict with char $ac_func (); below.
18922     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18923     <limits.h> exists even on freestanding compilers.  */
18924
18925 #ifdef __STDC__
18926 # include <limits.h>
18927 #else
18928 # include <assert.h>
18929 #endif
18930
18931 #undef $ac_func
18932
18933 /* Override any GCC internal prototype to avoid an error.
18934    Use char because int might match the return type of a GCC
18935    builtin and then its argument prototype would still apply.  */
18936 #ifdef __cplusplus
18937 extern "C"
18938 #endif
18939 char $ac_func ();
18940 /* The GNU C library defines this for functions which it implements
18941     to always fail with ENOSYS.  Some functions are actually named
18942     something starting with __ and the normal name is an alias.  */
18943 #if defined __stub_$ac_func || defined __stub___$ac_func
18944 choke me
18945 #endif
18946
18947 int
18948 main ()
18949 {
18950 return $ac_func ();
18951   ;
18952   return 0;
18953 }
18954 _ACEOF
18955 rm -f conftest.$ac_objext conftest$ac_exeext
18956 if { (ac_try="$ac_link"
18957 case "(($ac_try" in
18958   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18959   *) ac_try_echo=$ac_try;;
18960 esac
18961 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18962 $as_echo "$ac_try_echo") >&5
18963   (eval "$ac_link") 2>conftest.er1
18964   ac_status=$?
18965   grep -v '^ *+' conftest.er1 >conftest.err
18966   rm -f conftest.er1
18967   cat conftest.err >&5
18968   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18969   (exit $ac_status); } && {
18970          test -z "$ac_c_werror_flag" ||
18971          test ! -s conftest.err
18972        } && test -s conftest$ac_exeext && {
18973          test "$cross_compiling" = yes ||
18974          $as_test_x conftest$ac_exeext
18975        }; then
18976   eval "$as_ac_var=yes"
18977 else
18978   $as_echo "$as_me: failed program was:" >&5
18979 sed 's/^/| /' conftest.$ac_ext >&5
18980
18981         eval "$as_ac_var=no"
18982 fi
18983
18984 rm -rf conftest.dSYM
18985 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18986       conftest$ac_exeext conftest.$ac_ext
18987 fi
18988 ac_res=`eval 'as_val=${'$as_ac_var'}
18989                  $as_echo "$as_val"'`
18990                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18991 $as_echo "$ac_res" >&6; }
18992 as_val=`eval 'as_val=${'$as_ac_var'}
18993                  $as_echo "$as_val"'`
18994    if test "x$as_val" = x""yes; then
18995   cat >>confdefs.h <<_ACEOF
18996 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18997 _ACEOF
18998
18999 else
19000   case " $LIBOBJS " in
19001   *" $ac_func.$ac_objext "* ) ;;
19002   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
19003  ;;
19004 esac
19005
19006 fi
19007 done
19008
19009
19010 else
19011   case " $LIBOBJS " in
19012   *" getaddrinfo.$ac_objext "* ) ;;
19013   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
19014  ;;
19015 esac
19016
19017 fi
19018
19019 # Similarly, use system's getopt_long() only if system provides struct option.
19020 if test x"$ac_cv_type_struct_option" = xyes ; then
19021
19022 for ac_func in getopt_long
19023 do
19024 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19025 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19026 $as_echo_n "checking for $ac_func... " >&6; }
19027 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19028   $as_echo_n "(cached) " >&6
19029 else
19030   cat >conftest.$ac_ext <<_ACEOF
19031 /* confdefs.h.  */
19032 _ACEOF
19033 cat confdefs.h >>conftest.$ac_ext
19034 cat >>conftest.$ac_ext <<_ACEOF
19035 /* end confdefs.h.  */
19036 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19037    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19038 #define $ac_func innocuous_$ac_func
19039
19040 /* System header to define __stub macros and hopefully few prototypes,
19041     which can conflict with char $ac_func (); below.
19042     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19043     <limits.h> exists even on freestanding compilers.  */
19044
19045 #ifdef __STDC__
19046 # include <limits.h>
19047 #else
19048 # include <assert.h>
19049 #endif
19050
19051 #undef $ac_func
19052
19053 /* Override any GCC internal prototype to avoid an error.
19054    Use char because int might match the return type of a GCC
19055    builtin and then its argument prototype would still apply.  */
19056 #ifdef __cplusplus
19057 extern "C"
19058 #endif
19059 char $ac_func ();
19060 /* The GNU C library defines this for functions which it implements
19061     to always fail with ENOSYS.  Some functions are actually named
19062     something starting with __ and the normal name is an alias.  */
19063 #if defined __stub_$ac_func || defined __stub___$ac_func
19064 choke me
19065 #endif
19066
19067 int
19068 main ()
19069 {
19070 return $ac_func ();
19071   ;
19072   return 0;
19073 }
19074 _ACEOF
19075 rm -f conftest.$ac_objext conftest$ac_exeext
19076 if { (ac_try="$ac_link"
19077 case "(($ac_try" in
19078   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19079   *) ac_try_echo=$ac_try;;
19080 esac
19081 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19082 $as_echo "$ac_try_echo") >&5
19083   (eval "$ac_link") 2>conftest.er1
19084   ac_status=$?
19085   grep -v '^ *+' conftest.er1 >conftest.err
19086   rm -f conftest.er1
19087   cat conftest.err >&5
19088   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19089   (exit $ac_status); } && {
19090          test -z "$ac_c_werror_flag" ||
19091          test ! -s conftest.err
19092        } && test -s conftest$ac_exeext && {
19093          test "$cross_compiling" = yes ||
19094          $as_test_x conftest$ac_exeext
19095        }; then
19096   eval "$as_ac_var=yes"
19097 else
19098   $as_echo "$as_me: failed program was:" >&5
19099 sed 's/^/| /' conftest.$ac_ext >&5
19100
19101         eval "$as_ac_var=no"
19102 fi
19103
19104 rm -rf conftest.dSYM
19105 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19106       conftest$ac_exeext conftest.$ac_ext
19107 fi
19108 ac_res=`eval 'as_val=${'$as_ac_var'}
19109                  $as_echo "$as_val"'`
19110                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19111 $as_echo "$ac_res" >&6; }
19112 as_val=`eval 'as_val=${'$as_ac_var'}
19113                  $as_echo "$as_val"'`
19114    if test "x$as_val" = x""yes; then
19115   cat >>confdefs.h <<_ACEOF
19116 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19117 _ACEOF
19118
19119 else
19120   case " $LIBOBJS " in
19121   *" $ac_func.$ac_objext "* ) ;;
19122   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
19123  ;;
19124 esac
19125
19126 fi
19127 done
19128
19129
19130 else
19131   case " $LIBOBJS " in
19132   *" getopt_long.$ac_objext "* ) ;;
19133   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
19134  ;;
19135 esac
19136
19137 fi
19138
19139 # Solaris' getopt() doesn't do what we want for long options, so always use
19140 # our version on that platform.
19141 if test "$PORTNAME" = "solaris"; then
19142   case " $LIBOBJS " in
19143   *" getopt.$ac_objext "* ) ;;
19144   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
19145  ;;
19146 esac
19147
19148 fi
19149
19150 # Cygwin's erand48() is broken (always returns zero) in some releases,
19151 # so force use of ours.
19152 if test "$PORTNAME" = "cygwin"; then
19153   case " $LIBOBJS " in
19154   *" erand48.$ac_objext "* ) ;;
19155   *) LIBOBJS="$LIBOBJS erand48.$ac_objext"
19156  ;;
19157 esac
19158
19159 fi
19160
19161 # Win32 support
19162 if test "$PORTNAME" = "win32"; then
19163
19164 for ac_func in gettimeofday
19165 do
19166 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19167 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19168 $as_echo_n "checking for $ac_func... " >&6; }
19169 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19170   $as_echo_n "(cached) " >&6
19171 else
19172   cat >conftest.$ac_ext <<_ACEOF
19173 /* confdefs.h.  */
19174 _ACEOF
19175 cat confdefs.h >>conftest.$ac_ext
19176 cat >>conftest.$ac_ext <<_ACEOF
19177 /* end confdefs.h.  */
19178 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19179    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19180 #define $ac_func innocuous_$ac_func
19181
19182 /* System header to define __stub macros and hopefully few prototypes,
19183     which can conflict with char $ac_func (); below.
19184     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19185     <limits.h> exists even on freestanding compilers.  */
19186
19187 #ifdef __STDC__
19188 # include <limits.h>
19189 #else
19190 # include <assert.h>
19191 #endif
19192
19193 #undef $ac_func
19194
19195 /* Override any GCC internal prototype to avoid an error.
19196    Use char because int might match the return type of a GCC
19197    builtin and then its argument prototype would still apply.  */
19198 #ifdef __cplusplus
19199 extern "C"
19200 #endif
19201 char $ac_func ();
19202 /* The GNU C library defines this for functions which it implements
19203     to always fail with ENOSYS.  Some functions are actually named
19204     something starting with __ and the normal name is an alias.  */
19205 #if defined __stub_$ac_func || defined __stub___$ac_func
19206 choke me
19207 #endif
19208
19209 int
19210 main ()
19211 {
19212 return $ac_func ();
19213   ;
19214   return 0;
19215 }
19216 _ACEOF
19217 rm -f conftest.$ac_objext conftest$ac_exeext
19218 if { (ac_try="$ac_link"
19219 case "(($ac_try" in
19220   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19221   *) ac_try_echo=$ac_try;;
19222 esac
19223 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19224 $as_echo "$ac_try_echo") >&5
19225   (eval "$ac_link") 2>conftest.er1
19226   ac_status=$?
19227   grep -v '^ *+' conftest.er1 >conftest.err
19228   rm -f conftest.er1
19229   cat conftest.err >&5
19230   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19231   (exit $ac_status); } && {
19232          test -z "$ac_c_werror_flag" ||
19233          test ! -s conftest.err
19234        } && test -s conftest$ac_exeext && {
19235          test "$cross_compiling" = yes ||
19236          $as_test_x conftest$ac_exeext
19237        }; then
19238   eval "$as_ac_var=yes"
19239 else
19240   $as_echo "$as_me: failed program was:" >&5
19241 sed 's/^/| /' conftest.$ac_ext >&5
19242
19243         eval "$as_ac_var=no"
19244 fi
19245
19246 rm -rf conftest.dSYM
19247 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19248       conftest$ac_exeext conftest.$ac_ext
19249 fi
19250 ac_res=`eval 'as_val=${'$as_ac_var'}
19251                  $as_echo "$as_val"'`
19252                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19253 $as_echo "$ac_res" >&6; }
19254 as_val=`eval 'as_val=${'$as_ac_var'}
19255                  $as_echo "$as_val"'`
19256    if test "x$as_val" = x""yes; then
19257   cat >>confdefs.h <<_ACEOF
19258 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19259 _ACEOF
19260
19261 else
19262   case " $LIBOBJS " in
19263   *" $ac_func.$ac_objext "* ) ;;
19264   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
19265  ;;
19266 esac
19267
19268 fi
19269 done
19270
19271
19272 case " $LIBOBJS " in
19273   *" kill.$ac_objext "* ) ;;
19274   *) LIBOBJS="$LIBOBJS kill.$ac_objext"
19275  ;;
19276 esac
19277
19278 case " $LIBOBJS " in
19279   *" open.$ac_objext "* ) ;;
19280   *) LIBOBJS="$LIBOBJS open.$ac_objext"
19281  ;;
19282 esac
19283
19284 case " $LIBOBJS " in
19285   *" win32env.$ac_objext "* ) ;;
19286   *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
19287  ;;
19288 esac
19289
19290 case " $LIBOBJS " in
19291   *" win32error.$ac_objext "* ) ;;
19292   *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
19293  ;;
19294 esac
19295
19296
19297 cat >>confdefs.h <<\_ACEOF
19298 #define HAVE_SYMLINK 1
19299 _ACEOF
19300
19301 fi
19302
19303 if test "$with_readline" = yes; then
19304   { $as_echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
19305 $as_echo_n "checking for rl_completion_append_character... " >&6; }
19306 cat >conftest.$ac_ext <<_ACEOF
19307 /* confdefs.h.  */
19308 _ACEOF
19309 cat confdefs.h >>conftest.$ac_ext
19310 cat >>conftest.$ac_ext <<_ACEOF
19311 /* end confdefs.h.  */
19312 #include <stdio.h>
19313 #ifdef HAVE_READLINE_READLINE_H
19314 # include <readline/readline.h>
19315 #elif defined(HAVE_READLINE_H)
19316 # include <readline.h>
19317 #endif
19318
19319 int
19320 main ()
19321 {
19322 rl_completion_append_character = 'x';
19323   ;
19324   return 0;
19325 }
19326 _ACEOF
19327 rm -f conftest.$ac_objext conftest$ac_exeext
19328 if { (ac_try="$ac_link"
19329 case "(($ac_try" in
19330   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19331   *) ac_try_echo=$ac_try;;
19332 esac
19333 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19334 $as_echo "$ac_try_echo") >&5
19335   (eval "$ac_link") 2>conftest.er1
19336   ac_status=$?
19337   grep -v '^ *+' conftest.er1 >conftest.err
19338   rm -f conftest.er1
19339   cat conftest.err >&5
19340   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19341   (exit $ac_status); } && {
19342          test -z "$ac_c_werror_flag" ||
19343          test ! -s conftest.err
19344        } && test -s conftest$ac_exeext && {
19345          test "$cross_compiling" = yes ||
19346          $as_test_x conftest$ac_exeext
19347        }; then
19348   { $as_echo "$as_me:$LINENO: result: yes" >&5
19349 $as_echo "yes" >&6; }
19350
19351 cat >>confdefs.h <<\_ACEOF
19352 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
19353 _ACEOF
19354
19355 else
19356   $as_echo "$as_me: failed program was:" >&5
19357 sed 's/^/| /' conftest.$ac_ext >&5
19358
19359         { $as_echo "$as_me:$LINENO: result: no" >&5
19360 $as_echo "no" >&6; }
19361 fi
19362
19363 rm -rf conftest.dSYM
19364 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19365       conftest$ac_exeext conftest.$ac_ext
19366
19367
19368 for ac_func in rl_completion_matches rl_filename_completion_function
19369 do
19370 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19371 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19372 $as_echo_n "checking for $ac_func... " >&6; }
19373 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19374   $as_echo_n "(cached) " >&6
19375 else
19376   cat >conftest.$ac_ext <<_ACEOF
19377 /* confdefs.h.  */
19378 _ACEOF
19379 cat confdefs.h >>conftest.$ac_ext
19380 cat >>conftest.$ac_ext <<_ACEOF
19381 /* end confdefs.h.  */
19382 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19383    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19384 #define $ac_func innocuous_$ac_func
19385
19386 /* System header to define __stub macros and hopefully few prototypes,
19387     which can conflict with char $ac_func (); below.
19388     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19389     <limits.h> exists even on freestanding compilers.  */
19390
19391 #ifdef __STDC__
19392 # include <limits.h>
19393 #else
19394 # include <assert.h>
19395 #endif
19396
19397 #undef $ac_func
19398
19399 /* Override any GCC internal prototype to avoid an error.
19400    Use char because int might match the return type of a GCC
19401    builtin and then its argument prototype would still apply.  */
19402 #ifdef __cplusplus
19403 extern "C"
19404 #endif
19405 char $ac_func ();
19406 /* The GNU C library defines this for functions which it implements
19407     to always fail with ENOSYS.  Some functions are actually named
19408     something starting with __ and the normal name is an alias.  */
19409 #if defined __stub_$ac_func || defined __stub___$ac_func
19410 choke me
19411 #endif
19412
19413 int
19414 main ()
19415 {
19416 return $ac_func ();
19417   ;
19418   return 0;
19419 }
19420 _ACEOF
19421 rm -f conftest.$ac_objext conftest$ac_exeext
19422 if { (ac_try="$ac_link"
19423 case "(($ac_try" in
19424   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19425   *) ac_try_echo=$ac_try;;
19426 esac
19427 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19428 $as_echo "$ac_try_echo") >&5
19429   (eval "$ac_link") 2>conftest.er1
19430   ac_status=$?
19431   grep -v '^ *+' conftest.er1 >conftest.err
19432   rm -f conftest.er1
19433   cat conftest.err >&5
19434   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19435   (exit $ac_status); } && {
19436          test -z "$ac_c_werror_flag" ||
19437          test ! -s conftest.err
19438        } && test -s conftest$ac_exeext && {
19439          test "$cross_compiling" = yes ||
19440          $as_test_x conftest$ac_exeext
19441        }; then
19442   eval "$as_ac_var=yes"
19443 else
19444   $as_echo "$as_me: failed program was:" >&5
19445 sed 's/^/| /' conftest.$ac_ext >&5
19446
19447         eval "$as_ac_var=no"
19448 fi
19449
19450 rm -rf conftest.dSYM
19451 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19452       conftest$ac_exeext conftest.$ac_ext
19453 fi
19454 ac_res=`eval 'as_val=${'$as_ac_var'}
19455                  $as_echo "$as_val"'`
19456                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19457 $as_echo "$ac_res" >&6; }
19458 as_val=`eval 'as_val=${'$as_ac_var'}
19459                  $as_echo "$as_val"'`
19460    if test "x$as_val" = x""yes; then
19461   cat >>confdefs.h <<_ACEOF
19462 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19463 _ACEOF
19464
19465 fi
19466 done
19467
19468
19469
19470 for ac_func in append_history history_truncate_file
19471 do
19472 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19473 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19474 $as_echo_n "checking for $ac_func... " >&6; }
19475 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19476   $as_echo_n "(cached) " >&6
19477 else
19478   cat >conftest.$ac_ext <<_ACEOF
19479 /* confdefs.h.  */
19480 _ACEOF
19481 cat confdefs.h >>conftest.$ac_ext
19482 cat >>conftest.$ac_ext <<_ACEOF
19483 /* end confdefs.h.  */
19484 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19485    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19486 #define $ac_func innocuous_$ac_func
19487
19488 /* System header to define __stub macros and hopefully few prototypes,
19489     which can conflict with char $ac_func (); below.
19490     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19491     <limits.h> exists even on freestanding compilers.  */
19492
19493 #ifdef __STDC__
19494 # include <limits.h>
19495 #else
19496 # include <assert.h>
19497 #endif
19498
19499 #undef $ac_func
19500
19501 /* Override any GCC internal prototype to avoid an error.
19502    Use char because int might match the return type of a GCC
19503    builtin and then its argument prototype would still apply.  */
19504 #ifdef __cplusplus
19505 extern "C"
19506 #endif
19507 char $ac_func ();
19508 /* The GNU C library defines this for functions which it implements
19509     to always fail with ENOSYS.  Some functions are actually named
19510     something starting with __ and the normal name is an alias.  */
19511 #if defined __stub_$ac_func || defined __stub___$ac_func
19512 choke me
19513 #endif
19514
19515 int
19516 main ()
19517 {
19518 return $ac_func ();
19519   ;
19520   return 0;
19521 }
19522 _ACEOF
19523 rm -f conftest.$ac_objext conftest$ac_exeext
19524 if { (ac_try="$ac_link"
19525 case "(($ac_try" in
19526   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19527   *) ac_try_echo=$ac_try;;
19528 esac
19529 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19530 $as_echo "$ac_try_echo") >&5
19531   (eval "$ac_link") 2>conftest.er1
19532   ac_status=$?
19533   grep -v '^ *+' conftest.er1 >conftest.err
19534   rm -f conftest.er1
19535   cat conftest.err >&5
19536   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19537   (exit $ac_status); } && {
19538          test -z "$ac_c_werror_flag" ||
19539          test ! -s conftest.err
19540        } && test -s conftest$ac_exeext && {
19541          test "$cross_compiling" = yes ||
19542          $as_test_x conftest$ac_exeext
19543        }; then
19544   eval "$as_ac_var=yes"
19545 else
19546   $as_echo "$as_me: failed program was:" >&5
19547 sed 's/^/| /' conftest.$ac_ext >&5
19548
19549         eval "$as_ac_var=no"
19550 fi
19551
19552 rm -rf conftest.dSYM
19553 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19554       conftest$ac_exeext conftest.$ac_ext
19555 fi
19556 ac_res=`eval 'as_val=${'$as_ac_var'}
19557                  $as_echo "$as_val"'`
19558                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19559 $as_echo "$ac_res" >&6; }
19560 as_val=`eval 'as_val=${'$as_ac_var'}
19561                  $as_echo "$as_val"'`
19562    if test "x$as_val" = x""yes; then
19563   cat >>confdefs.h <<_ACEOF
19564 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19565 _ACEOF
19566
19567 fi
19568 done
19569
19570 fi
19571
19572
19573 { $as_echo "$as_me:$LINENO: checking for sigsetjmp" >&5
19574 $as_echo_n "checking for sigsetjmp... " >&6; }
19575 cat >conftest.$ac_ext <<_ACEOF
19576 /* confdefs.h.  */
19577 _ACEOF
19578 cat confdefs.h >>conftest.$ac_ext
19579 cat >>conftest.$ac_ext <<_ACEOF
19580 /* end confdefs.h.  */
19581 #include <setjmp.h>
19582 int
19583 main ()
19584 {
19585 sigjmp_buf x; sigsetjmp(x, 1);
19586   ;
19587   return 0;
19588 }
19589 _ACEOF
19590 rm -f conftest.$ac_objext conftest$ac_exeext
19591 if { (ac_try="$ac_link"
19592 case "(($ac_try" in
19593   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19594   *) ac_try_echo=$ac_try;;
19595 esac
19596 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19597 $as_echo "$ac_try_echo") >&5
19598   (eval "$ac_link") 2>conftest.er1
19599   ac_status=$?
19600   grep -v '^ *+' conftest.er1 >conftest.err
19601   rm -f conftest.er1
19602   cat conftest.err >&5
19603   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19604   (exit $ac_status); } && {
19605          test -z "$ac_c_werror_flag" ||
19606          test ! -s conftest.err
19607        } && test -s conftest$ac_exeext && {
19608          test "$cross_compiling" = yes ||
19609          $as_test_x conftest$ac_exeext
19610        }; then
19611
19612 cat >>confdefs.h <<\_ACEOF
19613 #define HAVE_SIGSETJMP 1
19614 _ACEOF
19615
19616 { $as_echo "$as_me:$LINENO: result: yes" >&5
19617 $as_echo "yes" >&6; }
19618 else
19619   $as_echo "$as_me: failed program was:" >&5
19620 sed 's/^/| /' conftest.$ac_ext >&5
19621
19622         { $as_echo "$as_me:$LINENO: result: no" >&5
19623 $as_echo "no" >&6; }
19624 fi
19625
19626 rm -rf conftest.dSYM
19627 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19628       conftest$ac_exeext conftest.$ac_ext
19629
19630 { $as_echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
19631 $as_echo_n "checking whether sys_siglist is declared... " >&6; }
19632 if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
19633   $as_echo_n "(cached) " >&6
19634 else
19635   cat >conftest.$ac_ext <<_ACEOF
19636 /* confdefs.h.  */
19637 _ACEOF
19638 cat confdefs.h >>conftest.$ac_ext
19639 cat >>conftest.$ac_ext <<_ACEOF
19640 /* end confdefs.h.  */
19641 #include <signal.h>
19642 /* NetBSD declares sys_siglist in unistd.h.  */
19643 #ifdef HAVE_UNISTD_H
19644 # include <unistd.h>
19645 #endif
19646
19647
19648 int
19649 main ()
19650 {
19651 #ifndef sys_siglist
19652   (void) sys_siglist;
19653 #endif
19654
19655   ;
19656   return 0;
19657 }
19658 _ACEOF
19659 rm -f conftest.$ac_objext
19660 if { (ac_try="$ac_compile"
19661 case "(($ac_try" in
19662   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19663   *) ac_try_echo=$ac_try;;
19664 esac
19665 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19666 $as_echo "$ac_try_echo") >&5
19667   (eval "$ac_compile") 2>conftest.er1
19668   ac_status=$?
19669   grep -v '^ *+' conftest.er1 >conftest.err
19670   rm -f conftest.er1
19671   cat conftest.err >&5
19672   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19673   (exit $ac_status); } && {
19674          test -z "$ac_c_werror_flag" ||
19675          test ! -s conftest.err
19676        } && test -s conftest.$ac_objext; then
19677   ac_cv_have_decl_sys_siglist=yes
19678 else
19679   $as_echo "$as_me: failed program was:" >&5
19680 sed 's/^/| /' conftest.$ac_ext >&5
19681
19682         ac_cv_have_decl_sys_siglist=no
19683 fi
19684
19685 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19686 fi
19687 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
19688 $as_echo "$ac_cv_have_decl_sys_siglist" >&6; }
19689 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then
19690
19691 cat >>confdefs.h <<_ACEOF
19692 #define HAVE_DECL_SYS_SIGLIST 1
19693 _ACEOF
19694
19695
19696 else
19697   cat >>confdefs.h <<_ACEOF
19698 #define HAVE_DECL_SYS_SIGLIST 0
19699 _ACEOF
19700
19701
19702 fi
19703
19704
19705
19706
19707 { $as_echo "$as_me:$LINENO: checking for syslog" >&5
19708 $as_echo_n "checking for syslog... " >&6; }
19709 if test "${ac_cv_func_syslog+set}" = set; then
19710   $as_echo_n "(cached) " >&6
19711 else
19712   cat >conftest.$ac_ext <<_ACEOF
19713 /* confdefs.h.  */
19714 _ACEOF
19715 cat confdefs.h >>conftest.$ac_ext
19716 cat >>conftest.$ac_ext <<_ACEOF
19717 /* end confdefs.h.  */
19718 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
19719    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19720 #define syslog innocuous_syslog
19721
19722 /* System header to define __stub macros and hopefully few prototypes,
19723     which can conflict with char syslog (); below.
19724     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19725     <limits.h> exists even on freestanding compilers.  */
19726
19727 #ifdef __STDC__
19728 # include <limits.h>
19729 #else
19730 # include <assert.h>
19731 #endif
19732
19733 #undef syslog
19734
19735 /* Override any GCC internal prototype to avoid an error.
19736    Use char because int might match the return type of a GCC
19737    builtin and then its argument prototype would still apply.  */
19738 #ifdef __cplusplus
19739 extern "C"
19740 #endif
19741 char syslog ();
19742 /* The GNU C library defines this for functions which it implements
19743     to always fail with ENOSYS.  Some functions are actually named
19744     something starting with __ and the normal name is an alias.  */
19745 #if defined __stub_syslog || defined __stub___syslog
19746 choke me
19747 #endif
19748
19749 int
19750 main ()
19751 {
19752 return syslog ();
19753   ;
19754   return 0;
19755 }
19756 _ACEOF
19757 rm -f conftest.$ac_objext conftest$ac_exeext
19758 if { (ac_try="$ac_link"
19759 case "(($ac_try" in
19760   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19761   *) ac_try_echo=$ac_try;;
19762 esac
19763 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19764 $as_echo "$ac_try_echo") >&5
19765   (eval "$ac_link") 2>conftest.er1
19766   ac_status=$?
19767   grep -v '^ *+' conftest.er1 >conftest.err
19768   rm -f conftest.er1
19769   cat conftest.err >&5
19770   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19771   (exit $ac_status); } && {
19772          test -z "$ac_c_werror_flag" ||
19773          test ! -s conftest.err
19774        } && test -s conftest$ac_exeext && {
19775          test "$cross_compiling" = yes ||
19776          $as_test_x conftest$ac_exeext
19777        }; then
19778   ac_cv_func_syslog=yes
19779 else
19780   $as_echo "$as_me: failed program was:" >&5
19781 sed 's/^/| /' conftest.$ac_ext >&5
19782
19783         ac_cv_func_syslog=no
19784 fi
19785
19786 rm -rf conftest.dSYM
19787 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19788       conftest$ac_exeext conftest.$ac_ext
19789 fi
19790 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
19791 $as_echo "$ac_cv_func_syslog" >&6; }
19792 if test "x$ac_cv_func_syslog" = x""yes; then
19793   if test "${ac_cv_header_syslog_h+set}" = set; then
19794   { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
19795 $as_echo_n "checking for syslog.h... " >&6; }
19796 if test "${ac_cv_header_syslog_h+set}" = set; then
19797   $as_echo_n "(cached) " >&6
19798 fi
19799 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
19800 $as_echo "$ac_cv_header_syslog_h" >&6; }
19801 else
19802   # Is the header compilable?
19803 { $as_echo "$as_me:$LINENO: checking syslog.h usability" >&5
19804 $as_echo_n "checking syslog.h usability... " >&6; }
19805 cat >conftest.$ac_ext <<_ACEOF
19806 /* confdefs.h.  */
19807 _ACEOF
19808 cat confdefs.h >>conftest.$ac_ext
19809 cat >>conftest.$ac_ext <<_ACEOF
19810 /* end confdefs.h.  */
19811 $ac_includes_default
19812 #include <syslog.h>
19813 _ACEOF
19814 rm -f conftest.$ac_objext
19815 if { (ac_try="$ac_compile"
19816 case "(($ac_try" in
19817   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19818   *) ac_try_echo=$ac_try;;
19819 esac
19820 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19821 $as_echo "$ac_try_echo") >&5
19822   (eval "$ac_compile") 2>conftest.er1
19823   ac_status=$?
19824   grep -v '^ *+' conftest.er1 >conftest.err
19825   rm -f conftest.er1
19826   cat conftest.err >&5
19827   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19828   (exit $ac_status); } && {
19829          test -z "$ac_c_werror_flag" ||
19830          test ! -s conftest.err
19831        } && test -s conftest.$ac_objext; then
19832   ac_header_compiler=yes
19833 else
19834   $as_echo "$as_me: failed program was:" >&5
19835 sed 's/^/| /' conftest.$ac_ext >&5
19836
19837         ac_header_compiler=no
19838 fi
19839
19840 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19841 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
19842 $as_echo "$ac_header_compiler" >&6; }
19843
19844 # Is the header present?
19845 { $as_echo "$as_me:$LINENO: checking syslog.h presence" >&5
19846 $as_echo_n "checking syslog.h presence... " >&6; }
19847 cat >conftest.$ac_ext <<_ACEOF
19848 /* confdefs.h.  */
19849 _ACEOF
19850 cat confdefs.h >>conftest.$ac_ext
19851 cat >>conftest.$ac_ext <<_ACEOF
19852 /* end confdefs.h.  */
19853 #include <syslog.h>
19854 _ACEOF
19855 if { (ac_try="$ac_cpp conftest.$ac_ext"
19856 case "(($ac_try" in
19857   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19858   *) ac_try_echo=$ac_try;;
19859 esac
19860 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19861 $as_echo "$ac_try_echo") >&5
19862   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
19863   ac_status=$?
19864   grep -v '^ *+' conftest.er1 >conftest.err
19865   rm -f conftest.er1
19866   cat conftest.err >&5
19867   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19868   (exit $ac_status); } >/dev/null && {
19869          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
19870          test ! -s conftest.err
19871        }; then
19872   ac_header_preproc=yes
19873 else
19874   $as_echo "$as_me: failed program was:" >&5
19875 sed 's/^/| /' conftest.$ac_ext >&5
19876
19877   ac_header_preproc=no
19878 fi
19879
19880 rm -f conftest.err conftest.$ac_ext
19881 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
19882 $as_echo "$ac_header_preproc" >&6; }
19883
19884 # So?  What about this header?
19885 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
19886   yes:no: )
19887     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
19888 $as_echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
19889     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
19890 $as_echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
19891     ac_header_preproc=yes
19892     ;;
19893   no:yes:* )
19894     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
19895 $as_echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
19896     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
19897 $as_echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
19898     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
19899 $as_echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
19900     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
19901 $as_echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
19902     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
19903 $as_echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
19904     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
19905 $as_echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
19906     ( cat <<\_ASBOX
19907 ## ---------------------------------------- ##
19908 ## Report this to pgsql-bugs@postgresql.org ##
19909 ## ---------------------------------------- ##
19910 _ASBOX
19911      ) | sed "s/^/$as_me: WARNING:     /" >&2
19912     ;;
19913 esac
19914 { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
19915 $as_echo_n "checking for syslog.h... " >&6; }
19916 if test "${ac_cv_header_syslog_h+set}" = set; then
19917   $as_echo_n "(cached) " >&6
19918 else
19919   ac_cv_header_syslog_h=$ac_header_preproc
19920 fi
19921 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
19922 $as_echo "$ac_cv_header_syslog_h" >&6; }
19923
19924 fi
19925 if test "x$ac_cv_header_syslog_h" = x""yes; then
19926
19927 cat >>confdefs.h <<\_ACEOF
19928 #define HAVE_SYSLOG 1
19929 _ACEOF
19930
19931 fi
19932
19933
19934 fi
19935
19936
19937 { $as_echo "$as_me:$LINENO: checking for opterr" >&5
19938 $as_echo_n "checking for opterr... " >&6; }
19939 if test "${pgac_cv_var_int_opterr+set}" = set; then
19940   $as_echo_n "(cached) " >&6
19941 else
19942   cat >conftest.$ac_ext <<_ACEOF
19943 /* confdefs.h.  */
19944 _ACEOF
19945 cat confdefs.h >>conftest.$ac_ext
19946 cat >>conftest.$ac_ext <<_ACEOF
19947 /* end confdefs.h.  */
19948 #include <unistd.h>
19949 int
19950 main ()
19951 {
19952 extern int opterr; opterr = 1;
19953   ;
19954   return 0;
19955 }
19956 _ACEOF
19957 rm -f conftest.$ac_objext conftest$ac_exeext
19958 if { (ac_try="$ac_link"
19959 case "(($ac_try" in
19960   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19961   *) ac_try_echo=$ac_try;;
19962 esac
19963 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19964 $as_echo "$ac_try_echo") >&5
19965   (eval "$ac_link") 2>conftest.er1
19966   ac_status=$?
19967   grep -v '^ *+' conftest.er1 >conftest.err
19968   rm -f conftest.er1
19969   cat conftest.err >&5
19970   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19971   (exit $ac_status); } && {
19972          test -z "$ac_c_werror_flag" ||
19973          test ! -s conftest.err
19974        } && test -s conftest$ac_exeext && {
19975          test "$cross_compiling" = yes ||
19976          $as_test_x conftest$ac_exeext
19977        }; then
19978   pgac_cv_var_int_opterr=yes
19979 else
19980   $as_echo "$as_me: failed program was:" >&5
19981 sed 's/^/| /' conftest.$ac_ext >&5
19982
19983         pgac_cv_var_int_opterr=no
19984 fi
19985
19986 rm -rf conftest.dSYM
19987 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19988       conftest$ac_exeext conftest.$ac_ext
19989 fi
19990 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_opterr" >&5
19991 $as_echo "$pgac_cv_var_int_opterr" >&6; }
19992 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
19993
19994 cat >>confdefs.h <<\_ACEOF
19995 #define HAVE_INT_OPTERR 1
19996 _ACEOF
19997
19998 fi
19999
20000 { $as_echo "$as_me:$LINENO: checking for optreset" >&5
20001 $as_echo_n "checking for optreset... " >&6; }
20002 if test "${pgac_cv_var_int_optreset+set}" = set; then
20003   $as_echo_n "(cached) " >&6
20004 else
20005   cat >conftest.$ac_ext <<_ACEOF
20006 /* confdefs.h.  */
20007 _ACEOF
20008 cat confdefs.h >>conftest.$ac_ext
20009 cat >>conftest.$ac_ext <<_ACEOF
20010 /* end confdefs.h.  */
20011 #include <unistd.h>
20012 int
20013 main ()
20014 {
20015 extern int optreset; optreset = 1;
20016   ;
20017   return 0;
20018 }
20019 _ACEOF
20020 rm -f conftest.$ac_objext conftest$ac_exeext
20021 if { (ac_try="$ac_link"
20022 case "(($ac_try" in
20023   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20024   *) ac_try_echo=$ac_try;;
20025 esac
20026 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20027 $as_echo "$ac_try_echo") >&5
20028   (eval "$ac_link") 2>conftest.er1
20029   ac_status=$?
20030   grep -v '^ *+' conftest.er1 >conftest.err
20031   rm -f conftest.er1
20032   cat conftest.err >&5
20033   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20034   (exit $ac_status); } && {
20035          test -z "$ac_c_werror_flag" ||
20036          test ! -s conftest.err
20037        } && test -s conftest$ac_exeext && {
20038          test "$cross_compiling" = yes ||
20039          $as_test_x conftest$ac_exeext
20040        }; then
20041   pgac_cv_var_int_optreset=yes
20042 else
20043   $as_echo "$as_me: failed program was:" >&5
20044 sed 's/^/| /' conftest.$ac_ext >&5
20045
20046         pgac_cv_var_int_optreset=no
20047 fi
20048
20049 rm -rf conftest.dSYM
20050 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20051       conftest$ac_exeext conftest.$ac_ext
20052 fi
20053 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
20054 $as_echo "$pgac_cv_var_int_optreset" >&6; }
20055 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
20056
20057 cat >>confdefs.h <<\_ACEOF
20058 #define HAVE_INT_OPTRESET 1
20059 _ACEOF
20060
20061 fi
20062
20063
20064
20065 for ac_func in strtoll strtoq
20066 do
20067 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20068 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20069 $as_echo_n "checking for $ac_func... " >&6; }
20070 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20071   $as_echo_n "(cached) " >&6
20072 else
20073   cat >conftest.$ac_ext <<_ACEOF
20074 /* confdefs.h.  */
20075 _ACEOF
20076 cat confdefs.h >>conftest.$ac_ext
20077 cat >>conftest.$ac_ext <<_ACEOF
20078 /* end confdefs.h.  */
20079 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20080    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20081 #define $ac_func innocuous_$ac_func
20082
20083 /* System header to define __stub macros and hopefully few prototypes,
20084     which can conflict with char $ac_func (); below.
20085     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20086     <limits.h> exists even on freestanding compilers.  */
20087
20088 #ifdef __STDC__
20089 # include <limits.h>
20090 #else
20091 # include <assert.h>
20092 #endif
20093
20094 #undef $ac_func
20095
20096 /* Override any GCC internal prototype to avoid an error.
20097    Use char because int might match the return type of a GCC
20098    builtin and then its argument prototype would still apply.  */
20099 #ifdef __cplusplus
20100 extern "C"
20101 #endif
20102 char $ac_func ();
20103 /* The GNU C library defines this for functions which it implements
20104     to always fail with ENOSYS.  Some functions are actually named
20105     something starting with __ and the normal name is an alias.  */
20106 #if defined __stub_$ac_func || defined __stub___$ac_func
20107 choke me
20108 #endif
20109
20110 int
20111 main ()
20112 {
20113 return $ac_func ();
20114   ;
20115   return 0;
20116 }
20117 _ACEOF
20118 rm -f conftest.$ac_objext conftest$ac_exeext
20119 if { (ac_try="$ac_link"
20120 case "(($ac_try" in
20121   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20122   *) ac_try_echo=$ac_try;;
20123 esac
20124 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20125 $as_echo "$ac_try_echo") >&5
20126   (eval "$ac_link") 2>conftest.er1
20127   ac_status=$?
20128   grep -v '^ *+' conftest.er1 >conftest.err
20129   rm -f conftest.er1
20130   cat conftest.err >&5
20131   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20132   (exit $ac_status); } && {
20133          test -z "$ac_c_werror_flag" ||
20134          test ! -s conftest.err
20135        } && test -s conftest$ac_exeext && {
20136          test "$cross_compiling" = yes ||
20137          $as_test_x conftest$ac_exeext
20138        }; then
20139   eval "$as_ac_var=yes"
20140 else
20141   $as_echo "$as_me: failed program was:" >&5
20142 sed 's/^/| /' conftest.$ac_ext >&5
20143
20144         eval "$as_ac_var=no"
20145 fi
20146
20147 rm -rf conftest.dSYM
20148 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20149       conftest$ac_exeext conftest.$ac_ext
20150 fi
20151 ac_res=`eval 'as_val=${'$as_ac_var'}
20152                  $as_echo "$as_val"'`
20153                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20154 $as_echo "$ac_res" >&6; }
20155 as_val=`eval 'as_val=${'$as_ac_var'}
20156                  $as_echo "$as_val"'`
20157    if test "x$as_val" = x""yes; then
20158   cat >>confdefs.h <<_ACEOF
20159 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20160 _ACEOF
20161  break
20162 fi
20163 done
20164
20165
20166
20167 for ac_func in strtoull strtouq
20168 do
20169 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20170 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20171 $as_echo_n "checking for $ac_func... " >&6; }
20172 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20173   $as_echo_n "(cached) " >&6
20174 else
20175   cat >conftest.$ac_ext <<_ACEOF
20176 /* confdefs.h.  */
20177 _ACEOF
20178 cat confdefs.h >>conftest.$ac_ext
20179 cat >>conftest.$ac_ext <<_ACEOF
20180 /* end confdefs.h.  */
20181 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20182    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20183 #define $ac_func innocuous_$ac_func
20184
20185 /* System header to define __stub macros and hopefully few prototypes,
20186     which can conflict with char $ac_func (); below.
20187     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20188     <limits.h> exists even on freestanding compilers.  */
20189
20190 #ifdef __STDC__
20191 # include <limits.h>
20192 #else
20193 # include <assert.h>
20194 #endif
20195
20196 #undef $ac_func
20197
20198 /* Override any GCC internal prototype to avoid an error.
20199    Use char because int might match the return type of a GCC
20200    builtin and then its argument prototype would still apply.  */
20201 #ifdef __cplusplus
20202 extern "C"
20203 #endif
20204 char $ac_func ();
20205 /* The GNU C library defines this for functions which it implements
20206     to always fail with ENOSYS.  Some functions are actually named
20207     something starting with __ and the normal name is an alias.  */
20208 #if defined __stub_$ac_func || defined __stub___$ac_func
20209 choke me
20210 #endif
20211
20212 int
20213 main ()
20214 {
20215 return $ac_func ();
20216   ;
20217   return 0;
20218 }
20219 _ACEOF
20220 rm -f conftest.$ac_objext conftest$ac_exeext
20221 if { (ac_try="$ac_link"
20222 case "(($ac_try" in
20223   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20224   *) ac_try_echo=$ac_try;;
20225 esac
20226 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20227 $as_echo "$ac_try_echo") >&5
20228   (eval "$ac_link") 2>conftest.er1
20229   ac_status=$?
20230   grep -v '^ *+' conftest.er1 >conftest.err
20231   rm -f conftest.er1
20232   cat conftest.err >&5
20233   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20234   (exit $ac_status); } && {
20235          test -z "$ac_c_werror_flag" ||
20236          test ! -s conftest.err
20237        } && test -s conftest$ac_exeext && {
20238          test "$cross_compiling" = yes ||
20239          $as_test_x conftest$ac_exeext
20240        }; then
20241   eval "$as_ac_var=yes"
20242 else
20243   $as_echo "$as_me: failed program was:" >&5
20244 sed 's/^/| /' conftest.$ac_ext >&5
20245
20246         eval "$as_ac_var=no"
20247 fi
20248
20249 rm -rf conftest.dSYM
20250 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20251       conftest$ac_exeext conftest.$ac_ext
20252 fi
20253 ac_res=`eval 'as_val=${'$as_ac_var'}
20254                  $as_echo "$as_val"'`
20255                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20256 $as_echo "$ac_res" >&6; }
20257 as_val=`eval 'as_val=${'$as_ac_var'}
20258                  $as_echo "$as_val"'`
20259    if test "x$as_val" = x""yes; then
20260   cat >>confdefs.h <<_ACEOF
20261 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20262 _ACEOF
20263  break
20264 fi
20265 done
20266
20267
20268 # Check for one of atexit() or on_exit()
20269
20270 for ac_func in atexit
20271 do
20272 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20273 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20274 $as_echo_n "checking for $ac_func... " >&6; }
20275 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20276   $as_echo_n "(cached) " >&6
20277 else
20278   cat >conftest.$ac_ext <<_ACEOF
20279 /* confdefs.h.  */
20280 _ACEOF
20281 cat confdefs.h >>conftest.$ac_ext
20282 cat >>conftest.$ac_ext <<_ACEOF
20283 /* end confdefs.h.  */
20284 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20285    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20286 #define $ac_func innocuous_$ac_func
20287
20288 /* System header to define __stub macros and hopefully few prototypes,
20289     which can conflict with char $ac_func (); below.
20290     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20291     <limits.h> exists even on freestanding compilers.  */
20292
20293 #ifdef __STDC__
20294 # include <limits.h>
20295 #else
20296 # include <assert.h>
20297 #endif
20298
20299 #undef $ac_func
20300
20301 /* Override any GCC internal prototype to avoid an error.
20302    Use char because int might match the return type of a GCC
20303    builtin and then its argument prototype would still apply.  */
20304 #ifdef __cplusplus
20305 extern "C"
20306 #endif
20307 char $ac_func ();
20308 /* The GNU C library defines this for functions which it implements
20309     to always fail with ENOSYS.  Some functions are actually named
20310     something starting with __ and the normal name is an alias.  */
20311 #if defined __stub_$ac_func || defined __stub___$ac_func
20312 choke me
20313 #endif
20314
20315 int
20316 main ()
20317 {
20318 return $ac_func ();
20319   ;
20320   return 0;
20321 }
20322 _ACEOF
20323 rm -f conftest.$ac_objext conftest$ac_exeext
20324 if { (ac_try="$ac_link"
20325 case "(($ac_try" in
20326   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20327   *) ac_try_echo=$ac_try;;
20328 esac
20329 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20330 $as_echo "$ac_try_echo") >&5
20331   (eval "$ac_link") 2>conftest.er1
20332   ac_status=$?
20333   grep -v '^ *+' conftest.er1 >conftest.err
20334   rm -f conftest.er1
20335   cat conftest.err >&5
20336   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20337   (exit $ac_status); } && {
20338          test -z "$ac_c_werror_flag" ||
20339          test ! -s conftest.err
20340        } && test -s conftest$ac_exeext && {
20341          test "$cross_compiling" = yes ||
20342          $as_test_x conftest$ac_exeext
20343        }; then
20344   eval "$as_ac_var=yes"
20345 else
20346   $as_echo "$as_me: failed program was:" >&5
20347 sed 's/^/| /' conftest.$ac_ext >&5
20348
20349         eval "$as_ac_var=no"
20350 fi
20351
20352 rm -rf conftest.dSYM
20353 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20354       conftest$ac_exeext conftest.$ac_ext
20355 fi
20356 ac_res=`eval 'as_val=${'$as_ac_var'}
20357                  $as_echo "$as_val"'`
20358                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20359 $as_echo "$ac_res" >&6; }
20360 as_val=`eval 'as_val=${'$as_ac_var'}
20361                  $as_echo "$as_val"'`
20362    if test "x$as_val" = x""yes; then
20363   cat >>confdefs.h <<_ACEOF
20364 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20365 _ACEOF
20366
20367 else
20368
20369 for ac_func in on_exit
20370 do
20371 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20372 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20373 $as_echo_n "checking for $ac_func... " >&6; }
20374 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20375   $as_echo_n "(cached) " >&6
20376 else
20377   cat >conftest.$ac_ext <<_ACEOF
20378 /* confdefs.h.  */
20379 _ACEOF
20380 cat confdefs.h >>conftest.$ac_ext
20381 cat >>conftest.$ac_ext <<_ACEOF
20382 /* end confdefs.h.  */
20383 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20384    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20385 #define $ac_func innocuous_$ac_func
20386
20387 /* System header to define __stub macros and hopefully few prototypes,
20388     which can conflict with char $ac_func (); below.
20389     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20390     <limits.h> exists even on freestanding compilers.  */
20391
20392 #ifdef __STDC__
20393 # include <limits.h>
20394 #else
20395 # include <assert.h>
20396 #endif
20397
20398 #undef $ac_func
20399
20400 /* Override any GCC internal prototype to avoid an error.
20401    Use char because int might match the return type of a GCC
20402    builtin and then its argument prototype would still apply.  */
20403 #ifdef __cplusplus
20404 extern "C"
20405 #endif
20406 char $ac_func ();
20407 /* The GNU C library defines this for functions which it implements
20408     to always fail with ENOSYS.  Some functions are actually named
20409     something starting with __ and the normal name is an alias.  */
20410 #if defined __stub_$ac_func || defined __stub___$ac_func
20411 choke me
20412 #endif
20413
20414 int
20415 main ()
20416 {
20417 return $ac_func ();
20418   ;
20419   return 0;
20420 }
20421 _ACEOF
20422 rm -f conftest.$ac_objext conftest$ac_exeext
20423 if { (ac_try="$ac_link"
20424 case "(($ac_try" in
20425   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20426   *) ac_try_echo=$ac_try;;
20427 esac
20428 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20429 $as_echo "$ac_try_echo") >&5
20430   (eval "$ac_link") 2>conftest.er1
20431   ac_status=$?
20432   grep -v '^ *+' conftest.er1 >conftest.err
20433   rm -f conftest.er1
20434   cat conftest.err >&5
20435   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20436   (exit $ac_status); } && {
20437          test -z "$ac_c_werror_flag" ||
20438          test ! -s conftest.err
20439        } && test -s conftest$ac_exeext && {
20440          test "$cross_compiling" = yes ||
20441          $as_test_x conftest$ac_exeext
20442        }; then
20443   eval "$as_ac_var=yes"
20444 else
20445   $as_echo "$as_me: failed program was:" >&5
20446 sed 's/^/| /' conftest.$ac_ext >&5
20447
20448         eval "$as_ac_var=no"
20449 fi
20450
20451 rm -rf conftest.dSYM
20452 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20453       conftest$ac_exeext conftest.$ac_ext
20454 fi
20455 ac_res=`eval 'as_val=${'$as_ac_var'}
20456                  $as_echo "$as_val"'`
20457                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20458 $as_echo "$ac_res" >&6; }
20459 as_val=`eval 'as_val=${'$as_ac_var'}
20460                  $as_echo "$as_val"'`
20461    if test "x$as_val" = x""yes; then
20462   cat >>confdefs.h <<_ACEOF
20463 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20464 _ACEOF
20465
20466 else
20467   { { $as_echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
20468 $as_echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
20469    { (exit 1); exit 1; }; }
20470 fi
20471 done
20472
20473 fi
20474 done
20475
20476
20477
20478 for ac_func in fseeko
20479 do
20480 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20481 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20482 $as_echo_n "checking for $ac_func... " >&6; }
20483 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20484   $as_echo_n "(cached) " >&6
20485 else
20486   cat >conftest.$ac_ext <<_ACEOF
20487 /* confdefs.h.  */
20488 _ACEOF
20489 cat confdefs.h >>conftest.$ac_ext
20490 cat >>conftest.$ac_ext <<_ACEOF
20491 /* end confdefs.h.  */
20492 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20493    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20494 #define $ac_func innocuous_$ac_func
20495
20496 /* System header to define __stub macros and hopefully few prototypes,
20497     which can conflict with char $ac_func (); below.
20498     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20499     <limits.h> exists even on freestanding compilers.  */
20500
20501 #ifdef __STDC__
20502 # include <limits.h>
20503 #else
20504 # include <assert.h>
20505 #endif
20506
20507 #undef $ac_func
20508
20509 /* Override any GCC internal prototype to avoid an error.
20510    Use char because int might match the return type of a GCC
20511    builtin and then its argument prototype would still apply.  */
20512 #ifdef __cplusplus
20513 extern "C"
20514 #endif
20515 char $ac_func ();
20516 /* The GNU C library defines this for functions which it implements
20517     to always fail with ENOSYS.  Some functions are actually named
20518     something starting with __ and the normal name is an alias.  */
20519 #if defined __stub_$ac_func || defined __stub___$ac_func
20520 choke me
20521 #endif
20522
20523 int
20524 main ()
20525 {
20526 return $ac_func ();
20527   ;
20528   return 0;
20529 }
20530 _ACEOF
20531 rm -f conftest.$ac_objext conftest$ac_exeext
20532 if { (ac_try="$ac_link"
20533 case "(($ac_try" in
20534   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20535   *) ac_try_echo=$ac_try;;
20536 esac
20537 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20538 $as_echo "$ac_try_echo") >&5
20539   (eval "$ac_link") 2>conftest.er1
20540   ac_status=$?
20541   grep -v '^ *+' conftest.er1 >conftest.err
20542   rm -f conftest.er1
20543   cat conftest.err >&5
20544   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20545   (exit $ac_status); } && {
20546          test -z "$ac_c_werror_flag" ||
20547          test ! -s conftest.err
20548        } && test -s conftest$ac_exeext && {
20549          test "$cross_compiling" = yes ||
20550          $as_test_x conftest$ac_exeext
20551        }; then
20552   eval "$as_ac_var=yes"
20553 else
20554   $as_echo "$as_me: failed program was:" >&5
20555 sed 's/^/| /' conftest.$ac_ext >&5
20556
20557         eval "$as_ac_var=no"
20558 fi
20559
20560 rm -rf conftest.dSYM
20561 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20562       conftest$ac_exeext conftest.$ac_ext
20563 fi
20564 ac_res=`eval 'as_val=${'$as_ac_var'}
20565                  $as_echo "$as_val"'`
20566                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20567 $as_echo "$ac_res" >&6; }
20568 as_val=`eval 'as_val=${'$as_ac_var'}
20569                  $as_echo "$as_val"'`
20570    if test "x$as_val" = x""yes; then
20571   cat >>confdefs.h <<_ACEOF
20572 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20573 _ACEOF
20574
20575 else
20576   case " $LIBOBJS " in
20577   *" $ac_func.$ac_objext "* ) ;;
20578   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20579  ;;
20580 esac
20581
20582 fi
20583 done
20584
20585
20586 case $host_os in
20587         # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
20588         # Mingw uses macros to access Win32 API calls
20589         bsdi*|netbsd*|mingw*)
20590
20591 cat >>confdefs.h <<\_ACEOF
20592 #define HAVE_FSEEKO 1
20593 _ACEOF
20594
20595                 ac_cv_func_fseeko=yes;;
20596         *)
20597                 { $as_echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
20598 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
20599 if test "${ac_cv_sys_largefile_source+set}" = set; then
20600   $as_echo_n "(cached) " >&6
20601 else
20602   while :; do
20603   cat >conftest.$ac_ext <<_ACEOF
20604 /* confdefs.h.  */
20605 _ACEOF
20606 cat confdefs.h >>conftest.$ac_ext
20607 cat >>conftest.$ac_ext <<_ACEOF
20608 /* end confdefs.h.  */
20609 #include <sys/types.h> /* for off_t */
20610      #include <stdio.h>
20611 int
20612 main ()
20613 {
20614 int (*fp) (FILE *, off_t, int) = fseeko;
20615      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
20616   ;
20617   return 0;
20618 }
20619 _ACEOF
20620 rm -f conftest.$ac_objext conftest$ac_exeext
20621 if { (ac_try="$ac_link"
20622 case "(($ac_try" in
20623   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20624   *) ac_try_echo=$ac_try;;
20625 esac
20626 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20627 $as_echo "$ac_try_echo") >&5
20628   (eval "$ac_link") 2>conftest.er1
20629   ac_status=$?
20630   grep -v '^ *+' conftest.er1 >conftest.err
20631   rm -f conftest.er1
20632   cat conftest.err >&5
20633   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20634   (exit $ac_status); } && {
20635          test -z "$ac_c_werror_flag" ||
20636          test ! -s conftest.err
20637        } && test -s conftest$ac_exeext && {
20638          test "$cross_compiling" = yes ||
20639          $as_test_x conftest$ac_exeext
20640        }; then
20641   ac_cv_sys_largefile_source=no; break
20642 else
20643   $as_echo "$as_me: failed program was:" >&5
20644 sed 's/^/| /' conftest.$ac_ext >&5
20645
20646
20647 fi
20648
20649 rm -rf conftest.dSYM
20650 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20651       conftest$ac_exeext conftest.$ac_ext
20652   cat >conftest.$ac_ext <<_ACEOF
20653 /* confdefs.h.  */
20654 _ACEOF
20655 cat confdefs.h >>conftest.$ac_ext
20656 cat >>conftest.$ac_ext <<_ACEOF
20657 /* end confdefs.h.  */
20658 #define _LARGEFILE_SOURCE 1
20659 #include <sys/types.h> /* for off_t */
20660      #include <stdio.h>
20661 int
20662 main ()
20663 {
20664 int (*fp) (FILE *, off_t, int) = fseeko;
20665      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
20666   ;
20667   return 0;
20668 }
20669 _ACEOF
20670 rm -f conftest.$ac_objext conftest$ac_exeext
20671 if { (ac_try="$ac_link"
20672 case "(($ac_try" in
20673   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20674   *) ac_try_echo=$ac_try;;
20675 esac
20676 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20677 $as_echo "$ac_try_echo") >&5
20678   (eval "$ac_link") 2>conftest.er1
20679   ac_status=$?
20680   grep -v '^ *+' conftest.er1 >conftest.err
20681   rm -f conftest.er1
20682   cat conftest.err >&5
20683   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20684   (exit $ac_status); } && {
20685          test -z "$ac_c_werror_flag" ||
20686          test ! -s conftest.err
20687        } && test -s conftest$ac_exeext && {
20688          test "$cross_compiling" = yes ||
20689          $as_test_x conftest$ac_exeext
20690        }; then
20691   ac_cv_sys_largefile_source=1; break
20692 else
20693   $as_echo "$as_me: failed program was:" >&5
20694 sed 's/^/| /' conftest.$ac_ext >&5
20695
20696
20697 fi
20698
20699 rm -rf conftest.dSYM
20700 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20701       conftest$ac_exeext conftest.$ac_ext
20702   ac_cv_sys_largefile_source=unknown
20703   break
20704 done
20705 fi
20706 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
20707 $as_echo "$ac_cv_sys_largefile_source" >&6; }
20708 case $ac_cv_sys_largefile_source in #(
20709   no | unknown) ;;
20710   *)
20711 cat >>confdefs.h <<_ACEOF
20712 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
20713 _ACEOF
20714 ;;
20715 esac
20716 rm -rf conftest*
20717
20718 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
20719 # in glibc 2.1.3, but that breaks too many other things.
20720 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
20721 if test $ac_cv_sys_largefile_source != unknown; then
20722
20723 cat >>confdefs.h <<\_ACEOF
20724 #define HAVE_FSEEKO 1
20725 _ACEOF
20726
20727 fi
20728 ;;
20729 esac
20730
20731
20732 #
20733 # Pthreads
20734 #
20735 # For each platform, we need to know about any special compile and link
20736 # libraries, and whether the normal C function names are thread-safe.
20737 # See the comment at the top of src/port/thread.c for more information.
20738 # WIN32 doesn't need the pthread tests;  it always uses threads
20739 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then
20740
20741
20742
20743 ac_ext=c
20744 ac_cpp='$CPP $CPPFLAGS'
20745 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
20746 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
20747 ac_compiler_gnu=$ac_cv_c_compiler_gnu
20748
20749 acx_pthread_ok=no
20750
20751 # We used to check for pthread.h first, but this fails if pthread.h
20752 # requires special compiler flags (e.g. on True64 or Sequent).
20753 # It gets checked for in the link test anyway.
20754
20755 # First of all, check if the user has set any of the PTHREAD_LIBS,
20756 # etcetera environment variables, and if threads linking works using
20757 # them:
20758 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
20759         save_CFLAGS="$CFLAGS"
20760         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
20761         save_LIBS="$LIBS"
20762         LIBS="$PTHREAD_LIBS $LIBS"
20763         { $as_echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
20764 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
20765         cat >conftest.$ac_ext <<_ACEOF
20766 /* confdefs.h.  */
20767 _ACEOF
20768 cat confdefs.h >>conftest.$ac_ext
20769 cat >>conftest.$ac_ext <<_ACEOF
20770 /* end confdefs.h.  */
20771
20772 /* Override any GCC internal prototype to avoid an error.
20773    Use char because int might match the return type of a GCC
20774    builtin and then its argument prototype would still apply.  */
20775 #ifdef __cplusplus
20776 extern "C"
20777 #endif
20778 char pthread_join ();
20779 int
20780 main ()
20781 {
20782 return pthread_join ();
20783   ;
20784   return 0;
20785 }
20786 _ACEOF
20787 rm -f conftest.$ac_objext conftest$ac_exeext
20788 if { (ac_try="$ac_link"
20789 case "(($ac_try" in
20790   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20791   *) ac_try_echo=$ac_try;;
20792 esac
20793 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20794 $as_echo "$ac_try_echo") >&5
20795   (eval "$ac_link") 2>conftest.er1
20796   ac_status=$?
20797   grep -v '^ *+' conftest.er1 >conftest.err
20798   rm -f conftest.er1
20799   cat conftest.err >&5
20800   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20801   (exit $ac_status); } && {
20802          test -z "$ac_c_werror_flag" ||
20803          test ! -s conftest.err
20804        } && test -s conftest$ac_exeext && {
20805          test "$cross_compiling" = yes ||
20806          $as_test_x conftest$ac_exeext
20807        }; then
20808   acx_pthread_ok=yes
20809 else
20810   $as_echo "$as_me: failed program was:" >&5
20811 sed 's/^/| /' conftest.$ac_ext >&5
20812
20813
20814 fi
20815
20816 rm -rf conftest.dSYM
20817 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20818       conftest$ac_exeext conftest.$ac_ext
20819         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
20820 $as_echo "$acx_pthread_ok" >&6; }
20821         if test x"$acx_pthread_ok" = xno; then
20822                 PTHREAD_LIBS=""
20823                 PTHREAD_CFLAGS=""
20824         fi
20825         LIBS="$save_LIBS"
20826         CFLAGS="$save_CFLAGS"
20827 fi
20828
20829 # We must check for the threads library under a number of different
20830 # names; the ordering is very important because some systems
20831 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
20832 # libraries is broken (non-POSIX).
20833
20834 # Create a list of thread flags to try.  Items starting with a "-" are
20835 # C compiler flags, and other items are library names, except for "none"
20836 # which indicates that we try without any flags at all, and "pthread-config"
20837 # which is a program returning the flags for the Pth emulation library.
20838
20839 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
20840
20841 # The ordering *is* (sometimes) important.  Some notes on the
20842 # individual items follow:
20843
20844 # pthreads: AIX (must check this before -lpthread)
20845 # none: in case threads are in libc; should be tried before -Kthread and
20846 #       other compiler flags to prevent continual compiler warnings
20847 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
20848 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
20849 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
20850 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
20851 # -pthreads: Solaris/gcc
20852 # -mthreads: Mingw32/gcc, Lynx/gcc
20853 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
20854 #      doesn't hurt to check since this sometimes defines pthreads too;
20855 #      also defines -D_REENTRANT)
20856 # pthread: Linux, etcetera
20857 # --thread-safe: KAI C++
20858 # pthread-config: use pthread-config program (for GNU Pth library)
20859
20860 case "${host_cpu}-${host_os}" in
20861         *solaris*)
20862
20863         # On Solaris (at least, for some versions), libc contains stubbed
20864         # (non-functional) versions of the pthreads routines, so link-based
20865         # tests will erroneously succeed.  (We need to link with -pthread or
20866         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
20867         # a function called by this macro, so we could check for that, but
20868         # who knows whether they'll stub that too in a future libc.)  So,
20869         # we'll just look for -pthreads and -lpthread first:
20870
20871         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
20872         ;;
20873 esac
20874
20875 if test x"$acx_pthread_ok" = xno; then
20876 for flag in $acx_pthread_flags; do
20877
20878         tryPTHREAD_CFLAGS=""
20879         tryPTHREAD_LIBS=""
20880         case $flag in
20881                 none)
20882                 { $as_echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
20883 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
20884                 ;;
20885
20886                 -*)
20887                 { $as_echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
20888 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
20889                 tryPTHREAD_CFLAGS="$flag"
20890                 ;;
20891
20892                 pthread-config)
20893                 # skip this if we already have flags defined, for PostgreSQL
20894                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
20895                 # Extract the first word of "pthread-config", so it can be a program name with args.
20896 set dummy pthread-config; ac_word=$2
20897 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
20898 $as_echo_n "checking for $ac_word... " >&6; }
20899 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
20900   $as_echo_n "(cached) " >&6
20901 else
20902   if test -n "$acx_pthread_config"; then
20903   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
20904 else
20905 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
20906 for as_dir in $PATH
20907 do
20908   IFS=$as_save_IFS
20909   test -z "$as_dir" && as_dir=.
20910   for ac_exec_ext in '' $ac_executable_extensions; do
20911   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
20912     ac_cv_prog_acx_pthread_config="yes"
20913     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
20914     break 2
20915   fi
20916 done
20917 done
20918 IFS=$as_save_IFS
20919
20920   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
20921 fi
20922 fi
20923 acx_pthread_config=$ac_cv_prog_acx_pthread_config
20924 if test -n "$acx_pthread_config"; then
20925   { $as_echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
20926 $as_echo "$acx_pthread_config" >&6; }
20927 else
20928   { $as_echo "$as_me:$LINENO: result: no" >&5
20929 $as_echo "no" >&6; }
20930 fi
20931
20932
20933                 if test x"$acx_pthread_config" = xno; then continue; fi
20934                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
20935                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
20936                 ;;
20937
20938                 *)
20939                 { $as_echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
20940 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
20941                 tryPTHREAD_LIBS="-l$flag"
20942                 ;;
20943         esac
20944
20945         save_LIBS="$LIBS"
20946         save_CFLAGS="$CFLAGS"
20947         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
20948         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
20949
20950         # Check for various functions.  We must include pthread.h,
20951         # since some functions may be macros.  (On the Sequent, we
20952         # need a special flag -Kthread to make this header compile.)
20953         # We check for pthread_join because it is in -lpthread on IRIX
20954         # while pthread_create is in libc.  We check for pthread_attr_init
20955         # due to DEC craziness with -lpthreads.  We check for
20956         # pthread_cleanup_push because it is one of the few pthread
20957         # functions on Solaris that doesn't have a non-functional libc stub.
20958         # We try pthread_create on general principles.
20959         cat >conftest.$ac_ext <<_ACEOF
20960 /* confdefs.h.  */
20961 _ACEOF
20962 cat confdefs.h >>conftest.$ac_ext
20963 cat >>conftest.$ac_ext <<_ACEOF
20964 /* end confdefs.h.  */
20965 #include <pthread.h>
20966 int
20967 main ()
20968 {
20969 pthread_t th; pthread_join(th, 0);
20970                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
20971                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
20972   ;
20973   return 0;
20974 }
20975 _ACEOF
20976 rm -f conftest.$ac_objext conftest$ac_exeext
20977 if { (ac_try="$ac_link"
20978 case "(($ac_try" in
20979   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20980   *) ac_try_echo=$ac_try;;
20981 esac
20982 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20983 $as_echo "$ac_try_echo") >&5
20984   (eval "$ac_link") 2>conftest.er1
20985   ac_status=$?
20986   grep -v '^ *+' conftest.er1 >conftest.err
20987   rm -f conftest.er1
20988   cat conftest.err >&5
20989   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20990   (exit $ac_status); } && {
20991          test -z "$ac_c_werror_flag" ||
20992          test ! -s conftest.err
20993        } && test -s conftest$ac_exeext && {
20994          test "$cross_compiling" = yes ||
20995          $as_test_x conftest$ac_exeext
20996        }; then
20997   acx_pthread_ok=yes
20998 else
20999   $as_echo "$as_me: failed program was:" >&5
21000 sed 's/^/| /' conftest.$ac_ext >&5
21001
21002         acx_pthread_ok=no
21003 fi
21004
21005 rm -rf conftest.dSYM
21006 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21007       conftest$ac_exeext conftest.$ac_ext
21008
21009         if test "x$acx_pthread_ok" = xyes; then
21010             # Don't use options that are ignored by the compiler.
21011             # We find them by checking stderror.
21012             cat >conftest.$ac_ext <<_ACEOF
21013 int
21014 main (int argc, char **argv)
21015 {
21016   (void) argc;
21017   (void) argv;
21018   return 0;
21019 }
21020 _ACEOF
21021             rm -f conftest.$ac_objext conftest$ac_exeext
21022             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
21023                 # we continue with more flags because Linux needs -lpthread
21024                 # for libpq builds on PostgreSQL.  The test above only
21025                 # tests for building binaries, not shared libraries.
21026                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
21027                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
21028             else   acx_pthread_ok=no
21029             fi
21030         fi
21031
21032         LIBS="$save_LIBS"
21033         CFLAGS="$save_CFLAGS"
21034
21035         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
21036 $as_echo "$acx_pthread_ok" >&6; }
21037 done
21038 fi
21039
21040 # Various other checks:
21041 if test "x$acx_pthread_ok" = xyes; then
21042         save_LIBS="$LIBS"
21043         LIBS="$PTHREAD_LIBS $LIBS"
21044         save_CFLAGS="$CFLAGS"
21045         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
21046
21047         # Detect AIX lossage: threads are created detached by default
21048         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
21049         { $as_echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
21050 $as_echo_n "checking for joinable pthread attribute... " >&6; }
21051         cat >conftest.$ac_ext <<_ACEOF
21052 /* confdefs.h.  */
21053 _ACEOF
21054 cat confdefs.h >>conftest.$ac_ext
21055 cat >>conftest.$ac_ext <<_ACEOF
21056 /* end confdefs.h.  */
21057 #include <pthread.h>
21058 int
21059 main ()
21060 {
21061 int attr=PTHREAD_CREATE_JOINABLE;
21062   ;
21063   return 0;
21064 }
21065 _ACEOF
21066 rm -f conftest.$ac_objext conftest$ac_exeext
21067 if { (ac_try="$ac_link"
21068 case "(($ac_try" in
21069   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21070   *) ac_try_echo=$ac_try;;
21071 esac
21072 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21073 $as_echo "$ac_try_echo") >&5
21074   (eval "$ac_link") 2>conftest.er1
21075   ac_status=$?
21076   grep -v '^ *+' conftest.er1 >conftest.err
21077   rm -f conftest.er1
21078   cat conftest.err >&5
21079   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21080   (exit $ac_status); } && {
21081          test -z "$ac_c_werror_flag" ||
21082          test ! -s conftest.err
21083        } && test -s conftest$ac_exeext && {
21084          test "$cross_compiling" = yes ||
21085          $as_test_x conftest$ac_exeext
21086        }; then
21087   ok=PTHREAD_CREATE_JOINABLE
21088 else
21089   $as_echo "$as_me: failed program was:" >&5
21090 sed 's/^/| /' conftest.$ac_ext >&5
21091
21092         ok=unknown
21093 fi
21094
21095 rm -rf conftest.dSYM
21096 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21097       conftest$ac_exeext conftest.$ac_ext
21098         if test x"$ok" = xunknown; then
21099                 cat >conftest.$ac_ext <<_ACEOF
21100 /* confdefs.h.  */
21101 _ACEOF
21102 cat confdefs.h >>conftest.$ac_ext
21103 cat >>conftest.$ac_ext <<_ACEOF
21104 /* end confdefs.h.  */
21105 #include <pthread.h>
21106 int
21107 main ()
21108 {
21109 int attr=PTHREAD_CREATE_UNDETACHED;
21110   ;
21111   return 0;
21112 }
21113 _ACEOF
21114 rm -f conftest.$ac_objext conftest$ac_exeext
21115 if { (ac_try="$ac_link"
21116 case "(($ac_try" in
21117   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21118   *) ac_try_echo=$ac_try;;
21119 esac
21120 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21121 $as_echo "$ac_try_echo") >&5
21122   (eval "$ac_link") 2>conftest.er1
21123   ac_status=$?
21124   grep -v '^ *+' conftest.er1 >conftest.err
21125   rm -f conftest.er1
21126   cat conftest.err >&5
21127   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21128   (exit $ac_status); } && {
21129          test -z "$ac_c_werror_flag" ||
21130          test ! -s conftest.err
21131        } && test -s conftest$ac_exeext && {
21132          test "$cross_compiling" = yes ||
21133          $as_test_x conftest$ac_exeext
21134        }; then
21135   ok=PTHREAD_CREATE_UNDETACHED
21136 else
21137   $as_echo "$as_me: failed program was:" >&5
21138 sed 's/^/| /' conftest.$ac_ext >&5
21139
21140         ok=unknown
21141 fi
21142
21143 rm -rf conftest.dSYM
21144 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21145       conftest$ac_exeext conftest.$ac_ext
21146         fi
21147         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
21148
21149 cat >>confdefs.h <<\_ACEOF
21150 #define PTHREAD_CREATE_JOINABLE $ok
21151 _ACEOF
21152
21153         fi
21154         { $as_echo "$as_me:$LINENO: result: ${ok}" >&5
21155 $as_echo "${ok}" >&6; }
21156         if test x"$ok" = xunknown; then
21157                 { $as_echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
21158 $as_echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
21159         fi
21160
21161         { $as_echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
21162 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
21163         flag=no
21164 # We always add these in PostgreSQL
21165 #       case "${host_cpu}-${host_os}" in
21166 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
21167 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
21168 #       esac
21169         { $as_echo "$as_me:$LINENO: result: ${flag}" >&5
21170 $as_echo "${flag}" >&6; }
21171         if test "x$flag" != xno; then
21172                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
21173         fi
21174
21175         LIBS="$save_LIBS"
21176         CFLAGS="$save_CFLAGS"
21177
21178 # Supporting cc_r would require a special CC in all places that
21179 # use libpq, and that is ugly, so we don't do it.  Users can still
21180 # define their compiler as cc_r to do thread builds of everything.
21181         # More AIX lossage: must compile with cc_r
21182         # Extract the first word of "cc_r", so it can be a program name with args.
21183 set dummy cc_r; ac_word=$2
21184 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
21185 $as_echo_n "checking for $ac_word... " >&6; }
21186 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
21187   $as_echo_n "(cached) " >&6
21188 else
21189   if test -n "$PTHREAD_CC"; then
21190   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
21191 else
21192 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21193 for as_dir in $PATH
21194 do
21195   IFS=$as_save_IFS
21196   test -z "$as_dir" && as_dir=.
21197   for ac_exec_ext in '' $ac_executable_extensions; do
21198   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
21199     ac_cv_prog_PTHREAD_CC="cc_r"
21200     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21201     break 2
21202   fi
21203 done
21204 done
21205 IFS=$as_save_IFS
21206
21207   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
21208 fi
21209 fi
21210 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
21211 if test -n "$PTHREAD_CC"; then
21212   { $as_echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
21213 $as_echo "$PTHREAD_CC" >&6; }
21214 else
21215   { $as_echo "$as_me:$LINENO: result: no" >&5
21216 $as_echo "no" >&6; }
21217 fi
21218
21219
21220 else
21221         PTHREAD_CC="$CC"
21222 fi
21223
21224
21225
21226
21227
21228 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
21229 if test x"$acx_pthread_ok" = xyes; then
21230
21231 cat >>confdefs.h <<\_ACEOF
21232 #define HAVE_PTHREAD 1
21233 _ACEOF
21234
21235         :
21236 else
21237         acx_pthread_ok=no
21238
21239 fi
21240 ac_ext=c
21241 ac_cpp='$CPP $CPPFLAGS'
21242 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
21243 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
21244 ac_compiler_gnu=$ac_cv_c_compiler_gnu
21245
21246         # set thread flags
21247
21248 # Some platforms use these, so just define them.  They can't hurt if they
21249 # are not supported.  For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
21250 # enables 5-arg getpwuid_r, among other things.
21251 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
21252
21253
21254 # At this point, we don't want to muck with the compiler name for threading.
21255 # Let's see who fails, perhaps AIX.  2004-04-23
21256 if test "$PTHREAD_CC" != "$CC"; then
21257 { { $as_echo "$as_me:$LINENO: error:
21258 PostgreSQL does not support platforms that require a special compiler
21259 for thread safety;  use --disable-thread-safety to disable thread safety." >&5
21260 $as_echo "$as_me: error:
21261 PostgreSQL does not support platforms that require a special compiler
21262 for thread safety;  use --disable-thread-safety to disable thread safety." >&2;}
21263    { (exit 1); exit 1; }; }
21264 fi
21265
21266 # Check for *_r functions
21267 _CFLAGS="$CFLAGS"
21268 _LIBS="$LIBS"
21269 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
21270 LIBS="$LIBS $PTHREAD_LIBS"
21271
21272 if test "$PORTNAME" != "win32"; then
21273 if test "${ac_cv_header_pthread_h+set}" = set; then
21274   { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
21275 $as_echo_n "checking for pthread.h... " >&6; }
21276 if test "${ac_cv_header_pthread_h+set}" = set; then
21277   $as_echo_n "(cached) " >&6
21278 fi
21279 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
21280 $as_echo "$ac_cv_header_pthread_h" >&6; }
21281 else
21282   # Is the header compilable?
21283 { $as_echo "$as_me:$LINENO: checking pthread.h usability" >&5
21284 $as_echo_n "checking pthread.h usability... " >&6; }
21285 cat >conftest.$ac_ext <<_ACEOF
21286 /* confdefs.h.  */
21287 _ACEOF
21288 cat confdefs.h >>conftest.$ac_ext
21289 cat >>conftest.$ac_ext <<_ACEOF
21290 /* end confdefs.h.  */
21291 $ac_includes_default
21292 #include <pthread.h>
21293 _ACEOF
21294 rm -f conftest.$ac_objext
21295 if { (ac_try="$ac_compile"
21296 case "(($ac_try" in
21297   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21298   *) ac_try_echo=$ac_try;;
21299 esac
21300 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21301 $as_echo "$ac_try_echo") >&5
21302   (eval "$ac_compile") 2>conftest.er1
21303   ac_status=$?
21304   grep -v '^ *+' conftest.er1 >conftest.err
21305   rm -f conftest.er1
21306   cat conftest.err >&5
21307   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21308   (exit $ac_status); } && {
21309          test -z "$ac_c_werror_flag" ||
21310          test ! -s conftest.err
21311        } && test -s conftest.$ac_objext; then
21312   ac_header_compiler=yes
21313 else
21314   $as_echo "$as_me: failed program was:" >&5
21315 sed 's/^/| /' conftest.$ac_ext >&5
21316
21317         ac_header_compiler=no
21318 fi
21319
21320 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21321 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21322 $as_echo "$ac_header_compiler" >&6; }
21323
21324 # Is the header present?
21325 { $as_echo "$as_me:$LINENO: checking pthread.h presence" >&5
21326 $as_echo_n "checking pthread.h presence... " >&6; }
21327 cat >conftest.$ac_ext <<_ACEOF
21328 /* confdefs.h.  */
21329 _ACEOF
21330 cat confdefs.h >>conftest.$ac_ext
21331 cat >>conftest.$ac_ext <<_ACEOF
21332 /* end confdefs.h.  */
21333 #include <pthread.h>
21334 _ACEOF
21335 if { (ac_try="$ac_cpp conftest.$ac_ext"
21336 case "(($ac_try" in
21337   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21338   *) ac_try_echo=$ac_try;;
21339 esac
21340 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21341 $as_echo "$ac_try_echo") >&5
21342   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
21343   ac_status=$?
21344   grep -v '^ *+' conftest.er1 >conftest.err
21345   rm -f conftest.er1
21346   cat conftest.err >&5
21347   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21348   (exit $ac_status); } >/dev/null && {
21349          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
21350          test ! -s conftest.err
21351        }; then
21352   ac_header_preproc=yes
21353 else
21354   $as_echo "$as_me: failed program was:" >&5
21355 sed 's/^/| /' conftest.$ac_ext >&5
21356
21357   ac_header_preproc=no
21358 fi
21359
21360 rm -f conftest.err conftest.$ac_ext
21361 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21362 $as_echo "$ac_header_preproc" >&6; }
21363
21364 # So?  What about this header?
21365 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21366   yes:no: )
21367     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
21368 $as_echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21369     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
21370 $as_echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
21371     ac_header_preproc=yes
21372     ;;
21373   no:yes:* )
21374     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
21375 $as_echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
21376     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
21377 $as_echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
21378     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
21379 $as_echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
21380     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
21381 $as_echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21382     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
21383 $as_echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
21384     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
21385 $as_echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
21386     ( cat <<\_ASBOX
21387 ## ---------------------------------------- ##
21388 ## Report this to pgsql-bugs@postgresql.org ##
21389 ## ---------------------------------------- ##
21390 _ASBOX
21391      ) | sed "s/^/$as_me: WARNING:     /" >&2
21392     ;;
21393 esac
21394 { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
21395 $as_echo_n "checking for pthread.h... " >&6; }
21396 if test "${ac_cv_header_pthread_h+set}" = set; then
21397   $as_echo_n "(cached) " >&6
21398 else
21399   ac_cv_header_pthread_h=$ac_header_preproc
21400 fi
21401 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
21402 $as_echo "$ac_cv_header_pthread_h" >&6; }
21403
21404 fi
21405 if test "x$ac_cv_header_pthread_h" = x""yes; then
21406   :
21407 else
21408   { { $as_echo "$as_me:$LINENO: error:
21409 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&5
21410 $as_echo "$as_me: error:
21411 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&2;}
21412    { (exit 1); exit 1; }; }
21413 fi
21414
21415
21416 fi
21417
21418
21419
21420
21421 for ac_func in strerror_r getpwuid_r gethostbyname_r
21422 do
21423 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21424 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21425 $as_echo_n "checking for $ac_func... " >&6; }
21426 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21427   $as_echo_n "(cached) " >&6
21428 else
21429   cat >conftest.$ac_ext <<_ACEOF
21430 /* confdefs.h.  */
21431 _ACEOF
21432 cat confdefs.h >>conftest.$ac_ext
21433 cat >>conftest.$ac_ext <<_ACEOF
21434 /* end confdefs.h.  */
21435 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21436    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21437 #define $ac_func innocuous_$ac_func
21438
21439 /* System header to define __stub macros and hopefully few prototypes,
21440     which can conflict with char $ac_func (); below.
21441     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21442     <limits.h> exists even on freestanding compilers.  */
21443
21444 #ifdef __STDC__
21445 # include <limits.h>
21446 #else
21447 # include <assert.h>
21448 #endif
21449
21450 #undef $ac_func
21451
21452 /* Override any GCC internal prototype to avoid an error.
21453    Use char because int might match the return type of a GCC
21454    builtin and then its argument prototype would still apply.  */
21455 #ifdef __cplusplus
21456 extern "C"
21457 #endif
21458 char $ac_func ();
21459 /* The GNU C library defines this for functions which it implements
21460     to always fail with ENOSYS.  Some functions are actually named
21461     something starting with __ and the normal name is an alias.  */
21462 #if defined __stub_$ac_func || defined __stub___$ac_func
21463 choke me
21464 #endif
21465
21466 int
21467 main ()
21468 {
21469 return $ac_func ();
21470   ;
21471   return 0;
21472 }
21473 _ACEOF
21474 rm -f conftest.$ac_objext conftest$ac_exeext
21475 if { (ac_try="$ac_link"
21476 case "(($ac_try" in
21477   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21478   *) ac_try_echo=$ac_try;;
21479 esac
21480 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21481 $as_echo "$ac_try_echo") >&5
21482   (eval "$ac_link") 2>conftest.er1
21483   ac_status=$?
21484   grep -v '^ *+' conftest.er1 >conftest.err
21485   rm -f conftest.er1
21486   cat conftest.err >&5
21487   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21488   (exit $ac_status); } && {
21489          test -z "$ac_c_werror_flag" ||
21490          test ! -s conftest.err
21491        } && test -s conftest$ac_exeext && {
21492          test "$cross_compiling" = yes ||
21493          $as_test_x conftest$ac_exeext
21494        }; then
21495   eval "$as_ac_var=yes"
21496 else
21497   $as_echo "$as_me: failed program was:" >&5
21498 sed 's/^/| /' conftest.$ac_ext >&5
21499
21500         eval "$as_ac_var=no"
21501 fi
21502
21503 rm -rf conftest.dSYM
21504 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21505       conftest$ac_exeext conftest.$ac_ext
21506 fi
21507 ac_res=`eval 'as_val=${'$as_ac_var'}
21508                  $as_echo "$as_val"'`
21509                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21510 $as_echo "$ac_res" >&6; }
21511 as_val=`eval 'as_val=${'$as_ac_var'}
21512                  $as_echo "$as_val"'`
21513    if test "x$as_val" = x""yes; then
21514   cat >>confdefs.h <<_ACEOF
21515 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21516 _ACEOF
21517
21518 fi
21519 done
21520
21521
21522 # Do test here with the proper thread flags
21523 { $as_echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
21524 $as_echo_n "checking whether getpwuid_r takes a fifth argument... " >&6; }
21525 if test "${pgac_cv_func_getpwuid_r_5arg+set}" = set; then
21526   $as_echo_n "(cached) " >&6
21527 else
21528   cat >conftest.$ac_ext <<_ACEOF
21529 /* confdefs.h.  */
21530 _ACEOF
21531 cat confdefs.h >>conftest.$ac_ext
21532 cat >>conftest.$ac_ext <<_ACEOF
21533 /* end confdefs.h.  */
21534 #include <sys/types.h>
21535 #include <pwd.h>
21536 int
21537 main ()
21538 {
21539 uid_t uid;
21540 struct passwd *space;
21541 char *buf;
21542 size_t bufsize;
21543 struct passwd **result;
21544 getpwuid_r(uid, space, buf, bufsize, result);
21545   ;
21546   return 0;
21547 }
21548 _ACEOF
21549 rm -f conftest.$ac_objext
21550 if { (ac_try="$ac_compile"
21551 case "(($ac_try" in
21552   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21553   *) ac_try_echo=$ac_try;;
21554 esac
21555 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21556 $as_echo "$ac_try_echo") >&5
21557   (eval "$ac_compile") 2>conftest.er1
21558   ac_status=$?
21559   grep -v '^ *+' conftest.er1 >conftest.err
21560   rm -f conftest.er1
21561   cat conftest.err >&5
21562   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21563   (exit $ac_status); } && {
21564          test -z "$ac_c_werror_flag" ||
21565          test ! -s conftest.err
21566        } && test -s conftest.$ac_objext; then
21567   pgac_cv_func_getpwuid_r_5arg=yes
21568 else
21569   $as_echo "$as_me: failed program was:" >&5
21570 sed 's/^/| /' conftest.$ac_ext >&5
21571
21572         pgac_cv_func_getpwuid_r_5arg=no
21573 fi
21574
21575 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21576 fi
21577 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_getpwuid_r_5arg" >&5
21578 $as_echo "$pgac_cv_func_getpwuid_r_5arg" >&6; }
21579 if test x"$pgac_cv_func_getpwuid_r_5arg" = xyes ; then
21580
21581 cat >>confdefs.h <<\_ACEOF
21582 #define GETPWUID_R_5ARG /**/
21583 _ACEOF
21584
21585 fi
21586
21587 { $as_echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
21588 $as_echo_n "checking whether strerror_r returns int... " >&6; }
21589 if test "${pgac_cv_func_strerror_r_int+set}" = set; then
21590   $as_echo_n "(cached) " >&6
21591 else
21592   cat >conftest.$ac_ext <<_ACEOF
21593 /* confdefs.h.  */
21594 _ACEOF
21595 cat confdefs.h >>conftest.$ac_ext
21596 cat >>conftest.$ac_ext <<_ACEOF
21597 /* end confdefs.h.  */
21598 #include <string.h>
21599 int
21600 main ()
21601 {
21602 #ifndef _AIX
21603 int strerror_r(int, char *, size_t);
21604 #else
21605 /* Older AIX has 'int' for the third argument so we don't test the args. */
21606 int strerror_r();
21607 #endif
21608   ;
21609   return 0;
21610 }
21611 _ACEOF
21612 rm -f conftest.$ac_objext
21613 if { (ac_try="$ac_compile"
21614 case "(($ac_try" in
21615   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21616   *) ac_try_echo=$ac_try;;
21617 esac
21618 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21619 $as_echo "$ac_try_echo") >&5
21620   (eval "$ac_compile") 2>conftest.er1
21621   ac_status=$?
21622   grep -v '^ *+' conftest.er1 >conftest.err
21623   rm -f conftest.er1
21624   cat conftest.err >&5
21625   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21626   (exit $ac_status); } && {
21627          test -z "$ac_c_werror_flag" ||
21628          test ! -s conftest.err
21629        } && test -s conftest.$ac_objext; then
21630   pgac_cv_func_strerror_r_int=yes
21631 else
21632   $as_echo "$as_me: failed program was:" >&5
21633 sed 's/^/| /' conftest.$ac_ext >&5
21634
21635         pgac_cv_func_strerror_r_int=no
21636 fi
21637
21638 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21639 fi
21640 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_strerror_r_int" >&5
21641 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
21642 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
21643
21644 cat >>confdefs.h <<\_ACEOF
21645 #define STRERROR_R_INT /**/
21646 _ACEOF
21647
21648 fi
21649
21650
21651 CFLAGS="$_CFLAGS"
21652 LIBS="$_LIBS"
21653
21654 else
21655 # do not use values from template file
21656 PTHREAD_CFLAGS=
21657 PTHREAD_LIBS=
21658 fi
21659
21660
21661
21662
21663
21664 # We can test for libldap_r only after we know PTHREAD_LIBS
21665 if test "$with_ldap" = yes ; then
21666   _LIBS="$LIBS"
21667   if test "$PORTNAME" != "win32"; then
21668
21669 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
21670 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
21671 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
21672   $as_echo_n "(cached) " >&6
21673 else
21674   ac_check_lib_save_LIBS=$LIBS
21675 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
21676 cat >conftest.$ac_ext <<_ACEOF
21677 /* confdefs.h.  */
21678 _ACEOF
21679 cat confdefs.h >>conftest.$ac_ext
21680 cat >>conftest.$ac_ext <<_ACEOF
21681 /* end confdefs.h.  */
21682
21683 /* Override any GCC internal prototype to avoid an error.
21684    Use char because int might match the return type of a GCC
21685    builtin and then its argument prototype would still apply.  */
21686 #ifdef __cplusplus
21687 extern "C"
21688 #endif
21689 char ldap_bind ();
21690 int
21691 main ()
21692 {
21693 return ldap_bind ();
21694   ;
21695   return 0;
21696 }
21697 _ACEOF
21698 rm -f conftest.$ac_objext conftest$ac_exeext
21699 if { (ac_try="$ac_link"
21700 case "(($ac_try" in
21701   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21702   *) ac_try_echo=$ac_try;;
21703 esac
21704 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21705 $as_echo "$ac_try_echo") >&5
21706   (eval "$ac_link") 2>conftest.er1
21707   ac_status=$?
21708   grep -v '^ *+' conftest.er1 >conftest.err
21709   rm -f conftest.er1
21710   cat conftest.err >&5
21711   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21712   (exit $ac_status); } && {
21713          test -z "$ac_c_werror_flag" ||
21714          test ! -s conftest.err
21715        } && test -s conftest$ac_exeext && {
21716          test "$cross_compiling" = yes ||
21717          $as_test_x conftest$ac_exeext
21718        }; then
21719   ac_cv_lib_ldap_ldap_bind=yes
21720 else
21721   $as_echo "$as_me: failed program was:" >&5
21722 sed 's/^/| /' conftest.$ac_ext >&5
21723
21724         ac_cv_lib_ldap_ldap_bind=no
21725 fi
21726
21727 rm -rf conftest.dSYM
21728 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21729       conftest$ac_exeext conftest.$ac_ext
21730 LIBS=$ac_check_lib_save_LIBS
21731 fi
21732 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
21733 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
21734 if test "x$ac_cv_lib_ldap_ldap_bind" = x""yes; then
21735   cat >>confdefs.h <<_ACEOF
21736 #define HAVE_LIBLDAP 1
21737 _ACEOF
21738
21739   LIBS="-lldap $LIBS"
21740
21741 else
21742   { { $as_echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
21743 $as_echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
21744    { (exit 1); exit 1; }; }
21745 fi
21746
21747     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
21748     if test "$enable_thread_safety" = yes; then
21749       # on some platforms ldap_r fails to link without PTHREAD_LIBS
21750
21751 { $as_echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
21752 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
21753 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
21754   $as_echo_n "(cached) " >&6
21755 else
21756   ac_check_lib_save_LIBS=$LIBS
21757 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
21758 cat >conftest.$ac_ext <<_ACEOF
21759 /* confdefs.h.  */
21760 _ACEOF
21761 cat confdefs.h >>conftest.$ac_ext
21762 cat >>conftest.$ac_ext <<_ACEOF
21763 /* end confdefs.h.  */
21764
21765 /* Override any GCC internal prototype to avoid an error.
21766    Use char because int might match the return type of a GCC
21767    builtin and then its argument prototype would still apply.  */
21768 #ifdef __cplusplus
21769 extern "C"
21770 #endif
21771 char ldap_simple_bind ();
21772 int
21773 main ()
21774 {
21775 return ldap_simple_bind ();
21776   ;
21777   return 0;
21778 }
21779 _ACEOF
21780 rm -f conftest.$ac_objext conftest$ac_exeext
21781 if { (ac_try="$ac_link"
21782 case "(($ac_try" in
21783   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21784   *) ac_try_echo=$ac_try;;
21785 esac
21786 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21787 $as_echo "$ac_try_echo") >&5
21788   (eval "$ac_link") 2>conftest.er1
21789   ac_status=$?
21790   grep -v '^ *+' conftest.er1 >conftest.err
21791   rm -f conftest.er1
21792   cat conftest.err >&5
21793   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21794   (exit $ac_status); } && {
21795          test -z "$ac_c_werror_flag" ||
21796          test ! -s conftest.err
21797        } && test -s conftest$ac_exeext && {
21798          test "$cross_compiling" = yes ||
21799          $as_test_x conftest$ac_exeext
21800        }; then
21801   ac_cv_lib_ldap_r_ldap_simple_bind=yes
21802 else
21803   $as_echo "$as_me: failed program was:" >&5
21804 sed 's/^/| /' conftest.$ac_ext >&5
21805
21806         ac_cv_lib_ldap_r_ldap_simple_bind=no
21807 fi
21808
21809 rm -rf conftest.dSYM
21810 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21811       conftest$ac_exeext conftest.$ac_ext
21812 LIBS=$ac_check_lib_save_LIBS
21813 fi
21814 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
21815 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
21816 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = x""yes; then
21817   cat >>confdefs.h <<_ACEOF
21818 #define HAVE_LIBLDAP_R 1
21819 _ACEOF
21820
21821   LIBS="-lldap_r $LIBS"
21822
21823 else
21824   { { $as_echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
21825 $as_echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
21826    { (exit 1); exit 1; }; }
21827 fi
21828
21829       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
21830     else
21831       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
21832     fi
21833   else
21834
21835 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
21836 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
21837 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
21838   $as_echo_n "(cached) " >&6
21839 else
21840   ac_check_lib_save_LIBS=$LIBS
21841 LIBS="-lwldap32  $LIBS"
21842 cat >conftest.$ac_ext <<_ACEOF
21843 /* confdefs.h.  */
21844 _ACEOF
21845 cat confdefs.h >>conftest.$ac_ext
21846 cat >>conftest.$ac_ext <<_ACEOF
21847 /* end confdefs.h.  */
21848
21849 /* Override any GCC internal prototype to avoid an error.
21850    Use char because int might match the return type of a GCC
21851    builtin and then its argument prototype would still apply.  */
21852 #ifdef __cplusplus
21853 extern "C"
21854 #endif
21855 char ldap_bind ();
21856 int
21857 main ()
21858 {
21859 return ldap_bind ();
21860   ;
21861   return 0;
21862 }
21863 _ACEOF
21864 rm -f conftest.$ac_objext conftest$ac_exeext
21865 if { (ac_try="$ac_link"
21866 case "(($ac_try" in
21867   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21868   *) ac_try_echo=$ac_try;;
21869 esac
21870 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21871 $as_echo "$ac_try_echo") >&5
21872   (eval "$ac_link") 2>conftest.er1
21873   ac_status=$?
21874   grep -v '^ *+' conftest.er1 >conftest.err
21875   rm -f conftest.er1
21876   cat conftest.err >&5
21877   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21878   (exit $ac_status); } && {
21879          test -z "$ac_c_werror_flag" ||
21880          test ! -s conftest.err
21881        } && test -s conftest$ac_exeext && {
21882          test "$cross_compiling" = yes ||
21883          $as_test_x conftest$ac_exeext
21884        }; then
21885   ac_cv_lib_wldap32_ldap_bind=yes
21886 else
21887   $as_echo "$as_me: failed program was:" >&5
21888 sed 's/^/| /' conftest.$ac_ext >&5
21889
21890         ac_cv_lib_wldap32_ldap_bind=no
21891 fi
21892
21893 rm -rf conftest.dSYM
21894 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21895       conftest$ac_exeext conftest.$ac_ext
21896 LIBS=$ac_check_lib_save_LIBS
21897 fi
21898 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
21899 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
21900 if test "x$ac_cv_lib_wldap32_ldap_bind" = x""yes; then
21901   cat >>confdefs.h <<_ACEOF
21902 #define HAVE_LIBWLDAP32 1
21903 _ACEOF
21904
21905   LIBS="-lwldap32 $LIBS"
21906
21907 else
21908   { { $as_echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
21909 $as_echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
21910    { (exit 1); exit 1; }; }
21911 fi
21912
21913     LDAP_LIBS_FE="-lwldap32"
21914     LDAP_LIBS_BE="-lwldap32"
21915   fi
21916   LIBS="$_LIBS"
21917 fi
21918
21919
21920
21921
21922 # This test makes sure that run tests work at all.  Sometimes a shared
21923 # library is found by the linker, but the runtime linker can't find it.
21924 # This check should come after all modifications of compiler or linker
21925 # variables, and before any other run tests.
21926 { $as_echo "$as_me:$LINENO: checking test program" >&5
21927 $as_echo_n "checking test program... " >&6; }
21928 if test "$cross_compiling" = yes; then
21929   { $as_echo "$as_me:$LINENO: result: cross-compiling" >&5
21930 $as_echo "cross-compiling" >&6; }
21931 else
21932   cat >conftest.$ac_ext <<_ACEOF
21933 /* confdefs.h.  */
21934 _ACEOF
21935 cat confdefs.h >>conftest.$ac_ext
21936 cat >>conftest.$ac_ext <<_ACEOF
21937 /* end confdefs.h.  */
21938 int main() { return 0; }
21939 _ACEOF
21940 rm -f conftest$ac_exeext
21941 if { (ac_try="$ac_link"
21942 case "(($ac_try" in
21943   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21944   *) ac_try_echo=$ac_try;;
21945 esac
21946 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21947 $as_echo "$ac_try_echo") >&5
21948   (eval "$ac_link") 2>&5
21949   ac_status=$?
21950   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21951   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21952   { (case "(($ac_try" in
21953   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21954   *) ac_try_echo=$ac_try;;
21955 esac
21956 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21957 $as_echo "$ac_try_echo") >&5
21958   (eval "$ac_try") 2>&5
21959   ac_status=$?
21960   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21961   (exit $ac_status); }; }; then
21962   { $as_echo "$as_me:$LINENO: result: ok" >&5
21963 $as_echo "ok" >&6; }
21964 else
21965   $as_echo "$as_me: program exited with status $ac_status" >&5
21966 $as_echo "$as_me: failed program was:" >&5
21967 sed 's/^/| /' conftest.$ac_ext >&5
21968
21969 ( exit $ac_status )
21970 { $as_echo "$as_me:$LINENO: result: failed" >&5
21971 $as_echo "failed" >&6; }
21972 { { $as_echo "$as_me:$LINENO: error:
21973 Could not execute a simple test program.  This may be a problem
21974 related to locating shared libraries.  Check the file 'config.log'
21975 for the exact reason." >&5
21976 $as_echo "$as_me: error:
21977 Could not execute a simple test program.  This may be a problem
21978 related to locating shared libraries.  Check the file 'config.log'
21979 for the exact reason." >&2;}
21980    { (exit 1); exit 1; }; }
21981 fi
21982 rm -rf conftest.dSYM
21983 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21984 fi
21985
21986
21987
21988 # --------------------
21989 # Run tests below here
21990 # --------------------
21991
21992 # Force use of our snprintf if system's doesn't do arg control
21993 # See comment above at snprintf test for details.
21994 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
21995   { $as_echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
21996 $as_echo_n "checking whether printf supports argument control... " >&6; }
21997 if test "${pgac_cv_printf_arg_control+set}" = set; then
21998   $as_echo_n "(cached) " >&6
21999 else
22000   if test "$cross_compiling" = yes; then
22001   pgac_cv_printf_arg_control=cross
22002 else
22003   cat >conftest.$ac_ext <<_ACEOF
22004 /* confdefs.h.  */
22005 _ACEOF
22006 cat confdefs.h >>conftest.$ac_ext
22007 cat >>conftest.$ac_ext <<_ACEOF
22008 /* end confdefs.h.  */
22009 #include <stdio.h>
22010 #include <string.h>
22011
22012 int main()
22013 {
22014   char buf[100];
22015
22016   /* can it swap arguments? */
22017   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
22018   if (strcmp(buf, "4 3") != 0)
22019     return 1;
22020   return 0;
22021 }
22022 _ACEOF
22023 rm -f conftest$ac_exeext
22024 if { (ac_try="$ac_link"
22025 case "(($ac_try" in
22026   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22027   *) ac_try_echo=$ac_try;;
22028 esac
22029 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22030 $as_echo "$ac_try_echo") >&5
22031   (eval "$ac_link") 2>&5
22032   ac_status=$?
22033   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22034   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22035   { (case "(($ac_try" in
22036   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22037   *) ac_try_echo=$ac_try;;
22038 esac
22039 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22040 $as_echo "$ac_try_echo") >&5
22041   (eval "$ac_try") 2>&5
22042   ac_status=$?
22043   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22044   (exit $ac_status); }; }; then
22045   pgac_cv_printf_arg_control=yes
22046 else
22047   $as_echo "$as_me: program exited with status $ac_status" >&5
22048 $as_echo "$as_me: failed program was:" >&5
22049 sed 's/^/| /' conftest.$ac_ext >&5
22050
22051 ( exit $ac_status )
22052 pgac_cv_printf_arg_control=no
22053 fi
22054 rm -rf conftest.dSYM
22055 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22056 fi
22057
22058
22059
22060 fi
22061 { $as_echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
22062 $as_echo "$pgac_cv_printf_arg_control" >&6; }
22063
22064   if test $pgac_cv_printf_arg_control != yes ; then
22065     pgac_need_repl_snprintf=yes
22066   fi
22067 fi
22068
22069
22070
22071 { $as_echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
22072 $as_echo_n "checking whether long int is 64 bits... " >&6; }
22073 if test "${pgac_cv_type_long_int_64+set}" = set; then
22074   $as_echo_n "(cached) " >&6
22075 else
22076   if test "$cross_compiling" = yes; then
22077   # If cross-compiling, check the size reported by the compiler and
22078 # trust that the arithmetic works.
22079 cat >conftest.$ac_ext <<_ACEOF
22080 /* confdefs.h.  */
22081 _ACEOF
22082 cat confdefs.h >>conftest.$ac_ext
22083 cat >>conftest.$ac_ext <<_ACEOF
22084 /* end confdefs.h.  */
22085
22086 int
22087 main ()
22088 {
22089 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
22090 test_array [0] = 0
22091
22092   ;
22093   return 0;
22094 }
22095 _ACEOF
22096 rm -f conftest.$ac_objext
22097 if { (ac_try="$ac_compile"
22098 case "(($ac_try" in
22099   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22100   *) ac_try_echo=$ac_try;;
22101 esac
22102 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22103 $as_echo "$ac_try_echo") >&5
22104   (eval "$ac_compile") 2>conftest.er1
22105   ac_status=$?
22106   grep -v '^ *+' conftest.er1 >conftest.err
22107   rm -f conftest.er1
22108   cat conftest.err >&5
22109   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22110   (exit $ac_status); } && {
22111          test -z "$ac_c_werror_flag" ||
22112          test ! -s conftest.err
22113        } && test -s conftest.$ac_objext; then
22114   pgac_cv_type_long_int_64=yes
22115 else
22116   $as_echo "$as_me: failed program was:" >&5
22117 sed 's/^/| /' conftest.$ac_ext >&5
22118
22119         pgac_cv_type_long_int_64=no
22120 fi
22121
22122 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22123 else
22124   cat >conftest.$ac_ext <<_ACEOF
22125 /* confdefs.h.  */
22126 _ACEOF
22127 cat confdefs.h >>conftest.$ac_ext
22128 cat >>conftest.$ac_ext <<_ACEOF
22129 /* end confdefs.h.  */
22130 typedef long int ac_int64;
22131
22132 /*
22133  * These are globals to discourage the compiler from folding all the
22134  * arithmetic tests down to compile-time constants.
22135  */
22136 ac_int64 a = 20000001;
22137 ac_int64 b = 40000005;
22138
22139 int does_int64_work()
22140 {
22141   ac_int64 c,d;
22142
22143   if (sizeof(ac_int64) != 8)
22144     return 0;                   /* definitely not the right size */
22145
22146   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
22147   c = a * b;
22148   d = (c + b) / b;
22149   if (d != a+1)
22150     return 0;
22151   return 1;
22152 }
22153 main() {
22154   exit(! does_int64_work());
22155 }
22156 _ACEOF
22157 rm -f conftest$ac_exeext
22158 if { (ac_try="$ac_link"
22159 case "(($ac_try" in
22160   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22161   *) ac_try_echo=$ac_try;;
22162 esac
22163 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22164 $as_echo "$ac_try_echo") >&5
22165   (eval "$ac_link") 2>&5
22166   ac_status=$?
22167   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22168   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22169   { (case "(($ac_try" in
22170   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22171   *) ac_try_echo=$ac_try;;
22172 esac
22173 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22174 $as_echo "$ac_try_echo") >&5
22175   (eval "$ac_try") 2>&5
22176   ac_status=$?
22177   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22178   (exit $ac_status); }; }; then
22179   pgac_cv_type_long_int_64=yes
22180 else
22181   $as_echo "$as_me: program exited with status $ac_status" >&5
22182 $as_echo "$as_me: failed program was:" >&5
22183 sed 's/^/| /' conftest.$ac_ext >&5
22184
22185 ( exit $ac_status )
22186 pgac_cv_type_long_int_64=no
22187 fi
22188 rm -rf conftest.dSYM
22189 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22190 fi
22191
22192
22193 fi
22194 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
22195 $as_echo "$pgac_cv_type_long_int_64" >&6; }
22196
22197 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
22198 if test x"$pgac_cv_type_long_int_64" = xyes ; then
22199
22200 cat >>confdefs.h <<\_ACEOF
22201 #define HAVE_LONG_INT_64 1
22202 _ACEOF
22203
22204 fi
22205
22206
22207 if test x"$HAVE_LONG_INT_64" = x"no" ; then
22208   { $as_echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
22209 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
22210 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
22211   $as_echo_n "(cached) " >&6
22212 else
22213   if test "$cross_compiling" = yes; then
22214   # If cross-compiling, check the size reported by the compiler and
22215 # trust that the arithmetic works.
22216 cat >conftest.$ac_ext <<_ACEOF
22217 /* confdefs.h.  */
22218 _ACEOF
22219 cat confdefs.h >>conftest.$ac_ext
22220 cat >>conftest.$ac_ext <<_ACEOF
22221 /* end confdefs.h.  */
22222
22223 int
22224 main ()
22225 {
22226 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
22227 test_array [0] = 0
22228
22229   ;
22230   return 0;
22231 }
22232 _ACEOF
22233 rm -f conftest.$ac_objext
22234 if { (ac_try="$ac_compile"
22235 case "(($ac_try" in
22236   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22237   *) ac_try_echo=$ac_try;;
22238 esac
22239 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22240 $as_echo "$ac_try_echo") >&5
22241   (eval "$ac_compile") 2>conftest.er1
22242   ac_status=$?
22243   grep -v '^ *+' conftest.er1 >conftest.err
22244   rm -f conftest.er1
22245   cat conftest.err >&5
22246   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22247   (exit $ac_status); } && {
22248          test -z "$ac_c_werror_flag" ||
22249          test ! -s conftest.err
22250        } && test -s conftest.$ac_objext; then
22251   pgac_cv_type_long_long_int_64=yes
22252 else
22253   $as_echo "$as_me: failed program was:" >&5
22254 sed 's/^/| /' conftest.$ac_ext >&5
22255
22256         pgac_cv_type_long_long_int_64=no
22257 fi
22258
22259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22260 else
22261   cat >conftest.$ac_ext <<_ACEOF
22262 /* confdefs.h.  */
22263 _ACEOF
22264 cat confdefs.h >>conftest.$ac_ext
22265 cat >>conftest.$ac_ext <<_ACEOF
22266 /* end confdefs.h.  */
22267 typedef long long int ac_int64;
22268
22269 /*
22270  * These are globals to discourage the compiler from folding all the
22271  * arithmetic tests down to compile-time constants.
22272  */
22273 ac_int64 a = 20000001;
22274 ac_int64 b = 40000005;
22275
22276 int does_int64_work()
22277 {
22278   ac_int64 c,d;
22279
22280   if (sizeof(ac_int64) != 8)
22281     return 0;                   /* definitely not the right size */
22282
22283   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
22284   c = a * b;
22285   d = (c + b) / b;
22286   if (d != a+1)
22287     return 0;
22288   return 1;
22289 }
22290 main() {
22291   exit(! does_int64_work());
22292 }
22293 _ACEOF
22294 rm -f conftest$ac_exeext
22295 if { (ac_try="$ac_link"
22296 case "(($ac_try" in
22297   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22298   *) ac_try_echo=$ac_try;;
22299 esac
22300 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22301 $as_echo "$ac_try_echo") >&5
22302   (eval "$ac_link") 2>&5
22303   ac_status=$?
22304   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22305   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22306   { (case "(($ac_try" in
22307   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22308   *) ac_try_echo=$ac_try;;
22309 esac
22310 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22311 $as_echo "$ac_try_echo") >&5
22312   (eval "$ac_try") 2>&5
22313   ac_status=$?
22314   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22315   (exit $ac_status); }; }; then
22316   pgac_cv_type_long_long_int_64=yes
22317 else
22318   $as_echo "$as_me: program exited with status $ac_status" >&5
22319 $as_echo "$as_me: failed program was:" >&5
22320 sed 's/^/| /' conftest.$ac_ext >&5
22321
22322 ( exit $ac_status )
22323 pgac_cv_type_long_long_int_64=no
22324 fi
22325 rm -rf conftest.dSYM
22326 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22327 fi
22328
22329
22330 fi
22331 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
22332 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
22333
22334 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
22335 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
22336
22337 cat >>confdefs.h <<\_ACEOF
22338 #define HAVE_LONG_LONG_INT_64 1
22339 _ACEOF
22340
22341 fi
22342
22343 fi
22344
22345
22346
22347 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
22348   cat >conftest.$ac_ext <<_ACEOF
22349 /* confdefs.h.  */
22350 _ACEOF
22351 cat confdefs.h >>conftest.$ac_ext
22352 cat >>conftest.$ac_ext <<_ACEOF
22353 /* end confdefs.h.  */
22354
22355 #define INT64CONST(x)  x##LL
22356 long long int foo = INT64CONST(0x1234567890123456);
22357
22358 int
22359 main ()
22360 {
22361
22362   ;
22363   return 0;
22364 }
22365 _ACEOF
22366 rm -f conftest.$ac_objext
22367 if { (ac_try="$ac_compile"
22368 case "(($ac_try" in
22369   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22370   *) ac_try_echo=$ac_try;;
22371 esac
22372 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22373 $as_echo "$ac_try_echo") >&5
22374   (eval "$ac_compile") 2>conftest.er1
22375   ac_status=$?
22376   grep -v '^ *+' conftest.er1 >conftest.err
22377   rm -f conftest.er1
22378   cat conftest.err >&5
22379   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22380   (exit $ac_status); } && {
22381          test -z "$ac_c_werror_flag" ||
22382          test ! -s conftest.err
22383        } && test -s conftest.$ac_objext; then
22384
22385 cat >>confdefs.h <<\_ACEOF
22386 #define HAVE_LL_CONSTANTS 1
22387 _ACEOF
22388
22389 else
22390   $as_echo "$as_me: failed program was:" >&5
22391 sed 's/^/| /' conftest.$ac_ext >&5
22392
22393
22394 fi
22395
22396 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22397 fi
22398
22399
22400 # If we found "long int" is 64 bits, assume snprintf handles it.  If
22401 # we found we need to use "long long int", better check.  We cope with
22402 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
22403 # work, fall back to our own snprintf emulation (which we know uses %lld).
22404
22405 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
22406   if test $pgac_need_repl_snprintf = no; then
22407     { $as_echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
22408 $as_echo_n "checking snprintf format for long long int... " >&6; }
22409 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
22410   $as_echo_n "(cached) " >&6
22411 else
22412   for pgac_format in '%lld' '%qd' '%I64d'; do
22413 if test "$cross_compiling" = yes; then
22414   pgac_cv_snprintf_long_long_int_format=cross; break
22415 else
22416   cat >conftest.$ac_ext <<_ACEOF
22417 /* confdefs.h.  */
22418 _ACEOF
22419 cat confdefs.h >>conftest.$ac_ext
22420 cat >>conftest.$ac_ext <<_ACEOF
22421 /* end confdefs.h.  */
22422 #include <stdio.h>
22423 typedef long long int ac_int64;
22424 #define INT64_FORMAT "$pgac_format"
22425
22426 ac_int64 a = 20000001;
22427 ac_int64 b = 40000005;
22428
22429 int does_int64_snprintf_work()
22430 {
22431   ac_int64 c;
22432   char buf[100];
22433
22434   if (sizeof(ac_int64) != 8)
22435     return 0;                   /* doesn't look like the right size */
22436
22437   c = a * b;
22438   snprintf(buf, 100, INT64_FORMAT, c);
22439   if (strcmp(buf, "800000140000005") != 0)
22440     return 0;                   /* either multiply or snprintf is busted */
22441   return 1;
22442 }
22443 main() {
22444   exit(! does_int64_snprintf_work());
22445 }
22446 _ACEOF
22447 rm -f conftest$ac_exeext
22448 if { (ac_try="$ac_link"
22449 case "(($ac_try" in
22450   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22451   *) ac_try_echo=$ac_try;;
22452 esac
22453 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22454 $as_echo "$ac_try_echo") >&5
22455   (eval "$ac_link") 2>&5
22456   ac_status=$?
22457   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22458   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22459   { (case "(($ac_try" in
22460   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22461   *) ac_try_echo=$ac_try;;
22462 esac
22463 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22464 $as_echo "$ac_try_echo") >&5
22465   (eval "$ac_try") 2>&5
22466   ac_status=$?
22467   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22468   (exit $ac_status); }; }; then
22469   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
22470 else
22471   $as_echo "$as_me: program exited with status $ac_status" >&5
22472 $as_echo "$as_me: failed program was:" >&5
22473 sed 's/^/| /' conftest.$ac_ext >&5
22474
22475 fi
22476 rm -rf conftest.dSYM
22477 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22478 fi
22479
22480
22481 done
22482 fi
22483
22484 LONG_LONG_INT_FORMAT=''
22485
22486 case $pgac_cv_snprintf_long_long_int_format in
22487   cross) { $as_echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
22488 $as_echo "cannot test (not on host machine)" >&6; };;
22489   ?*)    { $as_echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
22490 $as_echo "$pgac_cv_snprintf_long_long_int_format" >&6; }
22491          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
22492   *)     { $as_echo "$as_me:$LINENO: result: none" >&5
22493 $as_echo "none" >&6; };;
22494 esac
22495     if test "$LONG_LONG_INT_FORMAT" = ""; then
22496       # Force usage of our own snprintf, since system snprintf is broken
22497       pgac_need_repl_snprintf=yes
22498       LONG_LONG_INT_FORMAT='%lld'
22499     fi
22500   else
22501     # Here if we previously decided we needed to use our own snprintf
22502     LONG_LONG_INT_FORMAT='%lld'
22503   fi
22504   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
22505   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
22506   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
22507 else
22508   # Here if we are not using 'long long int' at all
22509   INT64_FORMAT='"%ld"'
22510   UINT64_FORMAT='"%lu"'
22511 fi
22512
22513
22514 cat >>confdefs.h <<_ACEOF
22515 #define INT64_FORMAT $INT64_FORMAT
22516 _ACEOF
22517
22518
22519
22520 cat >>confdefs.h <<_ACEOF
22521 #define UINT64_FORMAT $UINT64_FORMAT
22522 _ACEOF
22523
22524
22525 # Now we have checked all the reasons to replace snprintf
22526 if test $pgac_need_repl_snprintf = yes; then
22527
22528 cat >>confdefs.h <<\_ACEOF
22529 #define USE_REPL_SNPRINTF 1
22530 _ACEOF
22531
22532   case " $LIBOBJS " in
22533   *" snprintf.$ac_objext "* ) ;;
22534   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
22535  ;;
22536 esac
22537
22538 fi
22539
22540 # Need a #define for the size of Datum (unsigned long)
22541 # The cast to long int works around a bug in the HP C Compiler
22542 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
22543 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
22544 # This bug is HP SR number 8606223364.
22545 { $as_echo "$as_me:$LINENO: checking size of unsigned long" >&5
22546 $as_echo_n "checking size of unsigned long... " >&6; }
22547 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
22548   $as_echo_n "(cached) " >&6
22549 else
22550   if test "$cross_compiling" = yes; then
22551   # Depending upon the size, compute the lo and hi bounds.
22552 cat >conftest.$ac_ext <<_ACEOF
22553 /* confdefs.h.  */
22554 _ACEOF
22555 cat confdefs.h >>conftest.$ac_ext
22556 cat >>conftest.$ac_ext <<_ACEOF
22557 /* end confdefs.h.  */
22558 $ac_includes_default
22559 int
22560 main ()
22561 {
22562 static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long))) >= 0)];
22563 test_array [0] = 0
22564
22565   ;
22566   return 0;
22567 }
22568 _ACEOF
22569 rm -f conftest.$ac_objext
22570 if { (ac_try="$ac_compile"
22571 case "(($ac_try" in
22572   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22573   *) ac_try_echo=$ac_try;;
22574 esac
22575 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22576 $as_echo "$ac_try_echo") >&5
22577   (eval "$ac_compile") 2>conftest.er1
22578   ac_status=$?
22579   grep -v '^ *+' conftest.er1 >conftest.err
22580   rm -f conftest.er1
22581   cat conftest.err >&5
22582   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22583   (exit $ac_status); } && {
22584          test -z "$ac_c_werror_flag" ||
22585          test ! -s conftest.err
22586        } && test -s conftest.$ac_objext; then
22587   ac_lo=0 ac_mid=0
22588   while :; do
22589     cat >conftest.$ac_ext <<_ACEOF
22590 /* confdefs.h.  */
22591 _ACEOF
22592 cat confdefs.h >>conftest.$ac_ext
22593 cat >>conftest.$ac_ext <<_ACEOF
22594 /* end confdefs.h.  */
22595 $ac_includes_default
22596 int
22597 main ()
22598 {
22599 static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long))) <= $ac_mid)];
22600 test_array [0] = 0
22601
22602   ;
22603   return 0;
22604 }
22605 _ACEOF
22606 rm -f conftest.$ac_objext
22607 if { (ac_try="$ac_compile"
22608 case "(($ac_try" in
22609   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22610   *) ac_try_echo=$ac_try;;
22611 esac
22612 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22613 $as_echo "$ac_try_echo") >&5
22614   (eval "$ac_compile") 2>conftest.er1
22615   ac_status=$?
22616   grep -v '^ *+' conftest.er1 >conftest.err
22617   rm -f conftest.er1
22618   cat conftest.err >&5
22619   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22620   (exit $ac_status); } && {
22621          test -z "$ac_c_werror_flag" ||
22622          test ! -s conftest.err
22623        } && test -s conftest.$ac_objext; then
22624   ac_hi=$ac_mid; break
22625 else
22626   $as_echo "$as_me: failed program was:" >&5
22627 sed 's/^/| /' conftest.$ac_ext >&5
22628
22629         ac_lo=`expr $ac_mid + 1`
22630                         if test $ac_lo -le $ac_mid; then
22631                           ac_lo= ac_hi=
22632                           break
22633                         fi
22634                         ac_mid=`expr 2 '*' $ac_mid + 1`
22635 fi
22636
22637 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22638   done
22639 else
22640   $as_echo "$as_me: failed program was:" >&5
22641 sed 's/^/| /' conftest.$ac_ext >&5
22642
22643         cat >conftest.$ac_ext <<_ACEOF
22644 /* confdefs.h.  */
22645 _ACEOF
22646 cat confdefs.h >>conftest.$ac_ext
22647 cat >>conftest.$ac_ext <<_ACEOF
22648 /* end confdefs.h.  */
22649 $ac_includes_default
22650 int
22651 main ()
22652 {
22653 static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long))) < 0)];
22654 test_array [0] = 0
22655
22656   ;
22657   return 0;
22658 }
22659 _ACEOF
22660 rm -f conftest.$ac_objext
22661 if { (ac_try="$ac_compile"
22662 case "(($ac_try" in
22663   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22664   *) ac_try_echo=$ac_try;;
22665 esac
22666 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22667 $as_echo "$ac_try_echo") >&5
22668   (eval "$ac_compile") 2>conftest.er1
22669   ac_status=$?
22670   grep -v '^ *+' conftest.er1 >conftest.err
22671   rm -f conftest.er1
22672   cat conftest.err >&5
22673   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22674   (exit $ac_status); } && {
22675          test -z "$ac_c_werror_flag" ||
22676          test ! -s conftest.err
22677        } && test -s conftest.$ac_objext; then
22678   ac_hi=-1 ac_mid=-1
22679   while :; do
22680     cat >conftest.$ac_ext <<_ACEOF
22681 /* confdefs.h.  */
22682 _ACEOF
22683 cat confdefs.h >>conftest.$ac_ext
22684 cat >>conftest.$ac_ext <<_ACEOF
22685 /* end confdefs.h.  */
22686 $ac_includes_default
22687 int
22688 main ()
22689 {
22690 static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long))) >= $ac_mid)];
22691 test_array [0] = 0
22692
22693   ;
22694   return 0;
22695 }
22696 _ACEOF
22697 rm -f conftest.$ac_objext
22698 if { (ac_try="$ac_compile"
22699 case "(($ac_try" in
22700   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22701   *) ac_try_echo=$ac_try;;
22702 esac
22703 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22704 $as_echo "$ac_try_echo") >&5
22705   (eval "$ac_compile") 2>conftest.er1
22706   ac_status=$?
22707   grep -v '^ *+' conftest.er1 >conftest.err
22708   rm -f conftest.er1
22709   cat conftest.err >&5
22710   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22711   (exit $ac_status); } && {
22712          test -z "$ac_c_werror_flag" ||
22713          test ! -s conftest.err
22714        } && test -s conftest.$ac_objext; then
22715   ac_lo=$ac_mid; break
22716 else
22717   $as_echo "$as_me: failed program was:" >&5
22718 sed 's/^/| /' conftest.$ac_ext >&5
22719
22720         ac_hi=`expr '(' $ac_mid ')' - 1`
22721                         if test $ac_mid -le $ac_hi; then
22722                           ac_lo= ac_hi=
22723                           break
22724                         fi
22725                         ac_mid=`expr 2 '*' $ac_mid`
22726 fi
22727
22728 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22729   done
22730 else
22731   $as_echo "$as_me: failed program was:" >&5
22732 sed 's/^/| /' conftest.$ac_ext >&5
22733
22734         ac_lo= ac_hi=
22735 fi
22736
22737 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22738 fi
22739
22740 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22741 # Binary search between lo and hi bounds.
22742 while test "x$ac_lo" != "x$ac_hi"; do
22743   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
22744   cat >conftest.$ac_ext <<_ACEOF
22745 /* confdefs.h.  */
22746 _ACEOF
22747 cat confdefs.h >>conftest.$ac_ext
22748 cat >>conftest.$ac_ext <<_ACEOF
22749 /* end confdefs.h.  */
22750 $ac_includes_default
22751 int
22752 main ()
22753 {
22754 static int test_array [1 - 2 * !(((long int) (sizeof (unsigned long))) <= $ac_mid)];
22755 test_array [0] = 0
22756
22757   ;
22758   return 0;
22759 }
22760 _ACEOF
22761 rm -f conftest.$ac_objext
22762 if { (ac_try="$ac_compile"
22763 case "(($ac_try" in
22764   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22765   *) ac_try_echo=$ac_try;;
22766 esac
22767 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22768 $as_echo "$ac_try_echo") >&5
22769   (eval "$ac_compile") 2>conftest.er1
22770   ac_status=$?
22771   grep -v '^ *+' conftest.er1 >conftest.err
22772   rm -f conftest.er1
22773   cat conftest.err >&5
22774   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22775   (exit $ac_status); } && {
22776          test -z "$ac_c_werror_flag" ||
22777          test ! -s conftest.err
22778        } && test -s conftest.$ac_objext; then
22779   ac_hi=$ac_mid
22780 else
22781   $as_echo "$as_me: failed program was:" >&5
22782 sed 's/^/| /' conftest.$ac_ext >&5
22783
22784         ac_lo=`expr '(' $ac_mid ')' + 1`
22785 fi
22786
22787 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22788 done
22789 case $ac_lo in
22790 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
22791 '') if test "$ac_cv_type_unsigned_long" = yes; then
22792      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
22793 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22794 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long)
22795 See \`config.log' for more details." >&5
22796 $as_echo "$as_me: error: cannot compute sizeof (unsigned long)
22797 See \`config.log' for more details." >&2;}
22798    { (exit 77); exit 77; }; }; }
22799    else
22800      ac_cv_sizeof_unsigned_long=0
22801    fi ;;
22802 esac
22803 else
22804   cat >conftest.$ac_ext <<_ACEOF
22805 /* confdefs.h.  */
22806 _ACEOF
22807 cat confdefs.h >>conftest.$ac_ext
22808 cat >>conftest.$ac_ext <<_ACEOF
22809 /* end confdefs.h.  */
22810 $ac_includes_default
22811 static long int longval () { return (long int) (sizeof (unsigned long)); }
22812 static unsigned long int ulongval () { return (long int) (sizeof (unsigned long)); }
22813 #include <stdio.h>
22814 #include <stdlib.h>
22815 int
22816 main ()
22817 {
22818
22819   FILE *f = fopen ("conftest.val", "w");
22820   if (! f)
22821     return 1;
22822   if (((long int) (sizeof (unsigned long))) < 0)
22823     {
22824       long int i = longval ();
22825       if (i != ((long int) (sizeof (unsigned long))))
22826         return 1;
22827       fprintf (f, "%ld", i);
22828     }
22829   else
22830     {
22831       unsigned long int i = ulongval ();
22832       if (i != ((long int) (sizeof (unsigned long))))
22833         return 1;
22834       fprintf (f, "%lu", i);
22835     }
22836   /* Do not output a trailing newline, as this causes \r\n confusion
22837      on some platforms.  */
22838   return ferror (f) || fclose (f) != 0;
22839
22840   ;
22841   return 0;
22842 }
22843 _ACEOF
22844 rm -f conftest$ac_exeext
22845 if { (ac_try="$ac_link"
22846 case "(($ac_try" in
22847   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22848   *) ac_try_echo=$ac_try;;
22849 esac
22850 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22851 $as_echo "$ac_try_echo") >&5
22852   (eval "$ac_link") 2>&5
22853   ac_status=$?
22854   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22855   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22856   { (case "(($ac_try" in
22857   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22858   *) ac_try_echo=$ac_try;;
22859 esac
22860 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22861 $as_echo "$ac_try_echo") >&5
22862   (eval "$ac_try") 2>&5
22863   ac_status=$?
22864   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22865   (exit $ac_status); }; }; then
22866   ac_cv_sizeof_unsigned_long=`cat conftest.val`
22867 else
22868   $as_echo "$as_me: program exited with status $ac_status" >&5
22869 $as_echo "$as_me: failed program was:" >&5
22870 sed 's/^/| /' conftest.$ac_ext >&5
22871
22872 ( exit $ac_status )
22873 if test "$ac_cv_type_unsigned_long" = yes; then
22874      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
22875 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
22876 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long)
22877 See \`config.log' for more details." >&5
22878 $as_echo "$as_me: error: cannot compute sizeof (unsigned long)
22879 See \`config.log' for more details." >&2;}
22880    { (exit 77); exit 77; }; }; }
22881    else
22882      ac_cv_sizeof_unsigned_long=0
22883    fi
22884 fi
22885 rm -rf conftest.dSYM
22886 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22887 fi
22888 rm -f conftest.val
22889 fi
22890 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
22891 $as_echo "$ac_cv_sizeof_unsigned_long" >&6; }
22892
22893
22894
22895 cat >>confdefs.h <<_ACEOF
22896 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
22897 _ACEOF
22898
22899
22900
22901 # And check size of void *, size_t (enables tweaks for > 32bit address space)
22902 # The cast to long int works around a bug in the HP C Compiler
22903 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
22904 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
22905 # This bug is HP SR number 8606223364.
22906 { $as_echo "$as_me:$LINENO: checking size of void *" >&5
22907 $as_echo_n "checking size of void *... " >&6; }
22908 if test "${ac_cv_sizeof_void_p+set}" = set; then
22909   $as_echo_n "(cached) " >&6
22910 else
22911   if test "$cross_compiling" = yes; then
22912   # Depending upon the size, compute the lo and hi bounds.
22913 cat >conftest.$ac_ext <<_ACEOF
22914 /* confdefs.h.  */
22915 _ACEOF
22916 cat confdefs.h >>conftest.$ac_ext
22917 cat >>conftest.$ac_ext <<_ACEOF
22918 /* end confdefs.h.  */
22919 $ac_includes_default
22920 int
22921 main ()
22922 {
22923 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= 0)];
22924 test_array [0] = 0
22925
22926   ;
22927   return 0;
22928 }
22929 _ACEOF
22930 rm -f conftest.$ac_objext
22931 if { (ac_try="$ac_compile"
22932 case "(($ac_try" in
22933   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22934   *) ac_try_echo=$ac_try;;
22935 esac
22936 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22937 $as_echo "$ac_try_echo") >&5
22938   (eval "$ac_compile") 2>conftest.er1
22939   ac_status=$?
22940   grep -v '^ *+' conftest.er1 >conftest.err
22941   rm -f conftest.er1
22942   cat conftest.err >&5
22943   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22944   (exit $ac_status); } && {
22945          test -z "$ac_c_werror_flag" ||
22946          test ! -s conftest.err
22947        } && test -s conftest.$ac_objext; then
22948   ac_lo=0 ac_mid=0
22949   while :; do
22950     cat >conftest.$ac_ext <<_ACEOF
22951 /* confdefs.h.  */
22952 _ACEOF
22953 cat confdefs.h >>conftest.$ac_ext
22954 cat >>conftest.$ac_ext <<_ACEOF
22955 /* end confdefs.h.  */
22956 $ac_includes_default
22957 int
22958 main ()
22959 {
22960 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
22961 test_array [0] = 0
22962
22963   ;
22964   return 0;
22965 }
22966 _ACEOF
22967 rm -f conftest.$ac_objext
22968 if { (ac_try="$ac_compile"
22969 case "(($ac_try" in
22970   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22971   *) ac_try_echo=$ac_try;;
22972 esac
22973 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22974 $as_echo "$ac_try_echo") >&5
22975   (eval "$ac_compile") 2>conftest.er1
22976   ac_status=$?
22977   grep -v '^ *+' conftest.er1 >conftest.err
22978   rm -f conftest.er1
22979   cat conftest.err >&5
22980   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22981   (exit $ac_status); } && {
22982          test -z "$ac_c_werror_flag" ||
22983          test ! -s conftest.err
22984        } && test -s conftest.$ac_objext; then
22985   ac_hi=$ac_mid; break
22986 else
22987   $as_echo "$as_me: failed program was:" >&5
22988 sed 's/^/| /' conftest.$ac_ext >&5
22989
22990         ac_lo=`expr $ac_mid + 1`
22991                         if test $ac_lo -le $ac_mid; then
22992                           ac_lo= ac_hi=
22993                           break
22994                         fi
22995                         ac_mid=`expr 2 '*' $ac_mid + 1`
22996 fi
22997
22998 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22999   done
23000 else
23001   $as_echo "$as_me: failed program was:" >&5
23002 sed 's/^/| /' conftest.$ac_ext >&5
23003
23004         cat >conftest.$ac_ext <<_ACEOF
23005 /* confdefs.h.  */
23006 _ACEOF
23007 cat confdefs.h >>conftest.$ac_ext
23008 cat >>conftest.$ac_ext <<_ACEOF
23009 /* end confdefs.h.  */
23010 $ac_includes_default
23011 int
23012 main ()
23013 {
23014 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) < 0)];
23015 test_array [0] = 0
23016
23017   ;
23018   return 0;
23019 }
23020 _ACEOF
23021 rm -f conftest.$ac_objext
23022 if { (ac_try="$ac_compile"
23023 case "(($ac_try" in
23024   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23025   *) ac_try_echo=$ac_try;;
23026 esac
23027 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23028 $as_echo "$ac_try_echo") >&5
23029   (eval "$ac_compile") 2>conftest.er1
23030   ac_status=$?
23031   grep -v '^ *+' conftest.er1 >conftest.err
23032   rm -f conftest.er1
23033   cat conftest.err >&5
23034   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23035   (exit $ac_status); } && {
23036          test -z "$ac_c_werror_flag" ||
23037          test ! -s conftest.err
23038        } && test -s conftest.$ac_objext; then
23039   ac_hi=-1 ac_mid=-1
23040   while :; do
23041     cat >conftest.$ac_ext <<_ACEOF
23042 /* confdefs.h.  */
23043 _ACEOF
23044 cat confdefs.h >>conftest.$ac_ext
23045 cat >>conftest.$ac_ext <<_ACEOF
23046 /* end confdefs.h.  */
23047 $ac_includes_default
23048 int
23049 main ()
23050 {
23051 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= $ac_mid)];
23052 test_array [0] = 0
23053
23054   ;
23055   return 0;
23056 }
23057 _ACEOF
23058 rm -f conftest.$ac_objext
23059 if { (ac_try="$ac_compile"
23060 case "(($ac_try" in
23061   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23062   *) ac_try_echo=$ac_try;;
23063 esac
23064 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23065 $as_echo "$ac_try_echo") >&5
23066   (eval "$ac_compile") 2>conftest.er1
23067   ac_status=$?
23068   grep -v '^ *+' conftest.er1 >conftest.err
23069   rm -f conftest.er1
23070   cat conftest.err >&5
23071   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23072   (exit $ac_status); } && {
23073          test -z "$ac_c_werror_flag" ||
23074          test ! -s conftest.err
23075        } && test -s conftest.$ac_objext; then
23076   ac_lo=$ac_mid; break
23077 else
23078   $as_echo "$as_me: failed program was:" >&5
23079 sed 's/^/| /' conftest.$ac_ext >&5
23080
23081         ac_hi=`expr '(' $ac_mid ')' - 1`
23082                         if test $ac_mid -le $ac_hi; then
23083                           ac_lo= ac_hi=
23084                           break
23085                         fi
23086                         ac_mid=`expr 2 '*' $ac_mid`
23087 fi
23088
23089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23090   done
23091 else
23092   $as_echo "$as_me: failed program was:" >&5
23093 sed 's/^/| /' conftest.$ac_ext >&5
23094
23095         ac_lo= ac_hi=
23096 fi
23097
23098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23099 fi
23100
23101 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23102 # Binary search between lo and hi bounds.
23103 while test "x$ac_lo" != "x$ac_hi"; do
23104   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
23105   cat >conftest.$ac_ext <<_ACEOF
23106 /* confdefs.h.  */
23107 _ACEOF
23108 cat confdefs.h >>conftest.$ac_ext
23109 cat >>conftest.$ac_ext <<_ACEOF
23110 /* end confdefs.h.  */
23111 $ac_includes_default
23112 int
23113 main ()
23114 {
23115 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
23116 test_array [0] = 0
23117
23118   ;
23119   return 0;
23120 }
23121 _ACEOF
23122 rm -f conftest.$ac_objext
23123 if { (ac_try="$ac_compile"
23124 case "(($ac_try" in
23125   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23126   *) ac_try_echo=$ac_try;;
23127 esac
23128 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23129 $as_echo "$ac_try_echo") >&5
23130   (eval "$ac_compile") 2>conftest.er1
23131   ac_status=$?
23132   grep -v '^ *+' conftest.er1 >conftest.err
23133   rm -f conftest.er1
23134   cat conftest.err >&5
23135   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23136   (exit $ac_status); } && {
23137          test -z "$ac_c_werror_flag" ||
23138          test ! -s conftest.err
23139        } && test -s conftest.$ac_objext; then
23140   ac_hi=$ac_mid
23141 else
23142   $as_echo "$as_me: failed program was:" >&5
23143 sed 's/^/| /' conftest.$ac_ext >&5
23144
23145         ac_lo=`expr '(' $ac_mid ')' + 1`
23146 fi
23147
23148 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23149 done
23150 case $ac_lo in
23151 ?*) ac_cv_sizeof_void_p=$ac_lo;;
23152 '') if test "$ac_cv_type_void_p" = yes; then
23153      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
23154 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23155 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
23156 See \`config.log' for more details." >&5
23157 $as_echo "$as_me: error: cannot compute sizeof (void *)
23158 See \`config.log' for more details." >&2;}
23159    { (exit 77); exit 77; }; }; }
23160    else
23161      ac_cv_sizeof_void_p=0
23162    fi ;;
23163 esac
23164 else
23165   cat >conftest.$ac_ext <<_ACEOF
23166 /* confdefs.h.  */
23167 _ACEOF
23168 cat confdefs.h >>conftest.$ac_ext
23169 cat >>conftest.$ac_ext <<_ACEOF
23170 /* end confdefs.h.  */
23171 $ac_includes_default
23172 static long int longval () { return (long int) (sizeof (void *)); }
23173 static unsigned long int ulongval () { return (long int) (sizeof (void *)); }
23174 #include <stdio.h>
23175 #include <stdlib.h>
23176 int
23177 main ()
23178 {
23179
23180   FILE *f = fopen ("conftest.val", "w");
23181   if (! f)
23182     return 1;
23183   if (((long int) (sizeof (void *))) < 0)
23184     {
23185       long int i = longval ();
23186       if (i != ((long int) (sizeof (void *))))
23187         return 1;
23188       fprintf (f, "%ld", i);
23189     }
23190   else
23191     {
23192       unsigned long int i = ulongval ();
23193       if (i != ((long int) (sizeof (void *))))
23194         return 1;
23195       fprintf (f, "%lu", i);
23196     }
23197   /* Do not output a trailing newline, as this causes \r\n confusion
23198      on some platforms.  */
23199   return ferror (f) || fclose (f) != 0;
23200
23201   ;
23202   return 0;
23203 }
23204 _ACEOF
23205 rm -f conftest$ac_exeext
23206 if { (ac_try="$ac_link"
23207 case "(($ac_try" in
23208   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23209   *) ac_try_echo=$ac_try;;
23210 esac
23211 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23212 $as_echo "$ac_try_echo") >&5
23213   (eval "$ac_link") 2>&5
23214   ac_status=$?
23215   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23216   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23217   { (case "(($ac_try" in
23218   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23219   *) ac_try_echo=$ac_try;;
23220 esac
23221 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23222 $as_echo "$ac_try_echo") >&5
23223   (eval "$ac_try") 2>&5
23224   ac_status=$?
23225   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23226   (exit $ac_status); }; }; then
23227   ac_cv_sizeof_void_p=`cat conftest.val`
23228 else
23229   $as_echo "$as_me: program exited with status $ac_status" >&5
23230 $as_echo "$as_me: failed program was:" >&5
23231 sed 's/^/| /' conftest.$ac_ext >&5
23232
23233 ( exit $ac_status )
23234 if test "$ac_cv_type_void_p" = yes; then
23235      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
23236 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23237 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
23238 See \`config.log' for more details." >&5
23239 $as_echo "$as_me: error: cannot compute sizeof (void *)
23240 See \`config.log' for more details." >&2;}
23241    { (exit 77); exit 77; }; }; }
23242    else
23243      ac_cv_sizeof_void_p=0
23244    fi
23245 fi
23246 rm -rf conftest.dSYM
23247 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23248 fi
23249 rm -f conftest.val
23250 fi
23251 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
23252 $as_echo "$ac_cv_sizeof_void_p" >&6; }
23253
23254
23255
23256 cat >>confdefs.h <<_ACEOF
23257 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
23258 _ACEOF
23259
23260
23261 # The cast to long int works around a bug in the HP C Compiler
23262 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
23263 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
23264 # This bug is HP SR number 8606223364.
23265 { $as_echo "$as_me:$LINENO: checking size of size_t" >&5
23266 $as_echo_n "checking size of size_t... " >&6; }
23267 if test "${ac_cv_sizeof_size_t+set}" = set; then
23268   $as_echo_n "(cached) " >&6
23269 else
23270   if test "$cross_compiling" = yes; then
23271   # Depending upon the size, compute the lo and hi bounds.
23272 cat >conftest.$ac_ext <<_ACEOF
23273 /* confdefs.h.  */
23274 _ACEOF
23275 cat confdefs.h >>conftest.$ac_ext
23276 cat >>conftest.$ac_ext <<_ACEOF
23277 /* end confdefs.h.  */
23278 $ac_includes_default
23279 int
23280 main ()
23281 {
23282 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= 0)];
23283 test_array [0] = 0
23284
23285   ;
23286   return 0;
23287 }
23288 _ACEOF
23289 rm -f conftest.$ac_objext
23290 if { (ac_try="$ac_compile"
23291 case "(($ac_try" in
23292   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23293   *) ac_try_echo=$ac_try;;
23294 esac
23295 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23296 $as_echo "$ac_try_echo") >&5
23297   (eval "$ac_compile") 2>conftest.er1
23298   ac_status=$?
23299   grep -v '^ *+' conftest.er1 >conftest.err
23300   rm -f conftest.er1
23301   cat conftest.err >&5
23302   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23303   (exit $ac_status); } && {
23304          test -z "$ac_c_werror_flag" ||
23305          test ! -s conftest.err
23306        } && test -s conftest.$ac_objext; then
23307   ac_lo=0 ac_mid=0
23308   while :; do
23309     cat >conftest.$ac_ext <<_ACEOF
23310 /* confdefs.h.  */
23311 _ACEOF
23312 cat confdefs.h >>conftest.$ac_ext
23313 cat >>conftest.$ac_ext <<_ACEOF
23314 /* end confdefs.h.  */
23315 $ac_includes_default
23316 int
23317 main ()
23318 {
23319 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
23320 test_array [0] = 0
23321
23322   ;
23323   return 0;
23324 }
23325 _ACEOF
23326 rm -f conftest.$ac_objext
23327 if { (ac_try="$ac_compile"
23328 case "(($ac_try" in
23329   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23330   *) ac_try_echo=$ac_try;;
23331 esac
23332 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23333 $as_echo "$ac_try_echo") >&5
23334   (eval "$ac_compile") 2>conftest.er1
23335   ac_status=$?
23336   grep -v '^ *+' conftest.er1 >conftest.err
23337   rm -f conftest.er1
23338   cat conftest.err >&5
23339   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23340   (exit $ac_status); } && {
23341          test -z "$ac_c_werror_flag" ||
23342          test ! -s conftest.err
23343        } && test -s conftest.$ac_objext; then
23344   ac_hi=$ac_mid; break
23345 else
23346   $as_echo "$as_me: failed program was:" >&5
23347 sed 's/^/| /' conftest.$ac_ext >&5
23348
23349         ac_lo=`expr $ac_mid + 1`
23350                         if test $ac_lo -le $ac_mid; then
23351                           ac_lo= ac_hi=
23352                           break
23353                         fi
23354                         ac_mid=`expr 2 '*' $ac_mid + 1`
23355 fi
23356
23357 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23358   done
23359 else
23360   $as_echo "$as_me: failed program was:" >&5
23361 sed 's/^/| /' conftest.$ac_ext >&5
23362
23363         cat >conftest.$ac_ext <<_ACEOF
23364 /* confdefs.h.  */
23365 _ACEOF
23366 cat confdefs.h >>conftest.$ac_ext
23367 cat >>conftest.$ac_ext <<_ACEOF
23368 /* end confdefs.h.  */
23369 $ac_includes_default
23370 int
23371 main ()
23372 {
23373 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) < 0)];
23374 test_array [0] = 0
23375
23376   ;
23377   return 0;
23378 }
23379 _ACEOF
23380 rm -f conftest.$ac_objext
23381 if { (ac_try="$ac_compile"
23382 case "(($ac_try" in
23383   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23384   *) ac_try_echo=$ac_try;;
23385 esac
23386 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23387 $as_echo "$ac_try_echo") >&5
23388   (eval "$ac_compile") 2>conftest.er1
23389   ac_status=$?
23390   grep -v '^ *+' conftest.er1 >conftest.err
23391   rm -f conftest.er1
23392   cat conftest.err >&5
23393   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23394   (exit $ac_status); } && {
23395          test -z "$ac_c_werror_flag" ||
23396          test ! -s conftest.err
23397        } && test -s conftest.$ac_objext; then
23398   ac_hi=-1 ac_mid=-1
23399   while :; do
23400     cat >conftest.$ac_ext <<_ACEOF
23401 /* confdefs.h.  */
23402 _ACEOF
23403 cat confdefs.h >>conftest.$ac_ext
23404 cat >>conftest.$ac_ext <<_ACEOF
23405 /* end confdefs.h.  */
23406 $ac_includes_default
23407 int
23408 main ()
23409 {
23410 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= $ac_mid)];
23411 test_array [0] = 0
23412
23413   ;
23414   return 0;
23415 }
23416 _ACEOF
23417 rm -f conftest.$ac_objext
23418 if { (ac_try="$ac_compile"
23419 case "(($ac_try" in
23420   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23421   *) ac_try_echo=$ac_try;;
23422 esac
23423 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23424 $as_echo "$ac_try_echo") >&5
23425   (eval "$ac_compile") 2>conftest.er1
23426   ac_status=$?
23427   grep -v '^ *+' conftest.er1 >conftest.err
23428   rm -f conftest.er1
23429   cat conftest.err >&5
23430   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23431   (exit $ac_status); } && {
23432          test -z "$ac_c_werror_flag" ||
23433          test ! -s conftest.err
23434        } && test -s conftest.$ac_objext; then
23435   ac_lo=$ac_mid; break
23436 else
23437   $as_echo "$as_me: failed program was:" >&5
23438 sed 's/^/| /' conftest.$ac_ext >&5
23439
23440         ac_hi=`expr '(' $ac_mid ')' - 1`
23441                         if test $ac_mid -le $ac_hi; then
23442                           ac_lo= ac_hi=
23443                           break
23444                         fi
23445                         ac_mid=`expr 2 '*' $ac_mid`
23446 fi
23447
23448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23449   done
23450 else
23451   $as_echo "$as_me: failed program was:" >&5
23452 sed 's/^/| /' conftest.$ac_ext >&5
23453
23454         ac_lo= ac_hi=
23455 fi
23456
23457 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23458 fi
23459
23460 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23461 # Binary search between lo and hi bounds.
23462 while test "x$ac_lo" != "x$ac_hi"; do
23463   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
23464   cat >conftest.$ac_ext <<_ACEOF
23465 /* confdefs.h.  */
23466 _ACEOF
23467 cat confdefs.h >>conftest.$ac_ext
23468 cat >>conftest.$ac_ext <<_ACEOF
23469 /* end confdefs.h.  */
23470 $ac_includes_default
23471 int
23472 main ()
23473 {
23474 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
23475 test_array [0] = 0
23476
23477   ;
23478   return 0;
23479 }
23480 _ACEOF
23481 rm -f conftest.$ac_objext
23482 if { (ac_try="$ac_compile"
23483 case "(($ac_try" in
23484   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23485   *) ac_try_echo=$ac_try;;
23486 esac
23487 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23488 $as_echo "$ac_try_echo") >&5
23489   (eval "$ac_compile") 2>conftest.er1
23490   ac_status=$?
23491   grep -v '^ *+' conftest.er1 >conftest.err
23492   rm -f conftest.er1
23493   cat conftest.err >&5
23494   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23495   (exit $ac_status); } && {
23496          test -z "$ac_c_werror_flag" ||
23497          test ! -s conftest.err
23498        } && test -s conftest.$ac_objext; then
23499   ac_hi=$ac_mid
23500 else
23501   $as_echo "$as_me: failed program was:" >&5
23502 sed 's/^/| /' conftest.$ac_ext >&5
23503
23504         ac_lo=`expr '(' $ac_mid ')' + 1`
23505 fi
23506
23507 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23508 done
23509 case $ac_lo in
23510 ?*) ac_cv_sizeof_size_t=$ac_lo;;
23511 '') if test "$ac_cv_type_size_t" = yes; then
23512      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
23513 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23514 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
23515 See \`config.log' for more details." >&5
23516 $as_echo "$as_me: error: cannot compute sizeof (size_t)
23517 See \`config.log' for more details." >&2;}
23518    { (exit 77); exit 77; }; }; }
23519    else
23520      ac_cv_sizeof_size_t=0
23521    fi ;;
23522 esac
23523 else
23524   cat >conftest.$ac_ext <<_ACEOF
23525 /* confdefs.h.  */
23526 _ACEOF
23527 cat confdefs.h >>conftest.$ac_ext
23528 cat >>conftest.$ac_ext <<_ACEOF
23529 /* end confdefs.h.  */
23530 $ac_includes_default
23531 static long int longval () { return (long int) (sizeof (size_t)); }
23532 static unsigned long int ulongval () { return (long int) (sizeof (size_t)); }
23533 #include <stdio.h>
23534 #include <stdlib.h>
23535 int
23536 main ()
23537 {
23538
23539   FILE *f = fopen ("conftest.val", "w");
23540   if (! f)
23541     return 1;
23542   if (((long int) (sizeof (size_t))) < 0)
23543     {
23544       long int i = longval ();
23545       if (i != ((long int) (sizeof (size_t))))
23546         return 1;
23547       fprintf (f, "%ld", i);
23548     }
23549   else
23550     {
23551       unsigned long int i = ulongval ();
23552       if (i != ((long int) (sizeof (size_t))))
23553         return 1;
23554       fprintf (f, "%lu", i);
23555     }
23556   /* Do not output a trailing newline, as this causes \r\n confusion
23557      on some platforms.  */
23558   return ferror (f) || fclose (f) != 0;
23559
23560   ;
23561   return 0;
23562 }
23563 _ACEOF
23564 rm -f conftest$ac_exeext
23565 if { (ac_try="$ac_link"
23566 case "(($ac_try" in
23567   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23568   *) ac_try_echo=$ac_try;;
23569 esac
23570 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23571 $as_echo "$ac_try_echo") >&5
23572   (eval "$ac_link") 2>&5
23573   ac_status=$?
23574   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23575   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23576   { (case "(($ac_try" in
23577   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23578   *) ac_try_echo=$ac_try;;
23579 esac
23580 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23581 $as_echo "$ac_try_echo") >&5
23582   (eval "$ac_try") 2>&5
23583   ac_status=$?
23584   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23585   (exit $ac_status); }; }; then
23586   ac_cv_sizeof_size_t=`cat conftest.val`
23587 else
23588   $as_echo "$as_me: program exited with status $ac_status" >&5
23589 $as_echo "$as_me: failed program was:" >&5
23590 sed 's/^/| /' conftest.$ac_ext >&5
23591
23592 ( exit $ac_status )
23593 if test "$ac_cv_type_size_t" = yes; then
23594      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
23595 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
23596 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
23597 See \`config.log' for more details." >&5
23598 $as_echo "$as_me: error: cannot compute sizeof (size_t)
23599 See \`config.log' for more details." >&2;}
23600    { (exit 77); exit 77; }; }; }
23601    else
23602      ac_cv_sizeof_size_t=0
23603    fi
23604 fi
23605 rm -rf conftest.dSYM
23606 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23607 fi
23608 rm -f conftest.val
23609 fi
23610 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
23611 $as_echo "$ac_cv_sizeof_size_t" >&6; }
23612
23613
23614
23615 cat >>confdefs.h <<_ACEOF
23616 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
23617 _ACEOF
23618
23619
23620
23621 # Decide whether float4 is passed by value: user-selectable, enabled by default
23622 { $as_echo "$as_me:$LINENO: checking whether to build with float4 passed by value" >&5
23623 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
23624
23625
23626 # Check whether --enable-float4-byval was given.
23627 if test "${enable_float4_byval+set}" = set; then
23628   enableval=$enable_float4_byval;
23629   case $enableval in
23630     yes)
23631
23632 cat >>confdefs.h <<\_ACEOF
23633 #define USE_FLOAT4_BYVAL 1
23634 _ACEOF
23635
23636                float4passbyval=true
23637       ;;
23638     no)
23639       float4passbyval=false
23640       ;;
23641     *)
23642       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float4-byval option" >&5
23643 $as_echo "$as_me: error: no argument expected for --enable-float4-byval option" >&2;}
23644    { (exit 1); exit 1; }; }
23645       ;;
23646   esac
23647
23648 else
23649   enable_float4_byval=yes
23650
23651 cat >>confdefs.h <<\_ACEOF
23652 #define USE_FLOAT4_BYVAL 1
23653 _ACEOF
23654
23655                float4passbyval=true
23656 fi
23657
23658
23659 { $as_echo "$as_me:$LINENO: result: $enable_float4_byval" >&5
23660 $as_echo "$enable_float4_byval" >&6; }
23661
23662 cat >>confdefs.h <<_ACEOF
23663 #define FLOAT4PASSBYVAL $float4passbyval
23664 _ACEOF
23665
23666
23667 # Decide whether float8 is passed by value.
23668 # Note: this setting also controls int8 and related types such as timestamp.
23669 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
23670 # If not, trying to select it is an error.
23671 { $as_echo "$as_me:$LINENO: checking whether to build with float8 passed by value" >&5
23672 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
23673 if test $ac_cv_sizeof_unsigned_long -ge 8 ; then
23674
23675
23676 # Check whether --enable-float8-byval was given.
23677 if test "${enable_float8_byval+set}" = set; then
23678   enableval=$enable_float8_byval;
23679   case $enableval in
23680     yes)
23681       :
23682       ;;
23683     no)
23684       :
23685       ;;
23686     *)
23687       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
23688 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
23689    { (exit 1); exit 1; }; }
23690       ;;
23691   esac
23692
23693 else
23694   enable_float8_byval=yes
23695
23696 fi
23697
23698
23699 else
23700
23701
23702 # Check whether --enable-float8-byval was given.
23703 if test "${enable_float8_byval+set}" = set; then
23704   enableval=$enable_float8_byval;
23705   case $enableval in
23706     yes)
23707       :
23708       ;;
23709     no)
23710       :
23711       ;;
23712     *)
23713       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
23714 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
23715    { (exit 1); exit 1; }; }
23716       ;;
23717   esac
23718
23719 else
23720   enable_float8_byval=no
23721
23722 fi
23723
23724
23725   if test "$enable_float8_byval" = yes ; then
23726     { { $as_echo "$as_me:$LINENO: error: --enable-float8-byval is not supported on 32-bit platforms." >&5
23727 $as_echo "$as_me: error: --enable-float8-byval is not supported on 32-bit platforms." >&2;}
23728    { (exit 1); exit 1; }; }
23729   fi
23730 fi
23731 if test "$enable_float8_byval" = yes ; then
23732
23733 cat >>confdefs.h <<\_ACEOF
23734 #define USE_FLOAT8_BYVAL 1
23735 _ACEOF
23736
23737   float8passbyval=true
23738 else
23739   float8passbyval=false
23740 fi
23741 { $as_echo "$as_me:$LINENO: result: $enable_float8_byval" >&5
23742 $as_echo "$enable_float8_byval" >&6; }
23743
23744 cat >>confdefs.h <<_ACEOF
23745 #define FLOAT8PASSBYVAL $float8passbyval
23746 _ACEOF
23747
23748
23749 # Determine memory alignment requirements for the basic C data types.
23750
23751 # The cast to long int works around a bug in the HP C Compiler,
23752 # see AC_CHECK_SIZEOF for more information.
23753 { $as_echo "$as_me:$LINENO: checking alignment of short" >&5
23754 $as_echo_n "checking alignment of short... " >&6; }
23755 if test "${ac_cv_alignof_short+set}" = set; then
23756   $as_echo_n "(cached) " >&6
23757 else
23758   if test "$cross_compiling" = yes; then
23759   # Depending upon the size, compute the lo and hi bounds.
23760 cat >conftest.$ac_ext <<_ACEOF
23761 /* confdefs.h.  */
23762 _ACEOF
23763 cat confdefs.h >>conftest.$ac_ext
23764 cat >>conftest.$ac_ext <<_ACEOF
23765 /* end confdefs.h.  */
23766 $ac_includes_default
23767 #ifndef offsetof
23768 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
23769 #endif
23770 typedef struct { char x; short y; } ac__type_alignof_;
23771 int
23772 main ()
23773 {
23774 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
23775 test_array [0] = 0
23776
23777   ;
23778   return 0;
23779 }
23780 _ACEOF
23781 rm -f conftest.$ac_objext
23782 if { (ac_try="$ac_compile"
23783 case "(($ac_try" in
23784   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23785   *) ac_try_echo=$ac_try;;
23786 esac
23787 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23788 $as_echo "$ac_try_echo") >&5
23789   (eval "$ac_compile") 2>conftest.er1
23790   ac_status=$?
23791   grep -v '^ *+' conftest.er1 >conftest.err
23792   rm -f conftest.er1
23793   cat conftest.err >&5
23794   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23795   (exit $ac_status); } && {
23796          test -z "$ac_c_werror_flag" ||
23797          test ! -s conftest.err
23798        } && test -s conftest.$ac_objext; then
23799   ac_lo=0 ac_mid=0
23800   while :; do
23801     cat >conftest.$ac_ext <<_ACEOF
23802 /* confdefs.h.  */
23803 _ACEOF
23804 cat confdefs.h >>conftest.$ac_ext
23805 cat >>conftest.$ac_ext <<_ACEOF
23806 /* end confdefs.h.  */
23807 $ac_includes_default
23808 #ifndef offsetof
23809 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
23810 #endif
23811 typedef struct { char x; short y; } ac__type_alignof_;
23812 int
23813 main ()
23814 {
23815 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
23816 test_array [0] = 0
23817
23818   ;
23819   return 0;
23820 }
23821 _ACEOF
23822 rm -f conftest.$ac_objext
23823 if { (ac_try="$ac_compile"
23824 case "(($ac_try" in
23825   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23826   *) ac_try_echo=$ac_try;;
23827 esac
23828 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23829 $as_echo "$ac_try_echo") >&5
23830   (eval "$ac_compile") 2>conftest.er1
23831   ac_status=$?
23832   grep -v '^ *+' conftest.er1 >conftest.err
23833   rm -f conftest.er1
23834   cat conftest.err >&5
23835   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23836   (exit $ac_status); } && {
23837          test -z "$ac_c_werror_flag" ||
23838          test ! -s conftest.err
23839        } && test -s conftest.$ac_objext; then
23840   ac_hi=$ac_mid; break
23841 else
23842   $as_echo "$as_me: failed program was:" >&5
23843 sed 's/^/| /' conftest.$ac_ext >&5
23844
23845         ac_lo=`expr $ac_mid + 1`
23846                         if test $ac_lo -le $ac_mid; then
23847                           ac_lo= ac_hi=
23848                           break
23849                         fi
23850                         ac_mid=`expr 2 '*' $ac_mid + 1`
23851 fi
23852
23853 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23854   done
23855 else
23856   $as_echo "$as_me: failed program was:" >&5
23857 sed 's/^/| /' conftest.$ac_ext >&5
23858
23859         cat >conftest.$ac_ext <<_ACEOF
23860 /* confdefs.h.  */
23861 _ACEOF
23862 cat confdefs.h >>conftest.$ac_ext
23863 cat >>conftest.$ac_ext <<_ACEOF
23864 /* end confdefs.h.  */
23865 $ac_includes_default
23866 #ifndef offsetof
23867 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
23868 #endif
23869 typedef struct { char x; short y; } ac__type_alignof_;
23870 int
23871 main ()
23872 {
23873 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
23874 test_array [0] = 0
23875
23876   ;
23877   return 0;
23878 }
23879 _ACEOF
23880 rm -f conftest.$ac_objext
23881 if { (ac_try="$ac_compile"
23882 case "(($ac_try" in
23883   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23884   *) ac_try_echo=$ac_try;;
23885 esac
23886 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23887 $as_echo "$ac_try_echo") >&5
23888   (eval "$ac_compile") 2>conftest.er1
23889   ac_status=$?
23890   grep -v '^ *+' conftest.er1 >conftest.err
23891   rm -f conftest.er1
23892   cat conftest.err >&5
23893   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23894   (exit $ac_status); } && {
23895          test -z "$ac_c_werror_flag" ||
23896          test ! -s conftest.err
23897        } && test -s conftest.$ac_objext; then
23898   ac_hi=-1 ac_mid=-1
23899   while :; do
23900     cat >conftest.$ac_ext <<_ACEOF
23901 /* confdefs.h.  */
23902 _ACEOF
23903 cat confdefs.h >>conftest.$ac_ext
23904 cat >>conftest.$ac_ext <<_ACEOF
23905 /* end confdefs.h.  */
23906 $ac_includes_default
23907 #ifndef offsetof
23908 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
23909 #endif
23910 typedef struct { char x; short y; } ac__type_alignof_;
23911 int
23912 main ()
23913 {
23914 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
23915 test_array [0] = 0
23916
23917   ;
23918   return 0;
23919 }
23920 _ACEOF
23921 rm -f conftest.$ac_objext
23922 if { (ac_try="$ac_compile"
23923 case "(($ac_try" in
23924   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23925   *) ac_try_echo=$ac_try;;
23926 esac
23927 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23928 $as_echo "$ac_try_echo") >&5
23929   (eval "$ac_compile") 2>conftest.er1
23930   ac_status=$?
23931   grep -v '^ *+' conftest.er1 >conftest.err
23932   rm -f conftest.er1
23933   cat conftest.err >&5
23934   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23935   (exit $ac_status); } && {
23936          test -z "$ac_c_werror_flag" ||
23937          test ! -s conftest.err
23938        } && test -s conftest.$ac_objext; then
23939   ac_lo=$ac_mid; break
23940 else
23941   $as_echo "$as_me: failed program was:" >&5
23942 sed 's/^/| /' conftest.$ac_ext >&5
23943
23944         ac_hi=`expr '(' $ac_mid ')' - 1`
23945                         if test $ac_mid -le $ac_hi; then
23946                           ac_lo= ac_hi=
23947                           break
23948                         fi
23949                         ac_mid=`expr 2 '*' $ac_mid`
23950 fi
23951
23952 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23953   done
23954 else
23955   $as_echo "$as_me: failed program was:" >&5
23956 sed 's/^/| /' conftest.$ac_ext >&5
23957
23958         ac_lo= ac_hi=
23959 fi
23960
23961 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23962 fi
23963
23964 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23965 # Binary search between lo and hi bounds.
23966 while test "x$ac_lo" != "x$ac_hi"; do
23967   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
23968   cat >conftest.$ac_ext <<_ACEOF
23969 /* confdefs.h.  */
23970 _ACEOF
23971 cat confdefs.h >>conftest.$ac_ext
23972 cat >>conftest.$ac_ext <<_ACEOF
23973 /* end confdefs.h.  */
23974 $ac_includes_default
23975 #ifndef offsetof
23976 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
23977 #endif
23978 typedef struct { char x; short y; } ac__type_alignof_;
23979 int
23980 main ()
23981 {
23982 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
23983 test_array [0] = 0
23984
23985   ;
23986   return 0;
23987 }
23988 _ACEOF
23989 rm -f conftest.$ac_objext
23990 if { (ac_try="$ac_compile"
23991 case "(($ac_try" in
23992   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23993   *) ac_try_echo=$ac_try;;
23994 esac
23995 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23996 $as_echo "$ac_try_echo") >&5
23997   (eval "$ac_compile") 2>conftest.er1
23998   ac_status=$?
23999   grep -v '^ *+' conftest.er1 >conftest.err
24000   rm -f conftest.er1
24001   cat conftest.err >&5
24002   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24003   (exit $ac_status); } && {
24004          test -z "$ac_c_werror_flag" ||
24005          test ! -s conftest.err
24006        } && test -s conftest.$ac_objext; then
24007   ac_hi=$ac_mid
24008 else
24009   $as_echo "$as_me: failed program was:" >&5
24010 sed 's/^/| /' conftest.$ac_ext >&5
24011
24012         ac_lo=`expr '(' $ac_mid ')' + 1`
24013 fi
24014
24015 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24016 done
24017 case $ac_lo in
24018 ?*) ac_cv_alignof_short=$ac_lo;;
24019 '') if test "$ac_cv_type_short" = yes; then
24020      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24021 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24022 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
24023 See \`config.log' for more details." >&5
24024 $as_echo "$as_me: error: cannot compute alignment of short
24025 See \`config.log' for more details." >&2;}
24026    { (exit 77); exit 77; }; }; }
24027    else
24028      ac_cv_alignof_short=0
24029    fi ;;
24030 esac
24031 else
24032   cat >conftest.$ac_ext <<_ACEOF
24033 /* confdefs.h.  */
24034 _ACEOF
24035 cat confdefs.h >>conftest.$ac_ext
24036 cat >>conftest.$ac_ext <<_ACEOF
24037 /* end confdefs.h.  */
24038 $ac_includes_default
24039 #ifndef offsetof
24040 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24041 #endif
24042 typedef struct { char x; short y; } ac__type_alignof_;
24043 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
24044 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
24045 #include <stdio.h>
24046 #include <stdlib.h>
24047 int
24048 main ()
24049 {
24050
24051   FILE *f = fopen ("conftest.val", "w");
24052   if (! f)
24053     return 1;
24054   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
24055     {
24056       long int i = longval ();
24057       if (i != ((long int) offsetof (ac__type_alignof_, y)))
24058         return 1;
24059       fprintf (f, "%ld", i);
24060     }
24061   else
24062     {
24063       unsigned long int i = ulongval ();
24064       if (i != ((long int) offsetof (ac__type_alignof_, y)))
24065         return 1;
24066       fprintf (f, "%lu", i);
24067     }
24068   /* Do not output a trailing newline, as this causes \r\n confusion
24069      on some platforms.  */
24070   return ferror (f) || fclose (f) != 0;
24071
24072   ;
24073   return 0;
24074 }
24075 _ACEOF
24076 rm -f conftest$ac_exeext
24077 if { (ac_try="$ac_link"
24078 case "(($ac_try" in
24079   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24080   *) ac_try_echo=$ac_try;;
24081 esac
24082 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24083 $as_echo "$ac_try_echo") >&5
24084   (eval "$ac_link") 2>&5
24085   ac_status=$?
24086   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24087   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24088   { (case "(($ac_try" in
24089   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24090   *) ac_try_echo=$ac_try;;
24091 esac
24092 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24093 $as_echo "$ac_try_echo") >&5
24094   (eval "$ac_try") 2>&5
24095   ac_status=$?
24096   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24097   (exit $ac_status); }; }; then
24098   ac_cv_alignof_short=`cat conftest.val`
24099 else
24100   $as_echo "$as_me: program exited with status $ac_status" >&5
24101 $as_echo "$as_me: failed program was:" >&5
24102 sed 's/^/| /' conftest.$ac_ext >&5
24103
24104 ( exit $ac_status )
24105 if test "$ac_cv_type_short" = 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 alignment of short
24109 See \`config.log' for more details." >&5
24110 $as_echo "$as_me: error: cannot compute alignment of short
24111 See \`config.log' for more details." >&2;}
24112    { (exit 77); exit 77; }; }; }
24113    else
24114      ac_cv_alignof_short=0
24115    fi
24116 fi
24117 rm -rf conftest.dSYM
24118 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24119 fi
24120 rm -f conftest.val
24121 fi
24122 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
24123 $as_echo "$ac_cv_alignof_short" >&6; }
24124
24125
24126
24127 cat >>confdefs.h <<_ACEOF
24128 #define ALIGNOF_SHORT $ac_cv_alignof_short
24129 _ACEOF
24130
24131
24132 # The cast to long int works around a bug in the HP C Compiler,
24133 # see AC_CHECK_SIZEOF for more information.
24134 { $as_echo "$as_me:$LINENO: checking alignment of int" >&5
24135 $as_echo_n "checking alignment of int... " >&6; }
24136 if test "${ac_cv_alignof_int+set}" = set; then
24137   $as_echo_n "(cached) " >&6
24138 else
24139   if test "$cross_compiling" = yes; then
24140   # Depending upon the size, compute the lo and hi bounds.
24141 cat >conftest.$ac_ext <<_ACEOF
24142 /* confdefs.h.  */
24143 _ACEOF
24144 cat confdefs.h >>conftest.$ac_ext
24145 cat >>conftest.$ac_ext <<_ACEOF
24146 /* end confdefs.h.  */
24147 $ac_includes_default
24148 #ifndef offsetof
24149 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24150 #endif
24151 typedef struct { char x; int y; } ac__type_alignof_;
24152 int
24153 main ()
24154 {
24155 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
24156 test_array [0] = 0
24157
24158   ;
24159   return 0;
24160 }
24161 _ACEOF
24162 rm -f conftest.$ac_objext
24163 if { (ac_try="$ac_compile"
24164 case "(($ac_try" in
24165   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24166   *) ac_try_echo=$ac_try;;
24167 esac
24168 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24169 $as_echo "$ac_try_echo") >&5
24170   (eval "$ac_compile") 2>conftest.er1
24171   ac_status=$?
24172   grep -v '^ *+' conftest.er1 >conftest.err
24173   rm -f conftest.er1
24174   cat conftest.err >&5
24175   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24176   (exit $ac_status); } && {
24177          test -z "$ac_c_werror_flag" ||
24178          test ! -s conftest.err
24179        } && test -s conftest.$ac_objext; then
24180   ac_lo=0 ac_mid=0
24181   while :; do
24182     cat >conftest.$ac_ext <<_ACEOF
24183 /* confdefs.h.  */
24184 _ACEOF
24185 cat confdefs.h >>conftest.$ac_ext
24186 cat >>conftest.$ac_ext <<_ACEOF
24187 /* end confdefs.h.  */
24188 $ac_includes_default
24189 #ifndef offsetof
24190 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24191 #endif
24192 typedef struct { char x; int y; } ac__type_alignof_;
24193 int
24194 main ()
24195 {
24196 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
24197 test_array [0] = 0
24198
24199   ;
24200   return 0;
24201 }
24202 _ACEOF
24203 rm -f conftest.$ac_objext
24204 if { (ac_try="$ac_compile"
24205 case "(($ac_try" in
24206   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24207   *) ac_try_echo=$ac_try;;
24208 esac
24209 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24210 $as_echo "$ac_try_echo") >&5
24211   (eval "$ac_compile") 2>conftest.er1
24212   ac_status=$?
24213   grep -v '^ *+' conftest.er1 >conftest.err
24214   rm -f conftest.er1
24215   cat conftest.err >&5
24216   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24217   (exit $ac_status); } && {
24218          test -z "$ac_c_werror_flag" ||
24219          test ! -s conftest.err
24220        } && test -s conftest.$ac_objext; then
24221   ac_hi=$ac_mid; break
24222 else
24223   $as_echo "$as_me: failed program was:" >&5
24224 sed 's/^/| /' conftest.$ac_ext >&5
24225
24226         ac_lo=`expr $ac_mid + 1`
24227                         if test $ac_lo -le $ac_mid; then
24228                           ac_lo= ac_hi=
24229                           break
24230                         fi
24231                         ac_mid=`expr 2 '*' $ac_mid + 1`
24232 fi
24233
24234 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24235   done
24236 else
24237   $as_echo "$as_me: failed program was:" >&5
24238 sed 's/^/| /' conftest.$ac_ext >&5
24239
24240         cat >conftest.$ac_ext <<_ACEOF
24241 /* confdefs.h.  */
24242 _ACEOF
24243 cat confdefs.h >>conftest.$ac_ext
24244 cat >>conftest.$ac_ext <<_ACEOF
24245 /* end confdefs.h.  */
24246 $ac_includes_default
24247 #ifndef offsetof
24248 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24249 #endif
24250 typedef struct { char x; int y; } ac__type_alignof_;
24251 int
24252 main ()
24253 {
24254 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
24255 test_array [0] = 0
24256
24257   ;
24258   return 0;
24259 }
24260 _ACEOF
24261 rm -f conftest.$ac_objext
24262 if { (ac_try="$ac_compile"
24263 case "(($ac_try" in
24264   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24265   *) ac_try_echo=$ac_try;;
24266 esac
24267 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24268 $as_echo "$ac_try_echo") >&5
24269   (eval "$ac_compile") 2>conftest.er1
24270   ac_status=$?
24271   grep -v '^ *+' conftest.er1 >conftest.err
24272   rm -f conftest.er1
24273   cat conftest.err >&5
24274   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24275   (exit $ac_status); } && {
24276          test -z "$ac_c_werror_flag" ||
24277          test ! -s conftest.err
24278        } && test -s conftest.$ac_objext; then
24279   ac_hi=-1 ac_mid=-1
24280   while :; do
24281     cat >conftest.$ac_ext <<_ACEOF
24282 /* confdefs.h.  */
24283 _ACEOF
24284 cat confdefs.h >>conftest.$ac_ext
24285 cat >>conftest.$ac_ext <<_ACEOF
24286 /* end confdefs.h.  */
24287 $ac_includes_default
24288 #ifndef offsetof
24289 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24290 #endif
24291 typedef struct { char x; int y; } ac__type_alignof_;
24292 int
24293 main ()
24294 {
24295 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
24296 test_array [0] = 0
24297
24298   ;
24299   return 0;
24300 }
24301 _ACEOF
24302 rm -f conftest.$ac_objext
24303 if { (ac_try="$ac_compile"
24304 case "(($ac_try" in
24305   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24306   *) ac_try_echo=$ac_try;;
24307 esac
24308 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24309 $as_echo "$ac_try_echo") >&5
24310   (eval "$ac_compile") 2>conftest.er1
24311   ac_status=$?
24312   grep -v '^ *+' conftest.er1 >conftest.err
24313   rm -f conftest.er1
24314   cat conftest.err >&5
24315   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24316   (exit $ac_status); } && {
24317          test -z "$ac_c_werror_flag" ||
24318          test ! -s conftest.err
24319        } && test -s conftest.$ac_objext; then
24320   ac_lo=$ac_mid; break
24321 else
24322   $as_echo "$as_me: failed program was:" >&5
24323 sed 's/^/| /' conftest.$ac_ext >&5
24324
24325         ac_hi=`expr '(' $ac_mid ')' - 1`
24326                         if test $ac_mid -le $ac_hi; then
24327                           ac_lo= ac_hi=
24328                           break
24329                         fi
24330                         ac_mid=`expr 2 '*' $ac_mid`
24331 fi
24332
24333 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24334   done
24335 else
24336   $as_echo "$as_me: failed program was:" >&5
24337 sed 's/^/| /' conftest.$ac_ext >&5
24338
24339         ac_lo= ac_hi=
24340 fi
24341
24342 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24343 fi
24344
24345 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24346 # Binary search between lo and hi bounds.
24347 while test "x$ac_lo" != "x$ac_hi"; do
24348   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24349   cat >conftest.$ac_ext <<_ACEOF
24350 /* confdefs.h.  */
24351 _ACEOF
24352 cat confdefs.h >>conftest.$ac_ext
24353 cat >>conftest.$ac_ext <<_ACEOF
24354 /* end confdefs.h.  */
24355 $ac_includes_default
24356 #ifndef offsetof
24357 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24358 #endif
24359 typedef struct { char x; int y; } ac__type_alignof_;
24360 int
24361 main ()
24362 {
24363 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $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_hi=$ac_mid
24389 else
24390   $as_echo "$as_me: failed program was:" >&5
24391 sed 's/^/| /' conftest.$ac_ext >&5
24392
24393         ac_lo=`expr '(' $ac_mid ')' + 1`
24394 fi
24395
24396 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24397 done
24398 case $ac_lo in
24399 ?*) ac_cv_alignof_int=$ac_lo;;
24400 '') if test "$ac_cv_type_int" = yes; then
24401      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24402 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24403 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
24404 See \`config.log' for more details." >&5
24405 $as_echo "$as_me: error: cannot compute alignment of int
24406 See \`config.log' for more details." >&2;}
24407    { (exit 77); exit 77; }; }; }
24408    else
24409      ac_cv_alignof_int=0
24410    fi ;;
24411 esac
24412 else
24413   cat >conftest.$ac_ext <<_ACEOF
24414 /* confdefs.h.  */
24415 _ACEOF
24416 cat confdefs.h >>conftest.$ac_ext
24417 cat >>conftest.$ac_ext <<_ACEOF
24418 /* end confdefs.h.  */
24419 $ac_includes_default
24420 #ifndef offsetof
24421 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24422 #endif
24423 typedef struct { char x; int y; } ac__type_alignof_;
24424 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
24425 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
24426 #include <stdio.h>
24427 #include <stdlib.h>
24428 int
24429 main ()
24430 {
24431
24432   FILE *f = fopen ("conftest.val", "w");
24433   if (! f)
24434     return 1;
24435   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
24436     {
24437       long int i = longval ();
24438       if (i != ((long int) offsetof (ac__type_alignof_, y)))
24439         return 1;
24440       fprintf (f, "%ld", i);
24441     }
24442   else
24443     {
24444       unsigned long int i = ulongval ();
24445       if (i != ((long int) offsetof (ac__type_alignof_, y)))
24446         return 1;
24447       fprintf (f, "%lu", i);
24448     }
24449   /* Do not output a trailing newline, as this causes \r\n confusion
24450      on some platforms.  */
24451   return ferror (f) || fclose (f) != 0;
24452
24453   ;
24454   return 0;
24455 }
24456 _ACEOF
24457 rm -f conftest$ac_exeext
24458 if { (ac_try="$ac_link"
24459 case "(($ac_try" in
24460   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24461   *) ac_try_echo=$ac_try;;
24462 esac
24463 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24464 $as_echo "$ac_try_echo") >&5
24465   (eval "$ac_link") 2>&5
24466   ac_status=$?
24467   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24468   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24469   { (case "(($ac_try" in
24470   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24471   *) ac_try_echo=$ac_try;;
24472 esac
24473 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24474 $as_echo "$ac_try_echo") >&5
24475   (eval "$ac_try") 2>&5
24476   ac_status=$?
24477   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24478   (exit $ac_status); }; }; then
24479   ac_cv_alignof_int=`cat conftest.val`
24480 else
24481   $as_echo "$as_me: program exited with status $ac_status" >&5
24482 $as_echo "$as_me: failed program was:" >&5
24483 sed 's/^/| /' conftest.$ac_ext >&5
24484
24485 ( exit $ac_status )
24486 if test "$ac_cv_type_int" = yes; then
24487      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24488 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24489 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
24490 See \`config.log' for more details." >&5
24491 $as_echo "$as_me: error: cannot compute alignment of int
24492 See \`config.log' for more details." >&2;}
24493    { (exit 77); exit 77; }; }; }
24494    else
24495      ac_cv_alignof_int=0
24496    fi
24497 fi
24498 rm -rf conftest.dSYM
24499 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24500 fi
24501 rm -f conftest.val
24502 fi
24503 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
24504 $as_echo "$ac_cv_alignof_int" >&6; }
24505
24506
24507
24508 cat >>confdefs.h <<_ACEOF
24509 #define ALIGNOF_INT $ac_cv_alignof_int
24510 _ACEOF
24511
24512
24513 # The cast to long int works around a bug in the HP C Compiler,
24514 # see AC_CHECK_SIZEOF for more information.
24515 { $as_echo "$as_me:$LINENO: checking alignment of long" >&5
24516 $as_echo_n "checking alignment of long... " >&6; }
24517 if test "${ac_cv_alignof_long+set}" = set; then
24518   $as_echo_n "(cached) " >&6
24519 else
24520   if test "$cross_compiling" = yes; then
24521   # Depending upon the size, compute the lo and hi bounds.
24522 cat >conftest.$ac_ext <<_ACEOF
24523 /* confdefs.h.  */
24524 _ACEOF
24525 cat confdefs.h >>conftest.$ac_ext
24526 cat >>conftest.$ac_ext <<_ACEOF
24527 /* end confdefs.h.  */
24528 $ac_includes_default
24529 #ifndef offsetof
24530 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24531 #endif
24532 typedef struct { char x; long y; } ac__type_alignof_;
24533 int
24534 main ()
24535 {
24536 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
24537 test_array [0] = 0
24538
24539   ;
24540   return 0;
24541 }
24542 _ACEOF
24543 rm -f conftest.$ac_objext
24544 if { (ac_try="$ac_compile"
24545 case "(($ac_try" in
24546   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24547   *) ac_try_echo=$ac_try;;
24548 esac
24549 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24550 $as_echo "$ac_try_echo") >&5
24551   (eval "$ac_compile") 2>conftest.er1
24552   ac_status=$?
24553   grep -v '^ *+' conftest.er1 >conftest.err
24554   rm -f conftest.er1
24555   cat conftest.err >&5
24556   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24557   (exit $ac_status); } && {
24558          test -z "$ac_c_werror_flag" ||
24559          test ! -s conftest.err
24560        } && test -s conftest.$ac_objext; then
24561   ac_lo=0 ac_mid=0
24562   while :; do
24563     cat >conftest.$ac_ext <<_ACEOF
24564 /* confdefs.h.  */
24565 _ACEOF
24566 cat confdefs.h >>conftest.$ac_ext
24567 cat >>conftest.$ac_ext <<_ACEOF
24568 /* end confdefs.h.  */
24569 $ac_includes_default
24570 #ifndef offsetof
24571 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24572 #endif
24573 typedef struct { char x; long y; } ac__type_alignof_;
24574 int
24575 main ()
24576 {
24577 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
24578 test_array [0] = 0
24579
24580   ;
24581   return 0;
24582 }
24583 _ACEOF
24584 rm -f conftest.$ac_objext
24585 if { (ac_try="$ac_compile"
24586 case "(($ac_try" in
24587   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24588   *) ac_try_echo=$ac_try;;
24589 esac
24590 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24591 $as_echo "$ac_try_echo") >&5
24592   (eval "$ac_compile") 2>conftest.er1
24593   ac_status=$?
24594   grep -v '^ *+' conftest.er1 >conftest.err
24595   rm -f conftest.er1
24596   cat conftest.err >&5
24597   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24598   (exit $ac_status); } && {
24599          test -z "$ac_c_werror_flag" ||
24600          test ! -s conftest.err
24601        } && test -s conftest.$ac_objext; then
24602   ac_hi=$ac_mid; break
24603 else
24604   $as_echo "$as_me: failed program was:" >&5
24605 sed 's/^/| /' conftest.$ac_ext >&5
24606
24607         ac_lo=`expr $ac_mid + 1`
24608                         if test $ac_lo -le $ac_mid; then
24609                           ac_lo= ac_hi=
24610                           break
24611                         fi
24612                         ac_mid=`expr 2 '*' $ac_mid + 1`
24613 fi
24614
24615 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24616   done
24617 else
24618   $as_echo "$as_me: failed program was:" >&5
24619 sed 's/^/| /' conftest.$ac_ext >&5
24620
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 #ifndef offsetof
24629 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24630 #endif
24631 typedef struct { char x; long y; } ac__type_alignof_;
24632 int
24633 main ()
24634 {
24635 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
24636 test_array [0] = 0
24637
24638   ;
24639   return 0;
24640 }
24641 _ACEOF
24642 rm -f conftest.$ac_objext
24643 if { (ac_try="$ac_compile"
24644 case "(($ac_try" in
24645   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24646   *) ac_try_echo=$ac_try;;
24647 esac
24648 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24649 $as_echo "$ac_try_echo") >&5
24650   (eval "$ac_compile") 2>conftest.er1
24651   ac_status=$?
24652   grep -v '^ *+' conftest.er1 >conftest.err
24653   rm -f conftest.er1
24654   cat conftest.err >&5
24655   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24656   (exit $ac_status); } && {
24657          test -z "$ac_c_werror_flag" ||
24658          test ! -s conftest.err
24659        } && test -s conftest.$ac_objext; then
24660   ac_hi=-1 ac_mid=-1
24661   while :; do
24662     cat >conftest.$ac_ext <<_ACEOF
24663 /* confdefs.h.  */
24664 _ACEOF
24665 cat confdefs.h >>conftest.$ac_ext
24666 cat >>conftest.$ac_ext <<_ACEOF
24667 /* end confdefs.h.  */
24668 $ac_includes_default
24669 #ifndef offsetof
24670 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24671 #endif
24672 typedef struct { char x; long y; } ac__type_alignof_;
24673 int
24674 main ()
24675 {
24676 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
24677 test_array [0] = 0
24678
24679   ;
24680   return 0;
24681 }
24682 _ACEOF
24683 rm -f conftest.$ac_objext
24684 if { (ac_try="$ac_compile"
24685 case "(($ac_try" in
24686   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24687   *) ac_try_echo=$ac_try;;
24688 esac
24689 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24690 $as_echo "$ac_try_echo") >&5
24691   (eval "$ac_compile") 2>conftest.er1
24692   ac_status=$?
24693   grep -v '^ *+' conftest.er1 >conftest.err
24694   rm -f conftest.er1
24695   cat conftest.err >&5
24696   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24697   (exit $ac_status); } && {
24698          test -z "$ac_c_werror_flag" ||
24699          test ! -s conftest.err
24700        } && test -s conftest.$ac_objext; then
24701   ac_lo=$ac_mid; break
24702 else
24703   $as_echo "$as_me: failed program was:" >&5
24704 sed 's/^/| /' conftest.$ac_ext >&5
24705
24706         ac_hi=`expr '(' $ac_mid ')' - 1`
24707                         if test $ac_mid -le $ac_hi; then
24708                           ac_lo= ac_hi=
24709                           break
24710                         fi
24711                         ac_mid=`expr 2 '*' $ac_mid`
24712 fi
24713
24714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24715   done
24716 else
24717   $as_echo "$as_me: failed program was:" >&5
24718 sed 's/^/| /' conftest.$ac_ext >&5
24719
24720         ac_lo= ac_hi=
24721 fi
24722
24723 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24724 fi
24725
24726 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24727 # Binary search between lo and hi bounds.
24728 while test "x$ac_lo" != "x$ac_hi"; do
24729   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24730   cat >conftest.$ac_ext <<_ACEOF
24731 /* confdefs.h.  */
24732 _ACEOF
24733 cat confdefs.h >>conftest.$ac_ext
24734 cat >>conftest.$ac_ext <<_ACEOF
24735 /* end confdefs.h.  */
24736 $ac_includes_default
24737 #ifndef offsetof
24738 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24739 #endif
24740 typedef struct { char x; long y; } ac__type_alignof_;
24741 int
24742 main ()
24743 {
24744 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
24745 test_array [0] = 0
24746
24747   ;
24748   return 0;
24749 }
24750 _ACEOF
24751 rm -f conftest.$ac_objext
24752 if { (ac_try="$ac_compile"
24753 case "(($ac_try" in
24754   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24755   *) ac_try_echo=$ac_try;;
24756 esac
24757 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24758 $as_echo "$ac_try_echo") >&5
24759   (eval "$ac_compile") 2>conftest.er1
24760   ac_status=$?
24761   grep -v '^ *+' conftest.er1 >conftest.err
24762   rm -f conftest.er1
24763   cat conftest.err >&5
24764   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24765   (exit $ac_status); } && {
24766          test -z "$ac_c_werror_flag" ||
24767          test ! -s conftest.err
24768        } && test -s conftest.$ac_objext; then
24769   ac_hi=$ac_mid
24770 else
24771   $as_echo "$as_me: failed program was:" >&5
24772 sed 's/^/| /' conftest.$ac_ext >&5
24773
24774         ac_lo=`expr '(' $ac_mid ')' + 1`
24775 fi
24776
24777 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24778 done
24779 case $ac_lo in
24780 ?*) ac_cv_alignof_long=$ac_lo;;
24781 '') if test "$ac_cv_type_long" = yes; then
24782      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24783 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24784 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
24785 See \`config.log' for more details." >&5
24786 $as_echo "$as_me: error: cannot compute alignment of long
24787 See \`config.log' for more details." >&2;}
24788    { (exit 77); exit 77; }; }; }
24789    else
24790      ac_cv_alignof_long=0
24791    fi ;;
24792 esac
24793 else
24794   cat >conftest.$ac_ext <<_ACEOF
24795 /* confdefs.h.  */
24796 _ACEOF
24797 cat confdefs.h >>conftest.$ac_ext
24798 cat >>conftest.$ac_ext <<_ACEOF
24799 /* end confdefs.h.  */
24800 $ac_includes_default
24801 #ifndef offsetof
24802 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24803 #endif
24804 typedef struct { char x; long y; } ac__type_alignof_;
24805 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
24806 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
24807 #include <stdio.h>
24808 #include <stdlib.h>
24809 int
24810 main ()
24811 {
24812
24813   FILE *f = fopen ("conftest.val", "w");
24814   if (! f)
24815     return 1;
24816   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
24817     {
24818       long int i = longval ();
24819       if (i != ((long int) offsetof (ac__type_alignof_, y)))
24820         return 1;
24821       fprintf (f, "%ld", i);
24822     }
24823   else
24824     {
24825       unsigned long int i = ulongval ();
24826       if (i != ((long int) offsetof (ac__type_alignof_, y)))
24827         return 1;
24828       fprintf (f, "%lu", i);
24829     }
24830   /* Do not output a trailing newline, as this causes \r\n confusion
24831      on some platforms.  */
24832   return ferror (f) || fclose (f) != 0;
24833
24834   ;
24835   return 0;
24836 }
24837 _ACEOF
24838 rm -f conftest$ac_exeext
24839 if { (ac_try="$ac_link"
24840 case "(($ac_try" in
24841   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24842   *) ac_try_echo=$ac_try;;
24843 esac
24844 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24845 $as_echo "$ac_try_echo") >&5
24846   (eval "$ac_link") 2>&5
24847   ac_status=$?
24848   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24849   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24850   { (case "(($ac_try" in
24851   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24852   *) ac_try_echo=$ac_try;;
24853 esac
24854 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24855 $as_echo "$ac_try_echo") >&5
24856   (eval "$ac_try") 2>&5
24857   ac_status=$?
24858   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24859   (exit $ac_status); }; }; then
24860   ac_cv_alignof_long=`cat conftest.val`
24861 else
24862   $as_echo "$as_me: program exited with status $ac_status" >&5
24863 $as_echo "$as_me: failed program was:" >&5
24864 sed 's/^/| /' conftest.$ac_ext >&5
24865
24866 ( exit $ac_status )
24867 if test "$ac_cv_type_long" = yes; then
24868      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24869 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24870 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
24871 See \`config.log' for more details." >&5
24872 $as_echo "$as_me: error: cannot compute alignment of long
24873 See \`config.log' for more details." >&2;}
24874    { (exit 77); exit 77; }; }; }
24875    else
24876      ac_cv_alignof_long=0
24877    fi
24878 fi
24879 rm -rf conftest.dSYM
24880 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24881 fi
24882 rm -f conftest.val
24883 fi
24884 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
24885 $as_echo "$ac_cv_alignof_long" >&6; }
24886
24887
24888
24889 cat >>confdefs.h <<_ACEOF
24890 #define ALIGNOF_LONG $ac_cv_alignof_long
24891 _ACEOF
24892
24893
24894 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
24895   # The cast to long int works around a bug in the HP C Compiler,
24896 # see AC_CHECK_SIZEOF for more information.
24897 { $as_echo "$as_me:$LINENO: checking alignment of long long int" >&5
24898 $as_echo_n "checking alignment of long long int... " >&6; }
24899 if test "${ac_cv_alignof_long_long_int+set}" = set; then
24900   $as_echo_n "(cached) " >&6
24901 else
24902   if test "$cross_compiling" = yes; then
24903   # Depending upon the size, compute the lo and hi bounds.
24904 cat >conftest.$ac_ext <<_ACEOF
24905 /* confdefs.h.  */
24906 _ACEOF
24907 cat confdefs.h >>conftest.$ac_ext
24908 cat >>conftest.$ac_ext <<_ACEOF
24909 /* end confdefs.h.  */
24910 $ac_includes_default
24911 #ifndef offsetof
24912 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24913 #endif
24914 typedef struct { char x; long long int y; } ac__type_alignof_;
24915 int
24916 main ()
24917 {
24918 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
24919 test_array [0] = 0
24920
24921   ;
24922   return 0;
24923 }
24924 _ACEOF
24925 rm -f conftest.$ac_objext
24926 if { (ac_try="$ac_compile"
24927 case "(($ac_try" in
24928   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24929   *) ac_try_echo=$ac_try;;
24930 esac
24931 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24932 $as_echo "$ac_try_echo") >&5
24933   (eval "$ac_compile") 2>conftest.er1
24934   ac_status=$?
24935   grep -v '^ *+' conftest.er1 >conftest.err
24936   rm -f conftest.er1
24937   cat conftest.err >&5
24938   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24939   (exit $ac_status); } && {
24940          test -z "$ac_c_werror_flag" ||
24941          test ! -s conftest.err
24942        } && test -s conftest.$ac_objext; then
24943   ac_lo=0 ac_mid=0
24944   while :; do
24945     cat >conftest.$ac_ext <<_ACEOF
24946 /* confdefs.h.  */
24947 _ACEOF
24948 cat confdefs.h >>conftest.$ac_ext
24949 cat >>conftest.$ac_ext <<_ACEOF
24950 /* end confdefs.h.  */
24951 $ac_includes_default
24952 #ifndef offsetof
24953 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
24954 #endif
24955 typedef struct { char x; long long int y; } ac__type_alignof_;
24956 int
24957 main ()
24958 {
24959 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
24960 test_array [0] = 0
24961
24962   ;
24963   return 0;
24964 }
24965 _ACEOF
24966 rm -f conftest.$ac_objext
24967 if { (ac_try="$ac_compile"
24968 case "(($ac_try" in
24969   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24970   *) ac_try_echo=$ac_try;;
24971 esac
24972 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24973 $as_echo "$ac_try_echo") >&5
24974   (eval "$ac_compile") 2>conftest.er1
24975   ac_status=$?
24976   grep -v '^ *+' conftest.er1 >conftest.err
24977   rm -f conftest.er1
24978   cat conftest.err >&5
24979   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24980   (exit $ac_status); } && {
24981          test -z "$ac_c_werror_flag" ||
24982          test ! -s conftest.err
24983        } && test -s conftest.$ac_objext; then
24984   ac_hi=$ac_mid; break
24985 else
24986   $as_echo "$as_me: failed program was:" >&5
24987 sed 's/^/| /' conftest.$ac_ext >&5
24988
24989         ac_lo=`expr $ac_mid + 1`
24990                         if test $ac_lo -le $ac_mid; then
24991                           ac_lo= ac_hi=
24992                           break
24993                         fi
24994                         ac_mid=`expr 2 '*' $ac_mid + 1`
24995 fi
24996
24997 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24998   done
24999 else
25000   $as_echo "$as_me: failed program was:" >&5
25001 sed 's/^/| /' conftest.$ac_ext >&5
25002
25003         cat >conftest.$ac_ext <<_ACEOF
25004 /* confdefs.h.  */
25005 _ACEOF
25006 cat confdefs.h >>conftest.$ac_ext
25007 cat >>conftest.$ac_ext <<_ACEOF
25008 /* end confdefs.h.  */
25009 $ac_includes_default
25010 #ifndef offsetof
25011 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25012 #endif
25013 typedef struct { char x; long long int y; } ac__type_alignof_;
25014 int
25015 main ()
25016 {
25017 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25018 test_array [0] = 0
25019
25020   ;
25021   return 0;
25022 }
25023 _ACEOF
25024 rm -f conftest.$ac_objext
25025 if { (ac_try="$ac_compile"
25026 case "(($ac_try" in
25027   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25028   *) ac_try_echo=$ac_try;;
25029 esac
25030 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25031 $as_echo "$ac_try_echo") >&5
25032   (eval "$ac_compile") 2>conftest.er1
25033   ac_status=$?
25034   grep -v '^ *+' conftest.er1 >conftest.err
25035   rm -f conftest.er1
25036   cat conftest.err >&5
25037   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25038   (exit $ac_status); } && {
25039          test -z "$ac_c_werror_flag" ||
25040          test ! -s conftest.err
25041        } && test -s conftest.$ac_objext; then
25042   ac_hi=-1 ac_mid=-1
25043   while :; do
25044     cat >conftest.$ac_ext <<_ACEOF
25045 /* confdefs.h.  */
25046 _ACEOF
25047 cat confdefs.h >>conftest.$ac_ext
25048 cat >>conftest.$ac_ext <<_ACEOF
25049 /* end confdefs.h.  */
25050 $ac_includes_default
25051 #ifndef offsetof
25052 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25053 #endif
25054 typedef struct { char x; long long int y; } ac__type_alignof_;
25055 int
25056 main ()
25057 {
25058 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25059 test_array [0] = 0
25060
25061   ;
25062   return 0;
25063 }
25064 _ACEOF
25065 rm -f conftest.$ac_objext
25066 if { (ac_try="$ac_compile"
25067 case "(($ac_try" in
25068   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25069   *) ac_try_echo=$ac_try;;
25070 esac
25071 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25072 $as_echo "$ac_try_echo") >&5
25073   (eval "$ac_compile") 2>conftest.er1
25074   ac_status=$?
25075   grep -v '^ *+' conftest.er1 >conftest.err
25076   rm -f conftest.er1
25077   cat conftest.err >&5
25078   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25079   (exit $ac_status); } && {
25080          test -z "$ac_c_werror_flag" ||
25081          test ! -s conftest.err
25082        } && test -s conftest.$ac_objext; then
25083   ac_lo=$ac_mid; break
25084 else
25085   $as_echo "$as_me: failed program was:" >&5
25086 sed 's/^/| /' conftest.$ac_ext >&5
25087
25088         ac_hi=`expr '(' $ac_mid ')' - 1`
25089                         if test $ac_mid -le $ac_hi; then
25090                           ac_lo= ac_hi=
25091                           break
25092                         fi
25093                         ac_mid=`expr 2 '*' $ac_mid`
25094 fi
25095
25096 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25097   done
25098 else
25099   $as_echo "$as_me: failed program was:" >&5
25100 sed 's/^/| /' conftest.$ac_ext >&5
25101
25102         ac_lo= ac_hi=
25103 fi
25104
25105 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25106 fi
25107
25108 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25109 # Binary search between lo and hi bounds.
25110 while test "x$ac_lo" != "x$ac_hi"; do
25111   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25112   cat >conftest.$ac_ext <<_ACEOF
25113 /* confdefs.h.  */
25114 _ACEOF
25115 cat confdefs.h >>conftest.$ac_ext
25116 cat >>conftest.$ac_ext <<_ACEOF
25117 /* end confdefs.h.  */
25118 $ac_includes_default
25119 #ifndef offsetof
25120 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25121 #endif
25122 typedef struct { char x; long long int y; } ac__type_alignof_;
25123 int
25124 main ()
25125 {
25126 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25127 test_array [0] = 0
25128
25129   ;
25130   return 0;
25131 }
25132 _ACEOF
25133 rm -f conftest.$ac_objext
25134 if { (ac_try="$ac_compile"
25135 case "(($ac_try" in
25136   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25137   *) ac_try_echo=$ac_try;;
25138 esac
25139 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25140 $as_echo "$ac_try_echo") >&5
25141   (eval "$ac_compile") 2>conftest.er1
25142   ac_status=$?
25143   grep -v '^ *+' conftest.er1 >conftest.err
25144   rm -f conftest.er1
25145   cat conftest.err >&5
25146   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25147   (exit $ac_status); } && {
25148          test -z "$ac_c_werror_flag" ||
25149          test ! -s conftest.err
25150        } && test -s conftest.$ac_objext; then
25151   ac_hi=$ac_mid
25152 else
25153   $as_echo "$as_me: failed program was:" >&5
25154 sed 's/^/| /' conftest.$ac_ext >&5
25155
25156         ac_lo=`expr '(' $ac_mid ')' + 1`
25157 fi
25158
25159 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25160 done
25161 case $ac_lo in
25162 ?*) ac_cv_alignof_long_long_int=$ac_lo;;
25163 '') if test "$ac_cv_type_long_long_int" = yes; then
25164      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25165 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25166 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
25167 See \`config.log' for more details." >&5
25168 $as_echo "$as_me: error: cannot compute alignment of long long int
25169 See \`config.log' for more details." >&2;}
25170    { (exit 77); exit 77; }; }; }
25171    else
25172      ac_cv_alignof_long_long_int=0
25173    fi ;;
25174 esac
25175 else
25176   cat >conftest.$ac_ext <<_ACEOF
25177 /* confdefs.h.  */
25178 _ACEOF
25179 cat confdefs.h >>conftest.$ac_ext
25180 cat >>conftest.$ac_ext <<_ACEOF
25181 /* end confdefs.h.  */
25182 $ac_includes_default
25183 #ifndef offsetof
25184 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25185 #endif
25186 typedef struct { char x; long long int y; } ac__type_alignof_;
25187 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
25188 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
25189 #include <stdio.h>
25190 #include <stdlib.h>
25191 int
25192 main ()
25193 {
25194
25195   FILE *f = fopen ("conftest.val", "w");
25196   if (! f)
25197     return 1;
25198   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
25199     {
25200       long int i = longval ();
25201       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25202         return 1;
25203       fprintf (f, "%ld", i);
25204     }
25205   else
25206     {
25207       unsigned long int i = ulongval ();
25208       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25209         return 1;
25210       fprintf (f, "%lu", i);
25211     }
25212   /* Do not output a trailing newline, as this causes \r\n confusion
25213      on some platforms.  */
25214   return ferror (f) || fclose (f) != 0;
25215
25216   ;
25217   return 0;
25218 }
25219 _ACEOF
25220 rm -f conftest$ac_exeext
25221 if { (ac_try="$ac_link"
25222 case "(($ac_try" in
25223   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25224   *) ac_try_echo=$ac_try;;
25225 esac
25226 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25227 $as_echo "$ac_try_echo") >&5
25228   (eval "$ac_link") 2>&5
25229   ac_status=$?
25230   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25231   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25232   { (case "(($ac_try" in
25233   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25234   *) ac_try_echo=$ac_try;;
25235 esac
25236 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25237 $as_echo "$ac_try_echo") >&5
25238   (eval "$ac_try") 2>&5
25239   ac_status=$?
25240   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25241   (exit $ac_status); }; }; then
25242   ac_cv_alignof_long_long_int=`cat conftest.val`
25243 else
25244   $as_echo "$as_me: program exited with status $ac_status" >&5
25245 $as_echo "$as_me: failed program was:" >&5
25246 sed 's/^/| /' conftest.$ac_ext >&5
25247
25248 ( exit $ac_status )
25249 if test "$ac_cv_type_long_long_int" = yes; then
25250      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25251 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25252 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
25253 See \`config.log' for more details." >&5
25254 $as_echo "$as_me: error: cannot compute alignment of long long int
25255 See \`config.log' for more details." >&2;}
25256    { (exit 77); exit 77; }; }; }
25257    else
25258      ac_cv_alignof_long_long_int=0
25259    fi
25260 fi
25261 rm -rf conftest.dSYM
25262 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25263 fi
25264 rm -f conftest.val
25265 fi
25266 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
25267 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
25268
25269
25270
25271 cat >>confdefs.h <<_ACEOF
25272 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
25273 _ACEOF
25274
25275
25276 fi
25277 # The cast to long int works around a bug in the HP C Compiler,
25278 # see AC_CHECK_SIZEOF for more information.
25279 { $as_echo "$as_me:$LINENO: checking alignment of double" >&5
25280 $as_echo_n "checking alignment of double... " >&6; }
25281 if test "${ac_cv_alignof_double+set}" = set; then
25282   $as_echo_n "(cached) " >&6
25283 else
25284   if test "$cross_compiling" = yes; then
25285   # Depending upon the size, compute the lo and hi bounds.
25286 cat >conftest.$ac_ext <<_ACEOF
25287 /* confdefs.h.  */
25288 _ACEOF
25289 cat confdefs.h >>conftest.$ac_ext
25290 cat >>conftest.$ac_ext <<_ACEOF
25291 /* end confdefs.h.  */
25292 $ac_includes_default
25293 #ifndef offsetof
25294 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25295 #endif
25296 typedef struct { char x; double y; } ac__type_alignof_;
25297 int
25298 main ()
25299 {
25300 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25301 test_array [0] = 0
25302
25303   ;
25304   return 0;
25305 }
25306 _ACEOF
25307 rm -f conftest.$ac_objext
25308 if { (ac_try="$ac_compile"
25309 case "(($ac_try" in
25310   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25311   *) ac_try_echo=$ac_try;;
25312 esac
25313 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25314 $as_echo "$ac_try_echo") >&5
25315   (eval "$ac_compile") 2>conftest.er1
25316   ac_status=$?
25317   grep -v '^ *+' conftest.er1 >conftest.err
25318   rm -f conftest.er1
25319   cat conftest.err >&5
25320   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25321   (exit $ac_status); } && {
25322          test -z "$ac_c_werror_flag" ||
25323          test ! -s conftest.err
25324        } && test -s conftest.$ac_objext; then
25325   ac_lo=0 ac_mid=0
25326   while :; do
25327     cat >conftest.$ac_ext <<_ACEOF
25328 /* confdefs.h.  */
25329 _ACEOF
25330 cat confdefs.h >>conftest.$ac_ext
25331 cat >>conftest.$ac_ext <<_ACEOF
25332 /* end confdefs.h.  */
25333 $ac_includes_default
25334 #ifndef offsetof
25335 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25336 #endif
25337 typedef struct { char x; double y; } ac__type_alignof_;
25338 int
25339 main ()
25340 {
25341 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25342 test_array [0] = 0
25343
25344   ;
25345   return 0;
25346 }
25347 _ACEOF
25348 rm -f conftest.$ac_objext
25349 if { (ac_try="$ac_compile"
25350 case "(($ac_try" in
25351   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25352   *) ac_try_echo=$ac_try;;
25353 esac
25354 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25355 $as_echo "$ac_try_echo") >&5
25356   (eval "$ac_compile") 2>conftest.er1
25357   ac_status=$?
25358   grep -v '^ *+' conftest.er1 >conftest.err
25359   rm -f conftest.er1
25360   cat conftest.err >&5
25361   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25362   (exit $ac_status); } && {
25363          test -z "$ac_c_werror_flag" ||
25364          test ! -s conftest.err
25365        } && test -s conftest.$ac_objext; then
25366   ac_hi=$ac_mid; break
25367 else
25368   $as_echo "$as_me: failed program was:" >&5
25369 sed 's/^/| /' conftest.$ac_ext >&5
25370
25371         ac_lo=`expr $ac_mid + 1`
25372                         if test $ac_lo -le $ac_mid; then
25373                           ac_lo= ac_hi=
25374                           break
25375                         fi
25376                         ac_mid=`expr 2 '*' $ac_mid + 1`
25377 fi
25378
25379 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25380   done
25381 else
25382   $as_echo "$as_me: failed program was:" >&5
25383 sed 's/^/| /' conftest.$ac_ext >&5
25384
25385         cat >conftest.$ac_ext <<_ACEOF
25386 /* confdefs.h.  */
25387 _ACEOF
25388 cat confdefs.h >>conftest.$ac_ext
25389 cat >>conftest.$ac_ext <<_ACEOF
25390 /* end confdefs.h.  */
25391 $ac_includes_default
25392 #ifndef offsetof
25393 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25394 #endif
25395 typedef struct { char x; double y; } ac__type_alignof_;
25396 int
25397 main ()
25398 {
25399 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25400 test_array [0] = 0
25401
25402   ;
25403   return 0;
25404 }
25405 _ACEOF
25406 rm -f conftest.$ac_objext
25407 if { (ac_try="$ac_compile"
25408 case "(($ac_try" in
25409   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25410   *) ac_try_echo=$ac_try;;
25411 esac
25412 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25413 $as_echo "$ac_try_echo") >&5
25414   (eval "$ac_compile") 2>conftest.er1
25415   ac_status=$?
25416   grep -v '^ *+' conftest.er1 >conftest.err
25417   rm -f conftest.er1
25418   cat conftest.err >&5
25419   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25420   (exit $ac_status); } && {
25421          test -z "$ac_c_werror_flag" ||
25422          test ! -s conftest.err
25423        } && test -s conftest.$ac_objext; then
25424   ac_hi=-1 ac_mid=-1
25425   while :; do
25426     cat >conftest.$ac_ext <<_ACEOF
25427 /* confdefs.h.  */
25428 _ACEOF
25429 cat confdefs.h >>conftest.$ac_ext
25430 cat >>conftest.$ac_ext <<_ACEOF
25431 /* end confdefs.h.  */
25432 $ac_includes_default
25433 #ifndef offsetof
25434 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25435 #endif
25436 typedef struct { char x; double y; } ac__type_alignof_;
25437 int
25438 main ()
25439 {
25440 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25441 test_array [0] = 0
25442
25443   ;
25444   return 0;
25445 }
25446 _ACEOF
25447 rm -f conftest.$ac_objext
25448 if { (ac_try="$ac_compile"
25449 case "(($ac_try" in
25450   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25451   *) ac_try_echo=$ac_try;;
25452 esac
25453 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25454 $as_echo "$ac_try_echo") >&5
25455   (eval "$ac_compile") 2>conftest.er1
25456   ac_status=$?
25457   grep -v '^ *+' conftest.er1 >conftest.err
25458   rm -f conftest.er1
25459   cat conftest.err >&5
25460   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25461   (exit $ac_status); } && {
25462          test -z "$ac_c_werror_flag" ||
25463          test ! -s conftest.err
25464        } && test -s conftest.$ac_objext; then
25465   ac_lo=$ac_mid; break
25466 else
25467   $as_echo "$as_me: failed program was:" >&5
25468 sed 's/^/| /' conftest.$ac_ext >&5
25469
25470         ac_hi=`expr '(' $ac_mid ')' - 1`
25471                         if test $ac_mid -le $ac_hi; then
25472                           ac_lo= ac_hi=
25473                           break
25474                         fi
25475                         ac_mid=`expr 2 '*' $ac_mid`
25476 fi
25477
25478 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25479   done
25480 else
25481   $as_echo "$as_me: failed program was:" >&5
25482 sed 's/^/| /' conftest.$ac_ext >&5
25483
25484         ac_lo= ac_hi=
25485 fi
25486
25487 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25488 fi
25489
25490 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25491 # Binary search between lo and hi bounds.
25492 while test "x$ac_lo" != "x$ac_hi"; do
25493   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
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; double 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
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 fi
25540
25541 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25542 done
25543 case $ac_lo in
25544 ?*) ac_cv_alignof_double=$ac_lo;;
25545 '') if test "$ac_cv_type_double" = yes; then
25546      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25547 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25548 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
25549 See \`config.log' for more details." >&5
25550 $as_echo "$as_me: error: cannot compute alignment of double
25551 See \`config.log' for more details." >&2;}
25552    { (exit 77); exit 77; }; }; }
25553    else
25554      ac_cv_alignof_double=0
25555    fi ;;
25556 esac
25557 else
25558   cat >conftest.$ac_ext <<_ACEOF
25559 /* confdefs.h.  */
25560 _ACEOF
25561 cat confdefs.h >>conftest.$ac_ext
25562 cat >>conftest.$ac_ext <<_ACEOF
25563 /* end confdefs.h.  */
25564 $ac_includes_default
25565 #ifndef offsetof
25566 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25567 #endif
25568 typedef struct { char x; double y; } ac__type_alignof_;
25569 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
25570 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
25571 #include <stdio.h>
25572 #include <stdlib.h>
25573 int
25574 main ()
25575 {
25576
25577   FILE *f = fopen ("conftest.val", "w");
25578   if (! f)
25579     return 1;
25580   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
25581     {
25582       long int i = longval ();
25583       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25584         return 1;
25585       fprintf (f, "%ld", i);
25586     }
25587   else
25588     {
25589       unsigned long int i = ulongval ();
25590       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25591         return 1;
25592       fprintf (f, "%lu", i);
25593     }
25594   /* Do not output a trailing newline, as this causes \r\n confusion
25595      on some platforms.  */
25596   return ferror (f) || fclose (f) != 0;
25597
25598   ;
25599   return 0;
25600 }
25601 _ACEOF
25602 rm -f conftest$ac_exeext
25603 if { (ac_try="$ac_link"
25604 case "(($ac_try" in
25605   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25606   *) ac_try_echo=$ac_try;;
25607 esac
25608 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25609 $as_echo "$ac_try_echo") >&5
25610   (eval "$ac_link") 2>&5
25611   ac_status=$?
25612   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25613   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25614   { (case "(($ac_try" in
25615   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25616   *) ac_try_echo=$ac_try;;
25617 esac
25618 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25619 $as_echo "$ac_try_echo") >&5
25620   (eval "$ac_try") 2>&5
25621   ac_status=$?
25622   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25623   (exit $ac_status); }; }; then
25624   ac_cv_alignof_double=`cat conftest.val`
25625 else
25626   $as_echo "$as_me: program exited with status $ac_status" >&5
25627 $as_echo "$as_me: failed program was:" >&5
25628 sed 's/^/| /' conftest.$ac_ext >&5
25629
25630 ( exit $ac_status )
25631 if test "$ac_cv_type_double" = yes; then
25632      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25633 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25634 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
25635 See \`config.log' for more details." >&5
25636 $as_echo "$as_me: error: cannot compute alignment of double
25637 See \`config.log' for more details." >&2;}
25638    { (exit 77); exit 77; }; }; }
25639    else
25640      ac_cv_alignof_double=0
25641    fi
25642 fi
25643 rm -rf conftest.dSYM
25644 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25645 fi
25646 rm -f conftest.val
25647 fi
25648 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
25649 $as_echo "$ac_cv_alignof_double" >&6; }
25650
25651
25652
25653 cat >>confdefs.h <<_ACEOF
25654 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
25655 _ACEOF
25656
25657
25658
25659 # Compute maximum alignment of any basic type.
25660 # We assume long's alignment is at least as strong as char, short, or int;
25661 # but we must check long long (if it exists) and double.
25662
25663 MAX_ALIGNOF=$ac_cv_alignof_long
25664 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
25665   MAX_ALIGNOF=$ac_cv_alignof_double
25666 fi
25667 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
25668   MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
25669 fi
25670
25671 cat >>confdefs.h <<_ACEOF
25672 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
25673 _ACEOF
25674
25675
25676
25677 # Some platforms predefine the types int8, int16, etc.  Only check
25678 # a (hopefully) representative subset.
25679 { $as_echo "$as_me:$LINENO: checking for int8" >&5
25680 $as_echo_n "checking for int8... " >&6; }
25681 if test "${ac_cv_type_int8+set}" = set; then
25682   $as_echo_n "(cached) " >&6
25683 else
25684   ac_cv_type_int8=no
25685 cat >conftest.$ac_ext <<_ACEOF
25686 /* confdefs.h.  */
25687 _ACEOF
25688 cat confdefs.h >>conftest.$ac_ext
25689 cat >>conftest.$ac_ext <<_ACEOF
25690 /* end confdefs.h.  */
25691 #include <stdio.h>
25692 #ifdef HAVE_SUPPORTDEFS_H
25693 #include <SupportDefs.h>
25694 #endif
25695
25696 int
25697 main ()
25698 {
25699 if (sizeof (int8))
25700        return 0;
25701   ;
25702   return 0;
25703 }
25704 _ACEOF
25705 rm -f conftest.$ac_objext
25706 if { (ac_try="$ac_compile"
25707 case "(($ac_try" in
25708   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25709   *) ac_try_echo=$ac_try;;
25710 esac
25711 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25712 $as_echo "$ac_try_echo") >&5
25713   (eval "$ac_compile") 2>conftest.er1
25714   ac_status=$?
25715   grep -v '^ *+' conftest.er1 >conftest.err
25716   rm -f conftest.er1
25717   cat conftest.err >&5
25718   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25719   (exit $ac_status); } && {
25720          test -z "$ac_c_werror_flag" ||
25721          test ! -s conftest.err
25722        } && test -s conftest.$ac_objext; then
25723   cat >conftest.$ac_ext <<_ACEOF
25724 /* confdefs.h.  */
25725 _ACEOF
25726 cat confdefs.h >>conftest.$ac_ext
25727 cat >>conftest.$ac_ext <<_ACEOF
25728 /* end confdefs.h.  */
25729 #include <stdio.h>
25730 #ifdef HAVE_SUPPORTDEFS_H
25731 #include <SupportDefs.h>
25732 #endif
25733
25734 int
25735 main ()
25736 {
25737 if (sizeof ((int8)))
25738           return 0;
25739   ;
25740   return 0;
25741 }
25742 _ACEOF
25743 rm -f conftest.$ac_objext
25744 if { (ac_try="$ac_compile"
25745 case "(($ac_try" in
25746   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25747   *) ac_try_echo=$ac_try;;
25748 esac
25749 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25750 $as_echo "$ac_try_echo") >&5
25751   (eval "$ac_compile") 2>conftest.er1
25752   ac_status=$?
25753   grep -v '^ *+' conftest.er1 >conftest.err
25754   rm -f conftest.er1
25755   cat conftest.err >&5
25756   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25757   (exit $ac_status); } && {
25758          test -z "$ac_c_werror_flag" ||
25759          test ! -s conftest.err
25760        } && test -s conftest.$ac_objext; then
25761   :
25762 else
25763   $as_echo "$as_me: failed program was:" >&5
25764 sed 's/^/| /' conftest.$ac_ext >&5
25765
25766         ac_cv_type_int8=yes
25767 fi
25768
25769 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25770 else
25771   $as_echo "$as_me: failed program was:" >&5
25772 sed 's/^/| /' conftest.$ac_ext >&5
25773
25774
25775 fi
25776
25777 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25778 fi
25779 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
25780 $as_echo "$ac_cv_type_int8" >&6; }
25781 if test "x$ac_cv_type_int8" = x""yes; then
25782
25783 cat >>confdefs.h <<_ACEOF
25784 #define HAVE_INT8 1
25785 _ACEOF
25786
25787
25788 fi
25789 { $as_echo "$as_me:$LINENO: checking for uint8" >&5
25790 $as_echo_n "checking for uint8... " >&6; }
25791 if test "${ac_cv_type_uint8+set}" = set; then
25792   $as_echo_n "(cached) " >&6
25793 else
25794   ac_cv_type_uint8=no
25795 cat >conftest.$ac_ext <<_ACEOF
25796 /* confdefs.h.  */
25797 _ACEOF
25798 cat confdefs.h >>conftest.$ac_ext
25799 cat >>conftest.$ac_ext <<_ACEOF
25800 /* end confdefs.h.  */
25801 #include <stdio.h>
25802 #ifdef HAVE_SUPPORTDEFS_H
25803 #include <SupportDefs.h>
25804 #endif
25805
25806 int
25807 main ()
25808 {
25809 if (sizeof (uint8))
25810        return 0;
25811   ;
25812   return 0;
25813 }
25814 _ACEOF
25815 rm -f conftest.$ac_objext
25816 if { (ac_try="$ac_compile"
25817 case "(($ac_try" in
25818   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25819   *) ac_try_echo=$ac_try;;
25820 esac
25821 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25822 $as_echo "$ac_try_echo") >&5
25823   (eval "$ac_compile") 2>conftest.er1
25824   ac_status=$?
25825   grep -v '^ *+' conftest.er1 >conftest.err
25826   rm -f conftest.er1
25827   cat conftest.err >&5
25828   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25829   (exit $ac_status); } && {
25830          test -z "$ac_c_werror_flag" ||
25831          test ! -s conftest.err
25832        } && test -s conftest.$ac_objext; then
25833   cat >conftest.$ac_ext <<_ACEOF
25834 /* confdefs.h.  */
25835 _ACEOF
25836 cat confdefs.h >>conftest.$ac_ext
25837 cat >>conftest.$ac_ext <<_ACEOF
25838 /* end confdefs.h.  */
25839 #include <stdio.h>
25840 #ifdef HAVE_SUPPORTDEFS_H
25841 #include <SupportDefs.h>
25842 #endif
25843
25844 int
25845 main ()
25846 {
25847 if (sizeof ((uint8)))
25848           return 0;
25849   ;
25850   return 0;
25851 }
25852 _ACEOF
25853 rm -f conftest.$ac_objext
25854 if { (ac_try="$ac_compile"
25855 case "(($ac_try" in
25856   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25857   *) ac_try_echo=$ac_try;;
25858 esac
25859 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25860 $as_echo "$ac_try_echo") >&5
25861   (eval "$ac_compile") 2>conftest.er1
25862   ac_status=$?
25863   grep -v '^ *+' conftest.er1 >conftest.err
25864   rm -f conftest.er1
25865   cat conftest.err >&5
25866   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25867   (exit $ac_status); } && {
25868          test -z "$ac_c_werror_flag" ||
25869          test ! -s conftest.err
25870        } && test -s conftest.$ac_objext; then
25871   :
25872 else
25873   $as_echo "$as_me: failed program was:" >&5
25874 sed 's/^/| /' conftest.$ac_ext >&5
25875
25876         ac_cv_type_uint8=yes
25877 fi
25878
25879 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25880 else
25881   $as_echo "$as_me: failed program was:" >&5
25882 sed 's/^/| /' conftest.$ac_ext >&5
25883
25884
25885 fi
25886
25887 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25888 fi
25889 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
25890 $as_echo "$ac_cv_type_uint8" >&6; }
25891 if test "x$ac_cv_type_uint8" = x""yes; then
25892
25893 cat >>confdefs.h <<_ACEOF
25894 #define HAVE_UINT8 1
25895 _ACEOF
25896
25897
25898 fi
25899 { $as_echo "$as_me:$LINENO: checking for int64" >&5
25900 $as_echo_n "checking for int64... " >&6; }
25901 if test "${ac_cv_type_int64+set}" = set; then
25902   $as_echo_n "(cached) " >&6
25903 else
25904   ac_cv_type_int64=no
25905 cat >conftest.$ac_ext <<_ACEOF
25906 /* confdefs.h.  */
25907 _ACEOF
25908 cat confdefs.h >>conftest.$ac_ext
25909 cat >>conftest.$ac_ext <<_ACEOF
25910 /* end confdefs.h.  */
25911 #include <stdio.h>
25912 #ifdef HAVE_SUPPORTDEFS_H
25913 #include <SupportDefs.h>
25914 #endif
25915
25916 int
25917 main ()
25918 {
25919 if (sizeof (int64))
25920        return 0;
25921   ;
25922   return 0;
25923 }
25924 _ACEOF
25925 rm -f conftest.$ac_objext
25926 if { (ac_try="$ac_compile"
25927 case "(($ac_try" in
25928   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25929   *) ac_try_echo=$ac_try;;
25930 esac
25931 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25932 $as_echo "$ac_try_echo") >&5
25933   (eval "$ac_compile") 2>conftest.er1
25934   ac_status=$?
25935   grep -v '^ *+' conftest.er1 >conftest.err
25936   rm -f conftest.er1
25937   cat conftest.err >&5
25938   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25939   (exit $ac_status); } && {
25940          test -z "$ac_c_werror_flag" ||
25941          test ! -s conftest.err
25942        } && test -s conftest.$ac_objext; then
25943   cat >conftest.$ac_ext <<_ACEOF
25944 /* confdefs.h.  */
25945 _ACEOF
25946 cat confdefs.h >>conftest.$ac_ext
25947 cat >>conftest.$ac_ext <<_ACEOF
25948 /* end confdefs.h.  */
25949 #include <stdio.h>
25950 #ifdef HAVE_SUPPORTDEFS_H
25951 #include <SupportDefs.h>
25952 #endif
25953
25954 int
25955 main ()
25956 {
25957 if (sizeof ((int64)))
25958           return 0;
25959   ;
25960   return 0;
25961 }
25962 _ACEOF
25963 rm -f conftest.$ac_objext
25964 if { (ac_try="$ac_compile"
25965 case "(($ac_try" in
25966   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25967   *) ac_try_echo=$ac_try;;
25968 esac
25969 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25970 $as_echo "$ac_try_echo") >&5
25971   (eval "$ac_compile") 2>conftest.er1
25972   ac_status=$?
25973   grep -v '^ *+' conftest.er1 >conftest.err
25974   rm -f conftest.er1
25975   cat conftest.err >&5
25976   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25977   (exit $ac_status); } && {
25978          test -z "$ac_c_werror_flag" ||
25979          test ! -s conftest.err
25980        } && test -s conftest.$ac_objext; then
25981   :
25982 else
25983   $as_echo "$as_me: failed program was:" >&5
25984 sed 's/^/| /' conftest.$ac_ext >&5
25985
25986         ac_cv_type_int64=yes
25987 fi
25988
25989 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25990 else
25991   $as_echo "$as_me: failed program was:" >&5
25992 sed 's/^/| /' conftest.$ac_ext >&5
25993
25994
25995 fi
25996
25997 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25998 fi
25999 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
26000 $as_echo "$ac_cv_type_int64" >&6; }
26001 if test "x$ac_cv_type_int64" = x""yes; then
26002
26003 cat >>confdefs.h <<_ACEOF
26004 #define HAVE_INT64 1
26005 _ACEOF
26006
26007
26008 fi
26009 { $as_echo "$as_me:$LINENO: checking for uint64" >&5
26010 $as_echo_n "checking for uint64... " >&6; }
26011 if test "${ac_cv_type_uint64+set}" = set; then
26012   $as_echo_n "(cached) " >&6
26013 else
26014   ac_cv_type_uint64=no
26015 cat >conftest.$ac_ext <<_ACEOF
26016 /* confdefs.h.  */
26017 _ACEOF
26018 cat confdefs.h >>conftest.$ac_ext
26019 cat >>conftest.$ac_ext <<_ACEOF
26020 /* end confdefs.h.  */
26021 #include <stdio.h>
26022 #ifdef HAVE_SUPPORTDEFS_H
26023 #include <SupportDefs.h>
26024 #endif
26025
26026 int
26027 main ()
26028 {
26029 if (sizeof (uint64))
26030        return 0;
26031   ;
26032   return 0;
26033 }
26034 _ACEOF
26035 rm -f conftest.$ac_objext
26036 if { (ac_try="$ac_compile"
26037 case "(($ac_try" in
26038   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26039   *) ac_try_echo=$ac_try;;
26040 esac
26041 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26042 $as_echo "$ac_try_echo") >&5
26043   (eval "$ac_compile") 2>conftest.er1
26044   ac_status=$?
26045   grep -v '^ *+' conftest.er1 >conftest.err
26046   rm -f conftest.er1
26047   cat conftest.err >&5
26048   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26049   (exit $ac_status); } && {
26050          test -z "$ac_c_werror_flag" ||
26051          test ! -s conftest.err
26052        } && test -s conftest.$ac_objext; then
26053   cat >conftest.$ac_ext <<_ACEOF
26054 /* confdefs.h.  */
26055 _ACEOF
26056 cat confdefs.h >>conftest.$ac_ext
26057 cat >>conftest.$ac_ext <<_ACEOF
26058 /* end confdefs.h.  */
26059 #include <stdio.h>
26060 #ifdef HAVE_SUPPORTDEFS_H
26061 #include <SupportDefs.h>
26062 #endif
26063
26064 int
26065 main ()
26066 {
26067 if (sizeof ((uint64)))
26068           return 0;
26069   ;
26070   return 0;
26071 }
26072 _ACEOF
26073 rm -f conftest.$ac_objext
26074 if { (ac_try="$ac_compile"
26075 case "(($ac_try" in
26076   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26077   *) ac_try_echo=$ac_try;;
26078 esac
26079 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26080 $as_echo "$ac_try_echo") >&5
26081   (eval "$ac_compile") 2>conftest.er1
26082   ac_status=$?
26083   grep -v '^ *+' conftest.er1 >conftest.err
26084   rm -f conftest.er1
26085   cat conftest.err >&5
26086   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26087   (exit $ac_status); } && {
26088          test -z "$ac_c_werror_flag" ||
26089          test ! -s conftest.err
26090        } && test -s conftest.$ac_objext; then
26091   :
26092 else
26093   $as_echo "$as_me: failed program was:" >&5
26094 sed 's/^/| /' conftest.$ac_ext >&5
26095
26096         ac_cv_type_uint64=yes
26097 fi
26098
26099 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26100 else
26101   $as_echo "$as_me: failed program was:" >&5
26102 sed 's/^/| /' conftest.$ac_ext >&5
26103
26104
26105 fi
26106
26107 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26108 fi
26109 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
26110 $as_echo "$ac_cv_type_uint64" >&6; }
26111 if test "x$ac_cv_type_uint64" = x""yes; then
26112
26113 cat >>confdefs.h <<_ACEOF
26114 #define HAVE_UINT64 1
26115 _ACEOF
26116
26117
26118 fi
26119
26120
26121 # We also check for sig_atomic_t, which *should* be defined per ANSI
26122 # C, but is missing on some old platforms.
26123 { $as_echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
26124 $as_echo_n "checking for sig_atomic_t... " >&6; }
26125 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
26126   $as_echo_n "(cached) " >&6
26127 else
26128   ac_cv_type_sig_atomic_t=no
26129 cat >conftest.$ac_ext <<_ACEOF
26130 /* confdefs.h.  */
26131 _ACEOF
26132 cat confdefs.h >>conftest.$ac_ext
26133 cat >>conftest.$ac_ext <<_ACEOF
26134 /* end confdefs.h.  */
26135 #include <signal.h>
26136
26137 int
26138 main ()
26139 {
26140 if (sizeof (sig_atomic_t))
26141        return 0;
26142   ;
26143   return 0;
26144 }
26145 _ACEOF
26146 rm -f conftest.$ac_objext
26147 if { (ac_try="$ac_compile"
26148 case "(($ac_try" in
26149   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26150   *) ac_try_echo=$ac_try;;
26151 esac
26152 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26153 $as_echo "$ac_try_echo") >&5
26154   (eval "$ac_compile") 2>conftest.er1
26155   ac_status=$?
26156   grep -v '^ *+' conftest.er1 >conftest.err
26157   rm -f conftest.er1
26158   cat conftest.err >&5
26159   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26160   (exit $ac_status); } && {
26161          test -z "$ac_c_werror_flag" ||
26162          test ! -s conftest.err
26163        } && test -s conftest.$ac_objext; then
26164   cat >conftest.$ac_ext <<_ACEOF
26165 /* confdefs.h.  */
26166 _ACEOF
26167 cat confdefs.h >>conftest.$ac_ext
26168 cat >>conftest.$ac_ext <<_ACEOF
26169 /* end confdefs.h.  */
26170 #include <signal.h>
26171
26172 int
26173 main ()
26174 {
26175 if (sizeof ((sig_atomic_t)))
26176           return 0;
26177   ;
26178   return 0;
26179 }
26180 _ACEOF
26181 rm -f conftest.$ac_objext
26182 if { (ac_try="$ac_compile"
26183 case "(($ac_try" in
26184   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26185   *) ac_try_echo=$ac_try;;
26186 esac
26187 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26188 $as_echo "$ac_try_echo") >&5
26189   (eval "$ac_compile") 2>conftest.er1
26190   ac_status=$?
26191   grep -v '^ *+' conftest.er1 >conftest.err
26192   rm -f conftest.er1
26193   cat conftest.err >&5
26194   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26195   (exit $ac_status); } && {
26196          test -z "$ac_c_werror_flag" ||
26197          test ! -s conftest.err
26198        } && test -s conftest.$ac_objext; then
26199   :
26200 else
26201   $as_echo "$as_me: failed program was:" >&5
26202 sed 's/^/| /' conftest.$ac_ext >&5
26203
26204         ac_cv_type_sig_atomic_t=yes
26205 fi
26206
26207 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26208 else
26209   $as_echo "$as_me: failed program was:" >&5
26210 sed 's/^/| /' conftest.$ac_ext >&5
26211
26212
26213 fi
26214
26215 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26216 fi
26217 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
26218 $as_echo "$ac_cv_type_sig_atomic_t" >&6; }
26219 if test "x$ac_cv_type_sig_atomic_t" = x""yes; then
26220
26221 cat >>confdefs.h <<_ACEOF
26222 #define HAVE_SIG_ATOMIC_T 1
26223 _ACEOF
26224
26225
26226 fi
26227
26228
26229
26230 # If the user did not disable integer datetimes, check that
26231 # there is a working 64-bit integral type to use.
26232 if test x"$USE_INTEGER_DATETIMES" = x"yes" &&
26233    test x"$HAVE_LONG_INT_64" = x"no" &&
26234    test x"$HAVE_LONG_LONG_INT_64" = x"no" &&
26235    test x"$HAVE_INT64" = x"no" ; then
26236   { { $as_echo "$as_me:$LINENO: error:
26237 Integer-based datetime support requires a 64-bit integer type,
26238 but no such type could be found. The --disable-integer-datetimes
26239 configure option can be used to disable integer-based storage
26240 of datetime values." >&5
26241 $as_echo "$as_me: error:
26242 Integer-based datetime support requires a 64-bit integer type,
26243 but no such type could be found. The --disable-integer-datetimes
26244 configure option can be used to disable integer-based storage
26245 of datetime values." >&2;}
26246    { (exit 1); exit 1; }; }
26247 fi
26248
26249
26250 if test "$PORTNAME" != "win32"
26251 then
26252 { $as_echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
26253 $as_echo_n "checking for POSIX signal interface... " >&6; }
26254 if test "${pgac_cv_func_posix_signals+set}" = set; then
26255   $as_echo_n "(cached) " >&6
26256 else
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 #include <signal.h>
26264
26265 int
26266 main ()
26267 {
26268 struct sigaction act, oact;
26269 sigemptyset(&act.sa_mask);
26270 act.sa_flags = SA_RESTART;
26271 sigaction(0, &act, &oact);
26272   ;
26273   return 0;
26274 }
26275 _ACEOF
26276 rm -f conftest.$ac_objext conftest$ac_exeext
26277 if { (ac_try="$ac_link"
26278 case "(($ac_try" in
26279   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26280   *) ac_try_echo=$ac_try;;
26281 esac
26282 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26283 $as_echo "$ac_try_echo") >&5
26284   (eval "$ac_link") 2>conftest.er1
26285   ac_status=$?
26286   grep -v '^ *+' conftest.er1 >conftest.err
26287   rm -f conftest.er1
26288   cat conftest.err >&5
26289   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26290   (exit $ac_status); } && {
26291          test -z "$ac_c_werror_flag" ||
26292          test ! -s conftest.err
26293        } && test -s conftest$ac_exeext && {
26294          test "$cross_compiling" = yes ||
26295          $as_test_x conftest$ac_exeext
26296        }; then
26297   pgac_cv_func_posix_signals=yes
26298 else
26299   $as_echo "$as_me: failed program was:" >&5
26300 sed 's/^/| /' conftest.$ac_ext >&5
26301
26302         pgac_cv_func_posix_signals=no
26303 fi
26304
26305 rm -rf conftest.dSYM
26306 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
26307       conftest$ac_exeext conftest.$ac_ext
26308 fi
26309 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
26310 $as_echo "$pgac_cv_func_posix_signals" >&6; }
26311 if test x"$pgac_cv_func_posix_signals" = xyes ; then
26312
26313 cat >>confdefs.h <<\_ACEOF
26314 #define HAVE_POSIX_SIGNALS /**/
26315 _ACEOF
26316
26317 fi
26318 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
26319
26320 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
26321   { { $as_echo "$as_me:$LINENO: error:
26322 Thread-safety requires POSIX signals, which are not supported by this
26323 operating system;  use --disable-thread-safety to disable thread safety." >&5
26324 $as_echo "$as_me: error:
26325 Thread-safety requires POSIX signals, which are not supported by this
26326 operating system;  use --disable-thread-safety to disable thread safety." >&2;}
26327    { (exit 1); exit 1; }; }
26328 fi
26329 fi
26330
26331 if test $ac_cv_func_fseeko = yes; then
26332 # Check whether --enable-largefile was given.
26333 if test "${enable_largefile+set}" = set; then
26334   enableval=$enable_largefile;
26335 fi
26336
26337 if test "$enable_largefile" != no; then
26338
26339   { $as_echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
26340 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
26341 if test "${ac_cv_sys_largefile_CC+set}" = set; then
26342   $as_echo_n "(cached) " >&6
26343 else
26344   ac_cv_sys_largefile_CC=no
26345      if test "$GCC" != yes; then
26346        ac_save_CC=$CC
26347        while :; do
26348          # IRIX 6.2 and later do not support large files by default,
26349          # so use the C compiler's -n32 option if that helps.
26350          cat >conftest.$ac_ext <<_ACEOF
26351 /* confdefs.h.  */
26352 _ACEOF
26353 cat confdefs.h >>conftest.$ac_ext
26354 cat >>conftest.$ac_ext <<_ACEOF
26355 /* end confdefs.h.  */
26356 #include <sys/types.h>
26357  /* Check that off_t can represent 2**63 - 1 correctly.
26358     We can't simply define LARGE_OFF_T to be 9223372036854775807,
26359     since some C++ compilers masquerading as C compilers
26360     incorrectly reject 9223372036854775807.  */
26361 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
26362   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
26363                        && LARGE_OFF_T % 2147483647 == 1)
26364                       ? 1 : -1];
26365 int
26366 main ()
26367 {
26368
26369   ;
26370   return 0;
26371 }
26372 _ACEOF
26373          rm -f conftest.$ac_objext
26374 if { (ac_try="$ac_compile"
26375 case "(($ac_try" in
26376   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26377   *) ac_try_echo=$ac_try;;
26378 esac
26379 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26380 $as_echo "$ac_try_echo") >&5
26381   (eval "$ac_compile") 2>conftest.er1
26382   ac_status=$?
26383   grep -v '^ *+' conftest.er1 >conftest.err
26384   rm -f conftest.er1
26385   cat conftest.err >&5
26386   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26387   (exit $ac_status); } && {
26388          test -z "$ac_c_werror_flag" ||
26389          test ! -s conftest.err
26390        } && test -s conftest.$ac_objext; then
26391   break
26392 else
26393   $as_echo "$as_me: failed program was:" >&5
26394 sed 's/^/| /' conftest.$ac_ext >&5
26395
26396
26397 fi
26398
26399 rm -f core conftest.err conftest.$ac_objext
26400          CC="$CC -n32"
26401          rm -f conftest.$ac_objext
26402 if { (ac_try="$ac_compile"
26403 case "(($ac_try" in
26404   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26405   *) ac_try_echo=$ac_try;;
26406 esac
26407 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26408 $as_echo "$ac_try_echo") >&5
26409   (eval "$ac_compile") 2>conftest.er1
26410   ac_status=$?
26411   grep -v '^ *+' conftest.er1 >conftest.err
26412   rm -f conftest.er1
26413   cat conftest.err >&5
26414   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26415   (exit $ac_status); } && {
26416          test -z "$ac_c_werror_flag" ||
26417          test ! -s conftest.err
26418        } && test -s conftest.$ac_objext; then
26419   ac_cv_sys_largefile_CC=' -n32'; break
26420 else
26421   $as_echo "$as_me: failed program was:" >&5
26422 sed 's/^/| /' conftest.$ac_ext >&5
26423
26424
26425 fi
26426
26427 rm -f core conftest.err conftest.$ac_objext
26428          break
26429        done
26430        CC=$ac_save_CC
26431        rm -f conftest.$ac_ext
26432     fi
26433 fi
26434 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
26435 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
26436   if test "$ac_cv_sys_largefile_CC" != no; then
26437     CC=$CC$ac_cv_sys_largefile_CC
26438   fi
26439
26440   { $as_echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
26441 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
26442 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
26443   $as_echo_n "(cached) " >&6
26444 else
26445   while :; do
26446   cat >conftest.$ac_ext <<_ACEOF
26447 /* confdefs.h.  */
26448 _ACEOF
26449 cat confdefs.h >>conftest.$ac_ext
26450 cat >>conftest.$ac_ext <<_ACEOF
26451 /* end confdefs.h.  */
26452 #include <sys/types.h>
26453  /* Check that off_t can represent 2**63 - 1 correctly.
26454     We can't simply define LARGE_OFF_T to be 9223372036854775807,
26455     since some C++ compilers masquerading as C compilers
26456     incorrectly reject 9223372036854775807.  */
26457 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
26458   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
26459                        && LARGE_OFF_T % 2147483647 == 1)
26460                       ? 1 : -1];
26461 int
26462 main ()
26463 {
26464
26465   ;
26466   return 0;
26467 }
26468 _ACEOF
26469 rm -f conftest.$ac_objext
26470 if { (ac_try="$ac_compile"
26471 case "(($ac_try" in
26472   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26473   *) ac_try_echo=$ac_try;;
26474 esac
26475 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26476 $as_echo "$ac_try_echo") >&5
26477   (eval "$ac_compile") 2>conftest.er1
26478   ac_status=$?
26479   grep -v '^ *+' conftest.er1 >conftest.err
26480   rm -f conftest.er1
26481   cat conftest.err >&5
26482   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26483   (exit $ac_status); } && {
26484          test -z "$ac_c_werror_flag" ||
26485          test ! -s conftest.err
26486        } && test -s conftest.$ac_objext; then
26487   ac_cv_sys_file_offset_bits=no; break
26488 else
26489   $as_echo "$as_me: failed program was:" >&5
26490 sed 's/^/| /' conftest.$ac_ext >&5
26491
26492
26493 fi
26494
26495 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26496   cat >conftest.$ac_ext <<_ACEOF
26497 /* confdefs.h.  */
26498 _ACEOF
26499 cat confdefs.h >>conftest.$ac_ext
26500 cat >>conftest.$ac_ext <<_ACEOF
26501 /* end confdefs.h.  */
26502 #define _FILE_OFFSET_BITS 64
26503 #include <sys/types.h>
26504  /* Check that off_t can represent 2**63 - 1 correctly.
26505     We can't simply define LARGE_OFF_T to be 9223372036854775807,
26506     since some C++ compilers masquerading as C compilers
26507     incorrectly reject 9223372036854775807.  */
26508 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
26509   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
26510                        && LARGE_OFF_T % 2147483647 == 1)
26511                       ? 1 : -1];
26512 int
26513 main ()
26514 {
26515
26516   ;
26517   return 0;
26518 }
26519 _ACEOF
26520 rm -f conftest.$ac_objext
26521 if { (ac_try="$ac_compile"
26522 case "(($ac_try" in
26523   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26524   *) ac_try_echo=$ac_try;;
26525 esac
26526 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26527 $as_echo "$ac_try_echo") >&5
26528   (eval "$ac_compile") 2>conftest.er1
26529   ac_status=$?
26530   grep -v '^ *+' conftest.er1 >conftest.err
26531   rm -f conftest.er1
26532   cat conftest.err >&5
26533   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26534   (exit $ac_status); } && {
26535          test -z "$ac_c_werror_flag" ||
26536          test ! -s conftest.err
26537        } && test -s conftest.$ac_objext; then
26538   ac_cv_sys_file_offset_bits=64; break
26539 else
26540   $as_echo "$as_me: failed program was:" >&5
26541 sed 's/^/| /' conftest.$ac_ext >&5
26542
26543
26544 fi
26545
26546 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26547   ac_cv_sys_file_offset_bits=unknown
26548   break
26549 done
26550 fi
26551 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
26552 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
26553 case $ac_cv_sys_file_offset_bits in #(
26554   no | unknown) ;;
26555   *)
26556 cat >>confdefs.h <<_ACEOF
26557 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
26558 _ACEOF
26559 ;;
26560 esac
26561 rm -rf conftest*
26562   if test $ac_cv_sys_file_offset_bits = unknown; then
26563     { $as_echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
26564 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
26565 if test "${ac_cv_sys_large_files+set}" = set; then
26566   $as_echo_n "(cached) " >&6
26567 else
26568   while :; do
26569   cat >conftest.$ac_ext <<_ACEOF
26570 /* confdefs.h.  */
26571 _ACEOF
26572 cat confdefs.h >>conftest.$ac_ext
26573 cat >>conftest.$ac_ext <<_ACEOF
26574 /* end confdefs.h.  */
26575 #include <sys/types.h>
26576  /* Check that off_t can represent 2**63 - 1 correctly.
26577     We can't simply define LARGE_OFF_T to be 9223372036854775807,
26578     since some C++ compilers masquerading as C compilers
26579     incorrectly reject 9223372036854775807.  */
26580 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
26581   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
26582                        && LARGE_OFF_T % 2147483647 == 1)
26583                       ? 1 : -1];
26584 int
26585 main ()
26586 {
26587
26588   ;
26589   return 0;
26590 }
26591 _ACEOF
26592 rm -f conftest.$ac_objext
26593 if { (ac_try="$ac_compile"
26594 case "(($ac_try" in
26595   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26596   *) ac_try_echo=$ac_try;;
26597 esac
26598 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26599 $as_echo "$ac_try_echo") >&5
26600   (eval "$ac_compile") 2>conftest.er1
26601   ac_status=$?
26602   grep -v '^ *+' conftest.er1 >conftest.err
26603   rm -f conftest.er1
26604   cat conftest.err >&5
26605   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26606   (exit $ac_status); } && {
26607          test -z "$ac_c_werror_flag" ||
26608          test ! -s conftest.err
26609        } && test -s conftest.$ac_objext; then
26610   ac_cv_sys_large_files=no; break
26611 else
26612   $as_echo "$as_me: failed program was:" >&5
26613 sed 's/^/| /' conftest.$ac_ext >&5
26614
26615
26616 fi
26617
26618 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26619   cat >conftest.$ac_ext <<_ACEOF
26620 /* confdefs.h.  */
26621 _ACEOF
26622 cat confdefs.h >>conftest.$ac_ext
26623 cat >>conftest.$ac_ext <<_ACEOF
26624 /* end confdefs.h.  */
26625 #define _LARGE_FILES 1
26626 #include <sys/types.h>
26627  /* Check that off_t can represent 2**63 - 1 correctly.
26628     We can't simply define LARGE_OFF_T to be 9223372036854775807,
26629     since some C++ compilers masquerading as C compilers
26630     incorrectly reject 9223372036854775807.  */
26631 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
26632   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
26633                        && LARGE_OFF_T % 2147483647 == 1)
26634                       ? 1 : -1];
26635 int
26636 main ()
26637 {
26638
26639   ;
26640   return 0;
26641 }
26642 _ACEOF
26643 rm -f conftest.$ac_objext
26644 if { (ac_try="$ac_compile"
26645 case "(($ac_try" in
26646   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26647   *) ac_try_echo=$ac_try;;
26648 esac
26649 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26650 $as_echo "$ac_try_echo") >&5
26651   (eval "$ac_compile") 2>conftest.er1
26652   ac_status=$?
26653   grep -v '^ *+' conftest.er1 >conftest.err
26654   rm -f conftest.er1
26655   cat conftest.err >&5
26656   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26657   (exit $ac_status); } && {
26658          test -z "$ac_c_werror_flag" ||
26659          test ! -s conftest.err
26660        } && test -s conftest.$ac_objext; then
26661   ac_cv_sys_large_files=1; break
26662 else
26663   $as_echo "$as_me: failed program was:" >&5
26664 sed 's/^/| /' conftest.$ac_ext >&5
26665
26666
26667 fi
26668
26669 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26670   ac_cv_sys_large_files=unknown
26671   break
26672 done
26673 fi
26674 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
26675 $as_echo "$ac_cv_sys_large_files" >&6; }
26676 case $ac_cv_sys_large_files in #(
26677   no | unknown) ;;
26678   *)
26679 cat >>confdefs.h <<_ACEOF
26680 #define _LARGE_FILES $ac_cv_sys_large_files
26681 _ACEOF
26682 ;;
26683 esac
26684 rm -rf conftest*
26685   fi
26686 fi
26687
26688 fi
26689
26690 # Check for largefile support (must be after AC_SYS_LARGEFILE)
26691 # The cast to long int works around a bug in the HP C Compiler
26692 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
26693 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
26694 # This bug is HP SR number 8606223364.
26695 { $as_echo "$as_me:$LINENO: checking size of off_t" >&5
26696 $as_echo_n "checking size of off_t... " >&6; }
26697 if test "${ac_cv_sizeof_off_t+set}" = set; then
26698   $as_echo_n "(cached) " >&6
26699 else
26700   if test "$cross_compiling" = yes; then
26701   # Depending upon the size, compute the lo and hi bounds.
26702 cat >conftest.$ac_ext <<_ACEOF
26703 /* confdefs.h.  */
26704 _ACEOF
26705 cat confdefs.h >>conftest.$ac_ext
26706 cat >>conftest.$ac_ext <<_ACEOF
26707 /* end confdefs.h.  */
26708 $ac_includes_default
26709 int
26710 main ()
26711 {
26712 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= 0)];
26713 test_array [0] = 0
26714
26715   ;
26716   return 0;
26717 }
26718 _ACEOF
26719 rm -f conftest.$ac_objext
26720 if { (ac_try="$ac_compile"
26721 case "(($ac_try" in
26722   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26723   *) ac_try_echo=$ac_try;;
26724 esac
26725 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26726 $as_echo "$ac_try_echo") >&5
26727   (eval "$ac_compile") 2>conftest.er1
26728   ac_status=$?
26729   grep -v '^ *+' conftest.er1 >conftest.err
26730   rm -f conftest.er1
26731   cat conftest.err >&5
26732   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26733   (exit $ac_status); } && {
26734          test -z "$ac_c_werror_flag" ||
26735          test ! -s conftest.err
26736        } && test -s conftest.$ac_objext; then
26737   ac_lo=0 ac_mid=0
26738   while :; do
26739     cat >conftest.$ac_ext <<_ACEOF
26740 /* confdefs.h.  */
26741 _ACEOF
26742 cat confdefs.h >>conftest.$ac_ext
26743 cat >>conftest.$ac_ext <<_ACEOF
26744 /* end confdefs.h.  */
26745 $ac_includes_default
26746 int
26747 main ()
26748 {
26749 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
26750 test_array [0] = 0
26751
26752   ;
26753   return 0;
26754 }
26755 _ACEOF
26756 rm -f conftest.$ac_objext
26757 if { (ac_try="$ac_compile"
26758 case "(($ac_try" in
26759   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26760   *) ac_try_echo=$ac_try;;
26761 esac
26762 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26763 $as_echo "$ac_try_echo") >&5
26764   (eval "$ac_compile") 2>conftest.er1
26765   ac_status=$?
26766   grep -v '^ *+' conftest.er1 >conftest.err
26767   rm -f conftest.er1
26768   cat conftest.err >&5
26769   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26770   (exit $ac_status); } && {
26771          test -z "$ac_c_werror_flag" ||
26772          test ! -s conftest.err
26773        } && test -s conftest.$ac_objext; then
26774   ac_hi=$ac_mid; break
26775 else
26776   $as_echo "$as_me: failed program was:" >&5
26777 sed 's/^/| /' conftest.$ac_ext >&5
26778
26779         ac_lo=`expr $ac_mid + 1`
26780                         if test $ac_lo -le $ac_mid; then
26781                           ac_lo= ac_hi=
26782                           break
26783                         fi
26784                         ac_mid=`expr 2 '*' $ac_mid + 1`
26785 fi
26786
26787 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26788   done
26789 else
26790   $as_echo "$as_me: failed program was:" >&5
26791 sed 's/^/| /' conftest.$ac_ext >&5
26792
26793         cat >conftest.$ac_ext <<_ACEOF
26794 /* confdefs.h.  */
26795 _ACEOF
26796 cat confdefs.h >>conftest.$ac_ext
26797 cat >>conftest.$ac_ext <<_ACEOF
26798 /* end confdefs.h.  */
26799 $ac_includes_default
26800 int
26801 main ()
26802 {
26803 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) < 0)];
26804 test_array [0] = 0
26805
26806   ;
26807   return 0;
26808 }
26809 _ACEOF
26810 rm -f conftest.$ac_objext
26811 if { (ac_try="$ac_compile"
26812 case "(($ac_try" in
26813   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26814   *) ac_try_echo=$ac_try;;
26815 esac
26816 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26817 $as_echo "$ac_try_echo") >&5
26818   (eval "$ac_compile") 2>conftest.er1
26819   ac_status=$?
26820   grep -v '^ *+' conftest.er1 >conftest.err
26821   rm -f conftest.er1
26822   cat conftest.err >&5
26823   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26824   (exit $ac_status); } && {
26825          test -z "$ac_c_werror_flag" ||
26826          test ! -s conftest.err
26827        } && test -s conftest.$ac_objext; then
26828   ac_hi=-1 ac_mid=-1
26829   while :; do
26830     cat >conftest.$ac_ext <<_ACEOF
26831 /* confdefs.h.  */
26832 _ACEOF
26833 cat confdefs.h >>conftest.$ac_ext
26834 cat >>conftest.$ac_ext <<_ACEOF
26835 /* end confdefs.h.  */
26836 $ac_includes_default
26837 int
26838 main ()
26839 {
26840 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= $ac_mid)];
26841 test_array [0] = 0
26842
26843   ;
26844   return 0;
26845 }
26846 _ACEOF
26847 rm -f conftest.$ac_objext
26848 if { (ac_try="$ac_compile"
26849 case "(($ac_try" in
26850   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26851   *) ac_try_echo=$ac_try;;
26852 esac
26853 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26854 $as_echo "$ac_try_echo") >&5
26855   (eval "$ac_compile") 2>conftest.er1
26856   ac_status=$?
26857   grep -v '^ *+' conftest.er1 >conftest.err
26858   rm -f conftest.er1
26859   cat conftest.err >&5
26860   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26861   (exit $ac_status); } && {
26862          test -z "$ac_c_werror_flag" ||
26863          test ! -s conftest.err
26864        } && test -s conftest.$ac_objext; then
26865   ac_lo=$ac_mid; break
26866 else
26867   $as_echo "$as_me: failed program was:" >&5
26868 sed 's/^/| /' conftest.$ac_ext >&5
26869
26870         ac_hi=`expr '(' $ac_mid ')' - 1`
26871                         if test $ac_mid -le $ac_hi; then
26872                           ac_lo= ac_hi=
26873                           break
26874                         fi
26875                         ac_mid=`expr 2 '*' $ac_mid`
26876 fi
26877
26878 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26879   done
26880 else
26881   $as_echo "$as_me: failed program was:" >&5
26882 sed 's/^/| /' conftest.$ac_ext >&5
26883
26884         ac_lo= ac_hi=
26885 fi
26886
26887 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26888 fi
26889
26890 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26891 # Binary search between lo and hi bounds.
26892 while test "x$ac_lo" != "x$ac_hi"; do
26893   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26894   cat >conftest.$ac_ext <<_ACEOF
26895 /* confdefs.h.  */
26896 _ACEOF
26897 cat confdefs.h >>conftest.$ac_ext
26898 cat >>conftest.$ac_ext <<_ACEOF
26899 /* end confdefs.h.  */
26900 $ac_includes_default
26901 int
26902 main ()
26903 {
26904 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
26905 test_array [0] = 0
26906
26907   ;
26908   return 0;
26909 }
26910 _ACEOF
26911 rm -f conftest.$ac_objext
26912 if { (ac_try="$ac_compile"
26913 case "(($ac_try" in
26914   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26915   *) ac_try_echo=$ac_try;;
26916 esac
26917 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26918 $as_echo "$ac_try_echo") >&5
26919   (eval "$ac_compile") 2>conftest.er1
26920   ac_status=$?
26921   grep -v '^ *+' conftest.er1 >conftest.err
26922   rm -f conftest.er1
26923   cat conftest.err >&5
26924   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26925   (exit $ac_status); } && {
26926          test -z "$ac_c_werror_flag" ||
26927          test ! -s conftest.err
26928        } && test -s conftest.$ac_objext; then
26929   ac_hi=$ac_mid
26930 else
26931   $as_echo "$as_me: failed program was:" >&5
26932 sed 's/^/| /' conftest.$ac_ext >&5
26933
26934         ac_lo=`expr '(' $ac_mid ')' + 1`
26935 fi
26936
26937 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26938 done
26939 case $ac_lo in
26940 ?*) ac_cv_sizeof_off_t=$ac_lo;;
26941 '') if test "$ac_cv_type_off_t" = yes; then
26942      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26943 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26944 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
26945 See \`config.log' for more details." >&5
26946 $as_echo "$as_me: error: cannot compute sizeof (off_t)
26947 See \`config.log' for more details." >&2;}
26948    { (exit 77); exit 77; }; }; }
26949    else
26950      ac_cv_sizeof_off_t=0
26951    fi ;;
26952 esac
26953 else
26954   cat >conftest.$ac_ext <<_ACEOF
26955 /* confdefs.h.  */
26956 _ACEOF
26957 cat confdefs.h >>conftest.$ac_ext
26958 cat >>conftest.$ac_ext <<_ACEOF
26959 /* end confdefs.h.  */
26960 $ac_includes_default
26961 static long int longval () { return (long int) (sizeof (off_t)); }
26962 static unsigned long int ulongval () { return (long int) (sizeof (off_t)); }
26963 #include <stdio.h>
26964 #include <stdlib.h>
26965 int
26966 main ()
26967 {
26968
26969   FILE *f = fopen ("conftest.val", "w");
26970   if (! f)
26971     return 1;
26972   if (((long int) (sizeof (off_t))) < 0)
26973     {
26974       long int i = longval ();
26975       if (i != ((long int) (sizeof (off_t))))
26976         return 1;
26977       fprintf (f, "%ld", i);
26978     }
26979   else
26980     {
26981       unsigned long int i = ulongval ();
26982       if (i != ((long int) (sizeof (off_t))))
26983         return 1;
26984       fprintf (f, "%lu", i);
26985     }
26986   /* Do not output a trailing newline, as this causes \r\n confusion
26987      on some platforms.  */
26988   return ferror (f) || fclose (f) != 0;
26989
26990   ;
26991   return 0;
26992 }
26993 _ACEOF
26994 rm -f conftest$ac_exeext
26995 if { (ac_try="$ac_link"
26996 case "(($ac_try" in
26997   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26998   *) ac_try_echo=$ac_try;;
26999 esac
27000 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27001 $as_echo "$ac_try_echo") >&5
27002   (eval "$ac_link") 2>&5
27003   ac_status=$?
27004   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27005   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27006   { (case "(($ac_try" in
27007   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27008   *) ac_try_echo=$ac_try;;
27009 esac
27010 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27011 $as_echo "$ac_try_echo") >&5
27012   (eval "$ac_try") 2>&5
27013   ac_status=$?
27014   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27015   (exit $ac_status); }; }; then
27016   ac_cv_sizeof_off_t=`cat conftest.val`
27017 else
27018   $as_echo "$as_me: program exited with status $ac_status" >&5
27019 $as_echo "$as_me: failed program was:" >&5
27020 sed 's/^/| /' conftest.$ac_ext >&5
27021
27022 ( exit $ac_status )
27023 if test "$ac_cv_type_off_t" = yes; then
27024      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27025 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27026 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
27027 See \`config.log' for more details." >&5
27028 $as_echo "$as_me: error: cannot compute sizeof (off_t)
27029 See \`config.log' for more details." >&2;}
27030    { (exit 77); exit 77; }; }; }
27031    else
27032      ac_cv_sizeof_off_t=0
27033    fi
27034 fi
27035 rm -rf conftest.dSYM
27036 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27037 fi
27038 rm -f conftest.val
27039 fi
27040 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
27041 $as_echo "$ac_cv_sizeof_off_t" >&6; }
27042
27043
27044
27045 cat >>confdefs.h <<_ACEOF
27046 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
27047 _ACEOF
27048
27049
27050
27051 # If we don't have largefile support, can't handle segsize >= 2GB.
27052 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
27053    { { $as_echo "$as_me:$LINENO: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&5
27054 $as_echo "$as_me: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&2;}
27055    { (exit 1); exit 1; }; }
27056 fi
27057
27058 # SunOS doesn't handle negative byte comparisons properly with +/- return
27059 { $as_echo "$as_me:$LINENO: checking for working memcmp" >&5
27060 $as_echo_n "checking for working memcmp... " >&6; }
27061 if test "${ac_cv_func_memcmp_working+set}" = set; then
27062   $as_echo_n "(cached) " >&6
27063 else
27064   if test "$cross_compiling" = yes; then
27065   ac_cv_func_memcmp_working=no
27066 else
27067   cat >conftest.$ac_ext <<_ACEOF
27068 /* confdefs.h.  */
27069 _ACEOF
27070 cat confdefs.h >>conftest.$ac_ext
27071 cat >>conftest.$ac_ext <<_ACEOF
27072 /* end confdefs.h.  */
27073 $ac_includes_default
27074 int
27075 main ()
27076 {
27077
27078   /* Some versions of memcmp are not 8-bit clean.  */
27079   char c0 = '\100', c1 = '\200', c2 = '\201';
27080   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
27081     return 1;
27082
27083   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
27084      or more and with at least one buffer not starting on a 4-byte boundary.
27085      William Lewis provided this test program.   */
27086   {
27087     char foo[21];
27088     char bar[21];
27089     int i;
27090     for (i = 0; i < 4; i++)
27091       {
27092         char *a = foo + i;
27093         char *b = bar + i;
27094         strcpy (a, "--------01111111");
27095         strcpy (b, "--------10000000");
27096         if (memcmp (a, b, 16) >= 0)
27097           return 1;
27098       }
27099     return 0;
27100   }
27101
27102   ;
27103   return 0;
27104 }
27105 _ACEOF
27106 rm -f conftest$ac_exeext
27107 if { (ac_try="$ac_link"
27108 case "(($ac_try" in
27109   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27110   *) ac_try_echo=$ac_try;;
27111 esac
27112 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27113 $as_echo "$ac_try_echo") >&5
27114   (eval "$ac_link") 2>&5
27115   ac_status=$?
27116   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27117   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27118   { (case "(($ac_try" in
27119   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27120   *) ac_try_echo=$ac_try;;
27121 esac
27122 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27123 $as_echo "$ac_try_echo") >&5
27124   (eval "$ac_try") 2>&5
27125   ac_status=$?
27126   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27127   (exit $ac_status); }; }; then
27128   ac_cv_func_memcmp_working=yes
27129 else
27130   $as_echo "$as_me: program exited with status $ac_status" >&5
27131 $as_echo "$as_me: failed program was:" >&5
27132 sed 's/^/| /' conftest.$ac_ext >&5
27133
27134 ( exit $ac_status )
27135 ac_cv_func_memcmp_working=no
27136 fi
27137 rm -rf conftest.dSYM
27138 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27139 fi
27140
27141
27142 fi
27143 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
27144 $as_echo "$ac_cv_func_memcmp_working" >&6; }
27145 test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
27146   *" memcmp.$ac_objext "* ) ;;
27147   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
27148  ;;
27149 esac
27150
27151
27152
27153
27154 # Select semaphore implementation type.
27155 if test "$PORTNAME" != "win32"; then
27156   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
27157
27158 cat >>confdefs.h <<\_ACEOF
27159 #define USE_NAMED_POSIX_SEMAPHORES 1
27160 _ACEOF
27161
27162     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
27163   else
27164     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
27165
27166 cat >>confdefs.h <<\_ACEOF
27167 #define USE_UNNAMED_POSIX_SEMAPHORES 1
27168 _ACEOF
27169
27170       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
27171     else
27172
27173 cat >>confdefs.h <<\_ACEOF
27174 #define USE_SYSV_SEMAPHORES 1
27175 _ACEOF
27176
27177       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
27178     fi
27179   fi
27180 else
27181
27182 cat >>confdefs.h <<\_ACEOF
27183 #define USE_WIN32_SEMAPHORES 1
27184 _ACEOF
27185
27186   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
27187 fi
27188
27189
27190 # Select shared-memory implementation type.
27191 if test "$PORTNAME" != "win32"; then
27192
27193 cat >>confdefs.h <<\_ACEOF
27194 #define USE_SYSV_SHARED_MEMORY 1
27195 _ACEOF
27196
27197   SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
27198 else
27199
27200 cat >>confdefs.h <<\_ACEOF
27201 #define USE_WIN32_SHARED_MEMORY 1
27202 _ACEOF
27203
27204   SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
27205 fi
27206
27207 # If not set in template file, set bytes to use libc memset()
27208 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
27209   MEMSET_LOOP_LIMIT=1024
27210 fi
27211
27212 cat >>confdefs.h <<_ACEOF
27213 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
27214 _ACEOF
27215
27216
27217
27218 if test "$enable_nls" = yes ; then
27219
27220   { $as_echo "$as_me:$LINENO: checking for library containing bind_textdomain_codeset" >&5
27221 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
27222 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
27223   $as_echo_n "(cached) " >&6
27224 else
27225   ac_func_search_save_LIBS=$LIBS
27226 cat >conftest.$ac_ext <<_ACEOF
27227 /* confdefs.h.  */
27228 _ACEOF
27229 cat confdefs.h >>conftest.$ac_ext
27230 cat >>conftest.$ac_ext <<_ACEOF
27231 /* end confdefs.h.  */
27232
27233 /* Override any GCC internal prototype to avoid an error.
27234    Use char because int might match the return type of a GCC
27235    builtin and then its argument prototype would still apply.  */
27236 #ifdef __cplusplus
27237 extern "C"
27238 #endif
27239 char bind_textdomain_codeset ();
27240 int
27241 main ()
27242 {
27243 return bind_textdomain_codeset ();
27244   ;
27245   return 0;
27246 }
27247 _ACEOF
27248 for ac_lib in '' intl; do
27249   if test -z "$ac_lib"; then
27250     ac_res="none required"
27251   else
27252     ac_res=-l$ac_lib
27253     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
27254   fi
27255   rm -f conftest.$ac_objext conftest$ac_exeext
27256 if { (ac_try="$ac_link"
27257 case "(($ac_try" in
27258   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27259   *) ac_try_echo=$ac_try;;
27260 esac
27261 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27262 $as_echo "$ac_try_echo") >&5
27263   (eval "$ac_link") 2>conftest.er1
27264   ac_status=$?
27265   grep -v '^ *+' conftest.er1 >conftest.err
27266   rm -f conftest.er1
27267   cat conftest.err >&5
27268   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27269   (exit $ac_status); } && {
27270          test -z "$ac_c_werror_flag" ||
27271          test ! -s conftest.err
27272        } && test -s conftest$ac_exeext && {
27273          test "$cross_compiling" = yes ||
27274          $as_test_x conftest$ac_exeext
27275        }; then
27276   ac_cv_search_bind_textdomain_codeset=$ac_res
27277 else
27278   $as_echo "$as_me: failed program was:" >&5
27279 sed 's/^/| /' conftest.$ac_ext >&5
27280
27281
27282 fi
27283
27284 rm -rf conftest.dSYM
27285 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
27286       conftest$ac_exeext
27287   if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
27288   break
27289 fi
27290 done
27291 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
27292   :
27293 else
27294   ac_cv_search_bind_textdomain_codeset=no
27295 fi
27296 rm conftest.$ac_ext
27297 LIBS=$ac_func_search_save_LIBS
27298 fi
27299 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_bind_textdomain_codeset" >&5
27300 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
27301 ac_res=$ac_cv_search_bind_textdomain_codeset
27302 if test "$ac_res" != no; then
27303   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27304
27305 else
27306   { { $as_echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
27307 $as_echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
27308    { (exit 1); exit 1; }; }
27309 fi
27310
27311   if test "${ac_cv_header_libintl_h+set}" = set; then
27312   { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
27313 $as_echo_n "checking for libintl.h... " >&6; }
27314 if test "${ac_cv_header_libintl_h+set}" = set; then
27315   $as_echo_n "(cached) " >&6
27316 fi
27317 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
27318 $as_echo "$ac_cv_header_libintl_h" >&6; }
27319 else
27320   # Is the header compilable?
27321 { $as_echo "$as_me:$LINENO: checking libintl.h usability" >&5
27322 $as_echo_n "checking libintl.h usability... " >&6; }
27323 cat >conftest.$ac_ext <<_ACEOF
27324 /* confdefs.h.  */
27325 _ACEOF
27326 cat confdefs.h >>conftest.$ac_ext
27327 cat >>conftest.$ac_ext <<_ACEOF
27328 /* end confdefs.h.  */
27329 $ac_includes_default
27330 #include <libintl.h>
27331 _ACEOF
27332 rm -f conftest.$ac_objext
27333 if { (ac_try="$ac_compile"
27334 case "(($ac_try" in
27335   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27336   *) ac_try_echo=$ac_try;;
27337 esac
27338 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27339 $as_echo "$ac_try_echo") >&5
27340   (eval "$ac_compile") 2>conftest.er1
27341   ac_status=$?
27342   grep -v '^ *+' conftest.er1 >conftest.err
27343   rm -f conftest.er1
27344   cat conftest.err >&5
27345   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27346   (exit $ac_status); } && {
27347          test -z "$ac_c_werror_flag" ||
27348          test ! -s conftest.err
27349        } && test -s conftest.$ac_objext; then
27350   ac_header_compiler=yes
27351 else
27352   $as_echo "$as_me: failed program was:" >&5
27353 sed 's/^/| /' conftest.$ac_ext >&5
27354
27355         ac_header_compiler=no
27356 fi
27357
27358 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27359 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27360 $as_echo "$ac_header_compiler" >&6; }
27361
27362 # Is the header present?
27363 { $as_echo "$as_me:$LINENO: checking libintl.h presence" >&5
27364 $as_echo_n "checking libintl.h presence... " >&6; }
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 <libintl.h>
27372 _ACEOF
27373 if { (ac_try="$ac_cpp conftest.$ac_ext"
27374 case "(($ac_try" in
27375   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27376   *) ac_try_echo=$ac_try;;
27377 esac
27378 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27379 $as_echo "$ac_try_echo") >&5
27380   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
27381   ac_status=$?
27382   grep -v '^ *+' conftest.er1 >conftest.err
27383   rm -f conftest.er1
27384   cat conftest.err >&5
27385   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27386   (exit $ac_status); } >/dev/null && {
27387          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
27388          test ! -s conftest.err
27389        }; then
27390   ac_header_preproc=yes
27391 else
27392   $as_echo "$as_me: failed program was:" >&5
27393 sed 's/^/| /' conftest.$ac_ext >&5
27394
27395   ac_header_preproc=no
27396 fi
27397
27398 rm -f conftest.err conftest.$ac_ext
27399 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27400 $as_echo "$ac_header_preproc" >&6; }
27401
27402 # So?  What about this header?
27403 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
27404   yes:no: )
27405     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
27406 $as_echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
27407     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
27408 $as_echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
27409     ac_header_preproc=yes
27410     ;;
27411   no:yes:* )
27412     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
27413 $as_echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
27414     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
27415 $as_echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
27416     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
27417 $as_echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
27418     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
27419 $as_echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
27420     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
27421 $as_echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
27422     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
27423 $as_echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
27424     ( cat <<\_ASBOX
27425 ## ---------------------------------------- ##
27426 ## Report this to pgsql-bugs@postgresql.org ##
27427 ## ---------------------------------------- ##
27428 _ASBOX
27429      ) | sed "s/^/$as_me: WARNING:     /" >&2
27430     ;;
27431 esac
27432 { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
27433 $as_echo_n "checking for libintl.h... " >&6; }
27434 if test "${ac_cv_header_libintl_h+set}" = set; then
27435   $as_echo_n "(cached) " >&6
27436 else
27437   ac_cv_header_libintl_h=$ac_header_preproc
27438 fi
27439 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
27440 $as_echo "$ac_cv_header_libintl_h" >&6; }
27441
27442 fi
27443 if test "x$ac_cv_header_libintl_h" = x""yes; then
27444   :
27445 else
27446   { { $as_echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
27447 $as_echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
27448    { (exit 1); exit 1; }; }
27449 fi
27450
27451
27452   for ac_prog in msgfmt
27453 do
27454   # Extract the first word of "$ac_prog", so it can be a program name with args.
27455 set dummy $ac_prog; ac_word=$2
27456 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
27457 $as_echo_n "checking for $ac_word... " >&6; }
27458 if test "${ac_cv_prog_MSGFMT+set}" = set; then
27459   $as_echo_n "(cached) " >&6
27460 else
27461   if test -n "$MSGFMT"; then
27462   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
27463 else
27464 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27465 for as_dir in $PATH
27466 do
27467   IFS=$as_save_IFS
27468   test -z "$as_dir" && as_dir=.
27469   for ac_exec_ext in '' $ac_executable_extensions; do
27470   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
27471     ac_cv_prog_MSGFMT="$ac_prog"
27472     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
27473     break 2
27474   fi
27475 done
27476 done
27477 IFS=$as_save_IFS
27478
27479 fi
27480 fi
27481 MSGFMT=$ac_cv_prog_MSGFMT
27482 if test -n "$MSGFMT"; then
27483   { $as_echo "$as_me:$LINENO: result: $MSGFMT" >&5
27484 $as_echo "$MSGFMT" >&6; }
27485 else
27486   { $as_echo "$as_me:$LINENO: result: no" >&5
27487 $as_echo "no" >&6; }
27488 fi
27489
27490
27491   test -n "$MSGFMT" && break
27492 done
27493
27494   if test -z "$MSGFMT"; then
27495     { { $as_echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
27496 $as_echo "$as_me: error: msgfmt is required for NLS" >&2;}
27497    { (exit 1); exit 1; }; }
27498   fi
27499   for ac_prog in msgmerge
27500 do
27501   # Extract the first word of "$ac_prog", so it can be a program name with args.
27502 set dummy $ac_prog; ac_word=$2
27503 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
27504 $as_echo_n "checking for $ac_word... " >&6; }
27505 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
27506   $as_echo_n "(cached) " >&6
27507 else
27508   if test -n "$MSGMERGE"; then
27509   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
27510 else
27511 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27512 for as_dir in $PATH
27513 do
27514   IFS=$as_save_IFS
27515   test -z "$as_dir" && as_dir=.
27516   for ac_exec_ext in '' $ac_executable_extensions; do
27517   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
27518     ac_cv_prog_MSGMERGE="$ac_prog"
27519     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
27520     break 2
27521   fi
27522 done
27523 done
27524 IFS=$as_save_IFS
27525
27526 fi
27527 fi
27528 MSGMERGE=$ac_cv_prog_MSGMERGE
27529 if test -n "$MSGMERGE"; then
27530   { $as_echo "$as_me:$LINENO: result: $MSGMERGE" >&5
27531 $as_echo "$MSGMERGE" >&6; }
27532 else
27533   { $as_echo "$as_me:$LINENO: result: no" >&5
27534 $as_echo "no" >&6; }
27535 fi
27536
27537
27538   test -n "$MSGMERGE" && break
27539 done
27540
27541   for ac_prog in xgettext
27542 do
27543   # Extract the first word of "$ac_prog", so it can be a program name with args.
27544 set dummy $ac_prog; ac_word=$2
27545 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
27546 $as_echo_n "checking for $ac_word... " >&6; }
27547 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
27548   $as_echo_n "(cached) " >&6
27549 else
27550   if test -n "$XGETTEXT"; then
27551   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
27552 else
27553 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27554 for as_dir in $PATH
27555 do
27556   IFS=$as_save_IFS
27557   test -z "$as_dir" && as_dir=.
27558   for ac_exec_ext in '' $ac_executable_extensions; do
27559   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
27560     ac_cv_prog_XGETTEXT="$ac_prog"
27561     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
27562     break 2
27563   fi
27564 done
27565 done
27566 IFS=$as_save_IFS
27567
27568 fi
27569 fi
27570 XGETTEXT=$ac_cv_prog_XGETTEXT
27571 if test -n "$XGETTEXT"; then
27572   { $as_echo "$as_me:$LINENO: result: $XGETTEXT" >&5
27573 $as_echo "$XGETTEXT" >&6; }
27574 else
27575   { $as_echo "$as_me:$LINENO: result: no" >&5
27576 $as_echo "no" >&6; }
27577 fi
27578
27579
27580   test -n "$XGETTEXT" && break
27581 done
27582
27583
27584 fi
27585
27586 # Check for Tcl configuration script tclConfig.sh
27587 if test "$with_tcl" = yes; then
27588     for ac_prog in tclsh tcl tclsh8.5 tclsh85 tclsh8.4 tclsh84 tclsh8.3 tclsh83
27589 do
27590   # Extract the first word of "$ac_prog", so it can be a program name with args.
27591 set dummy $ac_prog; ac_word=$2
27592 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
27593 $as_echo_n "checking for $ac_word... " >&6; }
27594 if test "${ac_cv_path_TCLSH+set}" = set; then
27595   $as_echo_n "(cached) " >&6
27596 else
27597   case $TCLSH in
27598   [\\/]* | ?:[\\/]*)
27599   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
27600   ;;
27601   *)
27602   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27603 for as_dir in $PATH
27604 do
27605   IFS=$as_save_IFS
27606   test -z "$as_dir" && as_dir=.
27607   for ac_exec_ext in '' $ac_executable_extensions; do
27608   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
27609     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
27610     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
27611     break 2
27612   fi
27613 done
27614 done
27615 IFS=$as_save_IFS
27616
27617   ;;
27618 esac
27619 fi
27620 TCLSH=$ac_cv_path_TCLSH
27621 if test -n "$TCLSH"; then
27622   { $as_echo "$as_me:$LINENO: result: $TCLSH" >&5
27623 $as_echo "$TCLSH" >&6; }
27624 else
27625   { $as_echo "$as_me:$LINENO: result: no" >&5
27626 $as_echo "no" >&6; }
27627 fi
27628
27629
27630   test -n "$TCLSH" && break
27631 done
27632
27633 if test x"$TCLSH" = x""; then
27634   { { $as_echo "$as_me:$LINENO: error: Tcl shell not found" >&5
27635 $as_echo "$as_me: error: Tcl shell not found" >&2;}
27636    { (exit 1); exit 1; }; }
27637 fi
27638
27639 { $as_echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
27640 $as_echo_n "checking for tclConfig.sh... " >&6; }
27641 # Let user override test
27642 if test -z "$TCL_CONFIG_SH"; then
27643     pgac_test_dirs="$with_tclconfig"
27644
27645     set X $pgac_test_dirs; shift
27646     if test $# -eq 0; then
27647         test -z "$TCLSH" && { { $as_echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
27648 $as_echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
27649    { (exit 1); exit 1; }; }
27650         set X `echo 'puts $auto_path' | $TCLSH`; shift
27651     fi
27652
27653     for pgac_dir do
27654         if test -r "$pgac_dir/tclConfig.sh"; then
27655             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
27656             break
27657         fi
27658     done
27659 fi
27660
27661 if test -z "$TCL_CONFIG_SH"; then
27662     { $as_echo "$as_me:$LINENO: result: no" >&5
27663 $as_echo "no" >&6; }
27664     { { $as_echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
27665 $as_echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
27666    { (exit 1); exit 1; }; }
27667 else
27668     { $as_echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
27669 $as_echo "$TCL_CONFIG_SH" >&6; }
27670 fi
27671
27672
27673
27674     . "$TCL_CONFIG_SH"
27675 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
27676 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
27677 eval TCL_LIBS=\"$TCL_LIBS\"
27678 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
27679 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
27680
27681         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
27682     ac_save_CPPFLAGS=$CPPFLAGS
27683     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
27684     if test "${ac_cv_header_tcl_h+set}" = set; then
27685   { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
27686 $as_echo_n "checking for tcl.h... " >&6; }
27687 if test "${ac_cv_header_tcl_h+set}" = set; then
27688   $as_echo_n "(cached) " >&6
27689 fi
27690 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
27691 $as_echo "$ac_cv_header_tcl_h" >&6; }
27692 else
27693   # Is the header compilable?
27694 { $as_echo "$as_me:$LINENO: checking tcl.h usability" >&5
27695 $as_echo_n "checking tcl.h usability... " >&6; }
27696 cat >conftest.$ac_ext <<_ACEOF
27697 /* confdefs.h.  */
27698 _ACEOF
27699 cat confdefs.h >>conftest.$ac_ext
27700 cat >>conftest.$ac_ext <<_ACEOF
27701 /* end confdefs.h.  */
27702 $ac_includes_default
27703 #include <tcl.h>
27704 _ACEOF
27705 rm -f conftest.$ac_objext
27706 if { (ac_try="$ac_compile"
27707 case "(($ac_try" in
27708   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27709   *) ac_try_echo=$ac_try;;
27710 esac
27711 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27712 $as_echo "$ac_try_echo") >&5
27713   (eval "$ac_compile") 2>conftest.er1
27714   ac_status=$?
27715   grep -v '^ *+' conftest.er1 >conftest.err
27716   rm -f conftest.er1
27717   cat conftest.err >&5
27718   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27719   (exit $ac_status); } && {
27720          test -z "$ac_c_werror_flag" ||
27721          test ! -s conftest.err
27722        } && test -s conftest.$ac_objext; then
27723   ac_header_compiler=yes
27724 else
27725   $as_echo "$as_me: failed program was:" >&5
27726 sed 's/^/| /' conftest.$ac_ext >&5
27727
27728         ac_header_compiler=no
27729 fi
27730
27731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27732 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
27733 $as_echo "$ac_header_compiler" >&6; }
27734
27735 # Is the header present?
27736 { $as_echo "$as_me:$LINENO: checking tcl.h presence" >&5
27737 $as_echo_n "checking tcl.h presence... " >&6; }
27738 cat >conftest.$ac_ext <<_ACEOF
27739 /* confdefs.h.  */
27740 _ACEOF
27741 cat confdefs.h >>conftest.$ac_ext
27742 cat >>conftest.$ac_ext <<_ACEOF
27743 /* end confdefs.h.  */
27744 #include <tcl.h>
27745 _ACEOF
27746 if { (ac_try="$ac_cpp conftest.$ac_ext"
27747 case "(($ac_try" in
27748   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27749   *) ac_try_echo=$ac_try;;
27750 esac
27751 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27752 $as_echo "$ac_try_echo") >&5
27753   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
27754   ac_status=$?
27755   grep -v '^ *+' conftest.er1 >conftest.err
27756   rm -f conftest.er1
27757   cat conftest.err >&5
27758   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27759   (exit $ac_status); } >/dev/null && {
27760          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
27761          test ! -s conftest.err
27762        }; then
27763   ac_header_preproc=yes
27764 else
27765   $as_echo "$as_me: failed program was:" >&5
27766 sed 's/^/| /' conftest.$ac_ext >&5
27767
27768   ac_header_preproc=no
27769 fi
27770
27771 rm -f conftest.err conftest.$ac_ext
27772 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
27773 $as_echo "$ac_header_preproc" >&6; }
27774
27775 # So?  What about this header?
27776 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
27777   yes:no: )
27778     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
27779 $as_echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
27780     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
27781 $as_echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
27782     ac_header_preproc=yes
27783     ;;
27784   no:yes:* )
27785     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
27786 $as_echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
27787     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
27788 $as_echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
27789     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
27790 $as_echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
27791     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
27792 $as_echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
27793     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
27794 $as_echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
27795     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
27796 $as_echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
27797     ( cat <<\_ASBOX
27798 ## ---------------------------------------- ##
27799 ## Report this to pgsql-bugs@postgresql.org ##
27800 ## ---------------------------------------- ##
27801 _ASBOX
27802      ) | sed "s/^/$as_me: WARNING:     /" >&2
27803     ;;
27804 esac
27805 { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
27806 $as_echo_n "checking for tcl.h... " >&6; }
27807 if test "${ac_cv_header_tcl_h+set}" = set; then
27808   $as_echo_n "(cached) " >&6
27809 else
27810   ac_cv_header_tcl_h=$ac_header_preproc
27811 fi
27812 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
27813 $as_echo "$ac_cv_header_tcl_h" >&6; }
27814
27815 fi
27816 if test "x$ac_cv_header_tcl_h" = x""yes; then
27817   :
27818 else
27819   { { $as_echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
27820 $as_echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
27821    { (exit 1); exit 1; }; }
27822 fi
27823
27824
27825     CPPFLAGS=$ac_save_CPPFLAGS
27826 fi
27827
27828 #
27829 # Check for DocBook and tools
27830 #
27831 for ac_prog in onsgmls nsgmls
27832 do
27833   # Extract the first word of "$ac_prog", so it can be a program name with args.
27834 set dummy $ac_prog; ac_word=$2
27835 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
27836 $as_echo_n "checking for $ac_word... " >&6; }
27837 if test "${ac_cv_prog_NSGMLS+set}" = set; then
27838   $as_echo_n "(cached) " >&6
27839 else
27840   if test -n "$NSGMLS"; then
27841   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
27842 else
27843 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27844 for as_dir in $PATH
27845 do
27846   IFS=$as_save_IFS
27847   test -z "$as_dir" && as_dir=.
27848   for ac_exec_ext in '' $ac_executable_extensions; do
27849   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
27850     ac_cv_prog_NSGMLS="$ac_prog"
27851     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
27852     break 2
27853   fi
27854 done
27855 done
27856 IFS=$as_save_IFS
27857
27858 fi
27859 fi
27860 NSGMLS=$ac_cv_prog_NSGMLS
27861 if test -n "$NSGMLS"; then
27862   { $as_echo "$as_me:$LINENO: result: $NSGMLS" >&5
27863 $as_echo "$NSGMLS" >&6; }
27864 else
27865   { $as_echo "$as_me:$LINENO: result: no" >&5
27866 $as_echo "no" >&6; }
27867 fi
27868
27869
27870   test -n "$NSGMLS" && break
27871 done
27872
27873 for ac_prog in openjade jade
27874 do
27875   # Extract the first word of "$ac_prog", so it can be a program name with args.
27876 set dummy $ac_prog; ac_word=$2
27877 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
27878 $as_echo_n "checking for $ac_word... " >&6; }
27879 if test "${ac_cv_prog_JADE+set}" = set; then
27880   $as_echo_n "(cached) " >&6
27881 else
27882   if test -n "$JADE"; then
27883   ac_cv_prog_JADE="$JADE" # Let the user override the test.
27884 else
27885 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27886 for as_dir in $PATH
27887 do
27888   IFS=$as_save_IFS
27889   test -z "$as_dir" && as_dir=.
27890   for ac_exec_ext in '' $ac_executable_extensions; do
27891   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
27892     ac_cv_prog_JADE="$ac_prog"
27893     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
27894     break 2
27895   fi
27896 done
27897 done
27898 IFS=$as_save_IFS
27899
27900 fi
27901 fi
27902 JADE=$ac_cv_prog_JADE
27903 if test -n "$JADE"; then
27904   { $as_echo "$as_me:$LINENO: result: $JADE" >&5
27905 $as_echo "$JADE" >&6; }
27906 else
27907   { $as_echo "$as_me:$LINENO: result: no" >&5
27908 $as_echo "no" >&6; }
27909 fi
27910
27911
27912   test -n "$JADE" && break
27913 done
27914
27915
27916 { $as_echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
27917 $as_echo_n "checking for DocBook V4.2... " >&6; }
27918 if test "${pgac_cv_check_docbook+set}" = set; then
27919   $as_echo_n "(cached) " >&6
27920 else
27921   cat >conftest.sgml <<EOF
27922 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
27923 <book>
27924  <title>test</title>
27925  <chapter>
27926   <title>random</title>
27927    <sect1>
27928     <title>testsect</title>
27929     <para>text</para>
27930   </sect1>
27931  </chapter>
27932 </book>
27933 EOF
27934
27935 pgac_cv_check_docbook=no
27936
27937 if test -n "$NSGMLS"; then
27938   $NSGMLS -s conftest.sgml 1>&5 2>&1
27939   if test $? -eq 0; then
27940     pgac_cv_check_docbook=yes
27941   fi
27942 fi
27943 rm -f conftest.sgml
27944 fi
27945 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
27946 $as_echo "$pgac_cv_check_docbook" >&6; }
27947
27948 have_docbook=$pgac_cv_check_docbook
27949
27950
27951 { $as_echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
27952 $as_echo_n "checking for DocBook stylesheets... " >&6; }
27953 if test "${pgac_cv_path_stylesheets+set}" = set; then
27954   $as_echo_n "(cached) " >&6
27955 else
27956   if test -n "$DOCBOOKSTYLE"; then
27957   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
27958 else
27959   for pgac_prefix in /usr /usr/local /opt /sw; do
27960     for pgac_infix in share lib; do
27961       for pgac_postfix in \
27962         sgml/stylesheets/nwalsh-modular \
27963         sgml/stylesheets/docbook \
27964         sgml/stylesheets/dsssl/docbook \
27965         sgml/docbook-dsssl \
27966         sgml/docbook/dsssl/modular \
27967         sgml/docbook/stylesheet/dsssl/modular \
27968         sgml/docbook/dsssl-stylesheets \
27969         sgml/dsssl/docbook-dsssl-nwalsh
27970       do
27971         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
27972         if test -r "$pgac_candidate/html/docbook.dsl" \
27973            && test -r "$pgac_candidate/print/docbook.dsl"
27974         then
27975           pgac_cv_path_stylesheets=$pgac_candidate
27976           break 3
27977         fi
27978       done
27979     done
27980   done
27981 fi
27982 fi
27983
27984 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
27985
27986 if test -n "$DOCBOOKSTYLE"; then
27987   { $as_echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
27988 $as_echo "$DOCBOOKSTYLE" >&6; }
27989 else
27990   { $as_echo "$as_me:$LINENO: result: no" >&5
27991 $as_echo "no" >&6; }
27992 fi
27993 if test -n "$DOCBOOKSTYLE"; then
27994   for ac_prog in collateindex.pl
27995 do
27996   # Extract the first word of "$ac_prog", so it can be a program name with args.
27997 set dummy $ac_prog; ac_word=$2
27998 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
27999 $as_echo_n "checking for $ac_word... " >&6; }
28000 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
28001   $as_echo_n "(cached) " >&6
28002 else
28003   case $COLLATEINDEX in
28004   [\\/]* | ?:[\\/]*)
28005   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
28006   ;;
28007   *)
28008   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28009 for as_dir in $DOCBOOKSTYLE/bin $PATH
28010 do
28011   IFS=$as_save_IFS
28012   test -z "$as_dir" && as_dir=.
28013   for ac_exec_ext in '' $ac_executable_extensions; do
28014   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28015     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
28016     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28017     break 2
28018   fi
28019 done
28020 done
28021 IFS=$as_save_IFS
28022
28023   ;;
28024 esac
28025 fi
28026 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
28027 if test -n "$COLLATEINDEX"; then
28028   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
28029 $as_echo "$COLLATEINDEX" >&6; }
28030 else
28031   { $as_echo "$as_me:$LINENO: result: no" >&5
28032 $as_echo "no" >&6; }
28033 fi
28034
28035
28036   test -n "$COLLATEINDEX" && break
28037 done
28038
28039 else
28040   for ac_prog in collateindex.pl
28041 do
28042   # Extract the first word of "$ac_prog", so it can be a program name with args.
28043 set dummy $ac_prog; ac_word=$2
28044 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28045 $as_echo_n "checking for $ac_word... " >&6; }
28046 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
28047   $as_echo_n "(cached) " >&6
28048 else
28049   case $COLLATEINDEX in
28050   [\\/]* | ?:[\\/]*)
28051   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
28052   ;;
28053   *)
28054   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28055 for as_dir in $PATH
28056 do
28057   IFS=$as_save_IFS
28058   test -z "$as_dir" && as_dir=.
28059   for ac_exec_ext in '' $ac_executable_extensions; do
28060   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28061     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
28062     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28063     break 2
28064   fi
28065 done
28066 done
28067 IFS=$as_save_IFS
28068
28069   ;;
28070 esac
28071 fi
28072 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
28073 if test -n "$COLLATEINDEX"; then
28074   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
28075 $as_echo "$COLLATEINDEX" >&6; }
28076 else
28077   { $as_echo "$as_me:$LINENO: result: no" >&5
28078 $as_echo "no" >&6; }
28079 fi
28080
28081
28082   test -n "$COLLATEINDEX" && break
28083 done
28084
28085 fi
28086 for ac_prog in xsltproc
28087 do
28088   # Extract the first word of "$ac_prog", so it can be a program name with args.
28089 set dummy $ac_prog; ac_word=$2
28090 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28091 $as_echo_n "checking for $ac_word... " >&6; }
28092 if test "${ac_cv_prog_XSLTPROC+set}" = set; then
28093   $as_echo_n "(cached) " >&6
28094 else
28095   if test -n "$XSLTPROC"; then
28096   ac_cv_prog_XSLTPROC="$XSLTPROC" # Let the user override the test.
28097 else
28098 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28099 for as_dir in $PATH
28100 do
28101   IFS=$as_save_IFS
28102   test -z "$as_dir" && as_dir=.
28103   for ac_exec_ext in '' $ac_executable_extensions; do
28104   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28105     ac_cv_prog_XSLTPROC="$ac_prog"
28106     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28107     break 2
28108   fi
28109 done
28110 done
28111 IFS=$as_save_IFS
28112
28113 fi
28114 fi
28115 XSLTPROC=$ac_cv_prog_XSLTPROC
28116 if test -n "$XSLTPROC"; then
28117   { $as_echo "$as_me:$LINENO: result: $XSLTPROC" >&5
28118 $as_echo "$XSLTPROC" >&6; }
28119 else
28120   { $as_echo "$as_me:$LINENO: result: no" >&5
28121 $as_echo "no" >&6; }
28122 fi
28123
28124
28125   test -n "$XSLTPROC" && break
28126 done
28127
28128 for ac_prog in osx sgml2xml sx
28129 do
28130   # Extract the first word of "$ac_prog", so it can be a program name with args.
28131 set dummy $ac_prog; ac_word=$2
28132 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28133 $as_echo_n "checking for $ac_word... " >&6; }
28134 if test "${ac_cv_prog_OSX+set}" = set; then
28135   $as_echo_n "(cached) " >&6
28136 else
28137   if test -n "$OSX"; then
28138   ac_cv_prog_OSX="$OSX" # Let the user override the test.
28139 else
28140 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28141 for as_dir in $PATH
28142 do
28143   IFS=$as_save_IFS
28144   test -z "$as_dir" && as_dir=.
28145   for ac_exec_ext in '' $ac_executable_extensions; do
28146   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28147     ac_cv_prog_OSX="$ac_prog"
28148     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28149     break 2
28150   fi
28151 done
28152 done
28153 IFS=$as_save_IFS
28154
28155 fi
28156 fi
28157 OSX=$ac_cv_prog_OSX
28158 if test -n "$OSX"; then
28159   { $as_echo "$as_me:$LINENO: result: $OSX" >&5
28160 $as_echo "$OSX" >&6; }
28161 else
28162   { $as_echo "$as_me:$LINENO: result: no" >&5
28163 $as_echo "no" >&6; }
28164 fi
28165
28166
28167   test -n "$OSX" && break
28168 done
28169
28170
28171 # Thread testing
28172
28173 # We have to run the thread test near the end so we have all our symbols
28174 # defined.  Cross compiling throws a warning.
28175 #
28176 if test "$enable_thread_safety" = yes; then
28177 if test "$PORTNAME" != "win32"
28178 then
28179 { $as_echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
28180 $as_echo_n "checking thread safety of required library functions... " >&6; }
28181
28182 _CFLAGS="$CFLAGS"
28183 _LIBS="$LIBS"
28184 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
28185 LIBS="$LIBS $PTHREAD_LIBS"
28186 if test "$cross_compiling" = yes; then
28187   { $as_echo "$as_me:$LINENO: result: maybe" >&5
28188 $as_echo "maybe" >&6; }
28189   { $as_echo "$as_me:$LINENO: WARNING:
28190 *** Skipping thread test program because of cross-compile build.
28191 *** Run the program in src/test/thread on the target machine.
28192 " >&5
28193 $as_echo "$as_me: WARNING:
28194 *** Skipping thread test program because of cross-compile build.
28195 *** Run the program in src/test/thread on the target machine.
28196 " >&2;}
28197 else
28198   cat >conftest.$ac_ext <<_ACEOF
28199 /* confdefs.h.  */
28200 _ACEOF
28201 cat confdefs.h >>conftest.$ac_ext
28202 cat >>conftest.$ac_ext <<_ACEOF
28203 /* end confdefs.h.  */
28204 #include "$srcdir/src/test/thread/thread_test.c"
28205 _ACEOF
28206 rm -f conftest$ac_exeext
28207 if { (ac_try="$ac_link"
28208 case "(($ac_try" in
28209   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28210   *) ac_try_echo=$ac_try;;
28211 esac
28212 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28213 $as_echo "$ac_try_echo") >&5
28214   (eval "$ac_link") 2>&5
28215   ac_status=$?
28216   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28217   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28218   { (case "(($ac_try" in
28219   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28220   *) ac_try_echo=$ac_try;;
28221 esac
28222 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28223 $as_echo "$ac_try_echo") >&5
28224   (eval "$ac_try") 2>&5
28225   ac_status=$?
28226   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28227   (exit $ac_status); }; }; then
28228   { $as_echo "$as_me:$LINENO: result: yes" >&5
28229 $as_echo "yes" >&6; }
28230 else
28231   $as_echo "$as_me: program exited with status $ac_status" >&5
28232 $as_echo "$as_me: failed program was:" >&5
28233 sed 's/^/| /' conftest.$ac_ext >&5
28234
28235 ( exit $ac_status )
28236 { $as_echo "$as_me:$LINENO: result: no" >&5
28237 $as_echo "no" >&6; }
28238   { { $as_echo "$as_me:$LINENO: error: thread test program failed
28239 This platform is not thread-safe.  Check the file 'config.log' or compile
28240 and run src/test/thread/thread_test for the exact reason.
28241 Use --disable-thread-safety to disable thread safety." >&5
28242 $as_echo "$as_me: error: thread test program failed
28243 This platform is not thread-safe.  Check the file 'config.log' or compile
28244 and run src/test/thread/thread_test for the exact reason.
28245 Use --disable-thread-safety to disable thread safety." >&2;}
28246    { (exit 1); exit 1; }; }
28247 fi
28248 rm -rf conftest.dSYM
28249 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28250 fi
28251
28252
28253 CFLAGS="$_CFLAGS"
28254 LIBS="$_LIBS"
28255 else
28256 { $as_echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
28257 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
28258 fi
28259 fi
28260
28261 # If compiler will take -Wl,--as-needed (or various platform-specific
28262 # spellings thereof) then add that to LDFLAGS.  This is much easier than
28263 # trying to filter LIBS to the minimum for each executable.
28264 # (Note that shared library links won't use this switch, though.)
28265 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
28266 # libreadline; therefore we postpone testing it until we know what library
28267 # dependencies readline has.  The test code will try to link with $LIBS.
28268 if test "$with_readline" = yes; then
28269   link_test_func=readline
28270 else
28271   link_test_func=exit
28272 fi
28273
28274 if test "$PORTNAME" = "darwin"; then
28275   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wl,-dead_strip_dylibs" >&5
28276 $as_echo_n "checking if $CC supports -Wl,-dead_strip_dylibs... " >&6; }
28277 pgac_save_LDFLAGS=$LDFLAGS
28278 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
28279 if test "$cross_compiling" = yes; then
28280   LDFLAGS="$pgac_save_LDFLAGS"
28281                { $as_echo "$as_me:$LINENO: result: assuming no" >&5
28282 $as_echo "assuming no" >&6; }
28283 else
28284   cat >conftest.$ac_ext <<_ACEOF
28285 /* confdefs.h.  */
28286 _ACEOF
28287 cat confdefs.h >>conftest.$ac_ext
28288 cat >>conftest.$ac_ext <<_ACEOF
28289 /* end confdefs.h.  */
28290 extern void $link_test_func (); void (*fptr) () = $link_test_func;
28291 int
28292 main ()
28293 {
28294
28295   ;
28296   return 0;
28297 }
28298 _ACEOF
28299 rm -f conftest$ac_exeext
28300 if { (ac_try="$ac_link"
28301 case "(($ac_try" in
28302   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28303   *) ac_try_echo=$ac_try;;
28304 esac
28305 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28306 $as_echo "$ac_try_echo") >&5
28307   (eval "$ac_link") 2>&5
28308   ac_status=$?
28309   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28310   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28311   { (case "(($ac_try" in
28312   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28313   *) ac_try_echo=$ac_try;;
28314 esac
28315 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28316 $as_echo "$ac_try_echo") >&5
28317   (eval "$ac_try") 2>&5
28318   ac_status=$?
28319   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28320   (exit $ac_status); }; }; then
28321   { $as_echo "$as_me:$LINENO: result: yes" >&5
28322 $as_echo "yes" >&6; }
28323 else
28324   $as_echo "$as_me: program exited with status $ac_status" >&5
28325 $as_echo "$as_me: failed program was:" >&5
28326 sed 's/^/| /' conftest.$ac_ext >&5
28327
28328 ( exit $ac_status )
28329 LDFLAGS="$pgac_save_LDFLAGS"
28330                { $as_echo "$as_me:$LINENO: result: no" >&5
28331 $as_echo "no" >&6; }
28332 fi
28333 rm -rf conftest.dSYM
28334 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28335 fi
28336
28337
28338
28339 elif test "$PORTNAME" = "openbsd"; then
28340   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wl,-Bdynamic" >&5
28341 $as_echo_n "checking if $CC supports -Wl,-Bdynamic... " >&6; }
28342 pgac_save_LDFLAGS=$LDFLAGS
28343 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
28344 if test "$cross_compiling" = yes; then
28345   LDFLAGS="$pgac_save_LDFLAGS"
28346                { $as_echo "$as_me:$LINENO: result: assuming no" >&5
28347 $as_echo "assuming no" >&6; }
28348 else
28349   cat >conftest.$ac_ext <<_ACEOF
28350 /* confdefs.h.  */
28351 _ACEOF
28352 cat confdefs.h >>conftest.$ac_ext
28353 cat >>conftest.$ac_ext <<_ACEOF
28354 /* end confdefs.h.  */
28355 extern void $link_test_func (); void (*fptr) () = $link_test_func;
28356 int
28357 main ()
28358 {
28359
28360   ;
28361   return 0;
28362 }
28363 _ACEOF
28364 rm -f conftest$ac_exeext
28365 if { (ac_try="$ac_link"
28366 case "(($ac_try" in
28367   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28368   *) ac_try_echo=$ac_try;;
28369 esac
28370 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28371 $as_echo "$ac_try_echo") >&5
28372   (eval "$ac_link") 2>&5
28373   ac_status=$?
28374   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28375   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28376   { (case "(($ac_try" in
28377   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28378   *) ac_try_echo=$ac_try;;
28379 esac
28380 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28381 $as_echo "$ac_try_echo") >&5
28382   (eval "$ac_try") 2>&5
28383   ac_status=$?
28384   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28385   (exit $ac_status); }; }; then
28386   { $as_echo "$as_me:$LINENO: result: yes" >&5
28387 $as_echo "yes" >&6; }
28388 else
28389   $as_echo "$as_me: program exited with status $ac_status" >&5
28390 $as_echo "$as_me: failed program was:" >&5
28391 sed 's/^/| /' conftest.$ac_ext >&5
28392
28393 ( exit $ac_status )
28394 LDFLAGS="$pgac_save_LDFLAGS"
28395                { $as_echo "$as_me:$LINENO: result: no" >&5
28396 $as_echo "no" >&6; }
28397 fi
28398 rm -rf conftest.dSYM
28399 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28400 fi
28401
28402
28403
28404 else
28405   { $as_echo "$as_me:$LINENO: checking if $CC supports -Wl,--as-needed" >&5
28406 $as_echo_n "checking if $CC supports -Wl,--as-needed... " >&6; }
28407 pgac_save_LDFLAGS=$LDFLAGS
28408 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
28409 if test "$cross_compiling" = yes; then
28410   LDFLAGS="$pgac_save_LDFLAGS"
28411                { $as_echo "$as_me:$LINENO: result: assuming no" >&5
28412 $as_echo "assuming no" >&6; }
28413 else
28414   cat >conftest.$ac_ext <<_ACEOF
28415 /* confdefs.h.  */
28416 _ACEOF
28417 cat confdefs.h >>conftest.$ac_ext
28418 cat >>conftest.$ac_ext <<_ACEOF
28419 /* end confdefs.h.  */
28420 extern void $link_test_func (); void (*fptr) () = $link_test_func;
28421 int
28422 main ()
28423 {
28424
28425   ;
28426   return 0;
28427 }
28428 _ACEOF
28429 rm -f conftest$ac_exeext
28430 if { (ac_try="$ac_link"
28431 case "(($ac_try" in
28432   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28433   *) ac_try_echo=$ac_try;;
28434 esac
28435 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28436 $as_echo "$ac_try_echo") >&5
28437   (eval "$ac_link") 2>&5
28438   ac_status=$?
28439   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28440   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28441   { (case "(($ac_try" in
28442   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28443   *) ac_try_echo=$ac_try;;
28444 esac
28445 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28446 $as_echo "$ac_try_echo") >&5
28447   (eval "$ac_try") 2>&5
28448   ac_status=$?
28449   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28450   (exit $ac_status); }; }; then
28451   { $as_echo "$as_me:$LINENO: result: yes" >&5
28452 $as_echo "yes" >&6; }
28453 else
28454   $as_echo "$as_me: program exited with status $ac_status" >&5
28455 $as_echo "$as_me: failed program was:" >&5
28456 sed 's/^/| /' conftest.$ac_ext >&5
28457
28458 ( exit $ac_status )
28459 LDFLAGS="$pgac_save_LDFLAGS"
28460                { $as_echo "$as_me:$LINENO: result: no" >&5
28461 $as_echo "no" >&6; }
28462 fi
28463 rm -rf conftest.dSYM
28464 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28465 fi
28466
28467
28468
28469 fi
28470
28471
28472 # Begin output steps
28473
28474 { $as_echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
28475 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
28476 { $as_echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
28477 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
28478 { $as_echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
28479 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
28480
28481 # Create compiler version string
28482 if test x"$GCC" = x"yes" ; then
28483   cc_string="GCC `${CC} --version | sed q`"
28484 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
28485   cc_string=`${CC} -V 2>&1 | sed q`
28486 else
28487   cc_string=$CC
28488 fi
28489
28490
28491 cat >>confdefs.h <<_ACEOF
28492 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
28493 _ACEOF
28494
28495
28496 # Supply a numeric version string for use by 3rd party add-ons
28497 # awk -F is a regex on some platforms, and not on others, so make "." a tab
28498 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
28499 tr '.' '        ' |
28500 $AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
28501
28502 cat >>confdefs.h <<_ACEOF
28503 #define PG_VERSION_NUM $PG_VERSION_NUM
28504 _ACEOF
28505
28506
28507
28508 # prepare build tree if outside source tree
28509 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
28510 # Note 2: /bin/pwd might be better than shell's built-in at getting
28511 #         a symlink-free name.
28512 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
28513   vpath_build=no
28514 else
28515   vpath_build=yes
28516   if test "$no_create" != yes; then
28517     $as_echo_n "preparing build tree... " >&6
28518     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
28519     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
28520       || { { $as_echo "$as_me:$LINENO: error: failed" >&5
28521 $as_echo "$as_me: error: failed" >&2;}
28522    { (exit 1); exit 1; }; }
28523     { $as_echo "$as_me:$LINENO: result: done" >&5
28524 $as_echo "done" >&6; }
28525   fi
28526 fi
28527
28528
28529
28530 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
28531
28532
28533 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}"
28534
28535
28536 if test "$PORTNAME" = "win32"; then
28537 ac_config_commands="$ac_config_commands check_win32_symlinks"
28538
28539 fi
28540
28541 ac_config_headers="$ac_config_headers src/include/pg_config.h"
28542
28543
28544 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
28545
28546
28547 cat >confcache <<\_ACEOF
28548 # This file is a shell script that caches the results of configure
28549 # tests run on this system so they can be shared between configure
28550 # scripts and configure runs, see configure's option --config-cache.
28551 # It is not useful on other systems.  If it contains results you don't
28552 # want to keep, you may remove or edit it.
28553 #
28554 # config.status only pays attention to the cache file if you give it
28555 # the --recheck option to rerun configure.
28556 #
28557 # `ac_cv_env_foo' variables (set or unset) will be overridden when
28558 # loading this file, other *unset* `ac_cv_foo' will be assigned the
28559 # following values.
28560
28561 _ACEOF
28562
28563 # The following way of writing the cache mishandles newlines in values,
28564 # but we know of no workaround that is simple, portable, and efficient.
28565 # So, we kill variables containing newlines.
28566 # Ultrix sh set writes to stderr and can't be redirected directly,
28567 # and sets the high bit in the cache file unless we assign to the vars.
28568 (
28569   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
28570     eval ac_val=\$$ac_var
28571     case $ac_val in #(
28572     *${as_nl}*)
28573       case $ac_var in #(
28574       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
28575 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
28576       esac
28577       case $ac_var in #(
28578       _ | IFS | as_nl) ;; #(
28579       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
28580       *) $as_unset $ac_var ;;
28581       esac ;;
28582     esac
28583   done
28584
28585   (set) 2>&1 |
28586     case $as_nl`(ac_space=' '; set) 2>&1` in #(
28587     *${as_nl}ac_space=\ *)
28588       # `set' does not quote correctly, so add quotes (double-quote
28589       # substitution turns \\\\ into \\, and sed turns \\ into \).
28590       sed -n \
28591         "s/'/'\\\\''/g;
28592           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
28593       ;; #(
28594     *)
28595       # `set' quotes correctly as required by POSIX, so do not add quotes.
28596       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
28597       ;;
28598     esac |
28599     sort
28600 ) |
28601   sed '
28602      /^ac_cv_env_/b end
28603      t clear
28604      :clear
28605      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
28606      t end
28607      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
28608      :end' >>confcache
28609 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
28610   if test -w "$cache_file"; then
28611     test "x$cache_file" != "x/dev/null" &&
28612       { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
28613 $as_echo "$as_me: updating cache $cache_file" >&6;}
28614     cat confcache >$cache_file
28615   else
28616     { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
28617 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
28618   fi
28619 fi
28620 rm -f confcache
28621
28622 test "x$prefix" = xNONE && prefix=$ac_default_prefix
28623 # Let make expand exec_prefix.
28624 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
28625
28626 DEFS=-DHAVE_CONFIG_H
28627
28628 ac_libobjs=
28629 ac_ltlibobjs=
28630 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
28631   # 1. Remove the extension, and $U if already installed.
28632   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
28633   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
28634   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
28635   #    will be set to the directory where LIBOBJS objects are built.
28636   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
28637   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
28638 done
28639 LIBOBJS=$ac_libobjs
28640
28641 LTLIBOBJS=$ac_ltlibobjs
28642
28643
28644
28645
28646 : ${CONFIG_STATUS=./config.status}
28647 ac_write_fail=0
28648 ac_clean_files_save=$ac_clean_files
28649 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
28650 { $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
28651 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
28652 cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28653 #! $SHELL
28654 # Generated by $as_me.
28655 # Run this file to recreate the current configuration.
28656 # Compiler output produced by configure, useful for debugging
28657 # configure, is in config.log if it exists.
28658
28659 debug=false
28660 ac_cs_recheck=false
28661 ac_cs_silent=false
28662 SHELL=\${CONFIG_SHELL-$SHELL}
28663 _ACEOF
28664
28665 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
28666 ## --------------------- ##
28667 ## M4sh Initialization.  ##
28668 ## --------------------- ##
28669
28670 # Be more Bourne compatible
28671 DUALCASE=1; export DUALCASE # for MKS sh
28672 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
28673   emulate sh
28674   NULLCMD=:
28675   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
28676   # is contrary to our usage.  Disable this feature.
28677   alias -g '${1+"$@"}'='"$@"'
28678   setopt NO_GLOB_SUBST
28679 else
28680   case `(set -o) 2>/dev/null` in
28681   *posix*) set -o posix ;;
28682 esac
28683
28684 fi
28685
28686
28687
28688
28689 # PATH needs CR
28690 # Avoid depending upon Character Ranges.
28691 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
28692 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
28693 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
28694 as_cr_digits='0123456789'
28695 as_cr_alnum=$as_cr_Letters$as_cr_digits
28696
28697 as_nl='
28698 '
28699 export as_nl
28700 # Printing a long string crashes Solaris 7 /usr/bin/printf.
28701 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
28702 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
28703 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
28704 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
28705   as_echo='printf %s\n'
28706   as_echo_n='printf %s'
28707 else
28708   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
28709     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
28710     as_echo_n='/usr/ucb/echo -n'
28711   else
28712     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
28713     as_echo_n_body='eval
28714       arg=$1;
28715       case $arg in
28716       *"$as_nl"*)
28717         expr "X$arg" : "X\\(.*\\)$as_nl";
28718         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
28719       esac;
28720       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
28721     '
28722     export as_echo_n_body
28723     as_echo_n='sh -c $as_echo_n_body as_echo'
28724   fi
28725   export as_echo_body
28726   as_echo='sh -c $as_echo_body as_echo'
28727 fi
28728
28729 # The user is always right.
28730 if test "${PATH_SEPARATOR+set}" != set; then
28731   PATH_SEPARATOR=:
28732   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
28733     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
28734       PATH_SEPARATOR=';'
28735   }
28736 fi
28737
28738 # Support unset when possible.
28739 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
28740   as_unset=unset
28741 else
28742   as_unset=false
28743 fi
28744
28745
28746 # IFS
28747 # We need space, tab and new line, in precisely that order.  Quoting is
28748 # there to prevent editors from complaining about space-tab.
28749 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
28750 # splitting by setting IFS to empty value.)
28751 IFS=" ""        $as_nl"
28752
28753 # Find who we are.  Look in the path if we contain no directory separator.
28754 case $0 in
28755   *[\\/]* ) as_myself=$0 ;;
28756   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28757 for as_dir in $PATH
28758 do
28759   IFS=$as_save_IFS
28760   test -z "$as_dir" && as_dir=.
28761   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
28762 done
28763 IFS=$as_save_IFS
28764
28765      ;;
28766 esac
28767 # We did not find ourselves, most probably we were run as `sh COMMAND'
28768 # in which case we are not to be found in the path.
28769 if test "x$as_myself" = x; then
28770   as_myself=$0
28771 fi
28772 if test ! -f "$as_myself"; then
28773   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
28774   { (exit 1); exit 1; }
28775 fi
28776
28777 # Work around bugs in pre-3.0 UWIN ksh.
28778 for as_var in ENV MAIL MAILPATH
28779 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
28780 done
28781 PS1='$ '
28782 PS2='> '
28783 PS4='+ '
28784
28785 # NLS nuisances.
28786 LC_ALL=C
28787 export LC_ALL
28788 LANGUAGE=C
28789 export LANGUAGE
28790
28791 # Required to use basename.
28792 if expr a : '\(a\)' >/dev/null 2>&1 &&
28793    test "X`expr 00001 : '.*\(...\)'`" = X001; then
28794   as_expr=expr
28795 else
28796   as_expr=false
28797 fi
28798
28799 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
28800   as_basename=basename
28801 else
28802   as_basename=false
28803 fi
28804
28805
28806 # Name of the executable.
28807 as_me=`$as_basename -- "$0" ||
28808 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
28809          X"$0" : 'X\(//\)$' \| \
28810          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
28811 $as_echo X/"$0" |
28812     sed '/^.*\/\([^/][^/]*\)\/*$/{
28813             s//\1/
28814             q
28815           }
28816           /^X\/\(\/\/\)$/{
28817             s//\1/
28818             q
28819           }
28820           /^X\/\(\/\).*/{
28821             s//\1/
28822             q
28823           }
28824           s/.*/./; q'`
28825
28826 # CDPATH.
28827 $as_unset CDPATH
28828
28829
28830
28831   as_lineno_1=$LINENO
28832   as_lineno_2=$LINENO
28833   test "x$as_lineno_1" != "x$as_lineno_2" &&
28834   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
28835
28836   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
28837   # uniformly replaced by the line number.  The first 'sed' inserts a
28838   # line-number line after each line using $LINENO; the second 'sed'
28839   # does the real work.  The second script uses 'N' to pair each
28840   # line-number line with the line containing $LINENO, and appends
28841   # trailing '-' during substitution so that $LINENO is not a special
28842   # case at line end.
28843   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
28844   # scripts with optimization help from Paolo Bonzini.  Blame Lee
28845   # E. McMahon (1931-1989) for sed's syntax.  :-)
28846   sed -n '
28847     p
28848     /[$]LINENO/=
28849   ' <$as_myself |
28850     sed '
28851       s/[$]LINENO.*/&-/
28852       t lineno
28853       b
28854       :lineno
28855       N
28856       :loop
28857       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
28858       t loop
28859       s/-\n.*//
28860     ' >$as_me.lineno &&
28861   chmod +x "$as_me.lineno" ||
28862     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
28863    { (exit 1); exit 1; }; }
28864
28865   # Don't try to exec as it changes $[0], causing all sort of problems
28866   # (the dirname of $[0] is not the place where we might find the
28867   # original and so on.  Autoconf is especially sensitive to this).
28868   . "./$as_me.lineno"
28869   # Exit status is that of the last command.
28870   exit
28871 }
28872
28873
28874 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
28875   as_dirname=dirname
28876 else
28877   as_dirname=false
28878 fi
28879
28880 ECHO_C= ECHO_N= ECHO_T=
28881 case `echo -n x` in
28882 -n*)
28883   case `echo 'x\c'` in
28884   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
28885   *)   ECHO_C='\c';;
28886   esac;;
28887 *)
28888   ECHO_N='-n';;
28889 esac
28890 if expr a : '\(a\)' >/dev/null 2>&1 &&
28891    test "X`expr 00001 : '.*\(...\)'`" = X001; then
28892   as_expr=expr
28893 else
28894   as_expr=false
28895 fi
28896
28897 rm -f conf$$ conf$$.exe conf$$.file
28898 if test -d conf$$.dir; then
28899   rm -f conf$$.dir/conf$$.file
28900 else
28901   rm -f conf$$.dir
28902   mkdir conf$$.dir 2>/dev/null
28903 fi
28904 if (echo >conf$$.file) 2>/dev/null; then
28905   if ln -s conf$$.file conf$$ 2>/dev/null; then
28906     as_ln_s='ln -s'
28907     # ... but there are two gotchas:
28908     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
28909     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
28910     # In both cases, we have to default to `cp -p'.
28911     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
28912       as_ln_s='cp -p'
28913   elif ln conf$$.file conf$$ 2>/dev/null; then
28914     as_ln_s=ln
28915   else
28916     as_ln_s='cp -p'
28917   fi
28918 else
28919   as_ln_s='cp -p'
28920 fi
28921 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
28922 rmdir conf$$.dir 2>/dev/null
28923
28924 if mkdir -p . 2>/dev/null; then
28925   as_mkdir_p=:
28926 else
28927   test -d ./-p && rmdir ./-p
28928   as_mkdir_p=false
28929 fi
28930
28931 if test -x / >/dev/null 2>&1; then
28932   as_test_x='test -x'
28933 else
28934   if ls -dL / >/dev/null 2>&1; then
28935     as_ls_L_option=L
28936   else
28937     as_ls_L_option=
28938   fi
28939   as_test_x='
28940     eval sh -c '\''
28941       if test -d "$1"; then
28942         test -d "$1/.";
28943       else
28944         case $1 in
28945         -*)set "./$1";;
28946         esac;
28947         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
28948         ???[sx]*):;;*)false;;esac;fi
28949     '\'' sh
28950   '
28951 fi
28952 as_executable_p=$as_test_x
28953
28954 # Sed expression to map a string onto a valid CPP name.
28955 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
28956
28957 # Sed expression to map a string onto a valid variable name.
28958 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
28959
28960
28961 exec 6>&1
28962
28963 # Save the log message, to keep $[0] and so on meaningful, and to
28964 # report actual input values of CONFIG_FILES etc. instead of their
28965 # values after options handling.
28966 ac_log="
28967 This file was extended by PostgreSQL $as_me 8.5devel, which was
28968 generated by GNU Autoconf 2.63.  Invocation command line was
28969
28970   CONFIG_FILES    = $CONFIG_FILES
28971   CONFIG_HEADERS  = $CONFIG_HEADERS
28972   CONFIG_LINKS    = $CONFIG_LINKS
28973   CONFIG_COMMANDS = $CONFIG_COMMANDS
28974   $ $0 $@
28975
28976 on `(hostname || uname -n) 2>/dev/null | sed 1q`
28977 "
28978
28979 _ACEOF
28980
28981 case $ac_config_files in *"
28982 "*) set x $ac_config_files; shift; ac_config_files=$*;;
28983 esac
28984
28985 case $ac_config_headers in *"
28986 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
28987 esac
28988
28989
28990 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
28991 # Files that config.status was made for.
28992 config_files="$ac_config_files"
28993 config_headers="$ac_config_headers"
28994 config_links="$ac_config_links"
28995 config_commands="$ac_config_commands"
28996
28997 _ACEOF
28998
28999 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29000 ac_cs_usage="\
29001 \`$as_me' instantiates files from templates according to the
29002 current configuration.
29003
29004 Usage: $0 [OPTION]... [FILE]...
29005
29006   -h, --help       print this help, then exit
29007   -V, --version    print version number and configuration settings, then exit
29008   -q, --quiet, --silent
29009                    do not print progress messages
29010   -d, --debug      don't remove temporary files
29011       --recheck    update $as_me by reconfiguring in the same conditions
29012       --file=FILE[:TEMPLATE]
29013                    instantiate the configuration file FILE
29014       --header=FILE[:TEMPLATE]
29015                    instantiate the configuration header FILE
29016
29017 Configuration files:
29018 $config_files
29019
29020 Configuration headers:
29021 $config_headers
29022
29023 Configuration links:
29024 $config_links
29025
29026 Configuration commands:
29027 $config_commands
29028
29029 Report bugs to <bug-autoconf@gnu.org>."
29030
29031 _ACEOF
29032 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29033 ac_cs_version="\\
29034 PostgreSQL config.status 8.5devel
29035 configured by $0, generated by GNU Autoconf 2.63,
29036   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
29037
29038 Copyright (C) 2008 Free Software Foundation, Inc.
29039 This config.status script is free software; the Free Software Foundation
29040 gives unlimited permission to copy, distribute and modify it."
29041
29042 ac_pwd='$ac_pwd'
29043 srcdir='$srcdir'
29044 MKDIR_P='$MKDIR_P'
29045 AWK='$AWK'
29046 test -n "\$AWK" || AWK=awk
29047 _ACEOF
29048
29049 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29050 # The default lists apply if the user does not specify any file.
29051 ac_need_defaults=:
29052 while test $# != 0
29053 do
29054   case $1 in
29055   --*=*)
29056     ac_option=`expr "X$1" : 'X\([^=]*\)='`
29057     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
29058     ac_shift=:
29059     ;;
29060   *)
29061     ac_option=$1
29062     ac_optarg=$2
29063     ac_shift=shift
29064     ;;
29065   esac
29066
29067   case $ac_option in
29068   # Handling of the options.
29069   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
29070     ac_cs_recheck=: ;;
29071   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
29072     $as_echo "$ac_cs_version"; exit ;;
29073   --debug | --debu | --deb | --de | --d | -d )
29074     debug=: ;;
29075   --file | --fil | --fi | --f )
29076     $ac_shift
29077     case $ac_optarg in
29078     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29079     esac
29080     CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
29081     ac_need_defaults=false;;
29082   --header | --heade | --head | --hea )
29083     $ac_shift
29084     case $ac_optarg in
29085     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29086     esac
29087     CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
29088     ac_need_defaults=false;;
29089   --he | --h)
29090     # Conflict between --help and --header
29091     { $as_echo "$as_me: error: ambiguous option: $1
29092 Try \`$0 --help' for more information." >&2
29093    { (exit 1); exit 1; }; };;
29094   --help | --hel | -h )
29095     $as_echo "$ac_cs_usage"; exit ;;
29096   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
29097   | -silent | --silent | --silen | --sile | --sil | --si | --s)
29098     ac_cs_silent=: ;;
29099
29100   # This is an error.
29101   -*) { $as_echo "$as_me: error: unrecognized option: $1
29102 Try \`$0 --help' for more information." >&2
29103    { (exit 1); exit 1; }; } ;;
29104
29105   *) ac_config_targets="$ac_config_targets $1"
29106      ac_need_defaults=false ;;
29107
29108   esac
29109   shift
29110 done
29111
29112 ac_configure_extra_args=
29113
29114 if $ac_cs_silent; then
29115   exec 6>/dev/null
29116   ac_configure_extra_args="$ac_configure_extra_args --silent"
29117 fi
29118
29119 _ACEOF
29120 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29121 if \$ac_cs_recheck; then
29122   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
29123   shift
29124   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
29125   CONFIG_SHELL='$SHELL'
29126   export CONFIG_SHELL
29127   exec "\$@"
29128 fi
29129
29130 _ACEOF
29131 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29132 exec 5>>config.log
29133 {
29134   echo
29135   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
29136 ## Running $as_me. ##
29137 _ASBOX
29138   $as_echo "$ac_log"
29139 } >&5
29140
29141 _ACEOF
29142 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29143 _ACEOF
29144
29145 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29146
29147 # Handling of arguments.
29148 for ac_config_target in $ac_config_targets
29149 do
29150   case $ac_config_target in
29151     "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
29152     "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
29153     "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
29154     "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
29155     "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
29156     "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
29157     "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
29158     "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
29159     "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
29160     "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
29161     "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
29162     "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
29163
29164   *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
29165 $as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
29166    { (exit 1); exit 1; }; };;
29167   esac
29168 done
29169
29170
29171 # If the user did not use the arguments to specify the items to instantiate,
29172 # then the envvar interface is used.  Set only those that are not.
29173 # We use the long form for the default assignment because of an extremely
29174 # bizarre bug on SunOS 4.1.3.
29175 if $ac_need_defaults; then
29176   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
29177   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
29178   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
29179   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
29180 fi
29181
29182 # Have a temporary directory for convenience.  Make it in the build tree
29183 # simply because there is no reason against having it here, and in addition,
29184 # creating and moving files from /tmp can sometimes cause problems.
29185 # Hook for its removal unless debugging.
29186 # Note that there is a small window in which the directory will not be cleaned:
29187 # after its creation but before its name has been assigned to `$tmp'.
29188 $debug ||
29189 {
29190   tmp=
29191   trap 'exit_status=$?
29192   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
29193 ' 0
29194   trap '{ (exit 1); exit 1; }' 1 2 13 15
29195 }
29196 # Create a (secure) tmp directory for tmp files.
29197
29198 {
29199   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
29200   test -n "$tmp" && test -d "$tmp"
29201 }  ||
29202 {
29203   tmp=./conf$$-$RANDOM
29204   (umask 077 && mkdir "$tmp")
29205 } ||
29206 {
29207    $as_echo "$as_me: cannot create a temporary directory in ." >&2
29208    { (exit 1); exit 1; }
29209 }
29210
29211 # Set up the scripts for CONFIG_FILES section.
29212 # No need to generate them if there are no CONFIG_FILES.
29213 # This happens for instance with `./config.status config.h'.
29214 if test -n "$CONFIG_FILES"; then
29215
29216
29217 ac_cr='\r'
29218 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
29219 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
29220   ac_cs_awk_cr='\\r'
29221 else
29222   ac_cs_awk_cr=$ac_cr
29223 fi
29224
29225 echo 'BEGIN {' >"$tmp/subs1.awk" &&
29226 _ACEOF
29227
29228
29229 {
29230   echo "cat >conf$$subs.awk <<_ACEOF" &&
29231   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
29232   echo "_ACEOF"
29233 } >conf$$subs.sh ||
29234   { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
29235 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
29236    { (exit 1); exit 1; }; }
29237 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
29238 ac_delim='%!_!# '
29239 for ac_last_try in false false false false false :; do
29240   . ./conf$$subs.sh ||
29241     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
29242 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
29243    { (exit 1); exit 1; }; }
29244
29245   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
29246   if test $ac_delim_n = $ac_delim_num; then
29247     break
29248   elif $ac_last_try; then
29249     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
29250 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
29251    { (exit 1); exit 1; }; }
29252   else
29253     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
29254   fi
29255 done
29256 rm -f conf$$subs.sh
29257
29258 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29259 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
29260 _ACEOF
29261 sed -n '
29262 h
29263 s/^/S["/; s/!.*/"]=/
29264 p
29265 g
29266 s/^[^!]*!//
29267 :repl
29268 t repl
29269 s/'"$ac_delim"'$//
29270 t delim
29271 :nl
29272 h
29273 s/\(.\{148\}\).*/\1/
29274 t more1
29275 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
29276 p
29277 n
29278 b repl
29279 :more1
29280 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29281 p
29282 g
29283 s/.\{148\}//
29284 t nl
29285 :delim
29286 h
29287 s/\(.\{148\}\).*/\1/
29288 t more2
29289 s/["\\]/\\&/g; s/^/"/; s/$/"/
29290 p
29291 b
29292 :more2
29293 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
29294 p
29295 g
29296 s/.\{148\}//
29297 t delim
29298 ' <conf$$subs.awk | sed '
29299 /^[^""]/{
29300   N
29301   s/\n//
29302 }
29303 ' >>$CONFIG_STATUS || ac_write_fail=1
29304 rm -f conf$$subs.awk
29305 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29306 _ACAWK
29307 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
29308   for (key in S) S_is_set[key] = 1
29309   FS = "\a"
29310
29311 }
29312 {
29313   line = $ 0
29314   nfields = split(line, field, "@")
29315   substed = 0
29316   len = length(field[1])
29317   for (i = 2; i < nfields; i++) {
29318     key = field[i]
29319     keylen = length(key)
29320     if (S_is_set[key]) {
29321       value = S[key]
29322       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
29323       len += length(value) + length(field[++i])
29324       substed = 1
29325     } else
29326       len += 1 + keylen
29327   }
29328
29329   print line
29330 }
29331
29332 _ACAWK
29333 _ACEOF
29334 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29335 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
29336   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
29337 else
29338   cat
29339 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
29340   || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
29341 $as_echo "$as_me: error: could not setup config files machinery" >&2;}
29342    { (exit 1); exit 1; }; }
29343 _ACEOF
29344
29345 # VPATH may cause trouble with some makes, so we remove $(srcdir),
29346 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
29347 # trailing colons and then remove the whole line if VPATH becomes empty
29348 # (actually we leave an empty line to preserve line numbers).
29349 if test "x$srcdir" = x.; then
29350   ac_vpsub='/^[  ]*VPATH[        ]*=/{
29351 s/:*\$(srcdir):*/:/
29352 s/:*\${srcdir}:*/:/
29353 s/:*@srcdir@:*/:/
29354 s/^\([^=]*=[     ]*\):*/\1/
29355 s/:*$//
29356 s/^[^=]*=[       ]*$//
29357 }'
29358 fi
29359
29360 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29361 fi # test -n "$CONFIG_FILES"
29362
29363 # Set up the scripts for CONFIG_HEADERS section.
29364 # No need to generate them if there are no CONFIG_HEADERS.
29365 # This happens for instance with `./config.status Makefile'.
29366 if test -n "$CONFIG_HEADERS"; then
29367 cat >"$tmp/defines.awk" <<\_ACAWK ||
29368 BEGIN {
29369 _ACEOF
29370
29371 # Transform confdefs.h into an awk script `defines.awk', embedded as
29372 # here-document in config.status, that substitutes the proper values into
29373 # config.h.in to produce config.h.
29374
29375 # Create a delimiter string that does not exist in confdefs.h, to ease
29376 # handling of long lines.
29377 ac_delim='%!_!# '
29378 for ac_last_try in false false :; do
29379   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
29380   if test -z "$ac_t"; then
29381     break
29382   elif $ac_last_try; then
29383     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
29384 $as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
29385    { (exit 1); exit 1; }; }
29386   else
29387     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
29388   fi
29389 done
29390
29391 # For the awk script, D is an array of macro values keyed by name,
29392 # likewise P contains macro parameters if any.  Preserve backslash
29393 # newline sequences.
29394
29395 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
29396 sed -n '
29397 s/.\{148\}/&'"$ac_delim"'/g
29398 t rset
29399 :rset
29400 s/^[     ]*#[    ]*define[       ][      ]*/ /
29401 t def
29402 d
29403 :def
29404 s/\\$//
29405 t bsnl
29406 s/["\\]/\\&/g
29407 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
29408 D["\1"]=" \3"/p
29409 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
29410 d
29411 :bsnl
29412 s/["\\]/\\&/g
29413 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
29414 D["\1"]=" \3\\\\\\n"\\/p
29415 t cont
29416 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
29417 t cont
29418 d
29419 :cont
29420 n
29421 s/.\{148\}/&'"$ac_delim"'/g
29422 t clear
29423 :clear
29424 s/\\$//
29425 t bsnlc
29426 s/["\\]/\\&/g; s/^/"/; s/$/"/p
29427 d
29428 :bsnlc
29429 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
29430 b cont
29431 ' <confdefs.h | sed '
29432 s/'"$ac_delim"'/"\\\
29433 "/g' >>$CONFIG_STATUS || ac_write_fail=1
29434
29435 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29436   for (key in D) D_is_set[key] = 1
29437   FS = "\a"
29438 }
29439 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
29440   line = \$ 0
29441   split(line, arg, " ")
29442   if (arg[1] == "#") {
29443     defundef = arg[2]
29444     mac1 = arg[3]
29445   } else {
29446     defundef = substr(arg[1], 2)
29447     mac1 = arg[2]
29448   }
29449   split(mac1, mac2, "(") #)
29450   macro = mac2[1]
29451   prefix = substr(line, 1, index(line, defundef) - 1)
29452   if (D_is_set[macro]) {
29453     # Preserve the white space surrounding the "#".
29454     print prefix "define", macro P[macro] D[macro]
29455     next
29456   } else {
29457     # Replace #undef with comments.  This is necessary, for example,
29458     # in the case of _POSIX_SOURCE, which is predefined and required
29459     # on some systems where configure will not decide to define it.
29460     if (defundef == "undef") {
29461       print "/*", prefix defundef, macro, "*/"
29462       next
29463     }
29464   }
29465 }
29466 { print }
29467 _ACAWK
29468 _ACEOF
29469 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29470   { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
29471 $as_echo "$as_me: error: could not setup config headers machinery" >&2;}
29472    { (exit 1); exit 1; }; }
29473 fi # test -n "$CONFIG_HEADERS"
29474
29475
29476 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
29477 shift
29478 for ac_tag
29479 do
29480   case $ac_tag in
29481   :[FHLC]) ac_mode=$ac_tag; continue;;
29482   esac
29483   case $ac_mode$ac_tag in
29484   :[FHL]*:*);;
29485   :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
29486 $as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
29487    { (exit 1); exit 1; }; };;
29488   :[FH]-) ac_tag=-:-;;
29489   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
29490   esac
29491   ac_save_IFS=$IFS
29492   IFS=:
29493   set x $ac_tag
29494   IFS=$ac_save_IFS
29495   shift
29496   ac_file=$1
29497   shift
29498
29499   case $ac_mode in
29500   :L) ac_source=$1;;
29501   :[FH])
29502     ac_file_inputs=
29503     for ac_f
29504     do
29505       case $ac_f in
29506       -) ac_f="$tmp/stdin";;
29507       *) # Look for the file first in the build tree, then in the source tree
29508          # (if the path is not absolute).  The absolute path cannot be DOS-style,
29509          # because $ac_f cannot contain `:'.
29510          test -f "$ac_f" ||
29511            case $ac_f in
29512            [\\/$]*) false;;
29513            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
29514            esac ||
29515            { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
29516 $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
29517    { (exit 1); exit 1; }; };;
29518       esac
29519       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
29520       ac_file_inputs="$ac_file_inputs '$ac_f'"
29521     done
29522
29523     # Let's still pretend it is `configure' which instantiates (i.e., don't
29524     # use $as_me), people would be surprised to read:
29525     #    /* config.h.  Generated by config.status.  */
29526     configure_input='Generated from '`
29527           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
29528         `' by configure.'
29529     if test x"$ac_file" != x-; then
29530       configure_input="$ac_file.  $configure_input"
29531       { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
29532 $as_echo "$as_me: creating $ac_file" >&6;}
29533     fi
29534     # Neutralize special characters interpreted by sed in replacement strings.
29535     case $configure_input in #(
29536     *\&* | *\|* | *\\* )
29537        ac_sed_conf_input=`$as_echo "$configure_input" |
29538        sed 's/[\\\\&|]/\\\\&/g'`;; #(
29539     *) ac_sed_conf_input=$configure_input;;
29540     esac
29541
29542     case $ac_tag in
29543     *:-:* | *:-) cat >"$tmp/stdin" \
29544       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
29545 $as_echo "$as_me: error: could not create $ac_file" >&2;}
29546    { (exit 1); exit 1; }; } ;;
29547     esac
29548     ;;
29549   esac
29550
29551   ac_dir=`$as_dirname -- "$ac_file" ||
29552 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29553          X"$ac_file" : 'X\(//\)[^/]' \| \
29554          X"$ac_file" : 'X\(//\)$' \| \
29555          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
29556 $as_echo X"$ac_file" |
29557     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29558             s//\1/
29559             q
29560           }
29561           /^X\(\/\/\)[^/].*/{
29562             s//\1/
29563             q
29564           }
29565           /^X\(\/\/\)$/{
29566             s//\1/
29567             q
29568           }
29569           /^X\(\/\).*/{
29570             s//\1/
29571             q
29572           }
29573           s/.*/./; q'`
29574   { as_dir="$ac_dir"
29575   case $as_dir in #(
29576   -*) as_dir=./$as_dir;;
29577   esac
29578   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
29579     as_dirs=
29580     while :; do
29581       case $as_dir in #(
29582       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
29583       *) as_qdir=$as_dir;;
29584       esac
29585       as_dirs="'$as_qdir' $as_dirs"
29586       as_dir=`$as_dirname -- "$as_dir" ||
29587 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
29588          X"$as_dir" : 'X\(//\)[^/]' \| \
29589          X"$as_dir" : 'X\(//\)$' \| \
29590          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
29591 $as_echo X"$as_dir" |
29592     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
29593             s//\1/
29594             q
29595           }
29596           /^X\(\/\/\)[^/].*/{
29597             s//\1/
29598             q
29599           }
29600           /^X\(\/\/\)$/{
29601             s//\1/
29602             q
29603           }
29604           /^X\(\/\).*/{
29605             s//\1/
29606             q
29607           }
29608           s/.*/./; q'`
29609       test -d "$as_dir" && break
29610     done
29611     test -z "$as_dirs" || eval "mkdir $as_dirs"
29612   } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
29613 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
29614    { (exit 1); exit 1; }; }; }
29615   ac_builddir=.
29616
29617 case "$ac_dir" in
29618 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
29619 *)
29620   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
29621   # A ".." for each directory in $ac_dir_suffix.
29622   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
29623   case $ac_top_builddir_sub in
29624   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
29625   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
29626   esac ;;
29627 esac
29628 ac_abs_top_builddir=$ac_pwd
29629 ac_abs_builddir=$ac_pwd$ac_dir_suffix
29630 # for backward compatibility:
29631 ac_top_builddir=$ac_top_build_prefix
29632
29633 case $srcdir in
29634   .)  # We are building in place.
29635     ac_srcdir=.
29636     ac_top_srcdir=$ac_top_builddir_sub
29637     ac_abs_top_srcdir=$ac_pwd ;;
29638   [\\/]* | ?:[\\/]* )  # Absolute name.
29639     ac_srcdir=$srcdir$ac_dir_suffix;
29640     ac_top_srcdir=$srcdir
29641     ac_abs_top_srcdir=$srcdir ;;
29642   *) # Relative name.
29643     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
29644     ac_top_srcdir=$ac_top_build_prefix$srcdir
29645     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
29646 esac
29647 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
29648
29649
29650   case $ac_mode in
29651   :F)
29652   #
29653   # CONFIG_FILE
29654   #
29655
29656   ac_MKDIR_P=$MKDIR_P
29657   case $MKDIR_P in
29658   [\\/$]* | ?:[\\/]* ) ;;
29659   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
29660   esac
29661 _ACEOF
29662
29663 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29664 # If the template does not know about datarootdir, expand it.
29665 # FIXME: This hack should be removed a few years after 2.60.
29666 ac_datarootdir_hack=; ac_datarootdir_seen=
29667
29668 ac_sed_dataroot='
29669 /datarootdir/ {
29670   p
29671   q
29672 }
29673 /@datadir@/p
29674 /@docdir@/p
29675 /@infodir@/p
29676 /@localedir@/p
29677 /@mandir@/p
29678 '
29679 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
29680 *datarootdir*) ac_datarootdir_seen=yes;;
29681 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
29682   { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
29683 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
29684 _ACEOF
29685 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29686   ac_datarootdir_hack='
29687   s&@datadir@&$datadir&g
29688   s&@docdir@&$docdir&g
29689   s&@infodir@&$infodir&g
29690   s&@localedir@&$localedir&g
29691   s&@mandir@&$mandir&g
29692     s&\\\${datarootdir}&$datarootdir&g' ;;
29693 esac
29694 _ACEOF
29695
29696 # Neutralize VPATH when `$srcdir' = `.'.
29697 # Shell code in configure.ac might set extrasub.
29698 # FIXME: do we really want to maintain this feature?
29699 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29700 ac_sed_extra="$ac_vpsub
29701 $extrasub
29702 _ACEOF
29703 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29704 :t
29705 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
29706 s|@configure_input@|$ac_sed_conf_input|;t t
29707 s&@top_builddir@&$ac_top_builddir_sub&;t t
29708 s&@top_build_prefix@&$ac_top_build_prefix&;t t
29709 s&@srcdir@&$ac_srcdir&;t t
29710 s&@abs_srcdir@&$ac_abs_srcdir&;t t
29711 s&@top_srcdir@&$ac_top_srcdir&;t t
29712 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
29713 s&@builddir@&$ac_builddir&;t t
29714 s&@abs_builddir@&$ac_abs_builddir&;t t
29715 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
29716 s&@MKDIR_P@&$ac_MKDIR_P&;t t
29717 $ac_datarootdir_hack
29718 "
29719 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
29720   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
29721 $as_echo "$as_me: error: could not create $ac_file" >&2;}
29722    { (exit 1); exit 1; }; }
29723
29724 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
29725   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
29726   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
29727   { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
29728 which seems to be undefined.  Please make sure it is defined." >&5
29729 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
29730 which seems to be undefined.  Please make sure it is defined." >&2;}
29731
29732   rm -f "$tmp/stdin"
29733   case $ac_file in
29734   -) cat "$tmp/out" && rm -f "$tmp/out";;
29735   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
29736   esac \
29737   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
29738 $as_echo "$as_me: error: could not create $ac_file" >&2;}
29739    { (exit 1); exit 1; }; }
29740  ;;
29741   :H)
29742   #
29743   # CONFIG_HEADER
29744   #
29745   if test x"$ac_file" != x-; then
29746     {
29747       $as_echo "/* $configure_input  */" \
29748       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
29749     } >"$tmp/config.h" \
29750       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
29751 $as_echo "$as_me: error: could not create $ac_file" >&2;}
29752    { (exit 1); exit 1; }; }
29753     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
29754       { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
29755 $as_echo "$as_me: $ac_file is unchanged" >&6;}
29756     else
29757       rm -f "$ac_file"
29758       mv "$tmp/config.h" "$ac_file" \
29759         || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
29760 $as_echo "$as_me: error: could not create $ac_file" >&2;}
29761    { (exit 1); exit 1; }; }
29762     fi
29763   else
29764     $as_echo "/* $configure_input  */" \
29765       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
29766       || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
29767 $as_echo "$as_me: error: could not create -" >&2;}
29768    { (exit 1); exit 1; }; }
29769   fi
29770  ;;
29771   :L)
29772   #
29773   # CONFIG_LINK
29774   #
29775
29776   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
29777     :
29778   else
29779     # Prefer the file from the source tree if names are identical.
29780     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
29781       ac_source=$srcdir/$ac_source
29782     fi
29783
29784     { $as_echo "$as_me:$LINENO: linking $ac_source to $ac_file" >&5
29785 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
29786
29787     if test ! -r "$ac_source"; then
29788       { { $as_echo "$as_me:$LINENO: error: $ac_source: file not found" >&5
29789 $as_echo "$as_me: error: $ac_source: file not found" >&2;}
29790    { (exit 1); exit 1; }; }
29791     fi
29792     rm -f "$ac_file"
29793
29794     # Try a relative symlink, then a hard link, then a copy.
29795     case $srcdir in
29796     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
29797         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
29798     esac
29799     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
29800       ln "$ac_source" "$ac_file" 2>/dev/null ||
29801       cp -p "$ac_source" "$ac_file" ||
29802       { { $as_echo "$as_me:$LINENO: error: cannot link or copy $ac_source to $ac_file" >&5
29803 $as_echo "$as_me: error: cannot link or copy $ac_source to $ac_file" >&2;}
29804    { (exit 1); exit 1; }; }
29805   fi
29806  ;;
29807   :C)  { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
29808 $as_echo "$as_me: executing $ac_file commands" >&6;}
29809  ;;
29810   esac
29811
29812
29813   case $ac_file$ac_mode in
29814     "check_win32_symlinks":C)
29815 # Links sometimes fail undetected on Mingw -
29816 # so here we detect it and warn the user
29817 for FILE in $CONFIG_LINKS
29818  do
29819         # test -e works for symlinks in the MinGW console
29820         test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
29821 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
29822  done
29823  ;;
29824     "src/include/pg_config.h":H)
29825 # Update timestamp for pg_config.h (see Makefile.global)
29826 echo >src/include/stamp-h
29827  ;;
29828     "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
29829
29830   esac
29831 done # for ac_tag
29832
29833
29834 { (exit 0); exit 0; }
29835 _ACEOF
29836 chmod +x $CONFIG_STATUS
29837 ac_clean_files=$ac_clean_files_save
29838
29839 test $ac_write_fail = 0 ||
29840   { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
29841 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
29842    { (exit 1); exit 1; }; }
29843
29844
29845 # configure is writing to config.log, and then calls config.status.
29846 # config.status does its own redirection, appending to config.log.
29847 # Unfortunately, on DOS this fails, as config.log is still kept open
29848 # by configure, so config.status won't be able to write to it; its
29849 # output is simply discarded.  So we exec the FD to /dev/null,
29850 # effectively closing config.log, so it can be properly (re)opened and
29851 # appended to by config.status.  When coming back to configure, we
29852 # need to make the FD available again.
29853 if test "$no_create" != yes; then
29854   ac_cs_success=:
29855   ac_config_status_args=
29856   test "$silent" = yes &&
29857     ac_config_status_args="$ac_config_status_args --quiet"
29858   exec 5>/dev/null
29859   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
29860   exec 5>>config.log
29861   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
29862   # would make configure fail if this is the last instruction.
29863   $ac_cs_success || { (exit 1); exit 1; }
29864 fi
29865 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
29866   { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
29867 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
29868 fi
29869