]> granicus.if.org Git - postgresql/blob - configure
Since we only use libld on AIX, don't include it in LIBS on any other
[postgresql] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.59 for PostgreSQL 8.2devel.
4 #
5 # Report bugs to <pgsql-bugs@postgresql.org>.
6 #
7 # Copyright (C) 2003 Free Software Foundation, Inc.
8 # This configure script is free software; the Free Software Foundation
9 # gives unlimited permission to copy, distribute and modify it.
10 #
11 # Copyright (c) 1996-2005, PostgreSQL Global Development Group
12 ## --------------------- ##
13 ## M4sh Initialization.  ##
14 ## --------------------- ##
15
16 # Be Bourne compatible
17 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
18   emulate sh
19   NULLCMD=:
20   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
21   # is contrary to our usage.  Disable this feature.
22   alias -g '${1+"$@"}'='"$@"'
23 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
24   set -o posix
25 fi
26 DUALCASE=1; export DUALCASE # for MKS sh
27
28 # Support unset when possible.
29 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
30   as_unset=unset
31 else
32   as_unset=false
33 fi
34
35
36 # Work around bugs in pre-3.0 UWIN ksh.
37 $as_unset ENV MAIL MAILPATH
38 PS1='$ '
39 PS2='> '
40 PS4='+ '
41
42 # NLS nuisances.
43 for as_var in \
44   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
45   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
46   LC_TELEPHONE LC_TIME
47 do
48   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
49     eval $as_var=C; export $as_var
50   else
51     $as_unset $as_var
52   fi
53 done
54
55 # Required to use basename.
56 if expr a : '\(a\)' >/dev/null 2>&1; then
57   as_expr=expr
58 else
59   as_expr=false
60 fi
61
62 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
63   as_basename=basename
64 else
65   as_basename=false
66 fi
67
68
69 # Name of the executable.
70 as_me=`$as_basename "$0" ||
71 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
72          X"$0" : 'X\(//\)$' \| \
73          X"$0" : 'X\(/\)$' \| \
74          .     : '\(.\)' 2>/dev/null ||
75 echo X/"$0" |
76     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
77           /^X\/\(\/\/\)$/{ s//\1/; q; }
78           /^X\/\(\/\).*/{ s//\1/; q; }
79           s/.*/./; q'`
80
81
82 # PATH needs CR, and LINENO needs CR and PATH.
83 # Avoid depending upon Character Ranges.
84 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
85 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
86 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
87 as_cr_digits='0123456789'
88 as_cr_alnum=$as_cr_Letters$as_cr_digits
89
90 # The user is always right.
91 if test "${PATH_SEPARATOR+set}" != set; then
92   echo "#! /bin/sh" >conf$$.sh
93   echo  "exit 0"   >>conf$$.sh
94   chmod +x conf$$.sh
95   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
96     PATH_SEPARATOR=';'
97   else
98     PATH_SEPARATOR=:
99   fi
100   rm -f conf$$.sh
101 fi
102
103
104   as_lineno_1=$LINENO
105   as_lineno_2=$LINENO
106   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
107   test "x$as_lineno_1" != "x$as_lineno_2" &&
108   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
109   # Find who we are.  Look in the path if we contain no path at all
110   # relative or not.
111   case $0 in
112     *[\\/]* ) as_myself=$0 ;;
113     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
114 for as_dir in $PATH
115 do
116   IFS=$as_save_IFS
117   test -z "$as_dir" && as_dir=.
118   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
119 done
120
121        ;;
122   esac
123   # We did not find ourselves, most probably we were run as `sh COMMAND'
124   # in which case we are not to be found in the path.
125   if test "x$as_myself" = x; then
126     as_myself=$0
127   fi
128   if test ! -f "$as_myself"; then
129     { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
130    { (exit 1); exit 1; }; }
131   fi
132   case $CONFIG_SHELL in
133   '')
134     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
135 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
136 do
137   IFS=$as_save_IFS
138   test -z "$as_dir" && as_dir=.
139   for as_base in sh bash ksh sh5; do
140          case $as_dir in
141          /*)
142            if ("$as_dir/$as_base" -c '
143   as_lineno_1=$LINENO
144   as_lineno_2=$LINENO
145   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
146   test "x$as_lineno_1" != "x$as_lineno_2" &&
147   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
148              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
149              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
150              CONFIG_SHELL=$as_dir/$as_base
151              export CONFIG_SHELL
152              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
153            fi;;
154          esac
155        done
156 done
157 ;;
158   esac
159
160   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
161   # uniformly replaced by the line number.  The first 'sed' inserts a
162   # line-number line before each line; the second 'sed' does the real
163   # work.  The second script uses 'N' to pair each line-number line
164   # with the numbered line, and appends trailing '-' during
165   # substitution so that $LINENO is not a special case at line end.
166   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
167   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
168   sed '=' <$as_myself |
169     sed '
170       N
171       s,$,-,
172       : loop
173       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
174       t loop
175       s,-$,,
176       s,^['$as_cr_digits']*\n,,
177     ' >$as_me.lineno &&
178   chmod +x $as_me.lineno ||
179     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
180    { (exit 1); exit 1; }; }
181
182   # Don't try to exec as it changes $[0], causing all sort of problems
183   # (the dirname of $[0] is not the place where we might find the
184   # original and so on.  Autoconf is especially sensible to this).
185   . ./$as_me.lineno
186   # Exit status is that of the last command.
187   exit
188 }
189
190
191 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
192   *c*,-n*) ECHO_N= ECHO_C='
193 ' ECHO_T='      ' ;;
194   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
195   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
196 esac
197
198 if expr a : '\(a\)' >/dev/null 2>&1; then
199   as_expr=expr
200 else
201   as_expr=false
202 fi
203
204 rm -f conf$$ conf$$.exe conf$$.file
205 echo >conf$$.file
206 if ln -s conf$$.file conf$$ 2>/dev/null; then
207   # We could just check for DJGPP; but this test a) works b) is more generic
208   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
209   if test -f conf$$.exe; then
210     # Don't use ln at all; we don't have any links
211     as_ln_s='cp -p'
212   else
213     as_ln_s='ln -s'
214   fi
215 elif ln conf$$.file conf$$ 2>/dev/null; then
216   as_ln_s=ln
217 else
218   as_ln_s='cp -p'
219 fi
220 rm -f conf$$ conf$$.exe conf$$.file
221
222 if mkdir -p . 2>/dev/null; then
223   as_mkdir_p=:
224 else
225   test -d ./-p && rmdir ./-p
226   as_mkdir_p=false
227 fi
228
229 as_executable_p="test -f"
230
231 # Sed expression to map a string onto a valid CPP name.
232 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
233
234 # Sed expression to map a string onto a valid variable name.
235 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
236
237
238 # IFS
239 # We need space, tab and new line, in precisely that order.
240 as_nl='
241 '
242 IFS="   $as_nl"
243
244 # CDPATH.
245 $as_unset CDPATH
246
247
248 # Name of the host.
249 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
250 # so uname gets run too.
251 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
252
253 exec 6>&1
254
255 #
256 # Initializations.
257 #
258 ac_default_prefix=/usr/local
259 ac_config_libobj_dir=.
260 cross_compiling=no
261 subdirs=
262 MFLAGS=
263 MAKEFLAGS=
264 SHELL=${CONFIG_SHELL-/bin/sh}
265
266 # Maximum number of lines to put in a shell here document.
267 # This variable seems obsolete.  It should probably be removed, and
268 # only ac_max_sed_lines should be used.
269 : ${ac_max_here_lines=38}
270
271 # Identity of this package.
272 PACKAGE_NAME='PostgreSQL'
273 PACKAGE_TARNAME='postgresql'
274 PACKAGE_VERSION='8.2devel'
275 PACKAGE_STRING='PostgreSQL 8.2devel'
276 PACKAGE_BUGREPORT='pgsql-bugs@postgresql.org'
277
278 ac_unique_file="src/backend/access/common/heaptuple.c"
279 ac_default_prefix=/usr/local/pgsql
280 # Factoring default headers for most tests.
281 ac_includes_default="\
282 #include <stdio.h>
283 #if HAVE_SYS_TYPES_H
284 # include <sys/types.h>
285 #endif
286 #if HAVE_SYS_STAT_H
287 # include <sys/stat.h>
288 #endif
289 #if STDC_HEADERS
290 # include <stdlib.h>
291 # include <stddef.h>
292 #else
293 # if HAVE_STDLIB_H
294 #  include <stdlib.h>
295 # endif
296 #endif
297 #if HAVE_STRING_H
298 # if !STDC_HEADERS && HAVE_MEMORY_H
299 #  include <memory.h>
300 # endif
301 # include <string.h>
302 #endif
303 #if HAVE_STRINGS_H
304 # include <strings.h>
305 #endif
306 #if HAVE_INTTYPES_H
307 # include <inttypes.h>
308 #else
309 # if HAVE_STDINT_H
310 #  include <stdint.h>
311 # endif
312 #endif
313 #if HAVE_UNISTD_H
314 # include <unistd.h>
315 #endif"
316
317 ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS configure_args build build_cpu build_vendor build_os host host_cpu host_vendor host_os PORTNAME docdir enable_nls WANTED_LANGUAGES default_port enable_shared enable_rpath enable_debug CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP GCC TAS autodepend INCLUDES enable_thread_safety with_tcl with_perl with_python with_krb5 krb_srvtab with_pam with_bonjour with_openssl with_zlib EGREP ELF_SYS LDFLAGS_SL AWK FLEX FLEXFLAGS LN_S LD with_gnu_ld ld_R_works RANLIB ac_ct_RANLIB LORDER TAR STRIP ac_ct_STRIP STRIP_STATIC_LIB STRIP_SHARED_LIB YACC YFLAGS PERL perl_archlibexp perl_privlibexp perl_useshrplib perl_embed_ldflags PYTHON python_version python_configdir python_includespec python_libdir python_libspec python_additional_libs HAVE_IPV6 LIBOBJS acx_pthread_config PTHREAD_CC PTHREAD_LIBS PTHREAD_CFLAGS HAVE_POSIX_SIGNALS MSGFMT MSGMERGE XGETTEXT localedir TCLSH TCL_CONFIG_SH TCL_INCLUDE_SPEC TCL_LIB_FILE TCL_LIBS TCL_LIB_SPEC TCL_SHARED_BUILD TCL_SHLIB_LD_LIBS NSGMLS JADE have_docbook DOCBOOKSTYLE COLLATEINDEX SGMLSPL vpath_build LTLIBOBJS'
318 ac_subst_files=''
319
320 # Initialize some variables set by options.
321 ac_init_help=
322 ac_init_version=false
323 # The variables have the same names as the options, with
324 # dashes changed to underlines.
325 cache_file=/dev/null
326 exec_prefix=NONE
327 no_create=
328 no_recursion=
329 prefix=NONE
330 program_prefix=NONE
331 program_suffix=NONE
332 program_transform_name=s,x,x,
333 silent=
334 site=
335 srcdir=
336 verbose=
337 x_includes=NONE
338 x_libraries=NONE
339
340 # Installation directory options.
341 # These are left unexpanded so users can "make install exec_prefix=/foo"
342 # and all the variables that are supposed to be based on exec_prefix
343 # by default will actually change.
344 # Use braces instead of parens because sh, perl, etc. also accept them.
345 bindir='${exec_prefix}/bin'
346 sbindir='${exec_prefix}/sbin'
347 libexecdir='${exec_prefix}/libexec'
348 datadir='${prefix}/share'
349 sysconfdir='${prefix}/etc'
350 sharedstatedir='${prefix}/com'
351 localstatedir='${prefix}/var'
352 libdir='${exec_prefix}/lib'
353 includedir='${prefix}/include'
354 oldincludedir='/usr/include'
355 infodir='${prefix}/info'
356 mandir='${prefix}/man'
357
358 ac_prev=
359 for ac_option
360 do
361   # If the previous option needs an argument, assign it.
362   if test -n "$ac_prev"; then
363     eval "$ac_prev=\$ac_option"
364     ac_prev=
365     continue
366   fi
367
368   ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
369
370   # Accept the important Cygnus configure options, so we can diagnose typos.
371
372   case $ac_option in
373
374   -bindir | --bindir | --bindi | --bind | --bin | --bi)
375     ac_prev=bindir ;;
376   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
377     bindir=$ac_optarg ;;
378
379   -build | --build | --buil | --bui | --bu)
380     ac_prev=build_alias ;;
381   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
382     build_alias=$ac_optarg ;;
383
384   -cache-file | --cache-file | --cache-fil | --cache-fi \
385   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
386     ac_prev=cache_file ;;
387   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
388   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
389     cache_file=$ac_optarg ;;
390
391   --config-cache | -C)
392     cache_file=config.cache ;;
393
394   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
395     ac_prev=datadir ;;
396   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
397   | --da=*)
398     datadir=$ac_optarg ;;
399
400   -disable-* | --disable-*)
401     ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
402     # Reject names that are not valid shell variable names.
403     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
404       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
405    { (exit 1); exit 1; }; }
406     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
407     eval "enable_$ac_feature=no" ;;
408
409   -enable-* | --enable-*)
410     ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
411     # Reject names that are not valid shell variable names.
412     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
413       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
414    { (exit 1); exit 1; }; }
415     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
416     case $ac_option in
417       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
418       *) ac_optarg=yes ;;
419     esac
420     eval "enable_$ac_feature='$ac_optarg'" ;;
421
422   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
423   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
424   | --exec | --exe | --ex)
425     ac_prev=exec_prefix ;;
426   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
427   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
428   | --exec=* | --exe=* | --ex=*)
429     exec_prefix=$ac_optarg ;;
430
431   -gas | --gas | --ga | --g)
432     # Obsolete; use --with-gas.
433     with_gas=yes ;;
434
435   -help | --help | --hel | --he | -h)
436     ac_init_help=long ;;
437   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
438     ac_init_help=recursive ;;
439   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
440     ac_init_help=short ;;
441
442   -host | --host | --hos | --ho)
443     ac_prev=host_alias ;;
444   -host=* | --host=* | --hos=* | --ho=*)
445     host_alias=$ac_optarg ;;
446
447   -includedir | --includedir | --includedi | --included | --include \
448   | --includ | --inclu | --incl | --inc)
449     ac_prev=includedir ;;
450   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
451   | --includ=* | --inclu=* | --incl=* | --inc=*)
452     includedir=$ac_optarg ;;
453
454   -infodir | --infodir | --infodi | --infod | --info | --inf)
455     ac_prev=infodir ;;
456   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
457     infodir=$ac_optarg ;;
458
459   -libdir | --libdir | --libdi | --libd)
460     ac_prev=libdir ;;
461   -libdir=* | --libdir=* | --libdi=* | --libd=*)
462     libdir=$ac_optarg ;;
463
464   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
465   | --libexe | --libex | --libe)
466     ac_prev=libexecdir ;;
467   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
468   | --libexe=* | --libex=* | --libe=*)
469     libexecdir=$ac_optarg ;;
470
471   -localstatedir | --localstatedir | --localstatedi | --localstated \
472   | --localstate | --localstat | --localsta | --localst \
473   | --locals | --local | --loca | --loc | --lo)
474     ac_prev=localstatedir ;;
475   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
476   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
477   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
478     localstatedir=$ac_optarg ;;
479
480   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
481     ac_prev=mandir ;;
482   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
483     mandir=$ac_optarg ;;
484
485   -nfp | --nfp | --nf)
486     # Obsolete; use --without-fp.
487     with_fp=no ;;
488
489   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
490   | --no-cr | --no-c | -n)
491     no_create=yes ;;
492
493   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
494   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
495     no_recursion=yes ;;
496
497   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
498   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
499   | --oldin | --oldi | --old | --ol | --o)
500     ac_prev=oldincludedir ;;
501   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
502   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
503   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
504     oldincludedir=$ac_optarg ;;
505
506   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
507     ac_prev=prefix ;;
508   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
509     prefix=$ac_optarg ;;
510
511   -program-prefix | --program-prefix | --program-prefi | --program-pref \
512   | --program-pre | --program-pr | --program-p)
513     ac_prev=program_prefix ;;
514   -program-prefix=* | --program-prefix=* | --program-prefi=* \
515   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
516     program_prefix=$ac_optarg ;;
517
518   -program-suffix | --program-suffix | --program-suffi | --program-suff \
519   | --program-suf | --program-su | --program-s)
520     ac_prev=program_suffix ;;
521   -program-suffix=* | --program-suffix=* | --program-suffi=* \
522   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
523     program_suffix=$ac_optarg ;;
524
525   -program-transform-name | --program-transform-name \
526   | --program-transform-nam | --program-transform-na \
527   | --program-transform-n | --program-transform- \
528   | --program-transform | --program-transfor \
529   | --program-transfo | --program-transf \
530   | --program-trans | --program-tran \
531   | --progr-tra | --program-tr | --program-t)
532     ac_prev=program_transform_name ;;
533   -program-transform-name=* | --program-transform-name=* \
534   | --program-transform-nam=* | --program-transform-na=* \
535   | --program-transform-n=* | --program-transform-=* \
536   | --program-transform=* | --program-transfor=* \
537   | --program-transfo=* | --program-transf=* \
538   | --program-trans=* | --program-tran=* \
539   | --progr-tra=* | --program-tr=* | --program-t=*)
540     program_transform_name=$ac_optarg ;;
541
542   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
543   | -silent | --silent | --silen | --sile | --sil)
544     silent=yes ;;
545
546   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
547     ac_prev=sbindir ;;
548   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
549   | --sbi=* | --sb=*)
550     sbindir=$ac_optarg ;;
551
552   -sharedstatedir | --sharedstatedir | --sharedstatedi \
553   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
554   | --sharedst | --shareds | --shared | --share | --shar \
555   | --sha | --sh)
556     ac_prev=sharedstatedir ;;
557   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
558   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
559   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
560   | --sha=* | --sh=*)
561     sharedstatedir=$ac_optarg ;;
562
563   -site | --site | --sit)
564     ac_prev=site ;;
565   -site=* | --site=* | --sit=*)
566     site=$ac_optarg ;;
567
568   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
569     ac_prev=srcdir ;;
570   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
571     srcdir=$ac_optarg ;;
572
573   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
574   | --syscon | --sysco | --sysc | --sys | --sy)
575     ac_prev=sysconfdir ;;
576   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
577   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
578     sysconfdir=$ac_optarg ;;
579
580   -target | --target | --targe | --targ | --tar | --ta | --t)
581     ac_prev=target_alias ;;
582   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
583     target_alias=$ac_optarg ;;
584
585   -v | -verbose | --verbose | --verbos | --verbo | --verb)
586     verbose=yes ;;
587
588   -version | --version | --versio | --versi | --vers | -V)
589     ac_init_version=: ;;
590
591   -with-* | --with-*)
592     ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
593     # Reject names that are not valid shell variable names.
594     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
595       { echo "$as_me: error: invalid package name: $ac_package" >&2
596    { (exit 1); exit 1; }; }
597     ac_package=`echo $ac_package| sed 's/-/_/g'`
598     case $ac_option in
599       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
600       *) ac_optarg=yes ;;
601     esac
602     eval "with_$ac_package='$ac_optarg'" ;;
603
604   -without-* | --without-*)
605     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
606     # Reject names that are not valid shell variable names.
607     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
608       { echo "$as_me: error: invalid package name: $ac_package" >&2
609    { (exit 1); exit 1; }; }
610     ac_package=`echo $ac_package | sed 's/-/_/g'`
611     eval "with_$ac_package=no" ;;
612
613   --x)
614     # Obsolete; use --with-x.
615     with_x=yes ;;
616
617   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
618   | --x-incl | --x-inc | --x-in | --x-i)
619     ac_prev=x_includes ;;
620   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
621   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
622     x_includes=$ac_optarg ;;
623
624   -x-libraries | --x-libraries | --x-librarie | --x-librari \
625   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
626     ac_prev=x_libraries ;;
627   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
628   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
629     x_libraries=$ac_optarg ;;
630
631   -*) { echo "$as_me: error: unrecognized option: $ac_option
632 Try \`$0 --help' for more information." >&2
633    { (exit 1); exit 1; }; }
634     ;;
635
636   *=*)
637     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
638     # Reject names that are not valid shell variable names.
639     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
640       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
641    { (exit 1); exit 1; }; }
642     ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
643     eval "$ac_envvar='$ac_optarg'"
644     export $ac_envvar ;;
645
646   *)
647     # FIXME: should be removed in autoconf 3.0.
648     echo "$as_me: WARNING: you should use --build, --host, --target" >&2
649     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
650       echo "$as_me: WARNING: invalid host type: $ac_option" >&2
651     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
652     ;;
653
654   esac
655 done
656
657 if test -n "$ac_prev"; then
658   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
659   { echo "$as_me: error: missing argument to $ac_option" >&2
660    { (exit 1); exit 1; }; }
661 fi
662
663 # Be sure to have absolute paths.
664 for ac_var in exec_prefix prefix
665 do
666   eval ac_val=$`echo $ac_var`
667   case $ac_val in
668     [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
669     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
670    { (exit 1); exit 1; }; };;
671   esac
672 done
673
674 # Be sure to have absolute paths.
675 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
676               localstatedir libdir includedir oldincludedir infodir mandir
677 do
678   eval ac_val=$`echo $ac_var`
679   case $ac_val in
680     [\\/$]* | ?:[\\/]* ) ;;
681     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
682    { (exit 1); exit 1; }; };;
683   esac
684 done
685
686 # There might be people who depend on the old broken behavior: `$host'
687 # used to hold the argument of --host etc.
688 # FIXME: To remove some day.
689 build=$build_alias
690 host=$host_alias
691 target=$target_alias
692
693 # FIXME: To remove some day.
694 if test "x$host_alias" != x; then
695   if test "x$build_alias" = x; then
696     cross_compiling=maybe
697     echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
698     If a cross compiler is detected then cross compile mode will be used." >&2
699   elif test "x$build_alias" != "x$host_alias"; then
700     cross_compiling=yes
701   fi
702 fi
703
704 ac_tool_prefix=
705 test -n "$host_alias" && ac_tool_prefix=$host_alias-
706
707 test "$silent" = yes && exec 6>/dev/null
708
709
710 # Find the source files, if location was not specified.
711 if test -z "$srcdir"; then
712   ac_srcdir_defaulted=yes
713   # Try the directory containing this script, then its parent.
714   ac_confdir=`(dirname "$0") 2>/dev/null ||
715 $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
716          X"$0" : 'X\(//\)[^/]' \| \
717          X"$0" : 'X\(//\)$' \| \
718          X"$0" : 'X\(/\)' \| \
719          .     : '\(.\)' 2>/dev/null ||
720 echo X"$0" |
721     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
722           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
723           /^X\(\/\/\)$/{ s//\1/; q; }
724           /^X\(\/\).*/{ s//\1/; q; }
725           s/.*/./; q'`
726   srcdir=$ac_confdir
727   if test ! -r $srcdir/$ac_unique_file; then
728     srcdir=..
729   fi
730 else
731   ac_srcdir_defaulted=no
732 fi
733 if test ! -r $srcdir/$ac_unique_file; then
734   if test "$ac_srcdir_defaulted" = yes; then
735     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
736    { (exit 1); exit 1; }; }
737   else
738     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
739    { (exit 1); exit 1; }; }
740   fi
741 fi
742 (cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
743   { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
744    { (exit 1); exit 1; }; }
745 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
746 ac_env_build_alias_set=${build_alias+set}
747 ac_env_build_alias_value=$build_alias
748 ac_cv_env_build_alias_set=${build_alias+set}
749 ac_cv_env_build_alias_value=$build_alias
750 ac_env_host_alias_set=${host_alias+set}
751 ac_env_host_alias_value=$host_alias
752 ac_cv_env_host_alias_set=${host_alias+set}
753 ac_cv_env_host_alias_value=$host_alias
754 ac_env_target_alias_set=${target_alias+set}
755 ac_env_target_alias_value=$target_alias
756 ac_cv_env_target_alias_set=${target_alias+set}
757 ac_cv_env_target_alias_value=$target_alias
758 ac_env_CC_set=${CC+set}
759 ac_env_CC_value=$CC
760 ac_cv_env_CC_set=${CC+set}
761 ac_cv_env_CC_value=$CC
762 ac_env_CFLAGS_set=${CFLAGS+set}
763 ac_env_CFLAGS_value=$CFLAGS
764 ac_cv_env_CFLAGS_set=${CFLAGS+set}
765 ac_cv_env_CFLAGS_value=$CFLAGS
766 ac_env_LDFLAGS_set=${LDFLAGS+set}
767 ac_env_LDFLAGS_value=$LDFLAGS
768 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
769 ac_cv_env_LDFLAGS_value=$LDFLAGS
770 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
771 ac_env_CPPFLAGS_value=$CPPFLAGS
772 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
773 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
774 ac_env_CPP_set=${CPP+set}
775 ac_env_CPP_value=$CPP
776 ac_cv_env_CPP_set=${CPP+set}
777 ac_cv_env_CPP_value=$CPP
778 ac_env_LDFLAGS_SL_set=${LDFLAGS_SL+set}
779 ac_env_LDFLAGS_SL_value=$LDFLAGS_SL
780 ac_cv_env_LDFLAGS_SL_set=${LDFLAGS_SL+set}
781 ac_cv_env_LDFLAGS_SL_value=$LDFLAGS_SL
782 ac_env_DOCBOOKSTYLE_set=${DOCBOOKSTYLE+set}
783 ac_env_DOCBOOKSTYLE_value=$DOCBOOKSTYLE
784 ac_cv_env_DOCBOOKSTYLE_set=${DOCBOOKSTYLE+set}
785 ac_cv_env_DOCBOOKSTYLE_value=$DOCBOOKSTYLE
786
787 #
788 # Report the --help message.
789 #
790 if test "$ac_init_help" = "long"; then
791   # Omit some internal or obsolete options to make the list less imposing.
792   # This message is too long to be a string in the A/UX 3.1 sh.
793   cat <<_ACEOF
794 \`configure' configures PostgreSQL 8.2devel to adapt to many kinds of systems.
795
796 Usage: $0 [OPTION]... [VAR=VALUE]...
797
798 To assign environment variables (e.g., CC, CFLAGS...), specify them as
799 VAR=VALUE.  See below for descriptions of some of the useful variables.
800
801 Defaults for the options are specified in brackets.
802
803 Configuration:
804   -h, --help              display this help and exit
805       --help=short        display options specific to this package
806       --help=recursive    display the short help of all the included packages
807   -V, --version           display version information and exit
808   -q, --quiet, --silent   do not print \`checking...' messages
809       --cache-file=FILE   cache test results in FILE [disabled]
810   -C, --config-cache      alias for \`--cache-file=config.cache'
811   -n, --no-create         do not create output files
812       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
813
814 _ACEOF
815
816   cat <<_ACEOF
817 Installation directories:
818   --prefix=PREFIX         install architecture-independent files in PREFIX
819                           [$ac_default_prefix]
820   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
821                           [PREFIX]
822
823 By default, \`make install' will install all the files in
824 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
825 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
826 for instance \`--prefix=\$HOME'.
827
828 For better control, use the options below.
829
830 Fine tuning of the installation directories:
831   --bindir=DIR           user executables [EPREFIX/bin]
832   --sbindir=DIR          system admin executables [EPREFIX/sbin]
833   --libexecdir=DIR       program executables [EPREFIX/libexec]
834   --datadir=DIR          read-only architecture-independent data [PREFIX/share]
835   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
836   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
837   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
838   --libdir=DIR           object code libraries [EPREFIX/lib]
839   --includedir=DIR       C header files [PREFIX/include]
840   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
841   --infodir=DIR          info documentation [PREFIX/info]
842   --mandir=DIR           man documentation [PREFIX/man]
843 _ACEOF
844
845   cat <<\_ACEOF
846
847 System types:
848   --build=BUILD     configure for building on BUILD [guessed]
849   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
850 _ACEOF
851 fi
852
853 if test -n "$ac_init_help"; then
854   case $ac_init_help in
855      short | recursive ) echo "Configuration of PostgreSQL 8.2devel:";;
856    esac
857   cat <<\_ACEOF
858
859 Optional Features:
860   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
861   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
862   --enable-integer-datetimes  enable 64-bit integer date/time support
863   --enable-nls[=LANGUAGES]  enable Native Language Support
864   --disable-shared        do not build shared libraries
865   --disable-rpath         do not embed shared library search path in executables
866   --disable-spinlocks     do not use spinlocks
867   --enable-debug          build with debugging symbols (-g)
868   --enable-depend         turn on automatic dependency tracking
869   --enable-cassert        enable assertion checks (for debugging)
870   --enable-thread-safety  make client libraries thread-safe
871   --enable-thread-safety-force  force thread-safety in spite of thread test failure
872   --disable-largefile     omit support for large files
873
874 Optional Packages:
875   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
876   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
877
878   --with-docdir=DIR       install the documentation in DIR [PREFIX/doc]
879   --without-docdir        do not install the documentation
880   --with-includes=DIRS    look for additional header files in DIRS
881   --with-libraries=DIRS   look for additional libraries in DIRS
882   --with-libs=DIRS        alternative spelling of --with-libraries
883   --with-pgport=PORTNUM   change default port number [5432]
884   --with-tcl              build Tcl modules (PL/Tcl)
885   --with-tclconfig=DIR    tclConfig.sh is in DIR
886   --with-perl             build Perl modules (PL/Perl)
887   --with-python           build Python modules (PL/Python)
888   --with-krb5             build with Kerberos 5 support
889   --with-krb-srvnam=NAME  name of the default service principal in Kerberos [postgres]
890   --with-pam              build with PAM support
891   --with-bonjour          build with Bonjour support
892   --with-openssl          build with OpenSSL support
893   --with-libedit-preferred  prefer BSD Libedit over GNU Readline
894   --without-readline      do not use GNU Readline / BSD Libedit line editing
895   --without-zlib          do not use Zlib
896   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
897
898 Some influential environment variables:
899   CC          C compiler command
900   CFLAGS      C compiler flags
901   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
902               nonstandard directory <lib dir>
903   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
904               headers in a nonstandard directory <include dir>
905   CPP         C preprocessor
906   LDFLAGS_SL
907   DOCBOOKSTYLE
908               location of DocBook stylesheets
909
910 Use these variables to override the choices made by `configure' or to help
911 it to find libraries and programs with nonstandard names/locations.
912
913 Report bugs to <pgsql-bugs@postgresql.org>.
914 _ACEOF
915 fi
916
917 if test "$ac_init_help" = "recursive"; then
918   # If there are subdirs, report their specific --help.
919   ac_popdir=`pwd`
920   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
921     test -d $ac_dir || continue
922     ac_builddir=.
923
924 if test "$ac_dir" != .; then
925   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
926   # A "../" for each directory in $ac_dir_suffix.
927   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
928 else
929   ac_dir_suffix= ac_top_builddir=
930 fi
931
932 case $srcdir in
933   .)  # No --srcdir option.  We are building in place.
934     ac_srcdir=.
935     if test -z "$ac_top_builddir"; then
936        ac_top_srcdir=.
937     else
938        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
939     fi ;;
940   [\\/]* | ?:[\\/]* )  # Absolute path.
941     ac_srcdir=$srcdir$ac_dir_suffix;
942     ac_top_srcdir=$srcdir ;;
943   *) # Relative path.
944     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
945     ac_top_srcdir=$ac_top_builddir$srcdir ;;
946 esac
947
948 # Do not use `cd foo && pwd` to compute absolute paths, because
949 # the directories may not exist.
950 case `pwd` in
951 .) ac_abs_builddir="$ac_dir";;
952 *)
953   case "$ac_dir" in
954   .) ac_abs_builddir=`pwd`;;
955   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
956   *) ac_abs_builddir=`pwd`/"$ac_dir";;
957   esac;;
958 esac
959 case $ac_abs_builddir in
960 .) ac_abs_top_builddir=${ac_top_builddir}.;;
961 *)
962   case ${ac_top_builddir}. in
963   .) ac_abs_top_builddir=$ac_abs_builddir;;
964   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
965   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
966   esac;;
967 esac
968 case $ac_abs_builddir in
969 .) ac_abs_srcdir=$ac_srcdir;;
970 *)
971   case $ac_srcdir in
972   .) ac_abs_srcdir=$ac_abs_builddir;;
973   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
974   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
975   esac;;
976 esac
977 case $ac_abs_builddir in
978 .) ac_abs_top_srcdir=$ac_top_srcdir;;
979 *)
980   case $ac_top_srcdir in
981   .) ac_abs_top_srcdir=$ac_abs_builddir;;
982   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
983   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
984   esac;;
985 esac
986
987     cd $ac_dir
988     # Check for guested configure; otherwise get Cygnus style configure.
989     if test -f $ac_srcdir/configure.gnu; then
990       echo
991       $SHELL $ac_srcdir/configure.gnu  --help=recursive
992     elif test -f $ac_srcdir/configure; then
993       echo
994       $SHELL $ac_srcdir/configure  --help=recursive
995     elif test -f $ac_srcdir/configure.ac ||
996            test -f $ac_srcdir/configure.in; then
997       echo
998       $ac_configure --help
999     else
1000       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1001     fi
1002     cd $ac_popdir
1003   done
1004 fi
1005
1006 test -n "$ac_init_help" && exit 0
1007 if $ac_init_version; then
1008   cat <<\_ACEOF
1009 PostgreSQL configure 8.2devel
1010 generated by GNU Autoconf 2.59
1011
1012 Copyright (C) 2003 Free Software Foundation, Inc.
1013 This configure script is free software; the Free Software Foundation
1014 gives unlimited permission to copy, distribute and modify it.
1015
1016 Copyright (c) 1996-2005, PostgreSQL Global Development Group
1017 _ACEOF
1018   exit 0
1019 fi
1020 exec 5>config.log
1021 cat >&5 <<_ACEOF
1022 This file contains any messages produced by compilers while
1023 running configure, to aid debugging if configure makes a mistake.
1024
1025 It was created by PostgreSQL $as_me 8.2devel, which was
1026 generated by GNU Autoconf 2.59.  Invocation command line was
1027
1028   $ $0 $@
1029
1030 _ACEOF
1031 {
1032 cat <<_ASUNAME
1033 ## --------- ##
1034 ## Platform. ##
1035 ## --------- ##
1036
1037 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1038 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1039 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1040 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1041 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1042
1043 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1044 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1045
1046 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1047 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1048 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1049 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1050 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1051 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1052 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1053
1054 _ASUNAME
1055
1056 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1057 for as_dir in $PATH
1058 do
1059   IFS=$as_save_IFS
1060   test -z "$as_dir" && as_dir=.
1061   echo "PATH: $as_dir"
1062 done
1063
1064 } >&5
1065
1066 cat >&5 <<_ACEOF
1067
1068
1069 ## ----------- ##
1070 ## Core tests. ##
1071 ## ----------- ##
1072
1073 _ACEOF
1074
1075
1076 # Keep a trace of the command line.
1077 # Strip out --no-create and --no-recursion so they do not pile up.
1078 # Strip out --silent because we don't want to record it for future runs.
1079 # Also quote any args containing shell meta-characters.
1080 # Make two passes to allow for proper duplicate-argument suppression.
1081 ac_configure_args=
1082 ac_configure_args0=
1083 ac_configure_args1=
1084 ac_sep=
1085 ac_must_keep_next=false
1086 for ac_pass in 1 2
1087 do
1088   for ac_arg
1089   do
1090     case $ac_arg in
1091     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1092     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1093     | -silent | --silent | --silen | --sile | --sil)
1094       continue ;;
1095     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1096       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1097     esac
1098     case $ac_pass in
1099     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1100     2)
1101       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1102       if test $ac_must_keep_next = true; then
1103         ac_must_keep_next=false # Got value, back to normal.
1104       else
1105         case $ac_arg in
1106           *=* | --config-cache | -C | -disable-* | --disable-* \
1107           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1108           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1109           | -with-* | --with-* | -without-* | --without-* | --x)
1110             case "$ac_configure_args0 " in
1111               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1112             esac
1113             ;;
1114           -* ) ac_must_keep_next=true ;;
1115         esac
1116       fi
1117       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1118       # Get rid of the leading space.
1119       ac_sep=" "
1120       ;;
1121     esac
1122   done
1123 done
1124 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1125 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1126
1127 # When interrupted or exit'd, cleanup temporary files, and complete
1128 # config.log.  We remove comments because anyway the quotes in there
1129 # would cause problems or look ugly.
1130 # WARNING: Be sure not to use single quotes in there, as some shells,
1131 # such as our DU 5.0 friend, will then `close' the trap.
1132 trap 'exit_status=$?
1133   # Save into config.log some information that might help in debugging.
1134   {
1135     echo
1136
1137     cat <<\_ASBOX
1138 ## ---------------- ##
1139 ## Cache variables. ##
1140 ## ---------------- ##
1141 _ASBOX
1142     echo
1143     # The following way of writing the cache mishandles newlines in values,
1144 {
1145   (set) 2>&1 |
1146     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1147     *ac_space=\ *)
1148       sed -n \
1149         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1150           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1151       ;;
1152     *)
1153       sed -n \
1154         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1155       ;;
1156     esac;
1157 }
1158     echo
1159
1160     cat <<\_ASBOX
1161 ## ----------------- ##
1162 ## Output variables. ##
1163 ## ----------------- ##
1164 _ASBOX
1165     echo
1166     for ac_var in $ac_subst_vars
1167     do
1168       eval ac_val=$`echo $ac_var`
1169       echo "$ac_var='"'"'$ac_val'"'"'"
1170     done | sort
1171     echo
1172
1173     if test -n "$ac_subst_files"; then
1174       cat <<\_ASBOX
1175 ## ------------- ##
1176 ## Output files. ##
1177 ## ------------- ##
1178 _ASBOX
1179       echo
1180       for ac_var in $ac_subst_files
1181       do
1182         eval ac_val=$`echo $ac_var`
1183         echo "$ac_var='"'"'$ac_val'"'"'"
1184       done | sort
1185       echo
1186     fi
1187
1188     if test -s confdefs.h; then
1189       cat <<\_ASBOX
1190 ## ----------- ##
1191 ## confdefs.h. ##
1192 ## ----------- ##
1193 _ASBOX
1194       echo
1195       sed "/^$/d" confdefs.h | sort
1196       echo
1197     fi
1198     test "$ac_signal" != 0 &&
1199       echo "$as_me: caught signal $ac_signal"
1200     echo "$as_me: exit $exit_status"
1201   } >&5
1202   rm -f core *.core &&
1203   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1204     exit $exit_status
1205      ' 0
1206 for ac_signal in 1 2 13 15; do
1207   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1208 done
1209 ac_signal=0
1210
1211 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1212 rm -rf conftest* confdefs.h
1213 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1214 echo >confdefs.h
1215
1216 # Predefined preprocessor variables.
1217
1218 cat >>confdefs.h <<_ACEOF
1219 #define PACKAGE_NAME "$PACKAGE_NAME"
1220 _ACEOF
1221
1222
1223 cat >>confdefs.h <<_ACEOF
1224 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1225 _ACEOF
1226
1227
1228 cat >>confdefs.h <<_ACEOF
1229 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1230 _ACEOF
1231
1232
1233 cat >>confdefs.h <<_ACEOF
1234 #define PACKAGE_STRING "$PACKAGE_STRING"
1235 _ACEOF
1236
1237
1238 cat >>confdefs.h <<_ACEOF
1239 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1240 _ACEOF
1241
1242
1243 # Let the site file select an alternate cache file if it wants to.
1244 # Prefer explicitly selected file to automatically selected ones.
1245 if test -z "$CONFIG_SITE"; then
1246   if test "x$prefix" != xNONE; then
1247     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1248   else
1249     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1250   fi
1251 fi
1252 for ac_site_file in $CONFIG_SITE; do
1253   if test -r "$ac_site_file"; then
1254     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1255 echo "$as_me: loading site script $ac_site_file" >&6;}
1256     sed 's/^/| /' "$ac_site_file" >&5
1257     . "$ac_site_file"
1258   fi
1259 done
1260
1261 if test -r "$cache_file"; then
1262   # Some versions of bash will fail to source /dev/null (special
1263   # files actually), so we avoid doing that.
1264   if test -f "$cache_file"; then
1265     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1266 echo "$as_me: loading cache $cache_file" >&6;}
1267     case $cache_file in
1268       [\\/]* | ?:[\\/]* ) . $cache_file;;
1269       *)                      . ./$cache_file;;
1270     esac
1271   fi
1272 else
1273   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1274 echo "$as_me: creating cache $cache_file" >&6;}
1275   >$cache_file
1276 fi
1277
1278 # Check that the precious variables saved in the cache have kept the same
1279 # value.
1280 ac_cache_corrupted=false
1281 for ac_var in `(set) 2>&1 |
1282                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1283   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1284   eval ac_new_set=\$ac_env_${ac_var}_set
1285   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1286   eval ac_new_val="\$ac_env_${ac_var}_value"
1287   case $ac_old_set,$ac_new_set in
1288     set,)
1289       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1290 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1291       ac_cache_corrupted=: ;;
1292     ,set)
1293       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1294 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1295       ac_cache_corrupted=: ;;
1296     ,);;
1297     *)
1298       if test "x$ac_old_val" != "x$ac_new_val"; then
1299         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1300 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1301         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1302 echo "$as_me:   former value:  $ac_old_val" >&2;}
1303         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1304 echo "$as_me:   current value: $ac_new_val" >&2;}
1305         ac_cache_corrupted=:
1306       fi;;
1307   esac
1308   # Pass precious variables to config.status.
1309   if test "$ac_new_set" = set; then
1310     case $ac_new_val in
1311     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1312       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1313     *) ac_arg=$ac_var=$ac_new_val ;;
1314     esac
1315     case " $ac_configure_args " in
1316       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1317       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1318     esac
1319   fi
1320 done
1321 if $ac_cache_corrupted; then
1322   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1323 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1324   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1325 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1326    { (exit 1); exit 1; }; }
1327 fi
1328
1329 ac_ext=c
1330 ac_cpp='$CPP $CPPFLAGS'
1331 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1332 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1333 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365 ac_aux_dir=
1366 for ac_dir in config $srcdir/config; do
1367   if test -f $ac_dir/install-sh; then
1368     ac_aux_dir=$ac_dir
1369     ac_install_sh="$ac_aux_dir/install-sh -c"
1370     break
1371   elif test -f $ac_dir/install.sh; then
1372     ac_aux_dir=$ac_dir
1373     ac_install_sh="$ac_aux_dir/install.sh -c"
1374     break
1375   elif test -f $ac_dir/shtool; then
1376     ac_aux_dir=$ac_dir
1377     ac_install_sh="$ac_aux_dir/shtool install -c"
1378     break
1379   fi
1380 done
1381 if test -z "$ac_aux_dir"; then
1382   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config $srcdir/config" >&5
1383 echo "$as_me: error: cannot find install-sh or install.sh in config $srcdir/config" >&2;}
1384    { (exit 1); exit 1; }; }
1385 fi
1386 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1387 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1388 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1389
1390
1391 configure_args=$ac_configure_args
1392
1393
1394
1395 cat >>confdefs.h <<_ACEOF
1396 #define PG_VERSION "$PACKAGE_VERSION"
1397 _ACEOF
1398
1399
1400 # Make sure we can run config.sub.
1401 $ac_config_sub sun4 >/dev/null 2>&1 ||
1402   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1403 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1404    { (exit 1); exit 1; }; }
1405
1406 echo "$as_me:$LINENO: checking build system type" >&5
1407 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1408 if test "${ac_cv_build+set}" = set; then
1409   echo $ECHO_N "(cached) $ECHO_C" >&6
1410 else
1411   ac_cv_build_alias=$build_alias
1412 test -z "$ac_cv_build_alias" &&
1413   ac_cv_build_alias=`$ac_config_guess`
1414 test -z "$ac_cv_build_alias" &&
1415   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1416 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1417    { (exit 1); exit 1; }; }
1418 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1419   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1420 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1421    { (exit 1); exit 1; }; }
1422
1423 fi
1424 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1425 echo "${ECHO_T}$ac_cv_build" >&6
1426 build=$ac_cv_build
1427 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1428 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1429 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1430
1431
1432 echo "$as_me:$LINENO: checking host system type" >&5
1433 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1434 if test "${ac_cv_host+set}" = set; then
1435   echo $ECHO_N "(cached) $ECHO_C" >&6
1436 else
1437   ac_cv_host_alias=$host_alias
1438 test -z "$ac_cv_host_alias" &&
1439   ac_cv_host_alias=$ac_cv_build_alias
1440 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1441   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1442 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1443    { (exit 1); exit 1; }; }
1444
1445 fi
1446 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1447 echo "${ECHO_T}$ac_cv_host" >&6
1448 host=$ac_cv_host
1449 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1450 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1451 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1452
1453
1454
1455 template=
1456 echo "$as_me:$LINENO: checking which template to use" >&5
1457 echo $ECHO_N "checking which template to use... $ECHO_C" >&6
1458
1459
1460
1461
1462 # Check whether --with-template or --without-template was given.
1463 if test "${with_template+set}" = set; then
1464   withval="$with_template"
1465
1466   case $withval in
1467     yes)
1468       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1469 echo "$as_me: error: argument required for --with-template option" >&2;}
1470    { (exit 1); exit 1; }; }
1471       ;;
1472     no)
1473       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1474 echo "$as_me: error: argument required for --with-template option" >&2;}
1475    { (exit 1); exit 1; }; }
1476       ;;
1477     *)
1478
1479   case $withval in
1480     list)   echo; ls "$srcdir/src/template"; exit;;
1481     *)      if test -f "$srcdir/src/template/$with_template" ; then
1482               template=$withval
1483             else
1484               { { echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
1485 echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
1486    { (exit 1); exit 1; }; }
1487             fi;;
1488   esac
1489
1490       ;;
1491   esac
1492
1493 else
1494
1495 # --with-template not given
1496
1497 case $host_os in
1498      aix*) template=aix ;;
1499     bsdi*) template=bsdi ;;
1500   cygwin*) template=cygwin ;;
1501   darwin*) template=darwin ;;
1502     dgux*) template=dgux ;;
1503  freebsd*) template=freebsd ;;
1504     hpux*) template=hpux ;;
1505     irix*) template=irix ;;
1506  linux*|gnu*|k*bsd*-gnu)
1507            template=linux ;;
1508    mingw*) template=win32 ;;
1509   netbsd*) template=netbsd ;;
1510 nextstep*) template=nextstep ;;
1511  openbsd*) template=openbsd ;;
1512      osf*) template=osf ;;
1513      sco*) template=sco ;;
1514  solaris*) template=solaris ;;
1515    sunos*) template=sunos4 ;;
1516  sysv4.2*)
1517         case $host_vendor in
1518           univel) template=univel ;;
1519         esac ;;
1520    sysv4*) template=svr4 ;;
1521    sysv5*) template=unixware ;;
1522   ultrix*) template=ultrix4 ;;
1523 esac
1524
1525   if test x"$template" = x"" ; then
1526     { { echo "$as_me:$LINENO: error:
1527 *******************************************************************
1528 PostgreSQL has apparently not been ported to your platform yet.
1529 To try a manual configuration, look into the src/template directory
1530 for a similar platform and use the '--with-template=' option.
1531
1532 Please also contact <pgsql-ports@postgresql.org> to see about
1533 rectifying this.  Include the above 'checking host system type...'
1534 line.
1535 *******************************************************************
1536 " >&5
1537 echo "$as_me: error:
1538 *******************************************************************
1539 PostgreSQL has apparently not been ported to your platform yet.
1540 To try a manual configuration, look into the src/template directory
1541 for a similar platform and use the '--with-template=' option.
1542
1543 Please also contact <pgsql-ports@postgresql.org> to see about
1544 rectifying this.  Include the above 'checking host system type...'
1545 line.
1546 *******************************************************************
1547 " >&2;}
1548    { (exit 1); exit 1; }; }
1549   fi
1550
1551
1552 fi;
1553
1554
1555 echo "$as_me:$LINENO: result: $template" >&5
1556 echo "${ECHO_T}$template" >&6
1557
1558 PORTNAME=$template
1559
1560
1561 # Initialize default assumption that we do not need separate assembly code
1562 # for TAS (test-and-set).  This can be overridden by the template file
1563 # when it's executed.
1564 need_tas=no
1565 tas_file=dummy.s
1566
1567
1568
1569 ##
1570 ## Command line options
1571 ##
1572
1573 #
1574 # Installation directory for documentation
1575 #
1576
1577
1578
1579 # Check whether --with-docdir or --without-docdir was given.
1580 if test "${with_docdir+set}" = set; then
1581   withval="$with_docdir"
1582
1583   case $withval in
1584     yes)
1585       { { echo "$as_me:$LINENO: error: option --with-docdir requires an argument" >&5
1586 echo "$as_me: error: option --with-docdir requires an argument" >&2;}
1587    { (exit 1); exit 1; }; }
1588       ;;
1589     no)
1590       docdir=
1591       ;;
1592     *)
1593       docdir=$withval
1594       ;;
1595   esac
1596
1597 else
1598   docdir='${prefix}/doc'
1599 fi;
1600
1601
1602
1603
1604 #
1605 # Add non-standard directories to the include path
1606 #
1607
1608
1609
1610 # Check whether --with-includes or --without-includes was given.
1611 if test "${with_includes+set}" = set; then
1612   withval="$with_includes"
1613
1614   case $withval in
1615     yes)
1616       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1617 echo "$as_me: error: argument required for --with-includes option" >&2;}
1618    { (exit 1); exit 1; }; }
1619       ;;
1620     no)
1621       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1622 echo "$as_me: error: argument required for --with-includes option" >&2;}
1623    { (exit 1); exit 1; }; }
1624       ;;
1625     *)
1626
1627       ;;
1628   esac
1629
1630 fi;
1631
1632
1633
1634 #
1635 # Add non-standard directories to the library search path
1636 #
1637
1638
1639
1640 # Check whether --with-libraries or --without-libraries was given.
1641 if test "${with_libraries+set}" = set; then
1642   withval="$with_libraries"
1643
1644   case $withval in
1645     yes)
1646       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
1647 echo "$as_me: error: argument required for --with-libraries option" >&2;}
1648    { (exit 1); exit 1; }; }
1649       ;;
1650     no)
1651       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
1652 echo "$as_me: error: argument required for --with-libraries option" >&2;}
1653    { (exit 1); exit 1; }; }
1654       ;;
1655     *)
1656       LIBRARY_DIRS=$withval
1657       ;;
1658   esac
1659
1660 fi;
1661
1662
1663
1664
1665
1666 # Check whether --with-libs or --without-libs was given.
1667 if test "${with_libs+set}" = set; then
1668   withval="$with_libs"
1669
1670   case $withval in
1671     yes)
1672       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1673 echo "$as_me: error: argument required for --with-libs option" >&2;}
1674    { (exit 1); exit 1; }; }
1675       ;;
1676     no)
1677       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1678 echo "$as_me: error: argument required for --with-libs option" >&2;}
1679    { (exit 1); exit 1; }; }
1680       ;;
1681     *)
1682       LIBRARY_DIRS=$withval
1683       ;;
1684   esac
1685
1686 fi;
1687
1688
1689
1690 #
1691 # 64-bit integer date/time storage (--enable-integer-datetimes)
1692 #
1693 echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
1694 echo $ECHO_N "checking whether to build with 64-bit integer date/time support... $ECHO_C" >&6
1695
1696
1697 # Check whether --enable-integer-datetimes or --disable-integer-datetimes was given.
1698 if test "${enable_integer_datetimes+set}" = set; then
1699   enableval="$enable_integer_datetimes"
1700
1701   case $enableval in
1702     yes)
1703
1704 cat >>confdefs.h <<\_ACEOF
1705 #define USE_INTEGER_DATETIMES 1
1706 _ACEOF
1707
1708       ;;
1709     no)
1710       :
1711       ;;
1712     *)
1713       { { echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
1714 echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
1715    { (exit 1); exit 1; }; }
1716       ;;
1717   esac
1718
1719 else
1720   enable_integer_datetimes=no
1721
1722 fi;
1723
1724 echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
1725 echo "${ECHO_T}$enable_integer_datetimes" >&6
1726
1727
1728 #
1729 # NLS
1730 #
1731 echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
1732 echo $ECHO_N "checking whether NLS is wanted... $ECHO_C" >&6
1733
1734
1735 # Check whether --enable-nls or --disable-nls was given.
1736 if test "${enable_nls+set}" = set; then
1737   enableval="$enable_nls"
1738
1739   case $enableval in
1740     yes)
1741       :
1742       ;;
1743     no)
1744       :
1745       ;;
1746     *)
1747       enable_nls=yes
1748 WANTED_LANGUAGES=$enableval
1749       ;;
1750   esac
1751
1752 else
1753   enable_nls=no
1754 fi;
1755
1756
1757 if test "$enable_nls" = yes; then
1758
1759 cat >>confdefs.h <<\_ACEOF
1760 #define ENABLE_NLS 1
1761 _ACEOF
1762
1763 fi
1764
1765 echo "$as_me:$LINENO: result: $enable_nls" >&5
1766 echo "${ECHO_T}$enable_nls" >&6
1767
1768
1769
1770 #
1771 # Default port number (--with-pgport), default 5432
1772 #
1773 echo "$as_me:$LINENO: checking for default port number" >&5
1774 echo $ECHO_N "checking for default port number... $ECHO_C" >&6
1775
1776
1777
1778 # Check whether --with-pgport or --without-pgport was given.
1779 if test "${with_pgport+set}" = set; then
1780   withval="$with_pgport"
1781
1782   case $withval in
1783     yes)
1784       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1785 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1786    { (exit 1); exit 1; }; }
1787       ;;
1788     no)
1789       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1790 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1791    { (exit 1); exit 1; }; }
1792       ;;
1793     *)
1794       default_port=$withval
1795       ;;
1796   esac
1797
1798 else
1799   default_port=5432
1800 fi;
1801
1802 echo "$as_me:$LINENO: result: $default_port" >&5
1803 echo "${ECHO_T}$default_port" >&6
1804 # Need both of these because some places want an integer and some a string
1805
1806 cat >>confdefs.h <<_ACEOF
1807 #define DEF_PGPORT ${default_port}
1808 _ACEOF
1809
1810
1811 cat >>confdefs.h <<_ACEOF
1812 #define DEF_PGPORT_STR "${default_port}"
1813 _ACEOF
1814
1815
1816
1817 #
1818 # Option to disable shared libraries
1819 #
1820
1821
1822 # Check whether --enable-shared or --disable-shared was given.
1823 if test "${enable_shared+set}" = set; then
1824   enableval="$enable_shared"
1825
1826   case $enableval in
1827     yes)
1828       :
1829       ;;
1830     no)
1831       :
1832       ;;
1833     *)
1834       { { echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
1835 echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
1836    { (exit 1); exit 1; }; }
1837       ;;
1838   esac
1839
1840 else
1841   enable_shared=yes
1842
1843 fi;
1844
1845
1846
1847 #
1848 # '-rpath'-like feature can be disabled
1849 #
1850
1851
1852 # Check whether --enable-rpath or --disable-rpath was given.
1853 if test "${enable_rpath+set}" = set; then
1854   enableval="$enable_rpath"
1855
1856   case $enableval in
1857     yes)
1858       :
1859       ;;
1860     no)
1861       :
1862       ;;
1863     *)
1864       { { echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
1865 echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
1866    { (exit 1); exit 1; }; }
1867       ;;
1868   esac
1869
1870 else
1871   enable_rpath=yes
1872
1873 fi;
1874
1875
1876
1877 #
1878 # Spinlocks
1879 #
1880
1881
1882 # Check whether --enable-spinlocks or --disable-spinlocks was given.
1883 if test "${enable_spinlocks+set}" = set; then
1884   enableval="$enable_spinlocks"
1885
1886   case $enableval in
1887     yes)
1888       :
1889       ;;
1890     no)
1891       :
1892       ;;
1893     *)
1894       { { echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
1895 echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
1896    { (exit 1); exit 1; }; }
1897       ;;
1898   esac
1899
1900 else
1901   enable_spinlocks=yes
1902
1903 fi;
1904
1905
1906 #
1907 # --enable-debug adds -g to compiler flags
1908 #
1909
1910
1911 # Check whether --enable-debug or --disable-debug was given.
1912 if test "${enable_debug+set}" = set; then
1913   enableval="$enable_debug"
1914
1915   case $enableval in
1916     yes)
1917       :
1918       ;;
1919     no)
1920       :
1921       ;;
1922     *)
1923       { { echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
1924 echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
1925    { (exit 1); exit 1; }; }
1926       ;;
1927   esac
1928
1929 else
1930   enable_debug=no
1931
1932 fi;
1933
1934
1935
1936 #
1937 # C compiler
1938 #
1939
1940 # For historical reasons you can also use --with-CC to specify the C compiler
1941 # to use, although the standard way to do this is to set the CC environment
1942 # variable.
1943
1944
1945
1946 # Check whether --with-CC or --without-CC was given.
1947 if test "${with_CC+set}" = set; then
1948   withval="$with_CC"
1949
1950   case $withval in
1951     yes)
1952       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
1953 echo "$as_me: error: argument required for --with-CC option" >&2;}
1954    { (exit 1); exit 1; }; }
1955       ;;
1956     no)
1957       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
1958 echo "$as_me: error: argument required for --with-CC option" >&2;}
1959    { (exit 1); exit 1; }; }
1960       ;;
1961     *)
1962       CC=$with_CC
1963       ;;
1964   esac
1965
1966 fi;
1967
1968
1969 case $template in
1970   aix) pgac_cc_list="gcc xlc";;
1971  irix) pgac_cc_list="cc";; # no gcc
1972     *) pgac_cc_list="gcc cc";;
1973 esac
1974
1975 ac_ext=c
1976 ac_cpp='$CPP $CPPFLAGS'
1977 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1978 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1979 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1980 if test -n "$ac_tool_prefix"; then
1981   for ac_prog in $pgac_cc_list
1982   do
1983     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1984 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1985 echo "$as_me:$LINENO: checking for $ac_word" >&5
1986 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1987 if test "${ac_cv_prog_CC+set}" = set; then
1988   echo $ECHO_N "(cached) $ECHO_C" >&6
1989 else
1990   if test -n "$CC"; then
1991   ac_cv_prog_CC="$CC" # Let the user override the test.
1992 else
1993 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1994 for as_dir in $PATH
1995 do
1996   IFS=$as_save_IFS
1997   test -z "$as_dir" && as_dir=.
1998   for ac_exec_ext in '' $ac_executable_extensions; do
1999   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2000     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2001     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2002     break 2
2003   fi
2004 done
2005 done
2006
2007 fi
2008 fi
2009 CC=$ac_cv_prog_CC
2010 if test -n "$CC"; then
2011   echo "$as_me:$LINENO: result: $CC" >&5
2012 echo "${ECHO_T}$CC" >&6
2013 else
2014   echo "$as_me:$LINENO: result: no" >&5
2015 echo "${ECHO_T}no" >&6
2016 fi
2017
2018     test -n "$CC" && break
2019   done
2020 fi
2021 if test -z "$CC"; then
2022   ac_ct_CC=$CC
2023   for ac_prog in $pgac_cc_list
2024 do
2025   # Extract the first word of "$ac_prog", so it can be a program name with args.
2026 set dummy $ac_prog; ac_word=$2
2027 echo "$as_me:$LINENO: checking for $ac_word" >&5
2028 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2029 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2030   echo $ECHO_N "(cached) $ECHO_C" >&6
2031 else
2032   if test -n "$ac_ct_CC"; then
2033   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2034 else
2035 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2036 for as_dir in $PATH
2037 do
2038   IFS=$as_save_IFS
2039   test -z "$as_dir" && as_dir=.
2040   for ac_exec_ext in '' $ac_executable_extensions; do
2041   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2042     ac_cv_prog_ac_ct_CC="$ac_prog"
2043     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2044     break 2
2045   fi
2046 done
2047 done
2048
2049 fi
2050 fi
2051 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2052 if test -n "$ac_ct_CC"; then
2053   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2054 echo "${ECHO_T}$ac_ct_CC" >&6
2055 else
2056   echo "$as_me:$LINENO: result: no" >&5
2057 echo "${ECHO_T}no" >&6
2058 fi
2059
2060   test -n "$ac_ct_CC" && break
2061 done
2062
2063   CC=$ac_ct_CC
2064 fi
2065
2066
2067 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2068 See \`config.log' for more details." >&5
2069 echo "$as_me: error: no acceptable C compiler found in \$PATH
2070 See \`config.log' for more details." >&2;}
2071    { (exit 1); exit 1; }; }
2072
2073 # Provide some information about the compiler.
2074 echo "$as_me:$LINENO:" \
2075      "checking for C compiler version" >&5
2076 ac_compiler=`set X $ac_compile; echo $2`
2077 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
2078   (eval $ac_compiler --version </dev/null >&5) 2>&5
2079   ac_status=$?
2080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2081   (exit $ac_status); }
2082 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
2083   (eval $ac_compiler -v </dev/null >&5) 2>&5
2084   ac_status=$?
2085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2086   (exit $ac_status); }
2087 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
2088   (eval $ac_compiler -V </dev/null >&5) 2>&5
2089   ac_status=$?
2090   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2091   (exit $ac_status); }
2092
2093 cat >conftest.$ac_ext <<_ACEOF
2094 /* confdefs.h.  */
2095 _ACEOF
2096 cat confdefs.h >>conftest.$ac_ext
2097 cat >>conftest.$ac_ext <<_ACEOF
2098 /* end confdefs.h.  */
2099
2100 int
2101 main ()
2102 {
2103
2104   ;
2105   return 0;
2106 }
2107 _ACEOF
2108 ac_clean_files_save=$ac_clean_files
2109 ac_clean_files="$ac_clean_files a.out a.exe b.out"
2110 # Try to create an executable without -o first, disregard a.out.
2111 # It will help us diagnose broken compilers, and finding out an intuition
2112 # of exeext.
2113 echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2114 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
2115 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2116 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2117   (eval $ac_link_default) 2>&5
2118   ac_status=$?
2119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2120   (exit $ac_status); }; then
2121   # Find the output, starting from the most likely.  This scheme is
2122 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
2123 # resort.
2124
2125 # Be careful to initialize this variable, since it used to be cached.
2126 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2127 ac_cv_exeext=
2128 # b.out is created by i960 compilers.
2129 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
2130 do
2131   test -f "$ac_file" || continue
2132   case $ac_file in
2133     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
2134         ;;
2135     conftest.$ac_ext )
2136         # This is the source file.
2137         ;;
2138     [ab].out )
2139         # We found the default executable, but exeext='' is most
2140         # certainly right.
2141         break;;
2142     *.* )
2143         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2144         # FIXME: I believe we export ac_cv_exeext for Libtool,
2145         # but it would be cool to find out if it's true.  Does anybody
2146         # maintain Libtool? --akim.
2147         export ac_cv_exeext
2148         break;;
2149     * )
2150         break;;
2151   esac
2152 done
2153 else
2154   echo "$as_me: failed program was:" >&5
2155 sed 's/^/| /' conftest.$ac_ext >&5
2156
2157 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
2158 See \`config.log' for more details." >&5
2159 echo "$as_me: error: C compiler cannot create executables
2160 See \`config.log' for more details." >&2;}
2161    { (exit 77); exit 77; }; }
2162 fi
2163
2164 ac_exeext=$ac_cv_exeext
2165 echo "$as_me:$LINENO: result: $ac_file" >&5
2166 echo "${ECHO_T}$ac_file" >&6
2167
2168 # Check the compiler produces executables we can run.  If not, either
2169 # the compiler is broken, or we cross compile.
2170 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2171 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2172 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2173 # If not cross compiling, check that we can run a simple program.
2174 if test "$cross_compiling" != yes; then
2175   if { ac_try='./$ac_file'
2176   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2177   (eval $ac_try) 2>&5
2178   ac_status=$?
2179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2180   (exit $ac_status); }; }; then
2181     cross_compiling=no
2182   else
2183     if test "$cross_compiling" = maybe; then
2184         cross_compiling=yes
2185     else
2186         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2187 If you meant to cross compile, use \`--host'.
2188 See \`config.log' for more details." >&5
2189 echo "$as_me: error: cannot run C compiled programs.
2190 If you meant to cross compile, use \`--host'.
2191 See \`config.log' for more details." >&2;}
2192    { (exit 1); exit 1; }; }
2193     fi
2194   fi
2195 fi
2196 echo "$as_me:$LINENO: result: yes" >&5
2197 echo "${ECHO_T}yes" >&6
2198
2199 rm -f a.out a.exe conftest$ac_cv_exeext b.out
2200 ac_clean_files=$ac_clean_files_save
2201 # Check the compiler produces executables we can run.  If not, either
2202 # the compiler is broken, or we cross compile.
2203 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2204 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2205 echo "$as_me:$LINENO: result: $cross_compiling" >&5
2206 echo "${ECHO_T}$cross_compiling" >&6
2207
2208 echo "$as_me:$LINENO: checking for suffix of executables" >&5
2209 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2210 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2211   (eval $ac_link) 2>&5
2212   ac_status=$?
2213   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2214   (exit $ac_status); }; then
2215   # If both `conftest.exe' and `conftest' are `present' (well, observable)
2216 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
2217 # work properly (i.e., refer to `conftest.exe'), while it won't with
2218 # `rm'.
2219 for ac_file in conftest.exe conftest conftest.*; do
2220   test -f "$ac_file" || continue
2221   case $ac_file in
2222     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
2223     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2224           export ac_cv_exeext
2225           break;;
2226     * ) break;;
2227   esac
2228 done
2229 else
2230   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
2231 See \`config.log' for more details." >&5
2232 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
2233 See \`config.log' for more details." >&2;}
2234    { (exit 1); exit 1; }; }
2235 fi
2236
2237 rm -f conftest$ac_cv_exeext
2238 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2239 echo "${ECHO_T}$ac_cv_exeext" >&6
2240
2241 rm -f conftest.$ac_ext
2242 EXEEXT=$ac_cv_exeext
2243 ac_exeext=$EXEEXT
2244 echo "$as_me:$LINENO: checking for suffix of object files" >&5
2245 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2246 if test "${ac_cv_objext+set}" = set; then
2247   echo $ECHO_N "(cached) $ECHO_C" >&6
2248 else
2249   cat >conftest.$ac_ext <<_ACEOF
2250 /* confdefs.h.  */
2251 _ACEOF
2252 cat confdefs.h >>conftest.$ac_ext
2253 cat >>conftest.$ac_ext <<_ACEOF
2254 /* end confdefs.h.  */
2255
2256 int
2257 main ()
2258 {
2259
2260   ;
2261   return 0;
2262 }
2263 _ACEOF
2264 rm -f conftest.o conftest.obj
2265 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2266   (eval $ac_compile) 2>&5
2267   ac_status=$?
2268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2269   (exit $ac_status); }; then
2270   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2271   case $ac_file in
2272     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
2273     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2274        break;;
2275   esac
2276 done
2277 else
2278   echo "$as_me: failed program was:" >&5
2279 sed 's/^/| /' conftest.$ac_ext >&5
2280
2281 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
2282 See \`config.log' for more details." >&5
2283 echo "$as_me: error: cannot compute suffix of object files: cannot compile
2284 See \`config.log' for more details." >&2;}
2285    { (exit 1); exit 1; }; }
2286 fi
2287
2288 rm -f conftest.$ac_cv_objext conftest.$ac_ext
2289 fi
2290 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2291 echo "${ECHO_T}$ac_cv_objext" >&6
2292 OBJEXT=$ac_cv_objext
2293 ac_objext=$OBJEXT
2294 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2295 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2296 if test "${ac_cv_c_compiler_gnu+set}" = set; then
2297   echo $ECHO_N "(cached) $ECHO_C" >&6
2298 else
2299   cat >conftest.$ac_ext <<_ACEOF
2300 /* confdefs.h.  */
2301 _ACEOF
2302 cat confdefs.h >>conftest.$ac_ext
2303 cat >>conftest.$ac_ext <<_ACEOF
2304 /* end confdefs.h.  */
2305
2306 int
2307 main ()
2308 {
2309 #ifndef __GNUC__
2310        choke me
2311 #endif
2312
2313   ;
2314   return 0;
2315 }
2316 _ACEOF
2317 rm -f conftest.$ac_objext
2318 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2319   (eval $ac_compile) 2>conftest.er1
2320   ac_status=$?
2321   grep -v '^ *+' conftest.er1 >conftest.err
2322   rm -f conftest.er1
2323   cat conftest.err >&5
2324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2325   (exit $ac_status); } &&
2326          { ac_try='test -z "$ac_c_werror_flag"
2327                          || test ! -s conftest.err'
2328   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2329   (eval $ac_try) 2>&5
2330   ac_status=$?
2331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2332   (exit $ac_status); }; } &&
2333          { ac_try='test -s conftest.$ac_objext'
2334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2335   (eval $ac_try) 2>&5
2336   ac_status=$?
2337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2338   (exit $ac_status); }; }; then
2339   ac_compiler_gnu=yes
2340 else
2341   echo "$as_me: failed program was:" >&5
2342 sed 's/^/| /' conftest.$ac_ext >&5
2343
2344 ac_compiler_gnu=no
2345 fi
2346 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2347 ac_cv_c_compiler_gnu=$ac_compiler_gnu
2348
2349 fi
2350 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2351 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2352 GCC=`test $ac_compiler_gnu = yes && echo yes`
2353 ac_test_CFLAGS=${CFLAGS+set}
2354 ac_save_CFLAGS=$CFLAGS
2355 CFLAGS="-g"
2356 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2357 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2358 if test "${ac_cv_prog_cc_g+set}" = set; then
2359   echo $ECHO_N "(cached) $ECHO_C" >&6
2360 else
2361   cat >conftest.$ac_ext <<_ACEOF
2362 /* confdefs.h.  */
2363 _ACEOF
2364 cat confdefs.h >>conftest.$ac_ext
2365 cat >>conftest.$ac_ext <<_ACEOF
2366 /* end confdefs.h.  */
2367
2368 int
2369 main ()
2370 {
2371
2372   ;
2373   return 0;
2374 }
2375 _ACEOF
2376 rm -f conftest.$ac_objext
2377 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2378   (eval $ac_compile) 2>conftest.er1
2379   ac_status=$?
2380   grep -v '^ *+' conftest.er1 >conftest.err
2381   rm -f conftest.er1
2382   cat conftest.err >&5
2383   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2384   (exit $ac_status); } &&
2385          { ac_try='test -z "$ac_c_werror_flag"
2386                          || test ! -s conftest.err'
2387   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2388   (eval $ac_try) 2>&5
2389   ac_status=$?
2390   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2391   (exit $ac_status); }; } &&
2392          { ac_try='test -s conftest.$ac_objext'
2393   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2394   (eval $ac_try) 2>&5
2395   ac_status=$?
2396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2397   (exit $ac_status); }; }; then
2398   ac_cv_prog_cc_g=yes
2399 else
2400   echo "$as_me: failed program was:" >&5
2401 sed 's/^/| /' conftest.$ac_ext >&5
2402
2403 ac_cv_prog_cc_g=no
2404 fi
2405 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2406 fi
2407 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2408 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2409 if test "$ac_test_CFLAGS" = set; then
2410   CFLAGS=$ac_save_CFLAGS
2411 elif test $ac_cv_prog_cc_g = yes; then
2412   if test "$GCC" = yes; then
2413     CFLAGS="-g -O2"
2414   else
2415     CFLAGS="-g"
2416   fi
2417 else
2418   if test "$GCC" = yes; then
2419     CFLAGS="-O2"
2420   else
2421     CFLAGS=
2422   fi
2423 fi
2424 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
2425 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2426 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2427   echo $ECHO_N "(cached) $ECHO_C" >&6
2428 else
2429   ac_cv_prog_cc_stdc=no
2430 ac_save_CC=$CC
2431 cat >conftest.$ac_ext <<_ACEOF
2432 /* confdefs.h.  */
2433 _ACEOF
2434 cat confdefs.h >>conftest.$ac_ext
2435 cat >>conftest.$ac_ext <<_ACEOF
2436 /* end confdefs.h.  */
2437 #include <stdarg.h>
2438 #include <stdio.h>
2439 #include <sys/types.h>
2440 #include <sys/stat.h>
2441 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2442 struct buf { int x; };
2443 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2444 static char *e (p, i)
2445      char **p;
2446      int i;
2447 {
2448   return p[i];
2449 }
2450 static char *f (char * (*g) (char **, int), char **p, ...)
2451 {
2452   char *s;
2453   va_list v;
2454   va_start (v,p);
2455   s = g (p, va_arg (v,int));
2456   va_end (v);
2457   return s;
2458 }
2459
2460 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
2461    function prototypes and stuff, but not '\xHH' hex character constants.
2462    These don't provoke an error unfortunately, instead are silently treated
2463    as 'x'.  The following induces an error, until -std1 is added to get
2464    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
2465    array size at least.  It's necessary to write '\x00'==0 to get something
2466    that's true only with -std1.  */
2467 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
2468
2469 int test (int i, double x);
2470 struct s1 {int (*f) (int a);};
2471 struct s2 {int (*f) (double a);};
2472 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2473 int argc;
2474 char **argv;
2475 int
2476 main ()
2477 {
2478 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2479   ;
2480   return 0;
2481 }
2482 _ACEOF
2483 # Don't try gcc -ansi; that turns off useful extensions and
2484 # breaks some systems' header files.
2485 # AIX                   -qlanglvl=ansi
2486 # Ultrix and OSF/1      -std1
2487 # HP-UX 10.20 and later -Ae
2488 # HP-UX older versions  -Aa -D_HPUX_SOURCE
2489 # SVR4                  -Xc -D__EXTENSIONS__
2490 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2491 do
2492   CC="$ac_save_CC $ac_arg"
2493   rm -f conftest.$ac_objext
2494 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2495   (eval $ac_compile) 2>conftest.er1
2496   ac_status=$?
2497   grep -v '^ *+' conftest.er1 >conftest.err
2498   rm -f conftest.er1
2499   cat conftest.err >&5
2500   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2501   (exit $ac_status); } &&
2502          { ac_try='test -z "$ac_c_werror_flag"
2503                          || test ! -s conftest.err'
2504   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2505   (eval $ac_try) 2>&5
2506   ac_status=$?
2507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2508   (exit $ac_status); }; } &&
2509          { ac_try='test -s conftest.$ac_objext'
2510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2511   (eval $ac_try) 2>&5
2512   ac_status=$?
2513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2514   (exit $ac_status); }; }; then
2515   ac_cv_prog_cc_stdc=$ac_arg
2516 break
2517 else
2518   echo "$as_me: failed program was:" >&5
2519 sed 's/^/| /' conftest.$ac_ext >&5
2520
2521 fi
2522 rm -f conftest.err conftest.$ac_objext
2523 done
2524 rm -f conftest.$ac_ext conftest.$ac_objext
2525 CC=$ac_save_CC
2526
2527 fi
2528
2529 case "x$ac_cv_prog_cc_stdc" in
2530   x|xno)
2531     echo "$as_me:$LINENO: result: none needed" >&5
2532 echo "${ECHO_T}none needed" >&6 ;;
2533   *)
2534     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2535 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2536     CC="$CC $ac_cv_prog_cc_stdc" ;;
2537 esac
2538
2539 # Some people use a C++ compiler to compile C.  Since we use `exit',
2540 # in C++ we need to declare it.  In case someone uses the same compiler
2541 # for both compiling C and C++ we need to have the C++ compiler decide
2542 # the declaration of exit, since it's the most demanding environment.
2543 cat >conftest.$ac_ext <<_ACEOF
2544 #ifndef __cplusplus
2545   choke me
2546 #endif
2547 _ACEOF
2548 rm -f conftest.$ac_objext
2549 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2550   (eval $ac_compile) 2>conftest.er1
2551   ac_status=$?
2552   grep -v '^ *+' conftest.er1 >conftest.err
2553   rm -f conftest.er1
2554   cat conftest.err >&5
2555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2556   (exit $ac_status); } &&
2557          { ac_try='test -z "$ac_c_werror_flag"
2558                          || test ! -s conftest.err'
2559   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2560   (eval $ac_try) 2>&5
2561   ac_status=$?
2562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2563   (exit $ac_status); }; } &&
2564          { ac_try='test -s conftest.$ac_objext'
2565   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2566   (eval $ac_try) 2>&5
2567   ac_status=$?
2568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2569   (exit $ac_status); }; }; then
2570   for ac_declaration in \
2571    '' \
2572    'extern "C" void std::exit (int) throw (); using std::exit;' \
2573    'extern "C" void std::exit (int); using std::exit;' \
2574    'extern "C" void exit (int) throw ();' \
2575    'extern "C" void exit (int);' \
2576    'void exit (int);'
2577 do
2578   cat >conftest.$ac_ext <<_ACEOF
2579 /* confdefs.h.  */
2580 _ACEOF
2581 cat confdefs.h >>conftest.$ac_ext
2582 cat >>conftest.$ac_ext <<_ACEOF
2583 /* end confdefs.h.  */
2584 $ac_declaration
2585 #include <stdlib.h>
2586 int
2587 main ()
2588 {
2589 exit (42);
2590   ;
2591   return 0;
2592 }
2593 _ACEOF
2594 rm -f conftest.$ac_objext
2595 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2596   (eval $ac_compile) 2>conftest.er1
2597   ac_status=$?
2598   grep -v '^ *+' conftest.er1 >conftest.err
2599   rm -f conftest.er1
2600   cat conftest.err >&5
2601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2602   (exit $ac_status); } &&
2603          { ac_try='test -z "$ac_c_werror_flag"
2604                          || test ! -s conftest.err'
2605   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2606   (eval $ac_try) 2>&5
2607   ac_status=$?
2608   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2609   (exit $ac_status); }; } &&
2610          { ac_try='test -s conftest.$ac_objext'
2611   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2612   (eval $ac_try) 2>&5
2613   ac_status=$?
2614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2615   (exit $ac_status); }; }; then
2616   :
2617 else
2618   echo "$as_me: failed program was:" >&5
2619 sed 's/^/| /' conftest.$ac_ext >&5
2620
2621 continue
2622 fi
2623 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2624   cat >conftest.$ac_ext <<_ACEOF
2625 /* confdefs.h.  */
2626 _ACEOF
2627 cat confdefs.h >>conftest.$ac_ext
2628 cat >>conftest.$ac_ext <<_ACEOF
2629 /* end confdefs.h.  */
2630 $ac_declaration
2631 int
2632 main ()
2633 {
2634 exit (42);
2635   ;
2636   return 0;
2637 }
2638 _ACEOF
2639 rm -f conftest.$ac_objext
2640 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2641   (eval $ac_compile) 2>conftest.er1
2642   ac_status=$?
2643   grep -v '^ *+' conftest.er1 >conftest.err
2644   rm -f conftest.er1
2645   cat conftest.err >&5
2646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2647   (exit $ac_status); } &&
2648          { ac_try='test -z "$ac_c_werror_flag"
2649                          || test ! -s conftest.err'
2650   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2651   (eval $ac_try) 2>&5
2652   ac_status=$?
2653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2654   (exit $ac_status); }; } &&
2655          { ac_try='test -s conftest.$ac_objext'
2656   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2657   (eval $ac_try) 2>&5
2658   ac_status=$?
2659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2660   (exit $ac_status); }; }; then
2661   break
2662 else
2663   echo "$as_me: failed program was:" >&5
2664 sed 's/^/| /' conftest.$ac_ext >&5
2665
2666 fi
2667 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2668 done
2669 rm -f conftest*
2670 if test -n "$ac_declaration"; then
2671   echo '#ifdef __cplusplus' >>confdefs.h
2672   echo $ac_declaration      >>confdefs.h
2673   echo '#endif'             >>confdefs.h
2674 fi
2675
2676 else
2677   echo "$as_me: failed program was:" >&5
2678 sed 's/^/| /' conftest.$ac_ext >&5
2679
2680 fi
2681 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2682 ac_ext=c
2683 ac_cpp='$CPP $CPPFLAGS'
2684 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2685 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2686 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2687
2688
2689 unset CFLAGS
2690
2691 #
2692 # Read the template
2693 #
2694 . "$srcdir/src/template/$template" || exit
2695
2696 # CFLAGS are selected so:
2697 # If the user specifies something in the environment, that is used.
2698 # else:  If the template file set something, that is used.
2699 # else:  If the compiler is GCC, then we use -O2.
2700 # else:  If the compiler is something else, then we use -0.
2701
2702 if test "$ac_env_CFLAGS_set" = set; then
2703   CFLAGS=$ac_env_CFLAGS_value
2704 elif test "${CFLAGS+set}" = set; then
2705   : # (keep what template set)
2706 elif test "$GCC" = yes; then
2707   CFLAGS="-O2"
2708 else
2709   # if the user selected debug mode, don't use -O
2710   if test "$enable_debug" != yes; then
2711     CFLAGS="-O"
2712   fi
2713 fi
2714
2715 if test "$GCC" = yes; then
2716   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith -Winline"
2717
2718   # Some versions of GCC support some additional useful warning flags.
2719   # Check whether they are supported, and add them to CFLAGS if so.
2720   echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
2721 echo $ECHO_N "checking if $CC supports -Wdeclaration-after-statement... $ECHO_C" >&6
2722 pgac_save_CFLAGS=$CFLAGS
2723 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
2724 cat >conftest.$ac_ext <<_ACEOF
2725 /* confdefs.h.  */
2726 _ACEOF
2727 cat confdefs.h >>conftest.$ac_ext
2728 cat >>conftest.$ac_ext <<_ACEOF
2729 /* end confdefs.h.  */
2730
2731 int
2732 main ()
2733 {
2734
2735   ;
2736   return 0;
2737 }
2738 _ACEOF
2739 rm -f conftest.$ac_objext
2740 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2741   (eval $ac_compile) 2>conftest.er1
2742   ac_status=$?
2743   grep -v '^ *+' conftest.er1 >conftest.err
2744   rm -f conftest.er1
2745   cat conftest.err >&5
2746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2747   (exit $ac_status); } &&
2748          { ac_try='test -z "$ac_c_werror_flag"
2749                          || test ! -s conftest.err'
2750   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2751   (eval $ac_try) 2>&5
2752   ac_status=$?
2753   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2754   (exit $ac_status); }; } &&
2755          { ac_try='test -s conftest.$ac_objext'
2756   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2757   (eval $ac_try) 2>&5
2758   ac_status=$?
2759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2760   (exit $ac_status); }; }; then
2761   echo "$as_me:$LINENO: result: yes" >&5
2762 echo "${ECHO_T}yes" >&6
2763 else
2764   echo "$as_me: failed program was:" >&5
2765 sed 's/^/| /' conftest.$ac_ext >&5
2766
2767 CFLAGS="$pgac_save_CFLAGS"
2768                     echo "$as_me:$LINENO: result: no" >&5
2769 echo "${ECHO_T}no" >&6
2770 fi
2771 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2772
2773   echo "$as_me:$LINENO: checking if $CC supports -Wendif-labels" >&5
2774 echo $ECHO_N "checking if $CC supports -Wendif-labels... $ECHO_C" >&6
2775 pgac_save_CFLAGS=$CFLAGS
2776 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
2777 cat >conftest.$ac_ext <<_ACEOF
2778 /* confdefs.h.  */
2779 _ACEOF
2780 cat confdefs.h >>conftest.$ac_ext
2781 cat >>conftest.$ac_ext <<_ACEOF
2782 /* end confdefs.h.  */
2783
2784 int
2785 main ()
2786 {
2787
2788   ;
2789   return 0;
2790 }
2791 _ACEOF
2792 rm -f conftest.$ac_objext
2793 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2794   (eval $ac_compile) 2>conftest.er1
2795   ac_status=$?
2796   grep -v '^ *+' conftest.er1 >conftest.err
2797   rm -f conftest.er1
2798   cat conftest.err >&5
2799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2800   (exit $ac_status); } &&
2801          { ac_try='test -z "$ac_c_werror_flag"
2802                          || test ! -s conftest.err'
2803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2804   (eval $ac_try) 2>&5
2805   ac_status=$?
2806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2807   (exit $ac_status); }; } &&
2808          { ac_try='test -s conftest.$ac_objext'
2809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2810   (eval $ac_try) 2>&5
2811   ac_status=$?
2812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2813   (exit $ac_status); }; }; then
2814   echo "$as_me:$LINENO: result: yes" >&5
2815 echo "${ECHO_T}yes" >&6
2816 else
2817   echo "$as_me: failed program was:" >&5
2818 sed 's/^/| /' conftest.$ac_ext >&5
2819
2820 CFLAGS="$pgac_save_CFLAGS"
2821                     echo "$as_me:$LINENO: result: no" >&5
2822 echo "${ECHO_T}no" >&6
2823 fi
2824 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2825
2826
2827   # Disable strict-aliasing rules; needed for gcc 3.3+
2828   echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
2829 echo $ECHO_N "checking if $CC supports -fno-strict-aliasing... $ECHO_C" >&6
2830 pgac_save_CFLAGS=$CFLAGS
2831 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
2832 cat >conftest.$ac_ext <<_ACEOF
2833 /* confdefs.h.  */
2834 _ACEOF
2835 cat confdefs.h >>conftest.$ac_ext
2836 cat >>conftest.$ac_ext <<_ACEOF
2837 /* end confdefs.h.  */
2838
2839 int
2840 main ()
2841 {
2842
2843   ;
2844   return 0;
2845 }
2846 _ACEOF
2847 rm -f conftest.$ac_objext
2848 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2849   (eval $ac_compile) 2>conftest.er1
2850   ac_status=$?
2851   grep -v '^ *+' conftest.er1 >conftest.err
2852   rm -f conftest.er1
2853   cat conftest.err >&5
2854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2855   (exit $ac_status); } &&
2856          { ac_try='test -z "$ac_c_werror_flag"
2857                          || test ! -s conftest.err'
2858   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2859   (eval $ac_try) 2>&5
2860   ac_status=$?
2861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2862   (exit $ac_status); }; } &&
2863          { ac_try='test -s conftest.$ac_objext'
2864   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2865   (eval $ac_try) 2>&5
2866   ac_status=$?
2867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2868   (exit $ac_status); }; }; then
2869   echo "$as_me:$LINENO: result: yes" >&5
2870 echo "${ECHO_T}yes" >&6
2871 else
2872   echo "$as_me: failed program was:" >&5
2873 sed 's/^/| /' conftest.$ac_ext >&5
2874
2875 CFLAGS="$pgac_save_CFLAGS"
2876                     echo "$as_me:$LINENO: result: no" >&5
2877 echo "${ECHO_T}no" >&6
2878 fi
2879 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2880
2881 fi
2882
2883 # supply -g if --enable-debug
2884 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
2885   CFLAGS="$CFLAGS -g"
2886 fi
2887
2888 { echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
2889 echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
2890
2891 # We already have this in Makefile.win32, but configure needs it too
2892 if test "$PORTNAME" = "win32"; then
2893   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
2894 fi
2895
2896 # Check if the compiler still works with the template settings
2897 echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
2898 echo $ECHO_N "checking whether the C compiler still works... $ECHO_C" >&6
2899
2900 cat >conftest.$ac_ext <<_ACEOF
2901 /* confdefs.h.  */
2902 _ACEOF
2903 cat confdefs.h >>conftest.$ac_ext
2904 cat >>conftest.$ac_ext <<_ACEOF
2905 /* end confdefs.h.  */
2906
2907 int
2908 main ()
2909 {
2910 return 0;
2911   ;
2912   return 0;
2913 }
2914 _ACEOF
2915 rm -f conftest.$ac_objext conftest$ac_exeext
2916 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2917   (eval $ac_link) 2>conftest.er1
2918   ac_status=$?
2919   grep -v '^ *+' conftest.er1 >conftest.err
2920   rm -f conftest.er1
2921   cat conftest.err >&5
2922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2923   (exit $ac_status); } &&
2924          { ac_try='test -z "$ac_c_werror_flag"
2925                          || test ! -s conftest.err'
2926   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2927   (eval $ac_try) 2>&5
2928   ac_status=$?
2929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2930   (exit $ac_status); }; } &&
2931          { ac_try='test -s conftest$ac_exeext'
2932   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2933   (eval $ac_try) 2>&5
2934   ac_status=$?
2935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2936   (exit $ac_status); }; }; then
2937   echo "$as_me:$LINENO: result: yes" >&5
2938 echo "${ECHO_T}yes" >&6
2939 else
2940   echo "$as_me: failed program was:" >&5
2941 sed 's/^/| /' conftest.$ac_ext >&5
2942
2943 echo "$as_me:$LINENO: result: no" >&5
2944 echo "${ECHO_T}no" >&6
2945    { { echo "$as_me:$LINENO: error: cannot proceed" >&5
2946 echo "$as_me: error: cannot proceed" >&2;}
2947    { (exit 1); exit 1; }; }
2948 fi
2949 rm -f conftest.err conftest.$ac_objext \
2950       conftest$ac_exeext conftest.$ac_ext
2951
2952 # Defend against gcc -ffast-math
2953 if test "$GCC" = yes; then
2954 cat >conftest.$ac_ext <<_ACEOF
2955 /* confdefs.h.  */
2956 _ACEOF
2957 cat confdefs.h >>conftest.$ac_ext
2958 cat >>conftest.$ac_ext <<_ACEOF
2959 /* end confdefs.h.  */
2960
2961 int
2962 main ()
2963 {
2964 #ifdef __FAST_MATH__
2965 choke me
2966 #endif
2967   ;
2968   return 0;
2969 }
2970 _ACEOF
2971 rm -f conftest.$ac_objext
2972 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2973   (eval $ac_compile) 2>conftest.er1
2974   ac_status=$?
2975   grep -v '^ *+' conftest.er1 >conftest.err
2976   rm -f conftest.er1
2977   cat conftest.err >&5
2978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2979   (exit $ac_status); } &&
2980          { ac_try='test -z "$ac_c_werror_flag"
2981                          || test ! -s conftest.err'
2982   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2983   (eval $ac_try) 2>&5
2984   ac_status=$?
2985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2986   (exit $ac_status); }; } &&
2987          { ac_try='test -s conftest.$ac_objext'
2988   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2989   (eval $ac_try) 2>&5
2990   ac_status=$?
2991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2992   (exit $ac_status); }; }; then
2993   :
2994 else
2995   echo "$as_me: failed program was:" >&5
2996 sed 's/^/| /' conftest.$ac_ext >&5
2997
2998 { { echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
2999 echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
3000    { (exit 1); exit 1; }; }
3001 fi
3002 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3003 fi
3004
3005 ac_ext=c
3006 ac_cpp='$CPP $CPPFLAGS'
3007 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3008 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3009 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3010 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
3011 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
3012 # On Suns, sometimes $CPP names a directory.
3013 if test -n "$CPP" && test -d "$CPP"; then
3014   CPP=
3015 fi
3016 if test -z "$CPP"; then
3017   if test "${ac_cv_prog_CPP+set}" = set; then
3018   echo $ECHO_N "(cached) $ECHO_C" >&6
3019 else
3020       # Double quotes because CPP needs to be expanded
3021     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3022     do
3023       ac_preproc_ok=false
3024 for ac_c_preproc_warn_flag in '' yes
3025 do
3026   # Use a header file that comes with gcc, so configuring glibc
3027   # with a fresh cross-compiler works.
3028   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3029   # <limits.h> exists even on freestanding compilers.
3030   # On the NeXT, cc -E runs the code through the compiler's parser,
3031   # not just through cpp. "Syntax error" is here to catch this case.
3032   cat >conftest.$ac_ext <<_ACEOF
3033 /* confdefs.h.  */
3034 _ACEOF
3035 cat confdefs.h >>conftest.$ac_ext
3036 cat >>conftest.$ac_ext <<_ACEOF
3037 /* end confdefs.h.  */
3038 #ifdef __STDC__
3039 # include <limits.h>
3040 #else
3041 # include <assert.h>
3042 #endif
3043                      Syntax error
3044 _ACEOF
3045 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3046   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3047   ac_status=$?
3048   grep -v '^ *+' conftest.er1 >conftest.err
3049   rm -f conftest.er1
3050   cat conftest.err >&5
3051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3052   (exit $ac_status); } >/dev/null; then
3053   if test -s conftest.err; then
3054     ac_cpp_err=$ac_c_preproc_warn_flag
3055     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3056   else
3057     ac_cpp_err=
3058   fi
3059 else
3060   ac_cpp_err=yes
3061 fi
3062 if test -z "$ac_cpp_err"; then
3063   :
3064 else
3065   echo "$as_me: failed program was:" >&5
3066 sed 's/^/| /' conftest.$ac_ext >&5
3067
3068   # Broken: fails on valid input.
3069 continue
3070 fi
3071 rm -f conftest.err conftest.$ac_ext
3072
3073   # OK, works on sane cases.  Now check whether non-existent headers
3074   # can be detected and how.
3075   cat >conftest.$ac_ext <<_ACEOF
3076 /* confdefs.h.  */
3077 _ACEOF
3078 cat confdefs.h >>conftest.$ac_ext
3079 cat >>conftest.$ac_ext <<_ACEOF
3080 /* end confdefs.h.  */
3081 #include <ac_nonexistent.h>
3082 _ACEOF
3083 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3084   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3085   ac_status=$?
3086   grep -v '^ *+' conftest.er1 >conftest.err
3087   rm -f conftest.er1
3088   cat conftest.err >&5
3089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3090   (exit $ac_status); } >/dev/null; then
3091   if test -s conftest.err; then
3092     ac_cpp_err=$ac_c_preproc_warn_flag
3093     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3094   else
3095     ac_cpp_err=
3096   fi
3097 else
3098   ac_cpp_err=yes
3099 fi
3100 if test -z "$ac_cpp_err"; then
3101   # Broken: success on invalid input.
3102 continue
3103 else
3104   echo "$as_me: failed program was:" >&5
3105 sed 's/^/| /' conftest.$ac_ext >&5
3106
3107   # Passes both tests.
3108 ac_preproc_ok=:
3109 break
3110 fi
3111 rm -f conftest.err conftest.$ac_ext
3112
3113 done
3114 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3115 rm -f conftest.err conftest.$ac_ext
3116 if $ac_preproc_ok; then
3117   break
3118 fi
3119
3120     done
3121     ac_cv_prog_CPP=$CPP
3122
3123 fi
3124   CPP=$ac_cv_prog_CPP
3125 else
3126   ac_cv_prog_CPP=$CPP
3127 fi
3128 echo "$as_me:$LINENO: result: $CPP" >&5
3129 echo "${ECHO_T}$CPP" >&6
3130 ac_preproc_ok=false
3131 for ac_c_preproc_warn_flag in '' yes
3132 do
3133   # Use a header file that comes with gcc, so configuring glibc
3134   # with a fresh cross-compiler works.
3135   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3136   # <limits.h> exists even on freestanding compilers.
3137   # On the NeXT, cc -E runs the code through the compiler's parser,
3138   # not just through cpp. "Syntax error" is here to catch this case.
3139   cat >conftest.$ac_ext <<_ACEOF
3140 /* confdefs.h.  */
3141 _ACEOF
3142 cat confdefs.h >>conftest.$ac_ext
3143 cat >>conftest.$ac_ext <<_ACEOF
3144 /* end confdefs.h.  */
3145 #ifdef __STDC__
3146 # include <limits.h>
3147 #else
3148 # include <assert.h>
3149 #endif
3150                      Syntax error
3151 _ACEOF
3152 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3153   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3154   ac_status=$?
3155   grep -v '^ *+' conftest.er1 >conftest.err
3156   rm -f conftest.er1
3157   cat conftest.err >&5
3158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3159   (exit $ac_status); } >/dev/null; then
3160   if test -s conftest.err; then
3161     ac_cpp_err=$ac_c_preproc_warn_flag
3162     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3163   else
3164     ac_cpp_err=
3165   fi
3166 else
3167   ac_cpp_err=yes
3168 fi
3169 if test -z "$ac_cpp_err"; then
3170   :
3171 else
3172   echo "$as_me: failed program was:" >&5
3173 sed 's/^/| /' conftest.$ac_ext >&5
3174
3175   # Broken: fails on valid input.
3176 continue
3177 fi
3178 rm -f conftest.err conftest.$ac_ext
3179
3180   # OK, works on sane cases.  Now check whether non-existent headers
3181   # can be detected and how.
3182   cat >conftest.$ac_ext <<_ACEOF
3183 /* confdefs.h.  */
3184 _ACEOF
3185 cat confdefs.h >>conftest.$ac_ext
3186 cat >>conftest.$ac_ext <<_ACEOF
3187 /* end confdefs.h.  */
3188 #include <ac_nonexistent.h>
3189 _ACEOF
3190 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3191   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3192   ac_status=$?
3193   grep -v '^ *+' conftest.er1 >conftest.err
3194   rm -f conftest.er1
3195   cat conftest.err >&5
3196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3197   (exit $ac_status); } >/dev/null; then
3198   if test -s conftest.err; then
3199     ac_cpp_err=$ac_c_preproc_warn_flag
3200     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3201   else
3202     ac_cpp_err=
3203   fi
3204 else
3205   ac_cpp_err=yes
3206 fi
3207 if test -z "$ac_cpp_err"; then
3208   # Broken: success on invalid input.
3209 continue
3210 else
3211   echo "$as_me: failed program was:" >&5
3212 sed 's/^/| /' conftest.$ac_ext >&5
3213
3214   # Passes both tests.
3215 ac_preproc_ok=:
3216 break
3217 fi
3218 rm -f conftest.err conftest.$ac_ext
3219
3220 done
3221 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3222 rm -f conftest.err conftest.$ac_ext
3223 if $ac_preproc_ok; then
3224   :
3225 else
3226   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3227 See \`config.log' for more details." >&5
3228 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3229 See \`config.log' for more details." >&2;}
3230    { (exit 1); exit 1; }; }
3231 fi
3232
3233 ac_ext=c
3234 ac_cpp='$CPP $CPPFLAGS'
3235 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3236 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3237 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3238
3239
3240
3241 # Create compiler version string
3242 if test x"$GCC" = x"yes" ; then
3243   cc_string="GCC `${CC} --version | sed q`"
3244 else
3245   cc_string=$CC
3246 fi
3247
3248 cat >>confdefs.h <<_ACEOF
3249 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string"
3250 _ACEOF
3251
3252
3253
3254 #
3255 # Set up TAS assembly code if needed; the template file has now had its
3256 # chance to request this.
3257 #
3258           ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
3259
3260
3261 if test "$need_tas" = yes ; then
3262   TAS=tas.o
3263 else
3264   TAS=""
3265 fi
3266
3267
3268
3269 #
3270 # Automatic dependency tracking
3271 #
3272
3273
3274 # Check whether --enable-depend or --disable-depend was given.
3275 if test "${enable_depend+set}" = set; then
3276   enableval="$enable_depend"
3277
3278   case $enableval in
3279     yes)
3280       autodepend=yes
3281       ;;
3282     no)
3283       :
3284       ;;
3285     *)
3286       { { echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
3287 echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
3288    { (exit 1); exit 1; }; }
3289       ;;
3290   esac
3291
3292 else
3293   enable_depend=no
3294
3295 fi;
3296
3297
3298
3299
3300 #
3301 # Enable assert checks
3302 #
3303
3304
3305 # Check whether --enable-cassert or --disable-cassert was given.
3306 if test "${enable_cassert+set}" = set; then
3307   enableval="$enable_cassert"
3308
3309   case $enableval in
3310     yes)
3311
3312 cat >>confdefs.h <<\_ACEOF
3313 #define USE_ASSERT_CHECKING 1
3314 _ACEOF
3315
3316       ;;
3317     no)
3318       :
3319       ;;
3320     *)
3321       { { echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
3322 echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
3323    { (exit 1); exit 1; }; }
3324       ;;
3325   esac
3326
3327 else
3328   enable_cassert=no
3329
3330 fi;
3331
3332
3333
3334 #
3335 # Include directories
3336 #
3337 ac_save_IFS=$IFS
3338 IFS="${IFS}${PATH_SEPARATOR}"
3339 # SRCH_INC comes from the template file
3340 for dir in $with_includes $SRCH_INC; do
3341   if test -d "$dir"; then
3342     INCLUDES="$INCLUDES -I$dir"
3343   else
3344     { echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
3345 echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
3346   fi
3347 done
3348 IFS=$ac_save_IFS
3349
3350
3351
3352 #
3353 # Library directories
3354 #
3355 ac_save_IFS=$IFS
3356 IFS="${IFS}${PATH_SEPARATOR}"
3357 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
3358 for dir in $LIBRARY_DIRS $SRCH_LIB; do
3359   if test -d "$dir"; then
3360     LIBDIRS="$LIBDIRS -L$dir"
3361   else
3362     { echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
3363 echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
3364   fi
3365 done
3366 IFS=$ac_save_IFS
3367
3368 #
3369 # Enable thread-safe client libraries
3370 #
3371 echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
3372 echo $ECHO_N "checking allow thread-safe client libraries... $ECHO_C" >&6
3373
3374
3375 # Check whether --enable-thread-safety or --disable-thread-safety was given.
3376 if test "${enable_thread_safety+set}" = set; then
3377   enableval="$enable_thread_safety"
3378
3379   case $enableval in
3380     yes)
3381       :
3382       ;;
3383     no)
3384       :
3385       ;;
3386     *)
3387       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
3388 echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
3389    { (exit 1); exit 1; }; }
3390       ;;
3391   esac
3392
3393 else
3394   enable_thread_safety=no
3395
3396 fi;
3397
3398
3399
3400 # Check whether --enable-thread-safety-force or --disable-thread-safety-force was given.
3401 if test "${enable_thread_safety_force+set}" = set; then
3402   enableval="$enable_thread_safety_force"
3403
3404   case $enableval in
3405     yes)
3406       :
3407       ;;
3408     no)
3409       :
3410       ;;
3411     *)
3412       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety-force option" >&5
3413 echo "$as_me: error: no argument expected for --enable-thread-safety-force option" >&2;}
3414    { (exit 1); exit 1; }; }
3415       ;;
3416   esac
3417
3418 else
3419   enable_thread_safety_force=no
3420
3421 fi;
3422
3423 if test "$enable_thread_safety" = yes -o \
3424         "$enable_thread_safety_force" = yes; then
3425   enable_thread_safety="yes"    # for 'force'
3426
3427 cat >>confdefs.h <<\_ACEOF
3428 #define ENABLE_THREAD_SAFETY 1
3429 _ACEOF
3430
3431 fi
3432 echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
3433 echo "${ECHO_T}$enable_thread_safety" >&6
3434
3435
3436 #
3437 # Optionally build Tcl modules (PL/Tcl)
3438 #
3439 echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
3440 echo $ECHO_N "checking whether to build with Tcl... $ECHO_C" >&6
3441
3442
3443
3444 # Check whether --with-tcl or --without-tcl was given.
3445 if test "${with_tcl+set}" = set; then
3446   withval="$with_tcl"
3447
3448   case $withval in
3449     yes)
3450       :
3451       ;;
3452     no)
3453       :
3454       ;;
3455     *)
3456       { { echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
3457 echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
3458    { (exit 1); exit 1; }; }
3459       ;;
3460   esac
3461
3462 else
3463   with_tcl=no
3464
3465 fi;
3466
3467 echo "$as_me:$LINENO: result: $with_tcl" >&5
3468 echo "${ECHO_T}$with_tcl" >&6
3469
3470
3471 # We see if the path to the Tcl/Tk configuration scripts is specified.
3472 # This will override the use of tclsh to find the paths to search.
3473
3474
3475
3476
3477 # Check whether --with-tclconfig or --without-tclconfig was given.
3478 if test "${with_tclconfig+set}" = set; then
3479   withval="$with_tclconfig"
3480
3481   case $withval in
3482     yes)
3483       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3484 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3485    { (exit 1); exit 1; }; }
3486       ;;
3487     no)
3488       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3489 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3490    { (exit 1); exit 1; }; }
3491       ;;
3492     *)
3493
3494       ;;
3495   esac
3496
3497 fi;
3498
3499
3500 #
3501 # Optionally build Perl modules (PL/Perl)
3502 #
3503 echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
3504 echo $ECHO_N "checking whether to build Perl modules... $ECHO_C" >&6
3505
3506
3507
3508 # Check whether --with-perl or --without-perl was given.
3509 if test "${with_perl+set}" = set; then
3510   withval="$with_perl"
3511
3512   case $withval in
3513     yes)
3514       :
3515       ;;
3516     no)
3517       :
3518       ;;
3519     *)
3520       { { echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
3521 echo "$as_me: error: no argument expected for --with-perl option" >&2;}
3522    { (exit 1); exit 1; }; }
3523       ;;
3524   esac
3525
3526 else
3527   with_perl=no
3528
3529 fi;
3530
3531 echo "$as_me:$LINENO: result: $with_perl" >&5
3532 echo "${ECHO_T}$with_perl" >&6
3533
3534
3535 #
3536 # Optionally build Python modules (PL/Python)
3537 #
3538 echo "$as_me:$LINENO: checking whether to build Python modules" >&5
3539 echo $ECHO_N "checking whether to build Python modules... $ECHO_C" >&6
3540
3541
3542
3543 # Check whether --with-python or --without-python was given.
3544 if test "${with_python+set}" = set; then
3545   withval="$with_python"
3546
3547   case $withval in
3548     yes)
3549       :
3550       ;;
3551     no)
3552       :
3553       ;;
3554     *)
3555       { { echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
3556 echo "$as_me: error: no argument expected for --with-python option" >&2;}
3557    { (exit 1); exit 1; }; }
3558       ;;
3559   esac
3560
3561 else
3562   with_python=no
3563
3564 fi;
3565
3566 echo "$as_me:$LINENO: result: $with_python" >&5
3567 echo "${ECHO_T}$with_python" >&6
3568
3569
3570 #
3571 # Kerberos 5
3572 #
3573 echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
3574 echo $ECHO_N "checking whether to build with Kerberos 5 support... $ECHO_C" >&6
3575
3576
3577
3578 # Check whether --with-krb5 or --without-krb5 was given.
3579 if test "${with_krb5+set}" = set; then
3580   withval="$with_krb5"
3581
3582   case $withval in
3583     yes)
3584
3585
3586 cat >>confdefs.h <<\_ACEOF
3587 #define KRB5 1
3588 _ACEOF
3589
3590   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
3591
3592       ;;
3593     no)
3594       :
3595       ;;
3596     *)
3597       { { echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
3598 echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
3599    { (exit 1); exit 1; }; }
3600       ;;
3601   esac
3602
3603 else
3604   with_krb5=no
3605
3606 fi;
3607
3608 echo "$as_me:$LINENO: result: $with_krb5" >&5
3609 echo "${ECHO_T}$with_krb5" >&6
3610
3611
3612
3613
3614
3615
3616 #
3617 # Kerberos configuration parameters
3618 #
3619
3620
3621
3622 # Check whether --with-krb-srvnam or --without-krb-srvnam was given.
3623 if test "${with_krb_srvnam+set}" = set; then
3624   withval="$with_krb_srvnam"
3625
3626   case $withval in
3627     yes)
3628       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3629 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3630    { (exit 1); exit 1; }; }
3631       ;;
3632     no)
3633       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3634 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3635    { (exit 1); exit 1; }; }
3636       ;;
3637     *)
3638
3639       ;;
3640   esac
3641
3642 else
3643   with_krb_srvnam="postgres"
3644 fi;
3645
3646
3647 cat >>confdefs.h <<_ACEOF
3648 #define PG_KRB_SRVNAM "$with_krb_srvnam"
3649 _ACEOF
3650
3651
3652
3653 #
3654 # PAM
3655 #
3656 echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
3657 echo $ECHO_N "checking whether to build with PAM support... $ECHO_C" >&6
3658
3659
3660
3661 # Check whether --with-pam or --without-pam was given.
3662 if test "${with_pam+set}" = set; then
3663   withval="$with_pam"
3664
3665   case $withval in
3666     yes)
3667
3668 cat >>confdefs.h <<\_ACEOF
3669 #define USE_PAM 1
3670 _ACEOF
3671
3672       ;;
3673     no)
3674       :
3675       ;;
3676     *)
3677       { { echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
3678 echo "$as_me: error: no argument expected for --with-pam option" >&2;}
3679    { (exit 1); exit 1; }; }
3680       ;;
3681   esac
3682
3683 else
3684   with_pam=no
3685
3686 fi;
3687
3688 echo "$as_me:$LINENO: result: $with_pam" >&5
3689 echo "${ECHO_T}$with_pam" >&6
3690
3691
3692
3693 #
3694 # Bonjour
3695 #
3696 echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
3697 echo $ECHO_N "checking whether to build with Bonjour support... $ECHO_C" >&6
3698
3699
3700
3701 # Check whether --with-bonjour or --without-bonjour was given.
3702 if test "${with_bonjour+set}" = set; then
3703   withval="$with_bonjour"
3704
3705   case $withval in
3706     yes)
3707
3708 cat >>confdefs.h <<\_ACEOF
3709 #define USE_BONJOUR 1
3710 _ACEOF
3711
3712       ;;
3713     no)
3714       :
3715       ;;
3716     *)
3717       { { echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
3718 echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
3719    { (exit 1); exit 1; }; }
3720       ;;
3721   esac
3722
3723 else
3724   with_bonjour=no
3725
3726 fi;
3727
3728 echo "$as_me:$LINENO: result: $with_bonjour" >&5
3729 echo "${ECHO_T}$with_bonjour" >&6
3730
3731
3732
3733 #
3734 # OpenSSL
3735 #
3736 echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
3737 echo $ECHO_N "checking whether to build with OpenSSL support... $ECHO_C" >&6
3738
3739
3740
3741 # Check whether --with-openssl or --without-openssl was given.
3742 if test "${with_openssl+set}" = set; then
3743   withval="$with_openssl"
3744
3745   case $withval in
3746     yes)
3747
3748 cat >>confdefs.h <<\_ACEOF
3749 #define USE_SSL 1
3750 _ACEOF
3751
3752       ;;
3753     no)
3754       :
3755       ;;
3756     *)
3757       { { echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
3758 echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
3759    { (exit 1); exit 1; }; }
3760       ;;
3761   esac
3762
3763 else
3764   with_openssl=no
3765
3766 fi;
3767
3768 echo "$as_me:$LINENO: result: $with_openssl" >&5
3769 echo "${ECHO_T}$with_openssl" >&6
3770
3771
3772
3773 #
3774 # Prefer libedit
3775 #
3776
3777
3778
3779 # Check whether --with-libedit-preferred or --without-libedit-preferred was given.
3780 if test "${with_libedit_preferred+set}" = set; then
3781   withval="$with_libedit_preferred"
3782
3783   case $withval in
3784     yes)
3785       :
3786       ;;
3787     no)
3788       :
3789       ;;
3790     *)
3791       { { echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
3792 echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
3793    { (exit 1); exit 1; }; }
3794       ;;
3795   esac
3796
3797 else
3798   with_libedit_preferred=no
3799
3800 fi;
3801
3802
3803
3804 #
3805 # Readline
3806 #
3807
3808
3809
3810 # Check whether --with-readline or --without-readline was given.
3811 if test "${with_readline+set}" = set; then
3812   withval="$with_readline"
3813
3814   case $withval in
3815     yes)
3816       :
3817       ;;
3818     no)
3819       :
3820       ;;
3821     *)
3822       { { echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
3823 echo "$as_me: error: no argument expected for --with-readline option" >&2;}
3824    { (exit 1); exit 1; }; }
3825       ;;
3826   esac
3827
3828 else
3829   with_readline=yes
3830
3831 fi;
3832
3833 # readline on MinGW has problems with backslashes in psql and other bugs.
3834 # This is particularly a problem with non-US code pages.
3835 # Therefore disable its use until we understand the cause. 2004-07-20
3836 if test "$PORTNAME" = "win32"; then
3837   if test "$with_readline" = yes; then
3838     { echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
3839 echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
3840     with_readline=no
3841   fi
3842 fi
3843
3844
3845 #
3846 # Zlib
3847 #
3848
3849
3850
3851 # Check whether --with-zlib or --without-zlib was given.
3852 if test "${with_zlib+set}" = set; then
3853   withval="$with_zlib"
3854
3855   case $withval in
3856     yes)
3857       :
3858       ;;
3859     no)
3860       :
3861       ;;
3862     *)
3863       { { echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
3864 echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
3865    { (exit 1); exit 1; }; }
3866       ;;
3867   esac
3868
3869 else
3870   with_zlib=yes
3871
3872 fi;
3873
3874
3875
3876 #
3877 # Elf
3878 #
3879
3880 # Assume system is ELF if it predefines __ELF__ as 1,
3881 # otherwise believe host_os based default.
3882 case $host_os in
3883     freebsd1*|freebsd2*) elf=no;;
3884     freebsd3*|freebsd4*) elf=yes;;
3885 esac
3886
3887
3888 echo "$as_me:$LINENO: checking for egrep" >&5
3889 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
3890 if test "${ac_cv_prog_egrep+set}" = set; then
3891   echo $ECHO_N "(cached) $ECHO_C" >&6
3892 else
3893   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
3894     then ac_cv_prog_egrep='grep -E'
3895     else ac_cv_prog_egrep='egrep'
3896     fi
3897 fi
3898 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
3899 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
3900  EGREP=$ac_cv_prog_egrep
3901
3902
3903 cat >conftest.$ac_ext <<_ACEOF
3904 /* confdefs.h.  */
3905 _ACEOF
3906 cat confdefs.h >>conftest.$ac_ext
3907 cat >>conftest.$ac_ext <<_ACEOF
3908 /* end confdefs.h.  */
3909 #if __ELF__
3910   yes
3911 #endif
3912
3913 _ACEOF
3914 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3915   $EGREP "yes" >/dev/null 2>&1; then
3916   ELF_SYS=true
3917 else
3918   if test "X$elf" = "Xyes" ; then
3919   ELF_SYS=true
3920 else
3921   ELF_SYS=
3922 fi
3923 fi
3924 rm -f conftest*
3925
3926
3927
3928 #
3929 # Assignments
3930 #
3931
3932 CPPFLAGS="$CPPFLAGS $INCLUDES"
3933 LDFLAGS="$LDFLAGS $LIBDIRS"
3934
3935 { echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
3936 echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
3937 { echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
3938 echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
3939
3940
3941
3942 for ac_prog in gawk mawk nawk awk
3943 do
3944   # Extract the first word of "$ac_prog", so it can be a program name with args.
3945 set dummy $ac_prog; ac_word=$2
3946 echo "$as_me:$LINENO: checking for $ac_word" >&5
3947 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3948 if test "${ac_cv_prog_AWK+set}" = set; then
3949   echo $ECHO_N "(cached) $ECHO_C" >&6
3950 else
3951   if test -n "$AWK"; then
3952   ac_cv_prog_AWK="$AWK" # Let the user override the test.
3953 else
3954 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3955 for as_dir in $PATH
3956 do
3957   IFS=$as_save_IFS
3958   test -z "$as_dir" && as_dir=.
3959   for ac_exec_ext in '' $ac_executable_extensions; do
3960   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3961     ac_cv_prog_AWK="$ac_prog"
3962     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3963     break 2
3964   fi
3965 done
3966 done
3967
3968 fi
3969 fi
3970 AWK=$ac_cv_prog_AWK
3971 if test -n "$AWK"; then
3972   echo "$as_me:$LINENO: result: $AWK" >&5
3973 echo "${ECHO_T}$AWK" >&6
3974 else
3975   echo "$as_me:$LINENO: result: no" >&5
3976 echo "${ECHO_T}no" >&6
3977 fi
3978
3979   test -n "$AWK" && break
3980 done
3981
3982 echo "$as_me:$LINENO: checking for flex" >&5
3983 echo $ECHO_N "checking for flex... $ECHO_C" >&6
3984 if test "${pgac_cv_path_flex+set}" = set; then
3985   echo $ECHO_N "(cached) $ECHO_C" >&6
3986 else
3987   # Let the user override the test
3988 if test -n "$FLEX"; then
3989   pgac_cv_path_flex=$FLEX
3990 else
3991   pgac_save_IFS=$IFS
3992   IFS=$PATH_SEPARATOR
3993   for pgac_dir in $PATH; do
3994     IFS=$pgac_save_IFS
3995     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
3996       pgac_dir=`pwd`
3997     fi
3998     for pgac_prog in flex lex; do
3999       pgac_candidate="$pgac_dir/$pgac_prog"
4000       if test -f "$pgac_candidate" \
4001         && $pgac_candidate --version </dev/null >/dev/null 2>&1
4002       then
4003         echo '%%'  > conftest.l
4004         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
4005           if $pgac_candidate --version | grep ' 2\.5\.3$' >/dev/null 2>&1; then
4006             pgac_broken_flex=$pgac_candidate
4007             continue
4008           fi
4009
4010           pgac_cv_path_flex=$pgac_candidate
4011           break 2
4012         fi
4013       fi
4014     done
4015   done
4016   rm -f conftest.l lex.yy.c
4017   : ${pgac_cv_path_flex=no}
4018 fi
4019
4020 fi
4021 echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
4022 echo "${ECHO_T}$pgac_cv_path_flex" >&6
4023 if test x"$pgac_cv_path_flex" = x"no"; then
4024   if test -n "$pgac_broken_flex"; then
4025     { echo "$as_me:$LINENO: WARNING:
4026 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
4027 *** should get version 2.5.4 or later." >&5
4028 echo "$as_me: WARNING:
4029 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
4030 *** should get version 2.5.4 or later." >&2;}
4031   fi
4032
4033   { echo "$as_me:$LINENO: WARNING:
4034 *** Without Flex you will not be able to build PostgreSQL from CVS or
4035 *** change any of the scanner definition files.  You can obtain Flex from
4036 *** a GNU mirror site.  (If you are using the official distribution of
4037 *** PostgreSQL then you do not need to worry about this because the Flex
4038 *** output is pre-generated.)" >&5
4039 echo "$as_me: WARNING:
4040 *** Without Flex you will not be able to build PostgreSQL from CVS or
4041 *** change any of the scanner definition files.  You can obtain Flex from
4042 *** a GNU mirror site.  (If you are using the official distribution of
4043 *** PostgreSQL then you do not need to worry about this because the Flex
4044 *** output is pre-generated.)" >&2;}
4045 fi
4046
4047 if test x"$pgac_cv_path_flex" = x"no"; then
4048   FLEX=
4049 else
4050   FLEX=$pgac_cv_path_flex
4051 fi
4052
4053
4054
4055
4056 echo "$as_me:$LINENO: checking whether ln -s works" >&5
4057 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
4058 LN_S=$as_ln_s
4059 if test "$LN_S" = "ln -s"; then
4060   echo "$as_me:$LINENO: result: yes" >&5
4061 echo "${ECHO_T}yes" >&6
4062 else
4063   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
4064 echo "${ECHO_T}no, using $LN_S" >&6
4065 fi
4066
4067
4068 # Check whether --with-gnu-ld or --without-gnu-ld was given.
4069 if test "${with_gnu_ld+set}" = set; then
4070   withval="$with_gnu_ld"
4071   test "$withval" = no || with_gnu_ld=yes
4072 else
4073   with_gnu_ld=no
4074 fi;
4075 ac_prog=ld
4076 if test "$GCC" = yes; then
4077   # Check if gcc -print-prog-name=ld gives a path.
4078   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
4079 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
4080   case $host in
4081   *-*-mingw*)
4082     # gcc leaves a trailing carriage return which upsets mingw
4083     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4084   *)
4085     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4086   esac
4087   case "$ac_prog" in
4088     # Accept absolute paths.
4089     [\\/]* | [A-Za-z]:[\\/]*)
4090       re_direlt='/[^/][^/]*/\.\./'
4091       # Canonicalize the path of ld
4092       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
4093       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
4094         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
4095       done
4096       test -z "$LD" && LD="$ac_prog"
4097       ;;
4098   "")
4099     # If it fails, then pretend we aren't using GCC.
4100     ac_prog=ld
4101     ;;
4102   *)
4103     # If it is relative, then search for the first ld in PATH.
4104     with_gnu_ld=unknown
4105     ;;
4106   esac
4107 elif test "$with_gnu_ld" = yes; then
4108   echo "$as_me:$LINENO: checking for GNU ld" >&5
4109 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
4110 else
4111   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
4112 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
4113 fi
4114 if test "${ac_cv_path_LD+set}" = set; then
4115   echo $ECHO_N "(cached) $ECHO_C" >&6
4116 else
4117   if test -z "$LD"; then
4118   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
4119   for ac_dir in $PATH; do
4120     test -z "$ac_dir" && ac_dir=.
4121     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4122       ac_cv_path_LD="$ac_dir/$ac_prog"
4123       # Check to see if the program is GNU ld.  I'd rather use --version,
4124       # but apparently some GNU ld's only accept -v.
4125       # Break only if it was the GNU/non-GNU ld that we prefer.
4126       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
4127         test "$with_gnu_ld" != no && break
4128       else
4129         test "$with_gnu_ld" != yes && break
4130       fi
4131     fi
4132   done
4133   IFS="$ac_save_ifs"
4134 else
4135   ac_cv_path_LD="$LD" # Let the user override the test with a path.
4136 fi
4137 fi
4138
4139 LD="$ac_cv_path_LD"
4140 if test -n "$LD"; then
4141   echo "$as_me:$LINENO: result: $LD" >&5
4142 echo "${ECHO_T}$LD" >&6
4143 else
4144   echo "$as_me:$LINENO: result: no" >&5
4145 echo "${ECHO_T}no" >&6
4146 fi
4147 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
4148 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
4149    { (exit 1); exit 1; }; }
4150 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
4151 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
4152 if test "${ac_cv_prog_gnu_ld+set}" = set; then
4153   echo $ECHO_N "(cached) $ECHO_C" >&6
4154 else
4155   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
4156 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
4157   ac_cv_prog_gnu_ld=yes
4158 else
4159   ac_cv_prog_gnu_ld=no
4160 fi
4161 fi
4162 echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
4163 echo "${ECHO_T}$ac_cv_prog_gnu_ld" >&6
4164 with_gnu_ld=$ac_cv_prog_gnu_ld
4165
4166
4167
4168
4169 case $host_os in sysv5*)
4170   echo "$as_me:$LINENO: checking whether ld -R works" >&5
4171 echo $ECHO_N "checking whether ld -R works... $ECHO_C" >&6
4172 if test "${pgac_cv_prog_ld_R+set}" = set; then
4173   echo $ECHO_N "(cached) $ECHO_C" >&6
4174 else
4175
4176     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
4177     cat >conftest.$ac_ext <<_ACEOF
4178 /* confdefs.h.  */
4179 _ACEOF
4180 cat confdefs.h >>conftest.$ac_ext
4181 cat >>conftest.$ac_ext <<_ACEOF
4182 /* end confdefs.h.  */
4183
4184 int
4185 main ()
4186 {
4187
4188   ;
4189   return 0;
4190 }
4191 _ACEOF
4192 rm -f conftest.$ac_objext conftest$ac_exeext
4193 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4194   (eval $ac_link) 2>conftest.er1
4195   ac_status=$?
4196   grep -v '^ *+' conftest.er1 >conftest.err
4197   rm -f conftest.er1
4198   cat conftest.err >&5
4199   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4200   (exit $ac_status); } &&
4201          { ac_try='test -z "$ac_c_werror_flag"
4202                          || test ! -s conftest.err'
4203   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4204   (eval $ac_try) 2>&5
4205   ac_status=$?
4206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4207   (exit $ac_status); }; } &&
4208          { ac_try='test -s conftest$ac_exeext'
4209   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4210   (eval $ac_try) 2>&5
4211   ac_status=$?
4212   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4213   (exit $ac_status); }; }; then
4214   pgac_cv_prog_ld_R=yes
4215 else
4216   echo "$as_me: failed program was:" >&5
4217 sed 's/^/| /' conftest.$ac_ext >&5
4218
4219 pgac_cv_prog_ld_R=no
4220 fi
4221 rm -f conftest.err conftest.$ac_objext \
4222       conftest$ac_exeext conftest.$ac_ext
4223     LDFLAGS=$pgac_save_LDFLAGS
4224
4225 fi
4226 echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
4227 echo "${ECHO_T}$pgac_cv_prog_ld_R" >&6
4228   ld_R_works=$pgac_cv_prog_ld_R
4229
4230 esac
4231 if test -n "$ac_tool_prefix"; then
4232   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4233 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4234 echo "$as_me:$LINENO: checking for $ac_word" >&5
4235 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4236 if test "${ac_cv_prog_RANLIB+set}" = set; then
4237   echo $ECHO_N "(cached) $ECHO_C" >&6
4238 else
4239   if test -n "$RANLIB"; then
4240   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4241 else
4242 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4243 for as_dir in $PATH
4244 do
4245   IFS=$as_save_IFS
4246   test -z "$as_dir" && as_dir=.
4247   for ac_exec_ext in '' $ac_executable_extensions; do
4248   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4249     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4250     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4251     break 2
4252   fi
4253 done
4254 done
4255
4256 fi
4257 fi
4258 RANLIB=$ac_cv_prog_RANLIB
4259 if test -n "$RANLIB"; then
4260   echo "$as_me:$LINENO: result: $RANLIB" >&5
4261 echo "${ECHO_T}$RANLIB" >&6
4262 else
4263   echo "$as_me:$LINENO: result: no" >&5
4264 echo "${ECHO_T}no" >&6
4265 fi
4266
4267 fi
4268 if test -z "$ac_cv_prog_RANLIB"; then
4269   ac_ct_RANLIB=$RANLIB
4270   # Extract the first word of "ranlib", so it can be a program name with args.
4271 set dummy ranlib; ac_word=$2
4272 echo "$as_me:$LINENO: checking for $ac_word" >&5
4273 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4274 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4275   echo $ECHO_N "(cached) $ECHO_C" >&6
4276 else
4277   if test -n "$ac_ct_RANLIB"; then
4278   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4279 else
4280 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4281 for as_dir in $PATH
4282 do
4283   IFS=$as_save_IFS
4284   test -z "$as_dir" && as_dir=.
4285   for ac_exec_ext in '' $ac_executable_extensions; do
4286   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4287     ac_cv_prog_ac_ct_RANLIB="ranlib"
4288     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4289     break 2
4290   fi
4291 done
4292 done
4293
4294   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
4295 fi
4296 fi
4297 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4298 if test -n "$ac_ct_RANLIB"; then
4299   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
4300 echo "${ECHO_T}$ac_ct_RANLIB" >&6
4301 else
4302   echo "$as_me:$LINENO: result: no" >&5
4303 echo "${ECHO_T}no" >&6
4304 fi
4305
4306   RANLIB=$ac_ct_RANLIB
4307 else
4308   RANLIB="$ac_cv_prog_RANLIB"
4309 fi
4310
4311 for ac_prog in lorder
4312 do
4313   # Extract the first word of "$ac_prog", so it can be a program name with args.
4314 set dummy $ac_prog; ac_word=$2
4315 echo "$as_me:$LINENO: checking for $ac_word" >&5
4316 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4317 if test "${ac_cv_prog_LORDER+set}" = set; then
4318   echo $ECHO_N "(cached) $ECHO_C" >&6
4319 else
4320   if test -n "$LORDER"; then
4321   ac_cv_prog_LORDER="$LORDER" # Let the user override the test.
4322 else
4323 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4324 for as_dir in $PATH
4325 do
4326   IFS=$as_save_IFS
4327   test -z "$as_dir" && as_dir=.
4328   for ac_exec_ext in '' $ac_executable_extensions; do
4329   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4330     ac_cv_prog_LORDER="$ac_prog"
4331     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4332     break 2
4333   fi
4334 done
4335 done
4336
4337 fi
4338 fi
4339 LORDER=$ac_cv_prog_LORDER
4340 if test -n "$LORDER"; then
4341   echo "$as_me:$LINENO: result: $LORDER" >&5
4342 echo "${ECHO_T}$LORDER" >&6
4343 else
4344   echo "$as_me:$LINENO: result: no" >&5
4345 echo "${ECHO_T}no" >&6
4346 fi
4347
4348   test -n "$LORDER" && break
4349 done
4350
4351 # Extract the first word of "tar", so it can be a program name with args.
4352 set dummy tar; ac_word=$2
4353 echo "$as_me:$LINENO: checking for $ac_word" >&5
4354 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4355 if test "${ac_cv_path_TAR+set}" = set; then
4356   echo $ECHO_N "(cached) $ECHO_C" >&6
4357 else
4358   case $TAR in
4359   [\\/]* | ?:[\\/]*)
4360   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
4361   ;;
4362   *)
4363   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4364 for as_dir in $PATH
4365 do
4366   IFS=$as_save_IFS
4367   test -z "$as_dir" && as_dir=.
4368   for ac_exec_ext in '' $ac_executable_extensions; do
4369   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4370     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
4371     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4372     break 2
4373   fi
4374 done
4375 done
4376
4377   ;;
4378 esac
4379 fi
4380 TAR=$ac_cv_path_TAR
4381
4382 if test -n "$TAR"; then
4383   echo "$as_me:$LINENO: result: $TAR" >&5
4384 echo "${ECHO_T}$TAR" >&6
4385 else
4386   echo "$as_me:$LINENO: result: no" >&5
4387 echo "${ECHO_T}no" >&6
4388 fi
4389
4390
4391   if test -n "$ac_tool_prefix"; then
4392   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4393 set dummy ${ac_tool_prefix}strip; ac_word=$2
4394 echo "$as_me:$LINENO: checking for $ac_word" >&5
4395 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4396 if test "${ac_cv_prog_STRIP+set}" = set; then
4397   echo $ECHO_N "(cached) $ECHO_C" >&6
4398 else
4399   if test -n "$STRIP"; then
4400   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4401 else
4402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4403 for as_dir in $PATH
4404 do
4405   IFS=$as_save_IFS
4406   test -z "$as_dir" && as_dir=.
4407   for ac_exec_ext in '' $ac_executable_extensions; do
4408   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4409     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4410     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4411     break 2
4412   fi
4413 done
4414 done
4415
4416 fi
4417 fi
4418 STRIP=$ac_cv_prog_STRIP
4419 if test -n "$STRIP"; then
4420   echo "$as_me:$LINENO: result: $STRIP" >&5
4421 echo "${ECHO_T}$STRIP" >&6
4422 else
4423   echo "$as_me:$LINENO: result: no" >&5
4424 echo "${ECHO_T}no" >&6
4425 fi
4426
4427 fi
4428 if test -z "$ac_cv_prog_STRIP"; then
4429   ac_ct_STRIP=$STRIP
4430   # Extract the first word of "strip", so it can be a program name with args.
4431 set dummy strip; ac_word=$2
4432 echo "$as_me:$LINENO: checking for $ac_word" >&5
4433 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4434 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
4435   echo $ECHO_N "(cached) $ECHO_C" >&6
4436 else
4437   if test -n "$ac_ct_STRIP"; then
4438   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
4439 else
4440 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4441 for as_dir in $PATH
4442 do
4443   IFS=$as_save_IFS
4444   test -z "$as_dir" && as_dir=.
4445   for ac_exec_ext in '' $ac_executable_extensions; do
4446   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4447     ac_cv_prog_ac_ct_STRIP="strip"
4448     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4449     break 2
4450   fi
4451 done
4452 done
4453
4454   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
4455 fi
4456 fi
4457 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4458 if test -n "$ac_ct_STRIP"; then
4459   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
4460 echo "${ECHO_T}$ac_ct_STRIP" >&6
4461 else
4462   echo "$as_me:$LINENO: result: no" >&5
4463 echo "${ECHO_T}no" >&6
4464 fi
4465
4466   STRIP=$ac_ct_STRIP
4467 else
4468   STRIP="$ac_cv_prog_STRIP"
4469 fi
4470
4471
4472   echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
4473 echo $ECHO_N "checking whether it is possible to strip libraries... $ECHO_C" >&6
4474   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
4475     STRIP_STATIC_LIB="$STRIP -x"
4476     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
4477     echo "$as_me:$LINENO: result: yes" >&5
4478 echo "${ECHO_T}yes" >&6
4479   else
4480     STRIP_STATIC_LIB=:
4481     STRIP_SHARED_LIB=:
4482     echo "$as_me:$LINENO: result: no" >&5
4483 echo "${ECHO_T}no" >&6
4484   fi
4485
4486
4487
4488
4489 for ac_prog in 'bison -y'
4490 do
4491   # Extract the first word of "$ac_prog", so it can be a program name with args.
4492 set dummy $ac_prog; ac_word=$2
4493 echo "$as_me:$LINENO: checking for $ac_word" >&5
4494 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4495 if test "${ac_cv_prog_YACC+set}" = set; then
4496   echo $ECHO_N "(cached) $ECHO_C" >&6
4497 else
4498   if test -n "$YACC"; then
4499   ac_cv_prog_YACC="$YACC" # Let the user override the test.
4500 else
4501 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4502 for as_dir in $PATH
4503 do
4504   IFS=$as_save_IFS
4505   test -z "$as_dir" && as_dir=.
4506   for ac_exec_ext in '' $ac_executable_extensions; do
4507   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4508     ac_cv_prog_YACC="$ac_prog"
4509     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4510     break 2
4511   fi
4512 done
4513 done
4514
4515 fi
4516 fi
4517 YACC=$ac_cv_prog_YACC
4518 if test -n "$YACC"; then
4519   echo "$as_me:$LINENO: result: $YACC" >&5
4520 echo "${ECHO_T}$YACC" >&6
4521 else
4522   echo "$as_me:$LINENO: result: no" >&5
4523 echo "${ECHO_T}no" >&6
4524 fi
4525
4526   test -n "$YACC" && break
4527 done
4528
4529
4530 if test "$YACC"; then
4531   if $YACC --version | sed q | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'; then
4532     { echo "$as_me:$LINENO: WARNING:
4533 *** If you are going to modify the grammar files or build from CVS, the installed
4534 *** version of Bison is too old.  Bison version 1.875 or later is required." >&5
4535 echo "$as_me: WARNING:
4536 *** If you are going to modify the grammar files or build from CVS, the installed
4537 *** version of Bison is too old.  Bison version 1.875 or later is required." >&2;}
4538   fi
4539 fi
4540
4541 if test -z "$YACC"; then
4542   { echo "$as_me:$LINENO: WARNING:
4543 *** Without Bison you will not be able to build PostgreSQL from CVS or
4544 *** change any of the parser definition files.  You can obtain Bison from
4545 *** a GNU mirror site.  (If you are using the official distribution of
4546 *** PostgreSQL then you do not need to worry about this because the Bison
4547 *** output is pre-generated.)  To use a different yacc program (possible,
4548 *** but not recommended), set the environment variable YACC before running
4549 *** 'configure'." >&5
4550 echo "$as_me: WARNING:
4551 *** Without Bison you will not be able to build PostgreSQL from CVS or
4552 *** change any of the parser definition files.  You can obtain Bison from
4553 *** a GNU mirror site.  (If you are using the official distribution of
4554 *** PostgreSQL then you do not need to worry about this because the Bison
4555 *** output is pre-generated.)  To use a different yacc program (possible,
4556 *** but not recommended), set the environment variable YACC before running
4557 *** 'configure'." >&2;}
4558 fi
4559
4560
4561 # Extract the first word of "perl", so it can be a program name with args.
4562 set dummy perl; ac_word=$2
4563 echo "$as_me:$LINENO: checking for $ac_word" >&5
4564 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4565 if test "${ac_cv_path_PERL+set}" = set; then
4566   echo $ECHO_N "(cached) $ECHO_C" >&6
4567 else
4568   case $PERL in
4569   [\\/]* | ?:[\\/]*)
4570   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
4571   ;;
4572   *)
4573   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4574 for as_dir in $PATH
4575 do
4576   IFS=$as_save_IFS
4577   test -z "$as_dir" && as_dir=.
4578   for ac_exec_ext in '' $ac_executable_extensions; do
4579   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4580     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
4581     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4582     break 2
4583   fi
4584 done
4585 done
4586
4587   ;;
4588 esac
4589 fi
4590 PERL=$ac_cv_path_PERL
4591
4592 if test -n "$PERL"; then
4593   echo "$as_me:$LINENO: result: $PERL" >&5
4594 echo "${ECHO_T}$PERL" >&6
4595 else
4596   echo "$as_me:$LINENO: result: no" >&5
4597 echo "${ECHO_T}no" >&6
4598 fi
4599
4600 if test "$with_perl" = yes; then
4601
4602 echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
4603 echo $ECHO_N "checking for Perl archlibexp... $ECHO_C" >&6
4604 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
4605 echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
4606 echo "${ECHO_T}$perl_archlibexp" >&6
4607 echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
4608 echo $ECHO_N "checking for Perl privlibexp... $ECHO_C" >&6
4609 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
4610 echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
4611 echo "${ECHO_T}$perl_privlibexp" >&6
4612 echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
4613 echo $ECHO_N "checking for Perl useshrplib... $ECHO_C" >&6
4614 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
4615 echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
4616 echo "${ECHO_T}$perl_useshrplib" >&6
4617
4618 echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
4619 echo $ECHO_N "checking for flags to link embedded Perl... $ECHO_C" >&6
4620 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
4621 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
4622 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed "s/^X//;s%$pgac_tmp2%%"`
4623 echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
4624 echo "${ECHO_T}$perl_embed_ldflags" >&6
4625 fi
4626
4627 if test "$with_python" = yes; then
4628   # Extract the first word of "python", so it can be a program name with args.
4629 set dummy python; ac_word=$2
4630 echo "$as_me:$LINENO: checking for $ac_word" >&5
4631 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4632 if test "${ac_cv_path_PYTHON+set}" = set; then
4633   echo $ECHO_N "(cached) $ECHO_C" >&6
4634 else
4635   case $PYTHON in
4636   [\\/]* | ?:[\\/]*)
4637   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
4638   ;;
4639   *)
4640   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4641 for as_dir in $PATH
4642 do
4643   IFS=$as_save_IFS
4644   test -z "$as_dir" && as_dir=.
4645   for ac_exec_ext in '' $ac_executable_extensions; do
4646   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4647     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
4648     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4649     break 2
4650   fi
4651 done
4652 done
4653
4654   ;;
4655 esac
4656 fi
4657 PYTHON=$ac_cv_path_PYTHON
4658
4659 if test -n "$PYTHON"; then
4660   echo "$as_me:$LINENO: result: $PYTHON" >&5
4661 echo "${ECHO_T}$PYTHON" >&6
4662 else
4663   echo "$as_me:$LINENO: result: no" >&5
4664 echo "${ECHO_T}no" >&6
4665 fi
4666
4667 if test x"$PYTHON" = x""; then
4668   { { echo "$as_me:$LINENO: error: Python not found" >&5
4669 echo "$as_me: error: Python not found" >&2;}
4670    { (exit 1); exit 1; }; }
4671 fi
4672
4673
4674 echo "$as_me:$LINENO: checking for Python distutils module" >&5
4675 echo $ECHO_N "checking for Python distutils module... $ECHO_C" >&6
4676 if "${PYTHON}" 2>&- -c 'import distutils'
4677 then
4678     echo "$as_me:$LINENO: result: yes" >&5
4679 echo "${ECHO_T}yes" >&6
4680 else
4681     echo "$as_me:$LINENO: result: no" >&5
4682 echo "${ECHO_T}no" >&6
4683     { { echo "$as_me:$LINENO: error: distutils module not found" >&5
4684 echo "$as_me: error: distutils module not found" >&2;}
4685    { (exit 1); exit 1; }; }
4686 fi
4687 echo "$as_me:$LINENO: checking Python configuration directory" >&5
4688 echo $ECHO_N "checking Python configuration directory... $ECHO_C" >&6
4689 python_version=`${PYTHON} -c "import sys; print sys.version[:3]"`
4690 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')"`
4691 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print '-I'+distutils.sysconfig.get_python_inc()"`
4692
4693 # This should be enough of a message.
4694 echo "$as_me:$LINENO: result: $python_configdir" >&5
4695 echo "${ECHO_T}$python_configdir" >&6
4696
4697
4698 echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
4699 echo $ECHO_N "checking how to link an embedded Python application... $ECHO_C" >&6
4700
4701 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR')))"`
4702 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY')))"`
4703 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('SO')))"`
4704 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
4705
4706 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
4707 then
4708         # New way: use the official shared library
4709         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
4710         python_libspec="-L${python_libdir} -l${ldlibrary}"
4711 else
4712         # Old way: use libpython from python_configdir
4713         python_libdir="${python_configdir}"
4714         python_libspec="-L${python_libdir} -lpython${python_version}"
4715 fi
4716
4717 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','LOCALMODLIBS','BASEMODLIBS')))"`
4718
4719 echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
4720 echo "${ECHO_T}${python_libspec} ${python_additional_libs}" >&6
4721
4722
4723 # threaded python is not supported on bsd's
4724 echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
4725 echo $ECHO_N "checking whether Python is compiled with thread support... $ECHO_C" >&6
4726 pythreads=`${PYTHON} -c "import sys; print int('thread' in sys.builtin_module_names)"`
4727 if test "$pythreads" = "1"; then
4728   echo "$as_me:$LINENO: result: yes" >&5
4729 echo "${ECHO_T}yes" >&6
4730   case $host_os in
4731   openbsd*|freebsd4*)
4732     { { echo "$as_me:$LINENO: error: *** Threaded Python not supported on this platform ***" >&5
4733 echo "$as_me: error: *** Threaded Python not supported on this platform ***" >&2;}
4734    { (exit 1); exit 1; }; }
4735     ;;
4736   esac
4737 else
4738   echo "$as_me:$LINENO: result: no" >&5
4739 echo "${ECHO_T}no" >&6
4740 fi
4741
4742
4743 fi
4744
4745
4746 ##
4747 ## Libraries
4748 ##
4749
4750 echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
4751 echo $ECHO_N "checking for library containing setproctitle... $ECHO_C" >&6
4752 if test "${ac_cv_search_setproctitle+set}" = set; then
4753   echo $ECHO_N "(cached) $ECHO_C" >&6
4754 else
4755   ac_func_search_save_LIBS=$LIBS
4756 ac_cv_search_setproctitle=no
4757 cat >conftest.$ac_ext <<_ACEOF
4758 /* confdefs.h.  */
4759 _ACEOF
4760 cat confdefs.h >>conftest.$ac_ext
4761 cat >>conftest.$ac_ext <<_ACEOF
4762 /* end confdefs.h.  */
4763
4764 /* Override any gcc2 internal prototype to avoid an error.  */
4765 #ifdef __cplusplus
4766 extern "C"
4767 #endif
4768 /* We use char because int might match the return type of a gcc2
4769    builtin and then its argument prototype would still apply.  */
4770 char setproctitle ();
4771 int
4772 main ()
4773 {
4774 setproctitle ();
4775   ;
4776   return 0;
4777 }
4778 _ACEOF
4779 rm -f conftest.$ac_objext conftest$ac_exeext
4780 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4781   (eval $ac_link) 2>conftest.er1
4782   ac_status=$?
4783   grep -v '^ *+' conftest.er1 >conftest.err
4784   rm -f conftest.er1
4785   cat conftest.err >&5
4786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4787   (exit $ac_status); } &&
4788          { ac_try='test -z "$ac_c_werror_flag"
4789                          || test ! -s conftest.err'
4790   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4791   (eval $ac_try) 2>&5
4792   ac_status=$?
4793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4794   (exit $ac_status); }; } &&
4795          { ac_try='test -s conftest$ac_exeext'
4796   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4797   (eval $ac_try) 2>&5
4798   ac_status=$?
4799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4800   (exit $ac_status); }; }; then
4801   ac_cv_search_setproctitle="none required"
4802 else
4803   echo "$as_me: failed program was:" >&5
4804 sed 's/^/| /' conftest.$ac_ext >&5
4805
4806 fi
4807 rm -f conftest.err conftest.$ac_objext \
4808       conftest$ac_exeext conftest.$ac_ext
4809 if test "$ac_cv_search_setproctitle" = no; then
4810   for ac_lib in util; do
4811     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
4812     cat >conftest.$ac_ext <<_ACEOF
4813 /* confdefs.h.  */
4814 _ACEOF
4815 cat confdefs.h >>conftest.$ac_ext
4816 cat >>conftest.$ac_ext <<_ACEOF
4817 /* end confdefs.h.  */
4818
4819 /* Override any gcc2 internal prototype to avoid an error.  */
4820 #ifdef __cplusplus
4821 extern "C"
4822 #endif
4823 /* We use char because int might match the return type of a gcc2
4824    builtin and then its argument prototype would still apply.  */
4825 char setproctitle ();
4826 int
4827 main ()
4828 {
4829 setproctitle ();
4830   ;
4831   return 0;
4832 }
4833 _ACEOF
4834 rm -f conftest.$ac_objext conftest$ac_exeext
4835 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4836   (eval $ac_link) 2>conftest.er1
4837   ac_status=$?
4838   grep -v '^ *+' conftest.er1 >conftest.err
4839   rm -f conftest.er1
4840   cat conftest.err >&5
4841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4842   (exit $ac_status); } &&
4843          { ac_try='test -z "$ac_c_werror_flag"
4844                          || test ! -s conftest.err'
4845   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4846   (eval $ac_try) 2>&5
4847   ac_status=$?
4848   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4849   (exit $ac_status); }; } &&
4850          { ac_try='test -s conftest$ac_exeext'
4851   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4852   (eval $ac_try) 2>&5
4853   ac_status=$?
4854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4855   (exit $ac_status); }; }; then
4856   ac_cv_search_setproctitle="-l$ac_lib"
4857 break
4858 else
4859   echo "$as_me: failed program was:" >&5
4860 sed 's/^/| /' conftest.$ac_ext >&5
4861
4862 fi
4863 rm -f conftest.err conftest.$ac_objext \
4864       conftest$ac_exeext conftest.$ac_ext
4865   done
4866 fi
4867 LIBS=$ac_func_search_save_LIBS
4868 fi
4869 echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
4870 echo "${ECHO_T}$ac_cv_search_setproctitle" >&6
4871 if test "$ac_cv_search_setproctitle" != no; then
4872   test "$ac_cv_search_setproctitle" = "none required" || LIBS="$ac_cv_search_setproctitle $LIBS"
4873
4874 fi
4875
4876 echo "$as_me:$LINENO: checking for library containing pow" >&5
4877 echo $ECHO_N "checking for library containing pow... $ECHO_C" >&6
4878 if test "${ac_cv_search_pow+set}" = set; then
4879   echo $ECHO_N "(cached) $ECHO_C" >&6
4880 else
4881   ac_func_search_save_LIBS=$LIBS
4882 ac_cv_search_pow=no
4883 cat >conftest.$ac_ext <<_ACEOF
4884 /* confdefs.h.  */
4885 _ACEOF
4886 cat confdefs.h >>conftest.$ac_ext
4887 cat >>conftest.$ac_ext <<_ACEOF
4888 /* end confdefs.h.  */
4889
4890 /* Override any gcc2 internal prototype to avoid an error.  */
4891 #ifdef __cplusplus
4892 extern "C"
4893 #endif
4894 /* We use char because int might match the return type of a gcc2
4895    builtin and then its argument prototype would still apply.  */
4896 char pow ();
4897 int
4898 main ()
4899 {
4900 pow ();
4901   ;
4902   return 0;
4903 }
4904 _ACEOF
4905 rm -f conftest.$ac_objext conftest$ac_exeext
4906 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4907   (eval $ac_link) 2>conftest.er1
4908   ac_status=$?
4909   grep -v '^ *+' conftest.er1 >conftest.err
4910   rm -f conftest.er1
4911   cat conftest.err >&5
4912   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4913   (exit $ac_status); } &&
4914          { ac_try='test -z "$ac_c_werror_flag"
4915                          || test ! -s conftest.err'
4916   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4917   (eval $ac_try) 2>&5
4918   ac_status=$?
4919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4920   (exit $ac_status); }; } &&
4921          { ac_try='test -s conftest$ac_exeext'
4922   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4923   (eval $ac_try) 2>&5
4924   ac_status=$?
4925   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4926   (exit $ac_status); }; }; then
4927   ac_cv_search_pow="none required"
4928 else
4929   echo "$as_me: failed program was:" >&5
4930 sed 's/^/| /' conftest.$ac_ext >&5
4931
4932 fi
4933 rm -f conftest.err conftest.$ac_objext \
4934       conftest$ac_exeext conftest.$ac_ext
4935 if test "$ac_cv_search_pow" = no; then
4936   for ac_lib in m; do
4937     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
4938     cat >conftest.$ac_ext <<_ACEOF
4939 /* confdefs.h.  */
4940 _ACEOF
4941 cat confdefs.h >>conftest.$ac_ext
4942 cat >>conftest.$ac_ext <<_ACEOF
4943 /* end confdefs.h.  */
4944
4945 /* Override any gcc2 internal prototype to avoid an error.  */
4946 #ifdef __cplusplus
4947 extern "C"
4948 #endif
4949 /* We use char because int might match the return type of a gcc2
4950    builtin and then its argument prototype would still apply.  */
4951 char pow ();
4952 int
4953 main ()
4954 {
4955 pow ();
4956   ;
4957   return 0;
4958 }
4959 _ACEOF
4960 rm -f conftest.$ac_objext conftest$ac_exeext
4961 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4962   (eval $ac_link) 2>conftest.er1
4963   ac_status=$?
4964   grep -v '^ *+' conftest.er1 >conftest.err
4965   rm -f conftest.er1
4966   cat conftest.err >&5
4967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4968   (exit $ac_status); } &&
4969          { ac_try='test -z "$ac_c_werror_flag"
4970                          || test ! -s conftest.err'
4971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4972   (eval $ac_try) 2>&5
4973   ac_status=$?
4974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4975   (exit $ac_status); }; } &&
4976          { ac_try='test -s conftest$ac_exeext'
4977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4978   (eval $ac_try) 2>&5
4979   ac_status=$?
4980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4981   (exit $ac_status); }; }; then
4982   ac_cv_search_pow="-l$ac_lib"
4983 break
4984 else
4985   echo "$as_me: failed program was:" >&5
4986 sed 's/^/| /' conftest.$ac_ext >&5
4987
4988 fi
4989 rm -f conftest.err conftest.$ac_objext \
4990       conftest$ac_exeext conftest.$ac_ext
4991   done
4992 fi
4993 LIBS=$ac_func_search_save_LIBS
4994 fi
4995 echo "$as_me:$LINENO: result: $ac_cv_search_pow" >&5
4996 echo "${ECHO_T}$ac_cv_search_pow" >&6
4997 if test "$ac_cv_search_pow" != no; then
4998   test "$ac_cv_search_pow" = "none required" || LIBS="$ac_cv_search_pow $LIBS"
4999
5000 fi
5001
5002 echo "$as_me:$LINENO: checking for library containing dlopen" >&5
5003 echo $ECHO_N "checking for library containing dlopen... $ECHO_C" >&6
5004 if test "${ac_cv_search_dlopen+set}" = set; then
5005   echo $ECHO_N "(cached) $ECHO_C" >&6
5006 else
5007   ac_func_search_save_LIBS=$LIBS
5008 ac_cv_search_dlopen=no
5009 cat >conftest.$ac_ext <<_ACEOF
5010 /* confdefs.h.  */
5011 _ACEOF
5012 cat confdefs.h >>conftest.$ac_ext
5013 cat >>conftest.$ac_ext <<_ACEOF
5014 /* end confdefs.h.  */
5015
5016 /* Override any gcc2 internal prototype to avoid an error.  */
5017 #ifdef __cplusplus
5018 extern "C"
5019 #endif
5020 /* We use char because int might match the return type of a gcc2
5021    builtin and then its argument prototype would still apply.  */
5022 char dlopen ();
5023 int
5024 main ()
5025 {
5026 dlopen ();
5027   ;
5028   return 0;
5029 }
5030 _ACEOF
5031 rm -f conftest.$ac_objext conftest$ac_exeext
5032 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5033   (eval $ac_link) 2>conftest.er1
5034   ac_status=$?
5035   grep -v '^ *+' conftest.er1 >conftest.err
5036   rm -f conftest.er1
5037   cat conftest.err >&5
5038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5039   (exit $ac_status); } &&
5040          { ac_try='test -z "$ac_c_werror_flag"
5041                          || test ! -s conftest.err'
5042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5043   (eval $ac_try) 2>&5
5044   ac_status=$?
5045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5046   (exit $ac_status); }; } &&
5047          { ac_try='test -s conftest$ac_exeext'
5048   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5049   (eval $ac_try) 2>&5
5050   ac_status=$?
5051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5052   (exit $ac_status); }; }; then
5053   ac_cv_search_dlopen="none required"
5054 else
5055   echo "$as_me: failed program was:" >&5
5056 sed 's/^/| /' conftest.$ac_ext >&5
5057
5058 fi
5059 rm -f conftest.err conftest.$ac_objext \
5060       conftest$ac_exeext conftest.$ac_ext
5061 if test "$ac_cv_search_dlopen" = no; then
5062   for ac_lib in dl; do
5063     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5064     cat >conftest.$ac_ext <<_ACEOF
5065 /* confdefs.h.  */
5066 _ACEOF
5067 cat confdefs.h >>conftest.$ac_ext
5068 cat >>conftest.$ac_ext <<_ACEOF
5069 /* end confdefs.h.  */
5070
5071 /* Override any gcc2 internal prototype to avoid an error.  */
5072 #ifdef __cplusplus
5073 extern "C"
5074 #endif
5075 /* We use char because int might match the return type of a gcc2
5076    builtin and then its argument prototype would still apply.  */
5077 char dlopen ();
5078 int
5079 main ()
5080 {
5081 dlopen ();
5082   ;
5083   return 0;
5084 }
5085 _ACEOF
5086 rm -f conftest.$ac_objext conftest$ac_exeext
5087 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5088   (eval $ac_link) 2>conftest.er1
5089   ac_status=$?
5090   grep -v '^ *+' conftest.er1 >conftest.err
5091   rm -f conftest.er1
5092   cat conftest.err >&5
5093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5094   (exit $ac_status); } &&
5095          { ac_try='test -z "$ac_c_werror_flag"
5096                          || test ! -s conftest.err'
5097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5098   (eval $ac_try) 2>&5
5099   ac_status=$?
5100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5101   (exit $ac_status); }; } &&
5102          { ac_try='test -s conftest$ac_exeext'
5103   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5104   (eval $ac_try) 2>&5
5105   ac_status=$?
5106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5107   (exit $ac_status); }; }; then
5108   ac_cv_search_dlopen="-l$ac_lib"
5109 break
5110 else
5111   echo "$as_me: failed program was:" >&5
5112 sed 's/^/| /' conftest.$ac_ext >&5
5113
5114 fi
5115 rm -f conftest.err conftest.$ac_objext \
5116       conftest$ac_exeext conftest.$ac_ext
5117   done
5118 fi
5119 LIBS=$ac_func_search_save_LIBS
5120 fi
5121 echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
5122 echo "${ECHO_T}$ac_cv_search_dlopen" >&6
5123 if test "$ac_cv_search_dlopen" != no; then
5124   test "$ac_cv_search_dlopen" = "none required" || LIBS="$ac_cv_search_dlopen $LIBS"
5125
5126 fi
5127
5128 echo "$as_me:$LINENO: checking for library containing socket" >&5
5129 echo $ECHO_N "checking for library containing socket... $ECHO_C" >&6
5130 if test "${ac_cv_search_socket+set}" = set; then
5131   echo $ECHO_N "(cached) $ECHO_C" >&6
5132 else
5133   ac_func_search_save_LIBS=$LIBS
5134 ac_cv_search_socket=no
5135 cat >conftest.$ac_ext <<_ACEOF
5136 /* confdefs.h.  */
5137 _ACEOF
5138 cat confdefs.h >>conftest.$ac_ext
5139 cat >>conftest.$ac_ext <<_ACEOF
5140 /* end confdefs.h.  */
5141
5142 /* Override any gcc2 internal prototype to avoid an error.  */
5143 #ifdef __cplusplus
5144 extern "C"
5145 #endif
5146 /* We use char because int might match the return type of a gcc2
5147    builtin and then its argument prototype would still apply.  */
5148 char socket ();
5149 int
5150 main ()
5151 {
5152 socket ();
5153   ;
5154   return 0;
5155 }
5156 _ACEOF
5157 rm -f conftest.$ac_objext conftest$ac_exeext
5158 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5159   (eval $ac_link) 2>conftest.er1
5160   ac_status=$?
5161   grep -v '^ *+' conftest.er1 >conftest.err
5162   rm -f conftest.er1
5163   cat conftest.err >&5
5164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5165   (exit $ac_status); } &&
5166          { ac_try='test -z "$ac_c_werror_flag"
5167                          || test ! -s conftest.err'
5168   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5169   (eval $ac_try) 2>&5
5170   ac_status=$?
5171   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5172   (exit $ac_status); }; } &&
5173          { ac_try='test -s conftest$ac_exeext'
5174   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5175   (eval $ac_try) 2>&5
5176   ac_status=$?
5177   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5178   (exit $ac_status); }; }; then
5179   ac_cv_search_socket="none required"
5180 else
5181   echo "$as_me: failed program was:" >&5
5182 sed 's/^/| /' conftest.$ac_ext >&5
5183
5184 fi
5185 rm -f conftest.err conftest.$ac_objext \
5186       conftest$ac_exeext conftest.$ac_ext
5187 if test "$ac_cv_search_socket" = no; then
5188   for ac_lib in socket wsock32; do
5189     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5190     cat >conftest.$ac_ext <<_ACEOF
5191 /* confdefs.h.  */
5192 _ACEOF
5193 cat confdefs.h >>conftest.$ac_ext
5194 cat >>conftest.$ac_ext <<_ACEOF
5195 /* end confdefs.h.  */
5196
5197 /* Override any gcc2 internal prototype to avoid an error.  */
5198 #ifdef __cplusplus
5199 extern "C"
5200 #endif
5201 /* We use char because int might match the return type of a gcc2
5202    builtin and then its argument prototype would still apply.  */
5203 char socket ();
5204 int
5205 main ()
5206 {
5207 socket ();
5208   ;
5209   return 0;
5210 }
5211 _ACEOF
5212 rm -f conftest.$ac_objext conftest$ac_exeext
5213 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5214   (eval $ac_link) 2>conftest.er1
5215   ac_status=$?
5216   grep -v '^ *+' conftest.er1 >conftest.err
5217   rm -f conftest.er1
5218   cat conftest.err >&5
5219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5220   (exit $ac_status); } &&
5221          { ac_try='test -z "$ac_c_werror_flag"
5222                          || test ! -s conftest.err'
5223   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5224   (eval $ac_try) 2>&5
5225   ac_status=$?
5226   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5227   (exit $ac_status); }; } &&
5228          { ac_try='test -s conftest$ac_exeext'
5229   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5230   (eval $ac_try) 2>&5
5231   ac_status=$?
5232   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5233   (exit $ac_status); }; }; then
5234   ac_cv_search_socket="-l$ac_lib"
5235 break
5236 else
5237   echo "$as_me: failed program was:" >&5
5238 sed 's/^/| /' conftest.$ac_ext >&5
5239
5240 fi
5241 rm -f conftest.err conftest.$ac_objext \
5242       conftest$ac_exeext conftest.$ac_ext
5243   done
5244 fi
5245 LIBS=$ac_func_search_save_LIBS
5246 fi
5247 echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
5248 echo "${ECHO_T}$ac_cv_search_socket" >&6
5249 if test "$ac_cv_search_socket" != no; then
5250   test "$ac_cv_search_socket" = "none required" || LIBS="$ac_cv_search_socket $LIBS"
5251
5252 fi
5253
5254 echo "$as_me:$LINENO: checking for library containing shl_load" >&5
5255 echo $ECHO_N "checking for library containing shl_load... $ECHO_C" >&6
5256 if test "${ac_cv_search_shl_load+set}" = set; then
5257   echo $ECHO_N "(cached) $ECHO_C" >&6
5258 else
5259   ac_func_search_save_LIBS=$LIBS
5260 ac_cv_search_shl_load=no
5261 cat >conftest.$ac_ext <<_ACEOF
5262 /* confdefs.h.  */
5263 _ACEOF
5264 cat confdefs.h >>conftest.$ac_ext
5265 cat >>conftest.$ac_ext <<_ACEOF
5266 /* end confdefs.h.  */
5267
5268 /* Override any gcc2 internal prototype to avoid an error.  */
5269 #ifdef __cplusplus
5270 extern "C"
5271 #endif
5272 /* We use char because int might match the return type of a gcc2
5273    builtin and then its argument prototype would still apply.  */
5274 char shl_load ();
5275 int
5276 main ()
5277 {
5278 shl_load ();
5279   ;
5280   return 0;
5281 }
5282 _ACEOF
5283 rm -f conftest.$ac_objext conftest$ac_exeext
5284 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5285   (eval $ac_link) 2>conftest.er1
5286   ac_status=$?
5287   grep -v '^ *+' conftest.er1 >conftest.err
5288   rm -f conftest.er1
5289   cat conftest.err >&5
5290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5291   (exit $ac_status); } &&
5292          { ac_try='test -z "$ac_c_werror_flag"
5293                          || test ! -s conftest.err'
5294   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5295   (eval $ac_try) 2>&5
5296   ac_status=$?
5297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5298   (exit $ac_status); }; } &&
5299          { ac_try='test -s conftest$ac_exeext'
5300   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5301   (eval $ac_try) 2>&5
5302   ac_status=$?
5303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5304   (exit $ac_status); }; }; then
5305   ac_cv_search_shl_load="none required"
5306 else
5307   echo "$as_me: failed program was:" >&5
5308 sed 's/^/| /' conftest.$ac_ext >&5
5309
5310 fi
5311 rm -f conftest.err conftest.$ac_objext \
5312       conftest$ac_exeext conftest.$ac_ext
5313 if test "$ac_cv_search_shl_load" = no; then
5314   for ac_lib in dld; do
5315     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5316     cat >conftest.$ac_ext <<_ACEOF
5317 /* confdefs.h.  */
5318 _ACEOF
5319 cat confdefs.h >>conftest.$ac_ext
5320 cat >>conftest.$ac_ext <<_ACEOF
5321 /* end confdefs.h.  */
5322
5323 /* Override any gcc2 internal prototype to avoid an error.  */
5324 #ifdef __cplusplus
5325 extern "C"
5326 #endif
5327 /* We use char because int might match the return type of a gcc2
5328    builtin and then its argument prototype would still apply.  */
5329 char shl_load ();
5330 int
5331 main ()
5332 {
5333 shl_load ();
5334   ;
5335   return 0;
5336 }
5337 _ACEOF
5338 rm -f conftest.$ac_objext conftest$ac_exeext
5339 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5340   (eval $ac_link) 2>conftest.er1
5341   ac_status=$?
5342   grep -v '^ *+' conftest.er1 >conftest.err
5343   rm -f conftest.er1
5344   cat conftest.err >&5
5345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5346   (exit $ac_status); } &&
5347          { ac_try='test -z "$ac_c_werror_flag"
5348                          || test ! -s conftest.err'
5349   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5350   (eval $ac_try) 2>&5
5351   ac_status=$?
5352   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5353   (exit $ac_status); }; } &&
5354          { ac_try='test -s conftest$ac_exeext'
5355   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5356   (eval $ac_try) 2>&5
5357   ac_status=$?
5358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5359   (exit $ac_status); }; }; then
5360   ac_cv_search_shl_load="-l$ac_lib"
5361 break
5362 else
5363   echo "$as_me: failed program was:" >&5
5364 sed 's/^/| /' conftest.$ac_ext >&5
5365
5366 fi
5367 rm -f conftest.err conftest.$ac_objext \
5368       conftest$ac_exeext conftest.$ac_ext
5369   done
5370 fi
5371 LIBS=$ac_func_search_save_LIBS
5372 fi
5373 echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
5374 echo "${ECHO_T}$ac_cv_search_shl_load" >&6
5375 if test "$ac_cv_search_shl_load" != no; then
5376   test "$ac_cv_search_shl_load" = "none required" || LIBS="$ac_cv_search_shl_load $LIBS"
5377
5378 fi
5379
5380 # We only use libld in port/dynloader/aix.c
5381 case $host_os in
5382      aix*)
5383         echo "$as_me:$LINENO: checking for library containing ldopen" >&5
5384 echo $ECHO_N "checking for library containing ldopen... $ECHO_C" >&6
5385 if test "${ac_cv_search_ldopen+set}" = set; then
5386   echo $ECHO_N "(cached) $ECHO_C" >&6
5387 else
5388   ac_func_search_save_LIBS=$LIBS
5389 ac_cv_search_ldopen=no
5390 cat >conftest.$ac_ext <<_ACEOF
5391 /* confdefs.h.  */
5392 _ACEOF
5393 cat confdefs.h >>conftest.$ac_ext
5394 cat >>conftest.$ac_ext <<_ACEOF
5395 /* end confdefs.h.  */
5396
5397 /* Override any gcc2 internal prototype to avoid an error.  */
5398 #ifdef __cplusplus
5399 extern "C"
5400 #endif
5401 /* We use char because int might match the return type of a gcc2
5402    builtin and then its argument prototype would still apply.  */
5403 char ldopen ();
5404 int
5405 main ()
5406 {
5407 ldopen ();
5408   ;
5409   return 0;
5410 }
5411 _ACEOF
5412 rm -f conftest.$ac_objext conftest$ac_exeext
5413 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5414   (eval $ac_link) 2>conftest.er1
5415   ac_status=$?
5416   grep -v '^ *+' conftest.er1 >conftest.err
5417   rm -f conftest.er1
5418   cat conftest.err >&5
5419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5420   (exit $ac_status); } &&
5421          { ac_try='test -z "$ac_c_werror_flag"
5422                          || test ! -s conftest.err'
5423   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5424   (eval $ac_try) 2>&5
5425   ac_status=$?
5426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5427   (exit $ac_status); }; } &&
5428          { ac_try='test -s conftest$ac_exeext'
5429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5430   (eval $ac_try) 2>&5
5431   ac_status=$?
5432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5433   (exit $ac_status); }; }; then
5434   ac_cv_search_ldopen="none required"
5435 else
5436   echo "$as_me: failed program was:" >&5
5437 sed 's/^/| /' conftest.$ac_ext >&5
5438
5439 fi
5440 rm -f conftest.err conftest.$ac_objext \
5441       conftest$ac_exeext conftest.$ac_ext
5442 if test "$ac_cv_search_ldopen" = no; then
5443   for ac_lib in ld; do
5444     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5445     cat >conftest.$ac_ext <<_ACEOF
5446 /* confdefs.h.  */
5447 _ACEOF
5448 cat confdefs.h >>conftest.$ac_ext
5449 cat >>conftest.$ac_ext <<_ACEOF
5450 /* end confdefs.h.  */
5451
5452 /* Override any gcc2 internal prototype to avoid an error.  */
5453 #ifdef __cplusplus
5454 extern "C"
5455 #endif
5456 /* We use char because int might match the return type of a gcc2
5457    builtin and then its argument prototype would still apply.  */
5458 char ldopen ();
5459 int
5460 main ()
5461 {
5462 ldopen ();
5463   ;
5464   return 0;
5465 }
5466 _ACEOF
5467 rm -f conftest.$ac_objext conftest$ac_exeext
5468 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5469   (eval $ac_link) 2>conftest.er1
5470   ac_status=$?
5471   grep -v '^ *+' conftest.er1 >conftest.err
5472   rm -f conftest.er1
5473   cat conftest.err >&5
5474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5475   (exit $ac_status); } &&
5476          { ac_try='test -z "$ac_c_werror_flag"
5477                          || test ! -s conftest.err'
5478   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5479   (eval $ac_try) 2>&5
5480   ac_status=$?
5481   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5482   (exit $ac_status); }; } &&
5483          { ac_try='test -s conftest$ac_exeext'
5484   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5485   (eval $ac_try) 2>&5
5486   ac_status=$?
5487   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5488   (exit $ac_status); }; }; then
5489   ac_cv_search_ldopen="-l$ac_lib"
5490 break
5491 else
5492   echo "$as_me: failed program was:" >&5
5493 sed 's/^/| /' conftest.$ac_ext >&5
5494
5495 fi
5496 rm -f conftest.err conftest.$ac_objext \
5497       conftest$ac_exeext conftest.$ac_ext
5498   done
5499 fi
5500 LIBS=$ac_func_search_save_LIBS
5501 fi
5502 echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
5503 echo "${ECHO_T}$ac_cv_search_ldopen" >&6
5504 if test "$ac_cv_search_ldopen" != no; then
5505   test "$ac_cv_search_ldopen" = "none required" || LIBS="$ac_cv_search_ldopen $LIBS"
5506
5507 fi
5508
5509         ;;
5510 esac
5511 echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
5512 echo $ECHO_N "checking for library containing getopt_long... $ECHO_C" >&6
5513 if test "${ac_cv_search_getopt_long+set}" = set; then
5514   echo $ECHO_N "(cached) $ECHO_C" >&6
5515 else
5516   ac_func_search_save_LIBS=$LIBS
5517 ac_cv_search_getopt_long=no
5518 cat >conftest.$ac_ext <<_ACEOF
5519 /* confdefs.h.  */
5520 _ACEOF
5521 cat confdefs.h >>conftest.$ac_ext
5522 cat >>conftest.$ac_ext <<_ACEOF
5523 /* end confdefs.h.  */
5524
5525 /* Override any gcc2 internal prototype to avoid an error.  */
5526 #ifdef __cplusplus
5527 extern "C"
5528 #endif
5529 /* We use char because int might match the return type of a gcc2
5530    builtin and then its argument prototype would still apply.  */
5531 char getopt_long ();
5532 int
5533 main ()
5534 {
5535 getopt_long ();
5536   ;
5537   return 0;
5538 }
5539 _ACEOF
5540 rm -f conftest.$ac_objext conftest$ac_exeext
5541 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5542   (eval $ac_link) 2>conftest.er1
5543   ac_status=$?
5544   grep -v '^ *+' conftest.er1 >conftest.err
5545   rm -f conftest.er1
5546   cat conftest.err >&5
5547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5548   (exit $ac_status); } &&
5549          { ac_try='test -z "$ac_c_werror_flag"
5550                          || test ! -s conftest.err'
5551   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5552   (eval $ac_try) 2>&5
5553   ac_status=$?
5554   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5555   (exit $ac_status); }; } &&
5556          { ac_try='test -s conftest$ac_exeext'
5557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5558   (eval $ac_try) 2>&5
5559   ac_status=$?
5560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5561   (exit $ac_status); }; }; then
5562   ac_cv_search_getopt_long="none required"
5563 else
5564   echo "$as_me: failed program was:" >&5
5565 sed 's/^/| /' conftest.$ac_ext >&5
5566
5567 fi
5568 rm -f conftest.err conftest.$ac_objext \
5569       conftest$ac_exeext conftest.$ac_ext
5570 if test "$ac_cv_search_getopt_long" = no; then
5571   for ac_lib in getopt gnugetopt; do
5572     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5573     cat >conftest.$ac_ext <<_ACEOF
5574 /* confdefs.h.  */
5575 _ACEOF
5576 cat confdefs.h >>conftest.$ac_ext
5577 cat >>conftest.$ac_ext <<_ACEOF
5578 /* end confdefs.h.  */
5579
5580 /* Override any gcc2 internal prototype to avoid an error.  */
5581 #ifdef __cplusplus
5582 extern "C"
5583 #endif
5584 /* We use char because int might match the return type of a gcc2
5585    builtin and then its argument prototype would still apply.  */
5586 char getopt_long ();
5587 int
5588 main ()
5589 {
5590 getopt_long ();
5591   ;
5592   return 0;
5593 }
5594 _ACEOF
5595 rm -f conftest.$ac_objext conftest$ac_exeext
5596 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5597   (eval $ac_link) 2>conftest.er1
5598   ac_status=$?
5599   grep -v '^ *+' conftest.er1 >conftest.err
5600   rm -f conftest.er1
5601   cat conftest.err >&5
5602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5603   (exit $ac_status); } &&
5604          { ac_try='test -z "$ac_c_werror_flag"
5605                          || test ! -s conftest.err'
5606   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5607   (eval $ac_try) 2>&5
5608   ac_status=$?
5609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5610   (exit $ac_status); }; } &&
5611          { ac_try='test -s conftest$ac_exeext'
5612   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5613   (eval $ac_try) 2>&5
5614   ac_status=$?
5615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5616   (exit $ac_status); }; }; then
5617   ac_cv_search_getopt_long="-l$ac_lib"
5618 break
5619 else
5620   echo "$as_me: failed program was:" >&5
5621 sed 's/^/| /' conftest.$ac_ext >&5
5622
5623 fi
5624 rm -f conftest.err conftest.$ac_objext \
5625       conftest$ac_exeext conftest.$ac_ext
5626   done
5627 fi
5628 LIBS=$ac_func_search_save_LIBS
5629 fi
5630 echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
5631 echo "${ECHO_T}$ac_cv_search_getopt_long" >&6
5632 if test "$ac_cv_search_getopt_long" != no; then
5633   test "$ac_cv_search_getopt_long" = "none required" || LIBS="$ac_cv_search_getopt_long $LIBS"
5634
5635 fi
5636
5637 echo "$as_me:$LINENO: checking for library containing crypt" >&5
5638 echo $ECHO_N "checking for library containing crypt... $ECHO_C" >&6
5639 if test "${ac_cv_search_crypt+set}" = set; then
5640   echo $ECHO_N "(cached) $ECHO_C" >&6
5641 else
5642   ac_func_search_save_LIBS=$LIBS
5643 ac_cv_search_crypt=no
5644 cat >conftest.$ac_ext <<_ACEOF
5645 /* confdefs.h.  */
5646 _ACEOF
5647 cat confdefs.h >>conftest.$ac_ext
5648 cat >>conftest.$ac_ext <<_ACEOF
5649 /* end confdefs.h.  */
5650
5651 /* Override any gcc2 internal prototype to avoid an error.  */
5652 #ifdef __cplusplus
5653 extern "C"
5654 #endif
5655 /* We use char because int might match the return type of a gcc2
5656    builtin and then its argument prototype would still apply.  */
5657 char crypt ();
5658 int
5659 main ()
5660 {
5661 crypt ();
5662   ;
5663   return 0;
5664 }
5665 _ACEOF
5666 rm -f conftest.$ac_objext conftest$ac_exeext
5667 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5668   (eval $ac_link) 2>conftest.er1
5669   ac_status=$?
5670   grep -v '^ *+' conftest.er1 >conftest.err
5671   rm -f conftest.er1
5672   cat conftest.err >&5
5673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5674   (exit $ac_status); } &&
5675          { ac_try='test -z "$ac_c_werror_flag"
5676                          || test ! -s conftest.err'
5677   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5678   (eval $ac_try) 2>&5
5679   ac_status=$?
5680   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5681   (exit $ac_status); }; } &&
5682          { ac_try='test -s conftest$ac_exeext'
5683   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5684   (eval $ac_try) 2>&5
5685   ac_status=$?
5686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5687   (exit $ac_status); }; }; then
5688   ac_cv_search_crypt="none required"
5689 else
5690   echo "$as_me: failed program was:" >&5
5691 sed 's/^/| /' conftest.$ac_ext >&5
5692
5693 fi
5694 rm -f conftest.err conftest.$ac_objext \
5695       conftest$ac_exeext conftest.$ac_ext
5696 if test "$ac_cv_search_crypt" = no; then
5697   for ac_lib in crypt; do
5698     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5699     cat >conftest.$ac_ext <<_ACEOF
5700 /* confdefs.h.  */
5701 _ACEOF
5702 cat confdefs.h >>conftest.$ac_ext
5703 cat >>conftest.$ac_ext <<_ACEOF
5704 /* end confdefs.h.  */
5705
5706 /* Override any gcc2 internal prototype to avoid an error.  */
5707 #ifdef __cplusplus
5708 extern "C"
5709 #endif
5710 /* We use char because int might match the return type of a gcc2
5711    builtin and then its argument prototype would still apply.  */
5712 char crypt ();
5713 int
5714 main ()
5715 {
5716 crypt ();
5717   ;
5718   return 0;
5719 }
5720 _ACEOF
5721 rm -f conftest.$ac_objext conftest$ac_exeext
5722 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5723   (eval $ac_link) 2>conftest.er1
5724   ac_status=$?
5725   grep -v '^ *+' conftest.er1 >conftest.err
5726   rm -f conftest.er1
5727   cat conftest.err >&5
5728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5729   (exit $ac_status); } &&
5730          { ac_try='test -z "$ac_c_werror_flag"
5731                          || test ! -s conftest.err'
5732   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5733   (eval $ac_try) 2>&5
5734   ac_status=$?
5735   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5736   (exit $ac_status); }; } &&
5737          { ac_try='test -s conftest$ac_exeext'
5738   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5739   (eval $ac_try) 2>&5
5740   ac_status=$?
5741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5742   (exit $ac_status); }; }; then
5743   ac_cv_search_crypt="-l$ac_lib"
5744 break
5745 else
5746   echo "$as_me: failed program was:" >&5
5747 sed 's/^/| /' conftest.$ac_ext >&5
5748
5749 fi
5750 rm -f conftest.err conftest.$ac_objext \
5751       conftest$ac_exeext conftest.$ac_ext
5752   done
5753 fi
5754 LIBS=$ac_func_search_save_LIBS
5755 fi
5756 echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
5757 echo "${ECHO_T}$ac_cv_search_crypt" >&6
5758 if test "$ac_cv_search_crypt" != no; then
5759   test "$ac_cv_search_crypt" = "none required" || LIBS="$ac_cv_search_crypt $LIBS"
5760
5761 fi
5762
5763 # Solaris:
5764 echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
5765 echo $ECHO_N "checking for library containing fdatasync... $ECHO_C" >&6
5766 if test "${ac_cv_search_fdatasync+set}" = set; then
5767   echo $ECHO_N "(cached) $ECHO_C" >&6
5768 else
5769   ac_func_search_save_LIBS=$LIBS
5770 ac_cv_search_fdatasync=no
5771 cat >conftest.$ac_ext <<_ACEOF
5772 /* confdefs.h.  */
5773 _ACEOF
5774 cat confdefs.h >>conftest.$ac_ext
5775 cat >>conftest.$ac_ext <<_ACEOF
5776 /* end confdefs.h.  */
5777
5778 /* Override any gcc2 internal prototype to avoid an error.  */
5779 #ifdef __cplusplus
5780 extern "C"
5781 #endif
5782 /* We use char because int might match the return type of a gcc2
5783    builtin and then its argument prototype would still apply.  */
5784 char fdatasync ();
5785 int
5786 main ()
5787 {
5788 fdatasync ();
5789   ;
5790   return 0;
5791 }
5792 _ACEOF
5793 rm -f conftest.$ac_objext conftest$ac_exeext
5794 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5795   (eval $ac_link) 2>conftest.er1
5796   ac_status=$?
5797   grep -v '^ *+' conftest.er1 >conftest.err
5798   rm -f conftest.er1
5799   cat conftest.err >&5
5800   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5801   (exit $ac_status); } &&
5802          { ac_try='test -z "$ac_c_werror_flag"
5803                          || test ! -s conftest.err'
5804   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5805   (eval $ac_try) 2>&5
5806   ac_status=$?
5807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5808   (exit $ac_status); }; } &&
5809          { ac_try='test -s conftest$ac_exeext'
5810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5811   (eval $ac_try) 2>&5
5812   ac_status=$?
5813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5814   (exit $ac_status); }; }; then
5815   ac_cv_search_fdatasync="none required"
5816 else
5817   echo "$as_me: failed program was:" >&5
5818 sed 's/^/| /' conftest.$ac_ext >&5
5819
5820 fi
5821 rm -f conftest.err conftest.$ac_objext \
5822       conftest$ac_exeext conftest.$ac_ext
5823 if test "$ac_cv_search_fdatasync" = no; then
5824   for ac_lib in rt posix4; do
5825     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5826     cat >conftest.$ac_ext <<_ACEOF
5827 /* confdefs.h.  */
5828 _ACEOF
5829 cat confdefs.h >>conftest.$ac_ext
5830 cat >>conftest.$ac_ext <<_ACEOF
5831 /* end confdefs.h.  */
5832
5833 /* Override any gcc2 internal prototype to avoid an error.  */
5834 #ifdef __cplusplus
5835 extern "C"
5836 #endif
5837 /* We use char because int might match the return type of a gcc2
5838    builtin and then its argument prototype would still apply.  */
5839 char fdatasync ();
5840 int
5841 main ()
5842 {
5843 fdatasync ();
5844   ;
5845   return 0;
5846 }
5847 _ACEOF
5848 rm -f conftest.$ac_objext conftest$ac_exeext
5849 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5850   (eval $ac_link) 2>conftest.er1
5851   ac_status=$?
5852   grep -v '^ *+' conftest.er1 >conftest.err
5853   rm -f conftest.er1
5854   cat conftest.err >&5
5855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5856   (exit $ac_status); } &&
5857          { ac_try='test -z "$ac_c_werror_flag"
5858                          || test ! -s conftest.err'
5859   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5860   (eval $ac_try) 2>&5
5861   ac_status=$?
5862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5863   (exit $ac_status); }; } &&
5864          { ac_try='test -s conftest$ac_exeext'
5865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5866   (eval $ac_try) 2>&5
5867   ac_status=$?
5868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5869   (exit $ac_status); }; }; then
5870   ac_cv_search_fdatasync="-l$ac_lib"
5871 break
5872 else
5873   echo "$as_me: failed program was:" >&5
5874 sed 's/^/| /' conftest.$ac_ext >&5
5875
5876 fi
5877 rm -f conftest.err conftest.$ac_objext \
5878       conftest$ac_exeext conftest.$ac_ext
5879   done
5880 fi
5881 LIBS=$ac_func_search_save_LIBS
5882 fi
5883 echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
5884 echo "${ECHO_T}$ac_cv_search_fdatasync" >&6
5885 if test "$ac_cv_search_fdatasync" != no; then
5886   test "$ac_cv_search_fdatasync" = "none required" || LIBS="$ac_cv_search_fdatasync $LIBS"
5887
5888 fi
5889
5890 # Cygwin:
5891 echo "$as_me:$LINENO: checking for library containing shmget" >&5
5892 echo $ECHO_N "checking for library containing shmget... $ECHO_C" >&6
5893 if test "${ac_cv_search_shmget+set}" = set; then
5894   echo $ECHO_N "(cached) $ECHO_C" >&6
5895 else
5896   ac_func_search_save_LIBS=$LIBS
5897 ac_cv_search_shmget=no
5898 cat >conftest.$ac_ext <<_ACEOF
5899 /* confdefs.h.  */
5900 _ACEOF
5901 cat confdefs.h >>conftest.$ac_ext
5902 cat >>conftest.$ac_ext <<_ACEOF
5903 /* end confdefs.h.  */
5904
5905 /* Override any gcc2 internal prototype to avoid an error.  */
5906 #ifdef __cplusplus
5907 extern "C"
5908 #endif
5909 /* We use char because int might match the return type of a gcc2
5910    builtin and then its argument prototype would still apply.  */
5911 char shmget ();
5912 int
5913 main ()
5914 {
5915 shmget ();
5916   ;
5917   return 0;
5918 }
5919 _ACEOF
5920 rm -f conftest.$ac_objext conftest$ac_exeext
5921 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&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   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5928   (exit $ac_status); } &&
5929          { ac_try='test -z "$ac_c_werror_flag"
5930                          || test ! -s conftest.err'
5931   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5932   (eval $ac_try) 2>&5
5933   ac_status=$?
5934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5935   (exit $ac_status); }; } &&
5936          { ac_try='test -s conftest$ac_exeext'
5937   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5938   (eval $ac_try) 2>&5
5939   ac_status=$?
5940   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5941   (exit $ac_status); }; }; then
5942   ac_cv_search_shmget="none required"
5943 else
5944   echo "$as_me: failed program was:" >&5
5945 sed 's/^/| /' conftest.$ac_ext >&5
5946
5947 fi
5948 rm -f conftest.err conftest.$ac_objext \
5949       conftest$ac_exeext conftest.$ac_ext
5950 if test "$ac_cv_search_shmget" = no; then
5951   for ac_lib in cygipc; do
5952     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5953     cat >conftest.$ac_ext <<_ACEOF
5954 /* confdefs.h.  */
5955 _ACEOF
5956 cat confdefs.h >>conftest.$ac_ext
5957 cat >>conftest.$ac_ext <<_ACEOF
5958 /* end confdefs.h.  */
5959
5960 /* Override any gcc2 internal prototype to avoid an error.  */
5961 #ifdef __cplusplus
5962 extern "C"
5963 #endif
5964 /* We use char because int might match the return type of a gcc2
5965    builtin and then its argument prototype would still apply.  */
5966 char shmget ();
5967 int
5968 main ()
5969 {
5970 shmget ();
5971   ;
5972   return 0;
5973 }
5974 _ACEOF
5975 rm -f conftest.$ac_objext conftest$ac_exeext
5976 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5977   (eval $ac_link) 2>conftest.er1
5978   ac_status=$?
5979   grep -v '^ *+' conftest.er1 >conftest.err
5980   rm -f conftest.er1
5981   cat conftest.err >&5
5982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5983   (exit $ac_status); } &&
5984          { ac_try='test -z "$ac_c_werror_flag"
5985                          || test ! -s conftest.err'
5986   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5987   (eval $ac_try) 2>&5
5988   ac_status=$?
5989   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5990   (exit $ac_status); }; } &&
5991          { ac_try='test -s conftest$ac_exeext'
5992   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5993   (eval $ac_try) 2>&5
5994   ac_status=$?
5995   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5996   (exit $ac_status); }; }; then
5997   ac_cv_search_shmget="-l$ac_lib"
5998 break
5999 else
6000   echo "$as_me: failed program was:" >&5
6001 sed 's/^/| /' conftest.$ac_ext >&5
6002
6003 fi
6004 rm -f conftest.err conftest.$ac_objext \
6005       conftest$ac_exeext conftest.$ac_ext
6006   done
6007 fi
6008 LIBS=$ac_func_search_save_LIBS
6009 fi
6010 echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
6011 echo "${ECHO_T}$ac_cv_search_shmget" >&6
6012 if test "$ac_cv_search_shmget" != no; then
6013   test "$ac_cv_search_shmget" = "none required" || LIBS="$ac_cv_search_shmget $LIBS"
6014
6015 fi
6016
6017
6018 if test "$with_readline" = yes; then
6019
6020
6021 if test "${pgac_cv_check_readline+set}" = set; then
6022   echo $ECHO_N "(cached) $ECHO_C" >&6
6023 else
6024   pgac_cv_check_readline=no
6025 pgac_save_LIBS=$LIBS
6026 if test x"$with_libedit_preferred" != x"yes"
6027 then    READLINE_ORDER="-lreadline -ledit"
6028 else    READLINE_ORDER="-ledit -lreadline"
6029 fi
6030 for pgac_rllib in $READLINE_ORDER ; do
6031   echo "$as_me:$LINENO: checking for ${pgac_rllib}" >&5
6032 echo $ECHO_N "checking for ${pgac_rllib}... $ECHO_C" >&6
6033   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
6034     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
6035     cat >conftest.$ac_ext <<_ACEOF
6036 /* confdefs.h.  */
6037 _ACEOF
6038 cat confdefs.h >>conftest.$ac_ext
6039 cat >>conftest.$ac_ext <<_ACEOF
6040 /* end confdefs.h.  */
6041
6042 /* Override any gcc2 internal prototype to avoid an error.  */
6043 #ifdef __cplusplus
6044 extern "C"
6045 #endif
6046 /* We use char because int might match the return type of a gcc2
6047    builtin and then its argument prototype would still apply.  */
6048 char readline ();
6049 int
6050 main ()
6051 {
6052 readline ();
6053   ;
6054   return 0;
6055 }
6056 _ACEOF
6057 rm -f conftest.$ac_objext conftest$ac_exeext
6058 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6059   (eval $ac_link) 2>conftest.er1
6060   ac_status=$?
6061   grep -v '^ *+' conftest.er1 >conftest.err
6062   rm -f conftest.er1
6063   cat conftest.err >&5
6064   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6065   (exit $ac_status); } &&
6066          { ac_try='test -z "$ac_c_werror_flag"
6067                          || test ! -s conftest.err'
6068   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6069   (eval $ac_try) 2>&5
6070   ac_status=$?
6071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6072   (exit $ac_status); }; } &&
6073          { ac_try='test -s conftest$ac_exeext'
6074   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6075   (eval $ac_try) 2>&5
6076   ac_status=$?
6077   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6078   (exit $ac_status); }; }; then
6079
6080       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
6081       # recognize dependent libraries; assume curses is needed if we didn't
6082       # find any dependency.
6083       case $host_os in
6084         netbsd* | openbsd* | irix*)
6085           if test x"$pgac_lib" = x"" ; then
6086             pgac_lib=" -lcurses"
6087           fi ;;
6088       esac
6089
6090       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
6091       break
6092
6093 else
6094   echo "$as_me: failed program was:" >&5
6095 sed 's/^/| /' conftest.$ac_ext >&5
6096
6097 fi
6098 rm -f conftest.err conftest.$ac_objext \
6099       conftest$ac_exeext conftest.$ac_ext
6100   done
6101   if test "$pgac_cv_check_readline" != no ; then
6102     echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
6103 echo "${ECHO_T}yes ($pgac_cv_check_readline)" >&6
6104     break
6105   else
6106     echo "$as_me:$LINENO: result: no" >&5
6107 echo "${ECHO_T}no" >&6
6108   fi
6109 done
6110 LIBS=$pgac_save_LIBS
6111
6112 fi
6113
6114 if test "$pgac_cv_check_readline" != no ; then
6115   LIBS="$pgac_cv_check_readline $LIBS"
6116
6117 cat >>confdefs.h <<\_ACEOF
6118 #define HAVE_LIBREADLINE 1
6119 _ACEOF
6120
6121 fi
6122
6123
6124   if test x"$pgac_cv_check_readline" = x"no"; then
6125     { { echo "$as_me:$LINENO: error: readline library not found
6126 If you have readline already installed, see config.log for details on the
6127 failure.  It is possible the compiler isn't looking in the proper directory.
6128 Use --without-readline to disable readline support." >&5
6129 echo "$as_me: error: readline library not found
6130 If you have readline already installed, see config.log for details on the
6131 failure.  It is possible the compiler isn't looking in the proper directory.
6132 Use --without-readline to disable readline support." >&2;}
6133    { (exit 1); exit 1; }; }
6134   fi
6135 fi
6136
6137 if test "$with_zlib" = yes; then
6138
6139 echo "$as_me:$LINENO: checking for inflate in -lz" >&5
6140 echo $ECHO_N "checking for inflate in -lz... $ECHO_C" >&6
6141 if test "${ac_cv_lib_z_inflate+set}" = set; then
6142   echo $ECHO_N "(cached) $ECHO_C" >&6
6143 else
6144   ac_check_lib_save_LIBS=$LIBS
6145 LIBS="-lz  $LIBS"
6146 cat >conftest.$ac_ext <<_ACEOF
6147 /* confdefs.h.  */
6148 _ACEOF
6149 cat confdefs.h >>conftest.$ac_ext
6150 cat >>conftest.$ac_ext <<_ACEOF
6151 /* end confdefs.h.  */
6152
6153 /* Override any gcc2 internal prototype to avoid an error.  */
6154 #ifdef __cplusplus
6155 extern "C"
6156 #endif
6157 /* We use char because int might match the return type of a gcc2
6158    builtin and then its argument prototype would still apply.  */
6159 char inflate ();
6160 int
6161 main ()
6162 {
6163 inflate ();
6164   ;
6165   return 0;
6166 }
6167 _ACEOF
6168 rm -f conftest.$ac_objext conftest$ac_exeext
6169 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6170   (eval $ac_link) 2>conftest.er1
6171   ac_status=$?
6172   grep -v '^ *+' conftest.er1 >conftest.err
6173   rm -f conftest.er1
6174   cat conftest.err >&5
6175   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6176   (exit $ac_status); } &&
6177          { ac_try='test -z "$ac_c_werror_flag"
6178                          || test ! -s conftest.err'
6179   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6180   (eval $ac_try) 2>&5
6181   ac_status=$?
6182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6183   (exit $ac_status); }; } &&
6184          { ac_try='test -s conftest$ac_exeext'
6185   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6186   (eval $ac_try) 2>&5
6187   ac_status=$?
6188   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6189   (exit $ac_status); }; }; then
6190   ac_cv_lib_z_inflate=yes
6191 else
6192   echo "$as_me: failed program was:" >&5
6193 sed 's/^/| /' conftest.$ac_ext >&5
6194
6195 ac_cv_lib_z_inflate=no
6196 fi
6197 rm -f conftest.err conftest.$ac_objext \
6198       conftest$ac_exeext conftest.$ac_ext
6199 LIBS=$ac_check_lib_save_LIBS
6200 fi
6201 echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
6202 echo "${ECHO_T}$ac_cv_lib_z_inflate" >&6
6203 if test $ac_cv_lib_z_inflate = yes; then
6204   cat >>confdefs.h <<_ACEOF
6205 #define HAVE_LIBZ 1
6206 _ACEOF
6207
6208   LIBS="-lz $LIBS"
6209
6210 else
6211   { { echo "$as_me:$LINENO: error: zlib library not found
6212 If you have zlib already installed, see config.log for details on the
6213 failure.  It is possible the compiler isn't looking in the proper directory.
6214 Use --without-zlib to disable zlib support." >&5
6215 echo "$as_me: error: zlib library not found
6216 If you have zlib already installed, see config.log for details on the
6217 failure.  It is possible the compiler isn't looking in the proper directory.
6218 Use --without-zlib to disable zlib support." >&2;}
6219    { (exit 1); exit 1; }; }
6220 fi
6221
6222 fi
6223
6224 if test "$enable_spinlocks" = yes; then
6225
6226 cat >>confdefs.h <<\_ACEOF
6227 #define HAVE_SPINLOCKS 1
6228 _ACEOF
6229
6230 else
6231   { echo "$as_me:$LINENO: WARNING:
6232 *** Not using spinlocks will cause poor performance." >&5
6233 echo "$as_me: WARNING:
6234 *** Not using spinlocks will cause poor performance." >&2;}
6235 fi
6236
6237 if test "$with_krb5" = yes ; then
6238   if test "$PORTNAME" != "win32"; then
6239      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6240 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6241 if test "${ac_cv_search_com_err+set}" = set; then
6242   echo $ECHO_N "(cached) $ECHO_C" >&6
6243 else
6244   ac_func_search_save_LIBS=$LIBS
6245 ac_cv_search_com_err=no
6246 cat >conftest.$ac_ext <<_ACEOF
6247 /* confdefs.h.  */
6248 _ACEOF
6249 cat confdefs.h >>conftest.$ac_ext
6250 cat >>conftest.$ac_ext <<_ACEOF
6251 /* end confdefs.h.  */
6252
6253 /* Override any gcc2 internal prototype to avoid an error.  */
6254 #ifdef __cplusplus
6255 extern "C"
6256 #endif
6257 /* We use char because int might match the return type of a gcc2
6258    builtin and then its argument prototype would still apply.  */
6259 char com_err ();
6260 int
6261 main ()
6262 {
6263 com_err ();
6264   ;
6265   return 0;
6266 }
6267 _ACEOF
6268 rm -f conftest.$ac_objext conftest$ac_exeext
6269 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6270   (eval $ac_link) 2>conftest.er1
6271   ac_status=$?
6272   grep -v '^ *+' conftest.er1 >conftest.err
6273   rm -f conftest.er1
6274   cat conftest.err >&5
6275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6276   (exit $ac_status); } &&
6277          { ac_try='test -z "$ac_c_werror_flag"
6278                          || test ! -s conftest.err'
6279   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6280   (eval $ac_try) 2>&5
6281   ac_status=$?
6282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6283   (exit $ac_status); }; } &&
6284          { ac_try='test -s conftest$ac_exeext'
6285   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6286   (eval $ac_try) 2>&5
6287   ac_status=$?
6288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6289   (exit $ac_status); }; }; then
6290   ac_cv_search_com_err="none required"
6291 else
6292   echo "$as_me: failed program was:" >&5
6293 sed 's/^/| /' conftest.$ac_ext >&5
6294
6295 fi
6296 rm -f conftest.err conftest.$ac_objext \
6297       conftest$ac_exeext conftest.$ac_ext
6298 if test "$ac_cv_search_com_err" = no; then
6299   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' com_err; do
6300     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6301     cat >conftest.$ac_ext <<_ACEOF
6302 /* confdefs.h.  */
6303 _ACEOF
6304 cat confdefs.h >>conftest.$ac_ext
6305 cat >>conftest.$ac_ext <<_ACEOF
6306 /* end confdefs.h.  */
6307
6308 /* Override any gcc2 internal prototype to avoid an error.  */
6309 #ifdef __cplusplus
6310 extern "C"
6311 #endif
6312 /* We use char because int might match the return type of a gcc2
6313    builtin and then its argument prototype would still apply.  */
6314 char com_err ();
6315 int
6316 main ()
6317 {
6318 com_err ();
6319   ;
6320   return 0;
6321 }
6322 _ACEOF
6323 rm -f conftest.$ac_objext conftest$ac_exeext
6324 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6325   (eval $ac_link) 2>conftest.er1
6326   ac_status=$?
6327   grep -v '^ *+' conftest.er1 >conftest.err
6328   rm -f conftest.er1
6329   cat conftest.err >&5
6330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6331   (exit $ac_status); } &&
6332          { ac_try='test -z "$ac_c_werror_flag"
6333                          || test ! -s conftest.err'
6334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6335   (eval $ac_try) 2>&5
6336   ac_status=$?
6337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6338   (exit $ac_status); }; } &&
6339          { ac_try='test -s conftest$ac_exeext'
6340   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6341   (eval $ac_try) 2>&5
6342   ac_status=$?
6343   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6344   (exit $ac_status); }; }; then
6345   ac_cv_search_com_err="-l$ac_lib"
6346 break
6347 else
6348   echo "$as_me: failed program was:" >&5
6349 sed 's/^/| /' conftest.$ac_ext >&5
6350
6351 fi
6352 rm -f conftest.err conftest.$ac_objext \
6353       conftest$ac_exeext conftest.$ac_ext
6354   done
6355 fi
6356 LIBS=$ac_func_search_save_LIBS
6357 fi
6358 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6359 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6360 if test "$ac_cv_search_com_err" != no; then
6361   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6362
6363 else
6364   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6365 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6366    { (exit 1); exit 1; }; }
6367 fi
6368
6369      echo "$as_me:$LINENO: checking for library containing krb5_encrypt" >&5
6370 echo $ECHO_N "checking for library containing krb5_encrypt... $ECHO_C" >&6
6371 if test "${ac_cv_search_krb5_encrypt+set}" = set; then
6372   echo $ECHO_N "(cached) $ECHO_C" >&6
6373 else
6374   ac_func_search_save_LIBS=$LIBS
6375 ac_cv_search_krb5_encrypt=no
6376 cat >conftest.$ac_ext <<_ACEOF
6377 /* confdefs.h.  */
6378 _ACEOF
6379 cat confdefs.h >>conftest.$ac_ext
6380 cat >>conftest.$ac_ext <<_ACEOF
6381 /* end confdefs.h.  */
6382
6383 /* Override any gcc2 internal prototype to avoid an error.  */
6384 #ifdef __cplusplus
6385 extern "C"
6386 #endif
6387 /* We use char because int might match the return type of a gcc2
6388    builtin and then its argument prototype would still apply.  */
6389 char krb5_encrypt ();
6390 int
6391 main ()
6392 {
6393 krb5_encrypt ();
6394   ;
6395   return 0;
6396 }
6397 _ACEOF
6398 rm -f conftest.$ac_objext conftest$ac_exeext
6399 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6400   (eval $ac_link) 2>conftest.er1
6401   ac_status=$?
6402   grep -v '^ *+' conftest.er1 >conftest.err
6403   rm -f conftest.er1
6404   cat conftest.err >&5
6405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6406   (exit $ac_status); } &&
6407          { ac_try='test -z "$ac_c_werror_flag"
6408                          || test ! -s conftest.err'
6409   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6410   (eval $ac_try) 2>&5
6411   ac_status=$?
6412   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6413   (exit $ac_status); }; } &&
6414          { ac_try='test -s conftest$ac_exeext'
6415   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6416   (eval $ac_try) 2>&5
6417   ac_status=$?
6418   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6419   (exit $ac_status); }; }; then
6420   ac_cv_search_krb5_encrypt="none required"
6421 else
6422   echo "$as_me: failed program was:" >&5
6423 sed 's/^/| /' conftest.$ac_ext >&5
6424
6425 fi
6426 rm -f conftest.err conftest.$ac_objext \
6427       conftest$ac_exeext conftest.$ac_ext
6428 if test "$ac_cv_search_krb5_encrypt" = no; then
6429   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' crypto k5crypto; do
6430     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6431     cat >conftest.$ac_ext <<_ACEOF
6432 /* confdefs.h.  */
6433 _ACEOF
6434 cat confdefs.h >>conftest.$ac_ext
6435 cat >>conftest.$ac_ext <<_ACEOF
6436 /* end confdefs.h.  */
6437
6438 /* Override any gcc2 internal prototype to avoid an error.  */
6439 #ifdef __cplusplus
6440 extern "C"
6441 #endif
6442 /* We use char because int might match the return type of a gcc2
6443    builtin and then its argument prototype would still apply.  */
6444 char krb5_encrypt ();
6445 int
6446 main ()
6447 {
6448 krb5_encrypt ();
6449   ;
6450   return 0;
6451 }
6452 _ACEOF
6453 rm -f conftest.$ac_objext conftest$ac_exeext
6454 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6455   (eval $ac_link) 2>conftest.er1
6456   ac_status=$?
6457   grep -v '^ *+' conftest.er1 >conftest.err
6458   rm -f conftest.er1
6459   cat conftest.err >&5
6460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6461   (exit $ac_status); } &&
6462          { ac_try='test -z "$ac_c_werror_flag"
6463                          || test ! -s conftest.err'
6464   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6465   (eval $ac_try) 2>&5
6466   ac_status=$?
6467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6468   (exit $ac_status); }; } &&
6469          { ac_try='test -s conftest$ac_exeext'
6470   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6471   (eval $ac_try) 2>&5
6472   ac_status=$?
6473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6474   (exit $ac_status); }; }; then
6475   ac_cv_search_krb5_encrypt="-l$ac_lib"
6476 break
6477 else
6478   echo "$as_me: failed program was:" >&5
6479 sed 's/^/| /' conftest.$ac_ext >&5
6480
6481 fi
6482 rm -f conftest.err conftest.$ac_objext \
6483       conftest$ac_exeext conftest.$ac_ext
6484   done
6485 fi
6486 LIBS=$ac_func_search_save_LIBS
6487 fi
6488 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_encrypt" >&5
6489 echo "${ECHO_T}$ac_cv_search_krb5_encrypt" >&6
6490 if test "$ac_cv_search_krb5_encrypt" != no; then
6491   test "$ac_cv_search_krb5_encrypt" = "none required" || LIBS="$ac_cv_search_krb5_encrypt $LIBS"
6492
6493 else
6494   { { echo "$as_me:$LINENO: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&5
6495 echo "$as_me: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&2;}
6496    { (exit 1); exit 1; }; }
6497 fi
6498
6499      echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
6500 echo $ECHO_N "checking for library containing krb5_sendauth... $ECHO_C" >&6
6501 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
6502   echo $ECHO_N "(cached) $ECHO_C" >&6
6503 else
6504   ac_func_search_save_LIBS=$LIBS
6505 ac_cv_search_krb5_sendauth=no
6506 cat >conftest.$ac_ext <<_ACEOF
6507 /* confdefs.h.  */
6508 _ACEOF
6509 cat confdefs.h >>conftest.$ac_ext
6510 cat >>conftest.$ac_ext <<_ACEOF
6511 /* end confdefs.h.  */
6512
6513 /* Override any gcc2 internal prototype to avoid an error.  */
6514 #ifdef __cplusplus
6515 extern "C"
6516 #endif
6517 /* We use char because int might match the return type of a gcc2
6518    builtin and then its argument prototype would still apply.  */
6519 char krb5_sendauth ();
6520 int
6521 main ()
6522 {
6523 krb5_sendauth ();
6524   ;
6525   return 0;
6526 }
6527 _ACEOF
6528 rm -f conftest.$ac_objext conftest$ac_exeext
6529 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6530   (eval $ac_link) 2>conftest.er1
6531   ac_status=$?
6532   grep -v '^ *+' conftest.er1 >conftest.err
6533   rm -f conftest.er1
6534   cat conftest.err >&5
6535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6536   (exit $ac_status); } &&
6537          { ac_try='test -z "$ac_c_werror_flag"
6538                          || test ! -s conftest.err'
6539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6540   (eval $ac_try) 2>&5
6541   ac_status=$?
6542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6543   (exit $ac_status); }; } &&
6544          { ac_try='test -s conftest$ac_exeext'
6545   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6546   (eval $ac_try) 2>&5
6547   ac_status=$?
6548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6549   (exit $ac_status); }; }; then
6550   ac_cv_search_krb5_sendauth="none required"
6551 else
6552   echo "$as_me: failed program was:" >&5
6553 sed 's/^/| /' conftest.$ac_ext >&5
6554
6555 fi
6556 rm -f conftest.err conftest.$ac_objext \
6557       conftest$ac_exeext conftest.$ac_ext
6558 if test "$ac_cv_search_krb5_sendauth" = no; then
6559   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken'; do
6560     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6561     cat >conftest.$ac_ext <<_ACEOF
6562 /* confdefs.h.  */
6563 _ACEOF
6564 cat confdefs.h >>conftest.$ac_ext
6565 cat >>conftest.$ac_ext <<_ACEOF
6566 /* end confdefs.h.  */
6567
6568 /* Override any gcc2 internal prototype to avoid an error.  */
6569 #ifdef __cplusplus
6570 extern "C"
6571 #endif
6572 /* We use char because int might match the return type of a gcc2
6573    builtin and then its argument prototype would still apply.  */
6574 char krb5_sendauth ();
6575 int
6576 main ()
6577 {
6578 krb5_sendauth ();
6579   ;
6580   return 0;
6581 }
6582 _ACEOF
6583 rm -f conftest.$ac_objext conftest$ac_exeext
6584 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6585   (eval $ac_link) 2>conftest.er1
6586   ac_status=$?
6587   grep -v '^ *+' conftest.er1 >conftest.err
6588   rm -f conftest.er1
6589   cat conftest.err >&5
6590   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6591   (exit $ac_status); } &&
6592          { ac_try='test -z "$ac_c_werror_flag"
6593                          || test ! -s conftest.err'
6594   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6595   (eval $ac_try) 2>&5
6596   ac_status=$?
6597   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6598   (exit $ac_status); }; } &&
6599          { ac_try='test -s conftest$ac_exeext'
6600   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6601   (eval $ac_try) 2>&5
6602   ac_status=$?
6603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6604   (exit $ac_status); }; }; then
6605   ac_cv_search_krb5_sendauth="-l$ac_lib"
6606 break
6607 else
6608   echo "$as_me: failed program was:" >&5
6609 sed 's/^/| /' conftest.$ac_ext >&5
6610
6611 fi
6612 rm -f conftest.err conftest.$ac_objext \
6613       conftest$ac_exeext conftest.$ac_ext
6614   done
6615 fi
6616 LIBS=$ac_func_search_save_LIBS
6617 fi
6618 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
6619 echo "${ECHO_T}$ac_cv_search_krb5_sendauth" >&6
6620 if test "$ac_cv_search_krb5_sendauth" != no; then
6621   test "$ac_cv_search_krb5_sendauth" = "none required" || LIBS="$ac_cv_search_krb5_sendauth $LIBS"
6622
6623 else
6624   { { echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
6625 echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
6626    { (exit 1); exit 1; }; }
6627 fi
6628
6629   else
6630      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6631 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6632 if test "${ac_cv_search_com_err+set}" = set; then
6633   echo $ECHO_N "(cached) $ECHO_C" >&6
6634 else
6635   ac_func_search_save_LIBS=$LIBS
6636 ac_cv_search_com_err=no
6637 cat >conftest.$ac_ext <<_ACEOF
6638 /* confdefs.h.  */
6639 _ACEOF
6640 cat confdefs.h >>conftest.$ac_ext
6641 cat >>conftest.$ac_ext <<_ACEOF
6642 /* end confdefs.h.  */
6643
6644 /* Override any gcc2 internal prototype to avoid an error.  */
6645 #ifdef __cplusplus
6646 extern "C"
6647 #endif
6648 /* We use char because int might match the return type of a gcc2
6649    builtin and then its argument prototype would still apply.  */
6650 char com_err ();
6651 int
6652 main ()
6653 {
6654 com_err ();
6655   ;
6656   return 0;
6657 }
6658 _ACEOF
6659 rm -f conftest.$ac_objext conftest$ac_exeext
6660 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6661   (eval $ac_link) 2>conftest.er1
6662   ac_status=$?
6663   grep -v '^ *+' conftest.er1 >conftest.err
6664   rm -f conftest.er1
6665   cat conftest.err >&5
6666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6667   (exit $ac_status); } &&
6668          { ac_try='test -z "$ac_c_werror_flag"
6669                          || test ! -s conftest.err'
6670   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6671   (eval $ac_try) 2>&5
6672   ac_status=$?
6673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6674   (exit $ac_status); }; } &&
6675          { ac_try='test -s conftest$ac_exeext'
6676   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6677   (eval $ac_try) 2>&5
6678   ac_status=$?
6679   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6680   (exit $ac_status); }; }; then
6681   ac_cv_search_com_err="none required"
6682 else
6683   echo "$as_me: failed program was:" >&5
6684 sed 's/^/| /' conftest.$ac_ext >&5
6685
6686 fi
6687 rm -f conftest.err conftest.$ac_objext \
6688       conftest$ac_exeext conftest.$ac_ext
6689 if test "$ac_cv_search_com_err" = no; then
6690   for ac_lib in 'comerr32 -lkrb5_32'; do
6691     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6692     cat >conftest.$ac_ext <<_ACEOF
6693 /* confdefs.h.  */
6694 _ACEOF
6695 cat confdefs.h >>conftest.$ac_ext
6696 cat >>conftest.$ac_ext <<_ACEOF
6697 /* end confdefs.h.  */
6698
6699 /* Override any gcc2 internal prototype to avoid an error.  */
6700 #ifdef __cplusplus
6701 extern "C"
6702 #endif
6703 /* We use char because int might match the return type of a gcc2
6704    builtin and then its argument prototype would still apply.  */
6705 char com_err ();
6706 int
6707 main ()
6708 {
6709 com_err ();
6710   ;
6711   return 0;
6712 }
6713 _ACEOF
6714 rm -f conftest.$ac_objext conftest$ac_exeext
6715 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6716   (eval $ac_link) 2>conftest.er1
6717   ac_status=$?
6718   grep -v '^ *+' conftest.er1 >conftest.err
6719   rm -f conftest.er1
6720   cat conftest.err >&5
6721   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6722   (exit $ac_status); } &&
6723          { ac_try='test -z "$ac_c_werror_flag"
6724                          || test ! -s conftest.err'
6725   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6726   (eval $ac_try) 2>&5
6727   ac_status=$?
6728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6729   (exit $ac_status); }; } &&
6730          { ac_try='test -s conftest$ac_exeext'
6731   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6732   (eval $ac_try) 2>&5
6733   ac_status=$?
6734   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6735   (exit $ac_status); }; }; then
6736   ac_cv_search_com_err="-l$ac_lib"
6737 break
6738 else
6739   echo "$as_me: failed program was:" >&5
6740 sed 's/^/| /' conftest.$ac_ext >&5
6741
6742 fi
6743 rm -f conftest.err conftest.$ac_objext \
6744       conftest$ac_exeext conftest.$ac_ext
6745   done
6746 fi
6747 LIBS=$ac_func_search_save_LIBS
6748 fi
6749 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6750 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6751 if test "$ac_cv_search_com_err" != no; then
6752   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6753
6754 else
6755   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6756 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6757    { (exit 1); exit 1; }; }
6758 fi
6759
6760   fi
6761 fi
6762
6763 if test "$with_openssl" = yes ; then
6764     if test "$PORTNAME" != "win32"; then
6765
6766 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
6767 echo $ECHO_N "checking for CRYPTO_new_ex_data in -lcrypto... $ECHO_C" >&6
6768 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
6769   echo $ECHO_N "(cached) $ECHO_C" >&6
6770 else
6771   ac_check_lib_save_LIBS=$LIBS
6772 LIBS="-lcrypto  $LIBS"
6773 cat >conftest.$ac_ext <<_ACEOF
6774 /* confdefs.h.  */
6775 _ACEOF
6776 cat confdefs.h >>conftest.$ac_ext
6777 cat >>conftest.$ac_ext <<_ACEOF
6778 /* end confdefs.h.  */
6779
6780 /* Override any gcc2 internal prototype to avoid an error.  */
6781 #ifdef __cplusplus
6782 extern "C"
6783 #endif
6784 /* We use char because int might match the return type of a gcc2
6785    builtin and then its argument prototype would still apply.  */
6786 char CRYPTO_new_ex_data ();
6787 int
6788 main ()
6789 {
6790 CRYPTO_new_ex_data ();
6791   ;
6792   return 0;
6793 }
6794 _ACEOF
6795 rm -f conftest.$ac_objext conftest$ac_exeext
6796 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6797   (eval $ac_link) 2>conftest.er1
6798   ac_status=$?
6799   grep -v '^ *+' conftest.er1 >conftest.err
6800   rm -f conftest.er1
6801   cat conftest.err >&5
6802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6803   (exit $ac_status); } &&
6804          { ac_try='test -z "$ac_c_werror_flag"
6805                          || test ! -s conftest.err'
6806   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6807   (eval $ac_try) 2>&5
6808   ac_status=$?
6809   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6810   (exit $ac_status); }; } &&
6811          { ac_try='test -s conftest$ac_exeext'
6812   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6813   (eval $ac_try) 2>&5
6814   ac_status=$?
6815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6816   (exit $ac_status); }; }; then
6817   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
6818 else
6819   echo "$as_me: failed program was:" >&5
6820 sed 's/^/| /' conftest.$ac_ext >&5
6821
6822 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
6823 fi
6824 rm -f conftest.err conftest.$ac_objext \
6825       conftest$ac_exeext conftest.$ac_ext
6826 LIBS=$ac_check_lib_save_LIBS
6827 fi
6828 echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
6829 echo "${ECHO_T}$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6
6830 if test $ac_cv_lib_crypto_CRYPTO_new_ex_data = yes; then
6831   cat >>confdefs.h <<_ACEOF
6832 #define HAVE_LIBCRYPTO 1
6833 _ACEOF
6834
6835   LIBS="-lcrypto $LIBS"
6836
6837 else
6838   { { echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
6839 echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
6840    { (exit 1); exit 1; }; }
6841 fi
6842
6843
6844 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
6845 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
6846 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
6847   echo $ECHO_N "(cached) $ECHO_C" >&6
6848 else
6849   ac_check_lib_save_LIBS=$LIBS
6850 LIBS="-lssl  $LIBS"
6851 cat >conftest.$ac_ext <<_ACEOF
6852 /* confdefs.h.  */
6853 _ACEOF
6854 cat confdefs.h >>conftest.$ac_ext
6855 cat >>conftest.$ac_ext <<_ACEOF
6856 /* end confdefs.h.  */
6857
6858 /* Override any gcc2 internal prototype to avoid an error.  */
6859 #ifdef __cplusplus
6860 extern "C"
6861 #endif
6862 /* We use char because int might match the return type of a gcc2
6863    builtin and then its argument prototype would still apply.  */
6864 char SSL_library_init ();
6865 int
6866 main ()
6867 {
6868 SSL_library_init ();
6869   ;
6870   return 0;
6871 }
6872 _ACEOF
6873 rm -f conftest.$ac_objext conftest$ac_exeext
6874 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6875   (eval $ac_link) 2>conftest.er1
6876   ac_status=$?
6877   grep -v '^ *+' conftest.er1 >conftest.err
6878   rm -f conftest.er1
6879   cat conftest.err >&5
6880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6881   (exit $ac_status); } &&
6882          { ac_try='test -z "$ac_c_werror_flag"
6883                          || test ! -s conftest.err'
6884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6885   (eval $ac_try) 2>&5
6886   ac_status=$?
6887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6888   (exit $ac_status); }; } &&
6889          { ac_try='test -s conftest$ac_exeext'
6890   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6891   (eval $ac_try) 2>&5
6892   ac_status=$?
6893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6894   (exit $ac_status); }; }; then
6895   ac_cv_lib_ssl_SSL_library_init=yes
6896 else
6897   echo "$as_me: failed program was:" >&5
6898 sed 's/^/| /' conftest.$ac_ext >&5
6899
6900 ac_cv_lib_ssl_SSL_library_init=no
6901 fi
6902 rm -f conftest.err conftest.$ac_objext \
6903       conftest$ac_exeext conftest.$ac_ext
6904 LIBS=$ac_check_lib_save_LIBS
6905 fi
6906 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
6907 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
6908 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
6909   cat >>confdefs.h <<_ACEOF
6910 #define HAVE_LIBSSL 1
6911 _ACEOF
6912
6913   LIBS="-lssl $LIBS"
6914
6915 else
6916   { { echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
6917 echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
6918    { (exit 1); exit 1; }; }
6919 fi
6920
6921   else
6922
6923 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
6924 echo $ECHO_N "checking for CRYPTO_new_ex_data in -leay32... $ECHO_C" >&6
6925 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
6926   echo $ECHO_N "(cached) $ECHO_C" >&6
6927 else
6928   ac_check_lib_save_LIBS=$LIBS
6929 LIBS="-leay32  $LIBS"
6930 cat >conftest.$ac_ext <<_ACEOF
6931 /* confdefs.h.  */
6932 _ACEOF
6933 cat confdefs.h >>conftest.$ac_ext
6934 cat >>conftest.$ac_ext <<_ACEOF
6935 /* end confdefs.h.  */
6936
6937 /* Override any gcc2 internal prototype to avoid an error.  */
6938 #ifdef __cplusplus
6939 extern "C"
6940 #endif
6941 /* We use char because int might match the return type of a gcc2
6942    builtin and then its argument prototype would still apply.  */
6943 char CRYPTO_new_ex_data ();
6944 int
6945 main ()
6946 {
6947 CRYPTO_new_ex_data ();
6948   ;
6949   return 0;
6950 }
6951 _ACEOF
6952 rm -f conftest.$ac_objext conftest$ac_exeext
6953 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6954   (eval $ac_link) 2>conftest.er1
6955   ac_status=$?
6956   grep -v '^ *+' conftest.er1 >conftest.err
6957   rm -f conftest.er1
6958   cat conftest.err >&5
6959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6960   (exit $ac_status); } &&
6961          { ac_try='test -z "$ac_c_werror_flag"
6962                          || test ! -s conftest.err'
6963   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6964   (eval $ac_try) 2>&5
6965   ac_status=$?
6966   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6967   (exit $ac_status); }; } &&
6968          { ac_try='test -s conftest$ac_exeext'
6969   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6970   (eval $ac_try) 2>&5
6971   ac_status=$?
6972   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6973   (exit $ac_status); }; }; then
6974   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
6975 else
6976   echo "$as_me: failed program was:" >&5
6977 sed 's/^/| /' conftest.$ac_ext >&5
6978
6979 ac_cv_lib_eay32_CRYPTO_new_ex_data=no
6980 fi
6981 rm -f conftest.err conftest.$ac_objext \
6982       conftest$ac_exeext conftest.$ac_ext
6983 LIBS=$ac_check_lib_save_LIBS
6984 fi
6985 echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
6986 echo "${ECHO_T}$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6
6987 if test $ac_cv_lib_eay32_CRYPTO_new_ex_data = yes; then
6988   cat >>confdefs.h <<_ACEOF
6989 #define HAVE_LIBEAY32 1
6990 _ACEOF
6991
6992   LIBS="-leay32 $LIBS"
6993
6994 else
6995   { { echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
6996 echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
6997    { (exit 1); exit 1; }; }
6998 fi
6999
7000
7001 echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
7002 echo $ECHO_N "checking for SSL_library_init in -lssleay32... $ECHO_C" >&6
7003 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
7004   echo $ECHO_N "(cached) $ECHO_C" >&6
7005 else
7006   ac_check_lib_save_LIBS=$LIBS
7007 LIBS="-lssleay32  $LIBS"
7008 cat >conftest.$ac_ext <<_ACEOF
7009 /* confdefs.h.  */
7010 _ACEOF
7011 cat confdefs.h >>conftest.$ac_ext
7012 cat >>conftest.$ac_ext <<_ACEOF
7013 /* end confdefs.h.  */
7014
7015 /* Override any gcc2 internal prototype to avoid an error.  */
7016 #ifdef __cplusplus
7017 extern "C"
7018 #endif
7019 /* We use char because int might match the return type of a gcc2
7020    builtin and then its argument prototype would still apply.  */
7021 char SSL_library_init ();
7022 int
7023 main ()
7024 {
7025 SSL_library_init ();
7026   ;
7027   return 0;
7028 }
7029 _ACEOF
7030 rm -f conftest.$ac_objext conftest$ac_exeext
7031 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7032   (eval $ac_link) 2>conftest.er1
7033   ac_status=$?
7034   grep -v '^ *+' conftest.er1 >conftest.err
7035   rm -f conftest.er1
7036   cat conftest.err >&5
7037   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7038   (exit $ac_status); } &&
7039          { ac_try='test -z "$ac_c_werror_flag"
7040                          || test ! -s conftest.err'
7041   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7042   (eval $ac_try) 2>&5
7043   ac_status=$?
7044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7045   (exit $ac_status); }; } &&
7046          { ac_try='test -s conftest$ac_exeext'
7047   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7048   (eval $ac_try) 2>&5
7049   ac_status=$?
7050   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7051   (exit $ac_status); }; }; then
7052   ac_cv_lib_ssleay32_SSL_library_init=yes
7053 else
7054   echo "$as_me: failed program was:" >&5
7055 sed 's/^/| /' conftest.$ac_ext >&5
7056
7057 ac_cv_lib_ssleay32_SSL_library_init=no
7058 fi
7059 rm -f conftest.err conftest.$ac_objext \
7060       conftest$ac_exeext conftest.$ac_ext
7061 LIBS=$ac_check_lib_save_LIBS
7062 fi
7063 echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
7064 echo "${ECHO_T}$ac_cv_lib_ssleay32_SSL_library_init" >&6
7065 if test $ac_cv_lib_ssleay32_SSL_library_init = yes; then
7066   cat >>confdefs.h <<_ACEOF
7067 #define HAVE_LIBSSLEAY32 1
7068 _ACEOF
7069
7070   LIBS="-lssleay32 $LIBS"
7071
7072 else
7073   { { echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
7074 echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
7075    { (exit 1); exit 1; }; }
7076 fi
7077
7078   fi
7079 fi
7080
7081 if test "$with_pam" = yes ; then
7082
7083 echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
7084 echo $ECHO_N "checking for pam_start in -lpam... $ECHO_C" >&6
7085 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
7086   echo $ECHO_N "(cached) $ECHO_C" >&6
7087 else
7088   ac_check_lib_save_LIBS=$LIBS
7089 LIBS="-lpam  $LIBS"
7090 cat >conftest.$ac_ext <<_ACEOF
7091 /* confdefs.h.  */
7092 _ACEOF
7093 cat confdefs.h >>conftest.$ac_ext
7094 cat >>conftest.$ac_ext <<_ACEOF
7095 /* end confdefs.h.  */
7096
7097 /* Override any gcc2 internal prototype to avoid an error.  */
7098 #ifdef __cplusplus
7099 extern "C"
7100 #endif
7101 /* We use char because int might match the return type of a gcc2
7102    builtin and then its argument prototype would still apply.  */
7103 char pam_start ();
7104 int
7105 main ()
7106 {
7107 pam_start ();
7108   ;
7109   return 0;
7110 }
7111 _ACEOF
7112 rm -f conftest.$ac_objext conftest$ac_exeext
7113 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7114   (eval $ac_link) 2>conftest.er1
7115   ac_status=$?
7116   grep -v '^ *+' conftest.er1 >conftest.err
7117   rm -f conftest.er1
7118   cat conftest.err >&5
7119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7120   (exit $ac_status); } &&
7121          { ac_try='test -z "$ac_c_werror_flag"
7122                          || test ! -s conftest.err'
7123   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7124   (eval $ac_try) 2>&5
7125   ac_status=$?
7126   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7127   (exit $ac_status); }; } &&
7128          { ac_try='test -s conftest$ac_exeext'
7129   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7130   (eval $ac_try) 2>&5
7131   ac_status=$?
7132   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7133   (exit $ac_status); }; }; then
7134   ac_cv_lib_pam_pam_start=yes
7135 else
7136   echo "$as_me: failed program was:" >&5
7137 sed 's/^/| /' conftest.$ac_ext >&5
7138
7139 ac_cv_lib_pam_pam_start=no
7140 fi
7141 rm -f conftest.err conftest.$ac_objext \
7142       conftest$ac_exeext conftest.$ac_ext
7143 LIBS=$ac_check_lib_save_LIBS
7144 fi
7145 echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
7146 echo "${ECHO_T}$ac_cv_lib_pam_pam_start" >&6
7147 if test $ac_cv_lib_pam_pam_start = yes; then
7148   cat >>confdefs.h <<_ACEOF
7149 #define HAVE_LIBPAM 1
7150 _ACEOF
7151
7152   LIBS="-lpam $LIBS"
7153
7154 else
7155   { { echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
7156 echo "$as_me: error: library 'pam' is required for PAM" >&2;}
7157    { (exit 1); exit 1; }; }
7158 fi
7159
7160 fi
7161
7162
7163 ##
7164 ## Header files
7165 ##
7166
7167 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
7168 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
7169 if test "${ac_cv_header_stdc+set}" = set; then
7170   echo $ECHO_N "(cached) $ECHO_C" >&6
7171 else
7172   cat >conftest.$ac_ext <<_ACEOF
7173 /* confdefs.h.  */
7174 _ACEOF
7175 cat confdefs.h >>conftest.$ac_ext
7176 cat >>conftest.$ac_ext <<_ACEOF
7177 /* end confdefs.h.  */
7178 #include <stdlib.h>
7179 #include <stdarg.h>
7180 #include <string.h>
7181 #include <float.h>
7182
7183 int
7184 main ()
7185 {
7186
7187   ;
7188   return 0;
7189 }
7190 _ACEOF
7191 rm -f conftest.$ac_objext
7192 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7193   (eval $ac_compile) 2>conftest.er1
7194   ac_status=$?
7195   grep -v '^ *+' conftest.er1 >conftest.err
7196   rm -f conftest.er1
7197   cat conftest.err >&5
7198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7199   (exit $ac_status); } &&
7200          { ac_try='test -z "$ac_c_werror_flag"
7201                          || test ! -s conftest.err'
7202   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7203   (eval $ac_try) 2>&5
7204   ac_status=$?
7205   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7206   (exit $ac_status); }; } &&
7207          { ac_try='test -s conftest.$ac_objext'
7208   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7209   (eval $ac_try) 2>&5
7210   ac_status=$?
7211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7212   (exit $ac_status); }; }; then
7213   ac_cv_header_stdc=yes
7214 else
7215   echo "$as_me: failed program was:" >&5
7216 sed 's/^/| /' conftest.$ac_ext >&5
7217
7218 ac_cv_header_stdc=no
7219 fi
7220 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7221
7222 if test $ac_cv_header_stdc = yes; then
7223   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7224   cat >conftest.$ac_ext <<_ACEOF
7225 /* confdefs.h.  */
7226 _ACEOF
7227 cat confdefs.h >>conftest.$ac_ext
7228 cat >>conftest.$ac_ext <<_ACEOF
7229 /* end confdefs.h.  */
7230 #include <string.h>
7231
7232 _ACEOF
7233 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7234   $EGREP "memchr" >/dev/null 2>&1; then
7235   :
7236 else
7237   ac_cv_header_stdc=no
7238 fi
7239 rm -f conftest*
7240
7241 fi
7242
7243 if test $ac_cv_header_stdc = yes; then
7244   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7245   cat >conftest.$ac_ext <<_ACEOF
7246 /* confdefs.h.  */
7247 _ACEOF
7248 cat confdefs.h >>conftest.$ac_ext
7249 cat >>conftest.$ac_ext <<_ACEOF
7250 /* end confdefs.h.  */
7251 #include <stdlib.h>
7252
7253 _ACEOF
7254 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7255   $EGREP "free" >/dev/null 2>&1; then
7256   :
7257 else
7258   ac_cv_header_stdc=no
7259 fi
7260 rm -f conftest*
7261
7262 fi
7263
7264 if test $ac_cv_header_stdc = yes; then
7265   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7266   if test "$cross_compiling" = yes; then
7267   :
7268 else
7269   cat >conftest.$ac_ext <<_ACEOF
7270 /* confdefs.h.  */
7271 _ACEOF
7272 cat confdefs.h >>conftest.$ac_ext
7273 cat >>conftest.$ac_ext <<_ACEOF
7274 /* end confdefs.h.  */
7275 #include <ctype.h>
7276 #if ((' ' & 0x0FF) == 0x020)
7277 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7278 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7279 #else
7280 # define ISLOWER(c) \
7281                    (('a' <= (c) && (c) <= 'i') \
7282                      || ('j' <= (c) && (c) <= 'r') \
7283                      || ('s' <= (c) && (c) <= 'z'))
7284 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7285 #endif
7286
7287 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7288 int
7289 main ()
7290 {
7291   int i;
7292   for (i = 0; i < 256; i++)
7293     if (XOR (islower (i), ISLOWER (i))
7294         || toupper (i) != TOUPPER (i))
7295       exit(2);
7296   exit (0);
7297 }
7298 _ACEOF
7299 rm -f conftest$ac_exeext
7300 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7301   (eval $ac_link) 2>&5
7302   ac_status=$?
7303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7304   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7305   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7306   (eval $ac_try) 2>&5
7307   ac_status=$?
7308   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7309   (exit $ac_status); }; }; then
7310   :
7311 else
7312   echo "$as_me: program exited with status $ac_status" >&5
7313 echo "$as_me: failed program was:" >&5
7314 sed 's/^/| /' conftest.$ac_ext >&5
7315
7316 ( exit $ac_status )
7317 ac_cv_header_stdc=no
7318 fi
7319 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7320 fi
7321 fi
7322 fi
7323 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
7324 echo "${ECHO_T}$ac_cv_header_stdc" >&6
7325 if test $ac_cv_header_stdc = yes; then
7326
7327 cat >>confdefs.h <<\_ACEOF
7328 #define STDC_HEADERS 1
7329 _ACEOF
7330
7331 fi
7332
7333 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
7334
7335
7336
7337
7338
7339
7340
7341
7342
7343 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7344                   inttypes.h stdint.h unistd.h
7345 do
7346 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7347 echo "$as_me:$LINENO: checking for $ac_header" >&5
7348 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7349 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7350   echo $ECHO_N "(cached) $ECHO_C" >&6
7351 else
7352   cat >conftest.$ac_ext <<_ACEOF
7353 /* confdefs.h.  */
7354 _ACEOF
7355 cat confdefs.h >>conftest.$ac_ext
7356 cat >>conftest.$ac_ext <<_ACEOF
7357 /* end confdefs.h.  */
7358 $ac_includes_default
7359
7360 #include <$ac_header>
7361 _ACEOF
7362 rm -f conftest.$ac_objext
7363 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7364   (eval $ac_compile) 2>conftest.er1
7365   ac_status=$?
7366   grep -v '^ *+' conftest.er1 >conftest.err
7367   rm -f conftest.er1
7368   cat conftest.err >&5
7369   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7370   (exit $ac_status); } &&
7371          { ac_try='test -z "$ac_c_werror_flag"
7372                          || test ! -s conftest.err'
7373   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7374   (eval $ac_try) 2>&5
7375   ac_status=$?
7376   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7377   (exit $ac_status); }; } &&
7378          { ac_try='test -s conftest.$ac_objext'
7379   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7380   (eval $ac_try) 2>&5
7381   ac_status=$?
7382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7383   (exit $ac_status); }; }; then
7384   eval "$as_ac_Header=yes"
7385 else
7386   echo "$as_me: failed program was:" >&5
7387 sed 's/^/| /' conftest.$ac_ext >&5
7388
7389 eval "$as_ac_Header=no"
7390 fi
7391 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7392 fi
7393 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7394 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7395 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7396   cat >>confdefs.h <<_ACEOF
7397 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7398 _ACEOF
7399
7400 fi
7401
7402 done
7403
7404
7405
7406
7407
7408
7409
7410
7411
7412
7413
7414
7415
7416
7417
7418
7419
7420
7421
7422
7423
7424
7425
7426
7427
7428
7429
7430 for ac_header in crypt.h dld.h endian.h fp_class.h getopt.h ieeefp.h langinfo.h poll.h pwd.h sys/ipc.h sys/poll.h sys/pstat.h sys/select.h sys/sem.h sys/socket.h sys/shm.h sys/time.h sys/un.h termios.h utime.h wchar.h wctype.h kernel/OS.h kernel/image.h SupportDefs.h
7431 do
7432 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7433 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7434   echo "$as_me:$LINENO: checking for $ac_header" >&5
7435 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7436 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7437   echo $ECHO_N "(cached) $ECHO_C" >&6
7438 fi
7439 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7440 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7441 else
7442   # Is the header compilable?
7443 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7444 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7445 cat >conftest.$ac_ext <<_ACEOF
7446 /* confdefs.h.  */
7447 _ACEOF
7448 cat confdefs.h >>conftest.$ac_ext
7449 cat >>conftest.$ac_ext <<_ACEOF
7450 /* end confdefs.h.  */
7451 $ac_includes_default
7452 #include <$ac_header>
7453 _ACEOF
7454 rm -f conftest.$ac_objext
7455 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7456   (eval $ac_compile) 2>conftest.er1
7457   ac_status=$?
7458   grep -v '^ *+' conftest.er1 >conftest.err
7459   rm -f conftest.er1
7460   cat conftest.err >&5
7461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7462   (exit $ac_status); } &&
7463          { ac_try='test -z "$ac_c_werror_flag"
7464                          || test ! -s conftest.err'
7465   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7466   (eval $ac_try) 2>&5
7467   ac_status=$?
7468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7469   (exit $ac_status); }; } &&
7470          { ac_try='test -s conftest.$ac_objext'
7471   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7472   (eval $ac_try) 2>&5
7473   ac_status=$?
7474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7475   (exit $ac_status); }; }; then
7476   ac_header_compiler=yes
7477 else
7478   echo "$as_me: failed program was:" >&5
7479 sed 's/^/| /' conftest.$ac_ext >&5
7480
7481 ac_header_compiler=no
7482 fi
7483 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7484 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7485 echo "${ECHO_T}$ac_header_compiler" >&6
7486
7487 # Is the header present?
7488 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7489 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7490 cat >conftest.$ac_ext <<_ACEOF
7491 /* confdefs.h.  */
7492 _ACEOF
7493 cat confdefs.h >>conftest.$ac_ext
7494 cat >>conftest.$ac_ext <<_ACEOF
7495 /* end confdefs.h.  */
7496 #include <$ac_header>
7497 _ACEOF
7498 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7499   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7500   ac_status=$?
7501   grep -v '^ *+' conftest.er1 >conftest.err
7502   rm -f conftest.er1
7503   cat conftest.err >&5
7504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7505   (exit $ac_status); } >/dev/null; then
7506   if test -s conftest.err; then
7507     ac_cpp_err=$ac_c_preproc_warn_flag
7508     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7509   else
7510     ac_cpp_err=
7511   fi
7512 else
7513   ac_cpp_err=yes
7514 fi
7515 if test -z "$ac_cpp_err"; then
7516   ac_header_preproc=yes
7517 else
7518   echo "$as_me: failed program was:" >&5
7519 sed 's/^/| /' conftest.$ac_ext >&5
7520
7521   ac_header_preproc=no
7522 fi
7523 rm -f conftest.err conftest.$ac_ext
7524 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7525 echo "${ECHO_T}$ac_header_preproc" >&6
7526
7527 # So?  What about this header?
7528 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7529   yes:no: )
7530     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7531 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7532     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7533 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7534     ac_header_preproc=yes
7535     ;;
7536   no:yes:* )
7537     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7538 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7539     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7540 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7541     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7542 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7543     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7544 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7545     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7546 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7547     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7548 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7549     (
7550       cat <<\_ASBOX
7551 ## ---------------------------------------- ##
7552 ## Report this to pgsql-bugs@postgresql.org ##
7553 ## ---------------------------------------- ##
7554 _ASBOX
7555     ) |
7556       sed "s/^/$as_me: WARNING:     /" >&2
7557     ;;
7558 esac
7559 echo "$as_me:$LINENO: checking for $ac_header" >&5
7560 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7561 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7562   echo $ECHO_N "(cached) $ECHO_C" >&6
7563 else
7564   eval "$as_ac_Header=\$ac_header_preproc"
7565 fi
7566 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7567 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7568
7569 fi
7570 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7571   cat >>confdefs.h <<_ACEOF
7572 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7573 _ACEOF
7574
7575 fi
7576
7577 done
7578
7579
7580 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
7581 # netinet/in.h is included first.
7582
7583 for ac_header in netinet/in.h
7584 do
7585 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7586 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7587   echo "$as_me:$LINENO: checking for $ac_header" >&5
7588 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7589 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7590   echo $ECHO_N "(cached) $ECHO_C" >&6
7591 fi
7592 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7593 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7594 else
7595   # Is the header compilable?
7596 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7597 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7598 cat >conftest.$ac_ext <<_ACEOF
7599 /* confdefs.h.  */
7600 _ACEOF
7601 cat confdefs.h >>conftest.$ac_ext
7602 cat >>conftest.$ac_ext <<_ACEOF
7603 /* end confdefs.h.  */
7604 $ac_includes_default
7605 #include <$ac_header>
7606 _ACEOF
7607 rm -f conftest.$ac_objext
7608 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7609   (eval $ac_compile) 2>conftest.er1
7610   ac_status=$?
7611   grep -v '^ *+' conftest.er1 >conftest.err
7612   rm -f conftest.er1
7613   cat conftest.err >&5
7614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7615   (exit $ac_status); } &&
7616          { ac_try='test -z "$ac_c_werror_flag"
7617                          || test ! -s conftest.err'
7618   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7619   (eval $ac_try) 2>&5
7620   ac_status=$?
7621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7622   (exit $ac_status); }; } &&
7623          { ac_try='test -s conftest.$ac_objext'
7624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7625   (eval $ac_try) 2>&5
7626   ac_status=$?
7627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7628   (exit $ac_status); }; }; then
7629   ac_header_compiler=yes
7630 else
7631   echo "$as_me: failed program was:" >&5
7632 sed 's/^/| /' conftest.$ac_ext >&5
7633
7634 ac_header_compiler=no
7635 fi
7636 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7637 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7638 echo "${ECHO_T}$ac_header_compiler" >&6
7639
7640 # Is the header present?
7641 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7642 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7643 cat >conftest.$ac_ext <<_ACEOF
7644 /* confdefs.h.  */
7645 _ACEOF
7646 cat confdefs.h >>conftest.$ac_ext
7647 cat >>conftest.$ac_ext <<_ACEOF
7648 /* end confdefs.h.  */
7649 #include <$ac_header>
7650 _ACEOF
7651 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7652   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7653   ac_status=$?
7654   grep -v '^ *+' conftest.er1 >conftest.err
7655   rm -f conftest.er1
7656   cat conftest.err >&5
7657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7658   (exit $ac_status); } >/dev/null; then
7659   if test -s conftest.err; then
7660     ac_cpp_err=$ac_c_preproc_warn_flag
7661     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7662   else
7663     ac_cpp_err=
7664   fi
7665 else
7666   ac_cpp_err=yes
7667 fi
7668 if test -z "$ac_cpp_err"; then
7669   ac_header_preproc=yes
7670 else
7671   echo "$as_me: failed program was:" >&5
7672 sed 's/^/| /' conftest.$ac_ext >&5
7673
7674   ac_header_preproc=no
7675 fi
7676 rm -f conftest.err conftest.$ac_ext
7677 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7678 echo "${ECHO_T}$ac_header_preproc" >&6
7679
7680 # So?  What about this header?
7681 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7682   yes:no: )
7683     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7684 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7685     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7686 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7687     ac_header_preproc=yes
7688     ;;
7689   no:yes:* )
7690     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7691 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7692     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7693 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7694     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7695 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7696     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7697 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7698     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7699 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7700     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7701 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7702     (
7703       cat <<\_ASBOX
7704 ## ---------------------------------------- ##
7705 ## Report this to pgsql-bugs@postgresql.org ##
7706 ## ---------------------------------------- ##
7707 _ASBOX
7708     ) |
7709       sed "s/^/$as_me: WARNING:     /" >&2
7710     ;;
7711 esac
7712 echo "$as_me:$LINENO: checking for $ac_header" >&5
7713 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7714 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7715   echo $ECHO_N "(cached) $ECHO_C" >&6
7716 else
7717   eval "$as_ac_Header=\$ac_header_preproc"
7718 fi
7719 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7720 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7721
7722 fi
7723 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7724   cat >>confdefs.h <<_ACEOF
7725 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7726 _ACEOF
7727
7728 fi
7729
7730 done
7731
7732
7733 for ac_header in netinet/tcp.h
7734 do
7735 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7736 echo "$as_me:$LINENO: checking for $ac_header" >&5
7737 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7738 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7739   echo $ECHO_N "(cached) $ECHO_C" >&6
7740 else
7741   cat >conftest.$ac_ext <<_ACEOF
7742 /* confdefs.h.  */
7743 _ACEOF
7744 cat confdefs.h >>conftest.$ac_ext
7745 cat >>conftest.$ac_ext <<_ACEOF
7746 /* end confdefs.h.  */
7747 $ac_includes_default
7748 #ifdef HAVE_NETINET_IN_H
7749 #include <netinet/in.h>
7750 #endif
7751
7752
7753 #include <$ac_header>
7754 _ACEOF
7755 rm -f conftest.$ac_objext
7756 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7757   (eval $ac_compile) 2>conftest.er1
7758   ac_status=$?
7759   grep -v '^ *+' conftest.er1 >conftest.err
7760   rm -f conftest.er1
7761   cat conftest.err >&5
7762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7763   (exit $ac_status); } &&
7764          { ac_try='test -z "$ac_c_werror_flag"
7765                          || test ! -s conftest.err'
7766   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7767   (eval $ac_try) 2>&5
7768   ac_status=$?
7769   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7770   (exit $ac_status); }; } &&
7771          { ac_try='test -s conftest.$ac_objext'
7772   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7773   (eval $ac_try) 2>&5
7774   ac_status=$?
7775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7776   (exit $ac_status); }; }; then
7777   eval "$as_ac_Header=yes"
7778 else
7779   echo "$as_me: failed program was:" >&5
7780 sed 's/^/| /' conftest.$ac_ext >&5
7781
7782 eval "$as_ac_Header=no"
7783 fi
7784 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7785 fi
7786 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7787 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7788 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7789   cat >>confdefs.h <<_ACEOF
7790 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7791 _ACEOF
7792
7793 fi
7794
7795 done
7796
7797
7798 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
7799
7800 for ac_header in readline/readline.h
7801 do
7802 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7803 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7804   echo "$as_me:$LINENO: checking for $ac_header" >&5
7805 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7806 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7807   echo $ECHO_N "(cached) $ECHO_C" >&6
7808 fi
7809 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7810 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7811 else
7812   # Is the header compilable?
7813 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7814 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7815 cat >conftest.$ac_ext <<_ACEOF
7816 /* confdefs.h.  */
7817 _ACEOF
7818 cat confdefs.h >>conftest.$ac_ext
7819 cat >>conftest.$ac_ext <<_ACEOF
7820 /* end confdefs.h.  */
7821 $ac_includes_default
7822 #include <$ac_header>
7823 _ACEOF
7824 rm -f conftest.$ac_objext
7825 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7826   (eval $ac_compile) 2>conftest.er1
7827   ac_status=$?
7828   grep -v '^ *+' conftest.er1 >conftest.err
7829   rm -f conftest.er1
7830   cat conftest.err >&5
7831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7832   (exit $ac_status); } &&
7833          { ac_try='test -z "$ac_c_werror_flag"
7834                          || test ! -s conftest.err'
7835   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7836   (eval $ac_try) 2>&5
7837   ac_status=$?
7838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7839   (exit $ac_status); }; } &&
7840          { ac_try='test -s conftest.$ac_objext'
7841   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7842   (eval $ac_try) 2>&5
7843   ac_status=$?
7844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7845   (exit $ac_status); }; }; then
7846   ac_header_compiler=yes
7847 else
7848   echo "$as_me: failed program was:" >&5
7849 sed 's/^/| /' conftest.$ac_ext >&5
7850
7851 ac_header_compiler=no
7852 fi
7853 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7854 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7855 echo "${ECHO_T}$ac_header_compiler" >&6
7856
7857 # Is the header present?
7858 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7859 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7860 cat >conftest.$ac_ext <<_ACEOF
7861 /* confdefs.h.  */
7862 _ACEOF
7863 cat confdefs.h >>conftest.$ac_ext
7864 cat >>conftest.$ac_ext <<_ACEOF
7865 /* end confdefs.h.  */
7866 #include <$ac_header>
7867 _ACEOF
7868 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7869   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7870   ac_status=$?
7871   grep -v '^ *+' conftest.er1 >conftest.err
7872   rm -f conftest.er1
7873   cat conftest.err >&5
7874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7875   (exit $ac_status); } >/dev/null; then
7876   if test -s conftest.err; then
7877     ac_cpp_err=$ac_c_preproc_warn_flag
7878     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7879   else
7880     ac_cpp_err=
7881   fi
7882 else
7883   ac_cpp_err=yes
7884 fi
7885 if test -z "$ac_cpp_err"; then
7886   ac_header_preproc=yes
7887 else
7888   echo "$as_me: failed program was:" >&5
7889 sed 's/^/| /' conftest.$ac_ext >&5
7890
7891   ac_header_preproc=no
7892 fi
7893 rm -f conftest.err conftest.$ac_ext
7894 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7895 echo "${ECHO_T}$ac_header_preproc" >&6
7896
7897 # So?  What about this header?
7898 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7899   yes:no: )
7900     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7901 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7902     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7903 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7904     ac_header_preproc=yes
7905     ;;
7906   no:yes:* )
7907     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7908 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7909     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7910 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7911     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7912 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7913     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7914 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7915     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7916 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7917     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7918 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7919     (
7920       cat <<\_ASBOX
7921 ## ---------------------------------------- ##
7922 ## Report this to pgsql-bugs@postgresql.org ##
7923 ## ---------------------------------------- ##
7924 _ASBOX
7925     ) |
7926       sed "s/^/$as_me: WARNING:     /" >&2
7927     ;;
7928 esac
7929 echo "$as_me:$LINENO: checking for $ac_header" >&5
7930 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7931 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7932   echo $ECHO_N "(cached) $ECHO_C" >&6
7933 else
7934   eval "$as_ac_Header=\$ac_header_preproc"
7935 fi
7936 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7937 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7938
7939 fi
7940 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7941   cat >>confdefs.h <<_ACEOF
7942 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7943 _ACEOF
7944
7945 else
7946
7947 for ac_header in readline.h
7948 do
7949 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7950 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7951   echo "$as_me:$LINENO: checking for $ac_header" >&5
7952 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7953 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7954   echo $ECHO_N "(cached) $ECHO_C" >&6
7955 fi
7956 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7957 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7958 else
7959   # Is the header compilable?
7960 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7961 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7962 cat >conftest.$ac_ext <<_ACEOF
7963 /* confdefs.h.  */
7964 _ACEOF
7965 cat confdefs.h >>conftest.$ac_ext
7966 cat >>conftest.$ac_ext <<_ACEOF
7967 /* end confdefs.h.  */
7968 $ac_includes_default
7969 #include <$ac_header>
7970 _ACEOF
7971 rm -f conftest.$ac_objext
7972 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7973   (eval $ac_compile) 2>conftest.er1
7974   ac_status=$?
7975   grep -v '^ *+' conftest.er1 >conftest.err
7976   rm -f conftest.er1
7977   cat conftest.err >&5
7978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7979   (exit $ac_status); } &&
7980          { ac_try='test -z "$ac_c_werror_flag"
7981                          || test ! -s conftest.err'
7982   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7983   (eval $ac_try) 2>&5
7984   ac_status=$?
7985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7986   (exit $ac_status); }; } &&
7987          { ac_try='test -s conftest.$ac_objext'
7988   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7989   (eval $ac_try) 2>&5
7990   ac_status=$?
7991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7992   (exit $ac_status); }; }; then
7993   ac_header_compiler=yes
7994 else
7995   echo "$as_me: failed program was:" >&5
7996 sed 's/^/| /' conftest.$ac_ext >&5
7997
7998 ac_header_compiler=no
7999 fi
8000 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8001 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8002 echo "${ECHO_T}$ac_header_compiler" >&6
8003
8004 # Is the header present?
8005 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8006 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8007 cat >conftest.$ac_ext <<_ACEOF
8008 /* confdefs.h.  */
8009 _ACEOF
8010 cat confdefs.h >>conftest.$ac_ext
8011 cat >>conftest.$ac_ext <<_ACEOF
8012 /* end confdefs.h.  */
8013 #include <$ac_header>
8014 _ACEOF
8015 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8016   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8017   ac_status=$?
8018   grep -v '^ *+' conftest.er1 >conftest.err
8019   rm -f conftest.er1
8020   cat conftest.err >&5
8021   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8022   (exit $ac_status); } >/dev/null; then
8023   if test -s conftest.err; then
8024     ac_cpp_err=$ac_c_preproc_warn_flag
8025     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8026   else
8027     ac_cpp_err=
8028   fi
8029 else
8030   ac_cpp_err=yes
8031 fi
8032 if test -z "$ac_cpp_err"; then
8033   ac_header_preproc=yes
8034 else
8035   echo "$as_me: failed program was:" >&5
8036 sed 's/^/| /' conftest.$ac_ext >&5
8037
8038   ac_header_preproc=no
8039 fi
8040 rm -f conftest.err conftest.$ac_ext
8041 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8042 echo "${ECHO_T}$ac_header_preproc" >&6
8043
8044 # So?  What about this header?
8045 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8046   yes:no: )
8047     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8048 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8049     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8050 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8051     ac_header_preproc=yes
8052     ;;
8053   no:yes:* )
8054     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8055 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8056     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8057 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8058     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8059 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8060     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8061 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8062     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8063 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8064     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8065 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8066     (
8067       cat <<\_ASBOX
8068 ## ---------------------------------------- ##
8069 ## Report this to pgsql-bugs@postgresql.org ##
8070 ## ---------------------------------------- ##
8071 _ASBOX
8072     ) |
8073       sed "s/^/$as_me: WARNING:     /" >&2
8074     ;;
8075 esac
8076 echo "$as_me:$LINENO: checking for $ac_header" >&5
8077 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8078 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8079   echo $ECHO_N "(cached) $ECHO_C" >&6
8080 else
8081   eval "$as_ac_Header=\$ac_header_preproc"
8082 fi
8083 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8084 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8085
8086 fi
8087 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8088   cat >>confdefs.h <<_ACEOF
8089 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8090 _ACEOF
8091
8092 else
8093   { { echo "$as_me:$LINENO: error: readline header not found
8094 If you have readline already installed, see config.log for details on the
8095 failure.  It is possible the compiler isn't looking in the proper directory.
8096 Use --without-readline to disable readline support." >&5
8097 echo "$as_me: error: readline header not found
8098 If you have readline already installed, see config.log for details on the
8099 failure.  It is possible the compiler isn't looking in the proper directory.
8100 Use --without-readline to disable readline support." >&2;}
8101    { (exit 1); exit 1; }; }
8102 fi
8103
8104 done
8105
8106 fi
8107
8108 done
8109
8110
8111 for ac_header in readline/history.h
8112 do
8113 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8114 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8115   echo "$as_me:$LINENO: checking for $ac_header" >&5
8116 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8117 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8118   echo $ECHO_N "(cached) $ECHO_C" >&6
8119 fi
8120 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8121 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8122 else
8123   # Is the header compilable?
8124 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8125 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8126 cat >conftest.$ac_ext <<_ACEOF
8127 /* confdefs.h.  */
8128 _ACEOF
8129 cat confdefs.h >>conftest.$ac_ext
8130 cat >>conftest.$ac_ext <<_ACEOF
8131 /* end confdefs.h.  */
8132 $ac_includes_default
8133 #include <$ac_header>
8134 _ACEOF
8135 rm -f conftest.$ac_objext
8136 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8137   (eval $ac_compile) 2>conftest.er1
8138   ac_status=$?
8139   grep -v '^ *+' conftest.er1 >conftest.err
8140   rm -f conftest.er1
8141   cat conftest.err >&5
8142   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8143   (exit $ac_status); } &&
8144          { ac_try='test -z "$ac_c_werror_flag"
8145                          || test ! -s conftest.err'
8146   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8147   (eval $ac_try) 2>&5
8148   ac_status=$?
8149   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8150   (exit $ac_status); }; } &&
8151          { ac_try='test -s conftest.$ac_objext'
8152   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8153   (eval $ac_try) 2>&5
8154   ac_status=$?
8155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8156   (exit $ac_status); }; }; then
8157   ac_header_compiler=yes
8158 else
8159   echo "$as_me: failed program was:" >&5
8160 sed 's/^/| /' conftest.$ac_ext >&5
8161
8162 ac_header_compiler=no
8163 fi
8164 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8165 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8166 echo "${ECHO_T}$ac_header_compiler" >&6
8167
8168 # Is the header present?
8169 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8170 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8171 cat >conftest.$ac_ext <<_ACEOF
8172 /* confdefs.h.  */
8173 _ACEOF
8174 cat confdefs.h >>conftest.$ac_ext
8175 cat >>conftest.$ac_ext <<_ACEOF
8176 /* end confdefs.h.  */
8177 #include <$ac_header>
8178 _ACEOF
8179 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8180   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8181   ac_status=$?
8182   grep -v '^ *+' conftest.er1 >conftest.err
8183   rm -f conftest.er1
8184   cat conftest.err >&5
8185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8186   (exit $ac_status); } >/dev/null; then
8187   if test -s conftest.err; then
8188     ac_cpp_err=$ac_c_preproc_warn_flag
8189     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8190   else
8191     ac_cpp_err=
8192   fi
8193 else
8194   ac_cpp_err=yes
8195 fi
8196 if test -z "$ac_cpp_err"; then
8197   ac_header_preproc=yes
8198 else
8199   echo "$as_me: failed program was:" >&5
8200 sed 's/^/| /' conftest.$ac_ext >&5
8201
8202   ac_header_preproc=no
8203 fi
8204 rm -f conftest.err conftest.$ac_ext
8205 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8206 echo "${ECHO_T}$ac_header_preproc" >&6
8207
8208 # So?  What about this header?
8209 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8210   yes:no: )
8211     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8212 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8213     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8214 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8215     ac_header_preproc=yes
8216     ;;
8217   no:yes:* )
8218     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8219 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8220     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8221 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8222     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8223 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8224     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8225 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8226     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8227 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8228     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8229 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8230     (
8231       cat <<\_ASBOX
8232 ## ---------------------------------------- ##
8233 ## Report this to pgsql-bugs@postgresql.org ##
8234 ## ---------------------------------------- ##
8235 _ASBOX
8236     ) |
8237       sed "s/^/$as_me: WARNING:     /" >&2
8238     ;;
8239 esac
8240 echo "$as_me:$LINENO: checking for $ac_header" >&5
8241 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8242 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8243   echo $ECHO_N "(cached) $ECHO_C" >&6
8244 else
8245   eval "$as_ac_Header=\$ac_header_preproc"
8246 fi
8247 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8248 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8249
8250 fi
8251 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8252   cat >>confdefs.h <<_ACEOF
8253 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8254 _ACEOF
8255
8256 else
8257
8258 for ac_header in history.h
8259 do
8260 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8261 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8262   echo "$as_me:$LINENO: checking for $ac_header" >&5
8263 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8264 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8265   echo $ECHO_N "(cached) $ECHO_C" >&6
8266 fi
8267 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8268 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8269 else
8270   # Is the header compilable?
8271 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8272 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8273 cat >conftest.$ac_ext <<_ACEOF
8274 /* confdefs.h.  */
8275 _ACEOF
8276 cat confdefs.h >>conftest.$ac_ext
8277 cat >>conftest.$ac_ext <<_ACEOF
8278 /* end confdefs.h.  */
8279 $ac_includes_default
8280 #include <$ac_header>
8281 _ACEOF
8282 rm -f conftest.$ac_objext
8283 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8284   (eval $ac_compile) 2>conftest.er1
8285   ac_status=$?
8286   grep -v '^ *+' conftest.er1 >conftest.err
8287   rm -f conftest.er1
8288   cat conftest.err >&5
8289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8290   (exit $ac_status); } &&
8291          { ac_try='test -z "$ac_c_werror_flag"
8292                          || test ! -s conftest.err'
8293   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8294   (eval $ac_try) 2>&5
8295   ac_status=$?
8296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8297   (exit $ac_status); }; } &&
8298          { ac_try='test -s conftest.$ac_objext'
8299   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8300   (eval $ac_try) 2>&5
8301   ac_status=$?
8302   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8303   (exit $ac_status); }; }; then
8304   ac_header_compiler=yes
8305 else
8306   echo "$as_me: failed program was:" >&5
8307 sed 's/^/| /' conftest.$ac_ext >&5
8308
8309 ac_header_compiler=no
8310 fi
8311 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8312 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8313 echo "${ECHO_T}$ac_header_compiler" >&6
8314
8315 # Is the header present?
8316 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8317 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8318 cat >conftest.$ac_ext <<_ACEOF
8319 /* confdefs.h.  */
8320 _ACEOF
8321 cat confdefs.h >>conftest.$ac_ext
8322 cat >>conftest.$ac_ext <<_ACEOF
8323 /* end confdefs.h.  */
8324 #include <$ac_header>
8325 _ACEOF
8326 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8327   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8328   ac_status=$?
8329   grep -v '^ *+' conftest.er1 >conftest.err
8330   rm -f conftest.er1
8331   cat conftest.err >&5
8332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8333   (exit $ac_status); } >/dev/null; then
8334   if test -s conftest.err; then
8335     ac_cpp_err=$ac_c_preproc_warn_flag
8336     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8337   else
8338     ac_cpp_err=
8339   fi
8340 else
8341   ac_cpp_err=yes
8342 fi
8343 if test -z "$ac_cpp_err"; then
8344   ac_header_preproc=yes
8345 else
8346   echo "$as_me: failed program was:" >&5
8347 sed 's/^/| /' conftest.$ac_ext >&5
8348
8349   ac_header_preproc=no
8350 fi
8351 rm -f conftest.err conftest.$ac_ext
8352 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8353 echo "${ECHO_T}$ac_header_preproc" >&6
8354
8355 # So?  What about this header?
8356 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8357   yes:no: )
8358     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8359 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8360     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8361 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8362     ac_header_preproc=yes
8363     ;;
8364   no:yes:* )
8365     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8366 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8367     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8368 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8369     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8370 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8371     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8372 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8373     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8374 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8375     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8376 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8377     (
8378       cat <<\_ASBOX
8379 ## ---------------------------------------- ##
8380 ## Report this to pgsql-bugs@postgresql.org ##
8381 ## ---------------------------------------- ##
8382 _ASBOX
8383     ) |
8384       sed "s/^/$as_me: WARNING:     /" >&2
8385     ;;
8386 esac
8387 echo "$as_me:$LINENO: checking for $ac_header" >&5
8388 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8389 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8390   echo $ECHO_N "(cached) $ECHO_C" >&6
8391 else
8392   eval "$as_ac_Header=\$ac_header_preproc"
8393 fi
8394 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8395 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8396
8397 fi
8398 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8399   cat >>confdefs.h <<_ACEOF
8400 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8401 _ACEOF
8402
8403 else
8404   { { echo "$as_me:$LINENO: error: history header not found
8405 If you have readline already installed, see config.log for details on the
8406 failure.  It is possible the compiler isn't looking in the proper directory.
8407 Use --without-readline to disable readline support." >&5
8408 echo "$as_me: error: history header not found
8409 If you have readline already installed, see config.log for details on the
8410 failure.  It is possible the compiler isn't looking in the proper directory.
8411 Use --without-readline to disable readline support." >&2;}
8412    { (exit 1); exit 1; }; }
8413 fi
8414
8415 done
8416
8417 fi
8418
8419 done
8420
8421 fi
8422
8423 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
8424 # Some installations of libedit usurp /usr/include/readline/, which seems
8425 # bad practice, since in combined installations readline will have its headers
8426 # there.  We might have to resort to AC_EGREP checks to make sure we found
8427 # the proper header...
8428
8429 for ac_header in editline/readline.h
8430 do
8431 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8432 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8433   echo "$as_me:$LINENO: checking for $ac_header" >&5
8434 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8435 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8436   echo $ECHO_N "(cached) $ECHO_C" >&6
8437 fi
8438 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8439 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8440 else
8441   # Is the header compilable?
8442 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8443 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8444 cat >conftest.$ac_ext <<_ACEOF
8445 /* confdefs.h.  */
8446 _ACEOF
8447 cat confdefs.h >>conftest.$ac_ext
8448 cat >>conftest.$ac_ext <<_ACEOF
8449 /* end confdefs.h.  */
8450 $ac_includes_default
8451 #include <$ac_header>
8452 _ACEOF
8453 rm -f conftest.$ac_objext
8454 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8455   (eval $ac_compile) 2>conftest.er1
8456   ac_status=$?
8457   grep -v '^ *+' conftest.er1 >conftest.err
8458   rm -f conftest.er1
8459   cat conftest.err >&5
8460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8461   (exit $ac_status); } &&
8462          { ac_try='test -z "$ac_c_werror_flag"
8463                          || test ! -s conftest.err'
8464   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8465   (eval $ac_try) 2>&5
8466   ac_status=$?
8467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8468   (exit $ac_status); }; } &&
8469          { ac_try='test -s conftest.$ac_objext'
8470   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8471   (eval $ac_try) 2>&5
8472   ac_status=$?
8473   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8474   (exit $ac_status); }; }; then
8475   ac_header_compiler=yes
8476 else
8477   echo "$as_me: failed program was:" >&5
8478 sed 's/^/| /' conftest.$ac_ext >&5
8479
8480 ac_header_compiler=no
8481 fi
8482 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8483 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8484 echo "${ECHO_T}$ac_header_compiler" >&6
8485
8486 # Is the header present?
8487 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8488 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8489 cat >conftest.$ac_ext <<_ACEOF
8490 /* confdefs.h.  */
8491 _ACEOF
8492 cat confdefs.h >>conftest.$ac_ext
8493 cat >>conftest.$ac_ext <<_ACEOF
8494 /* end confdefs.h.  */
8495 #include <$ac_header>
8496 _ACEOF
8497 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8498   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8499   ac_status=$?
8500   grep -v '^ *+' conftest.er1 >conftest.err
8501   rm -f conftest.er1
8502   cat conftest.err >&5
8503   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8504   (exit $ac_status); } >/dev/null; then
8505   if test -s conftest.err; then
8506     ac_cpp_err=$ac_c_preproc_warn_flag
8507     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8508   else
8509     ac_cpp_err=
8510   fi
8511 else
8512   ac_cpp_err=yes
8513 fi
8514 if test -z "$ac_cpp_err"; then
8515   ac_header_preproc=yes
8516 else
8517   echo "$as_me: failed program was:" >&5
8518 sed 's/^/| /' conftest.$ac_ext >&5
8519
8520   ac_header_preproc=no
8521 fi
8522 rm -f conftest.err conftest.$ac_ext
8523 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8524 echo "${ECHO_T}$ac_header_preproc" >&6
8525
8526 # So?  What about this header?
8527 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8528   yes:no: )
8529     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8530 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8531     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8532 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8533     ac_header_preproc=yes
8534     ;;
8535   no:yes:* )
8536     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8537 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8538     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8539 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8540     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8541 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8542     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8543 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8544     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8545 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8546     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8547 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8548     (
8549       cat <<\_ASBOX
8550 ## ---------------------------------------- ##
8551 ## Report this to pgsql-bugs@postgresql.org ##
8552 ## ---------------------------------------- ##
8553 _ASBOX
8554     ) |
8555       sed "s/^/$as_me: WARNING:     /" >&2
8556     ;;
8557 esac
8558 echo "$as_me:$LINENO: checking for $ac_header" >&5
8559 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8560 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8561   echo $ECHO_N "(cached) $ECHO_C" >&6
8562 else
8563   eval "$as_ac_Header=\$ac_header_preproc"
8564 fi
8565 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8566 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8567
8568 fi
8569 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8570   cat >>confdefs.h <<_ACEOF
8571 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8572 _ACEOF
8573
8574 else
8575
8576 for ac_header in readline.h
8577 do
8578 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8579 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8580   echo "$as_me:$LINENO: checking for $ac_header" >&5
8581 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8582 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8583   echo $ECHO_N "(cached) $ECHO_C" >&6
8584 fi
8585 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8586 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8587 else
8588   # Is the header compilable?
8589 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8590 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8591 cat >conftest.$ac_ext <<_ACEOF
8592 /* confdefs.h.  */
8593 _ACEOF
8594 cat confdefs.h >>conftest.$ac_ext
8595 cat >>conftest.$ac_ext <<_ACEOF
8596 /* end confdefs.h.  */
8597 $ac_includes_default
8598 #include <$ac_header>
8599 _ACEOF
8600 rm -f conftest.$ac_objext
8601 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8602   (eval $ac_compile) 2>conftest.er1
8603   ac_status=$?
8604   grep -v '^ *+' conftest.er1 >conftest.err
8605   rm -f conftest.er1
8606   cat conftest.err >&5
8607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8608   (exit $ac_status); } &&
8609          { ac_try='test -z "$ac_c_werror_flag"
8610                          || test ! -s conftest.err'
8611   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8612   (eval $ac_try) 2>&5
8613   ac_status=$?
8614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8615   (exit $ac_status); }; } &&
8616          { ac_try='test -s conftest.$ac_objext'
8617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8618   (eval $ac_try) 2>&5
8619   ac_status=$?
8620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8621   (exit $ac_status); }; }; then
8622   ac_header_compiler=yes
8623 else
8624   echo "$as_me: failed program was:" >&5
8625 sed 's/^/| /' conftest.$ac_ext >&5
8626
8627 ac_header_compiler=no
8628 fi
8629 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8630 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8631 echo "${ECHO_T}$ac_header_compiler" >&6
8632
8633 # Is the header present?
8634 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8635 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8636 cat >conftest.$ac_ext <<_ACEOF
8637 /* confdefs.h.  */
8638 _ACEOF
8639 cat confdefs.h >>conftest.$ac_ext
8640 cat >>conftest.$ac_ext <<_ACEOF
8641 /* end confdefs.h.  */
8642 #include <$ac_header>
8643 _ACEOF
8644 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8645   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8646   ac_status=$?
8647   grep -v '^ *+' conftest.er1 >conftest.err
8648   rm -f conftest.er1
8649   cat conftest.err >&5
8650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8651   (exit $ac_status); } >/dev/null; then
8652   if test -s conftest.err; then
8653     ac_cpp_err=$ac_c_preproc_warn_flag
8654     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8655   else
8656     ac_cpp_err=
8657   fi
8658 else
8659   ac_cpp_err=yes
8660 fi
8661 if test -z "$ac_cpp_err"; then
8662   ac_header_preproc=yes
8663 else
8664   echo "$as_me: failed program was:" >&5
8665 sed 's/^/| /' conftest.$ac_ext >&5
8666
8667   ac_header_preproc=no
8668 fi
8669 rm -f conftest.err conftest.$ac_ext
8670 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8671 echo "${ECHO_T}$ac_header_preproc" >&6
8672
8673 # So?  What about this header?
8674 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8675   yes:no: )
8676     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8677 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8678     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8679 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8680     ac_header_preproc=yes
8681     ;;
8682   no:yes:* )
8683     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8684 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8685     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8686 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8687     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8688 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8689     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8690 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8691     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8692 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8693     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8694 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8695     (
8696       cat <<\_ASBOX
8697 ## ---------------------------------------- ##
8698 ## Report this to pgsql-bugs@postgresql.org ##
8699 ## ---------------------------------------- ##
8700 _ASBOX
8701     ) |
8702       sed "s/^/$as_me: WARNING:     /" >&2
8703     ;;
8704 esac
8705 echo "$as_me:$LINENO: checking for $ac_header" >&5
8706 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8707 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8708   echo $ECHO_N "(cached) $ECHO_C" >&6
8709 else
8710   eval "$as_ac_Header=\$ac_header_preproc"
8711 fi
8712 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8713 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8714
8715 fi
8716 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8717   cat >>confdefs.h <<_ACEOF
8718 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8719 _ACEOF
8720
8721 else
8722
8723 for ac_header in readline/readline.h
8724 do
8725 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8726 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8727   echo "$as_me:$LINENO: checking for $ac_header" >&5
8728 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8729 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8730   echo $ECHO_N "(cached) $ECHO_C" >&6
8731 fi
8732 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8733 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8734 else
8735   # Is the header compilable?
8736 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8737 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8738 cat >conftest.$ac_ext <<_ACEOF
8739 /* confdefs.h.  */
8740 _ACEOF
8741 cat confdefs.h >>conftest.$ac_ext
8742 cat >>conftest.$ac_ext <<_ACEOF
8743 /* end confdefs.h.  */
8744 $ac_includes_default
8745 #include <$ac_header>
8746 _ACEOF
8747 rm -f conftest.$ac_objext
8748 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8749   (eval $ac_compile) 2>conftest.er1
8750   ac_status=$?
8751   grep -v '^ *+' conftest.er1 >conftest.err
8752   rm -f conftest.er1
8753   cat conftest.err >&5
8754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8755   (exit $ac_status); } &&
8756          { ac_try='test -z "$ac_c_werror_flag"
8757                          || test ! -s conftest.err'
8758   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8759   (eval $ac_try) 2>&5
8760   ac_status=$?
8761   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8762   (exit $ac_status); }; } &&
8763          { ac_try='test -s conftest.$ac_objext'
8764   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8765   (eval $ac_try) 2>&5
8766   ac_status=$?
8767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8768   (exit $ac_status); }; }; then
8769   ac_header_compiler=yes
8770 else
8771   echo "$as_me: failed program was:" >&5
8772 sed 's/^/| /' conftest.$ac_ext >&5
8773
8774 ac_header_compiler=no
8775 fi
8776 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8777 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8778 echo "${ECHO_T}$ac_header_compiler" >&6
8779
8780 # Is the header present?
8781 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8782 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8783 cat >conftest.$ac_ext <<_ACEOF
8784 /* confdefs.h.  */
8785 _ACEOF
8786 cat confdefs.h >>conftest.$ac_ext
8787 cat >>conftest.$ac_ext <<_ACEOF
8788 /* end confdefs.h.  */
8789 #include <$ac_header>
8790 _ACEOF
8791 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8792   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8793   ac_status=$?
8794   grep -v '^ *+' conftest.er1 >conftest.err
8795   rm -f conftest.er1
8796   cat conftest.err >&5
8797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8798   (exit $ac_status); } >/dev/null; then
8799   if test -s conftest.err; then
8800     ac_cpp_err=$ac_c_preproc_warn_flag
8801     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8802   else
8803     ac_cpp_err=
8804   fi
8805 else
8806   ac_cpp_err=yes
8807 fi
8808 if test -z "$ac_cpp_err"; then
8809   ac_header_preproc=yes
8810 else
8811   echo "$as_me: failed program was:" >&5
8812 sed 's/^/| /' conftest.$ac_ext >&5
8813
8814   ac_header_preproc=no
8815 fi
8816 rm -f conftest.err conftest.$ac_ext
8817 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8818 echo "${ECHO_T}$ac_header_preproc" >&6
8819
8820 # So?  What about this header?
8821 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8822   yes:no: )
8823     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8824 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8825     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8826 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8827     ac_header_preproc=yes
8828     ;;
8829   no:yes:* )
8830     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8831 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8832     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8833 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8834     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8835 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8836     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8837 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8838     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8839 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8840     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8841 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8842     (
8843       cat <<\_ASBOX
8844 ## ---------------------------------------- ##
8845 ## Report this to pgsql-bugs@postgresql.org ##
8846 ## ---------------------------------------- ##
8847 _ASBOX
8848     ) |
8849       sed "s/^/$as_me: WARNING:     /" >&2
8850     ;;
8851 esac
8852 echo "$as_me:$LINENO: checking for $ac_header" >&5
8853 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8854 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8855   echo $ECHO_N "(cached) $ECHO_C" >&6
8856 else
8857   eval "$as_ac_Header=\$ac_header_preproc"
8858 fi
8859 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8860 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8861
8862 fi
8863 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8864   cat >>confdefs.h <<_ACEOF
8865 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8866 _ACEOF
8867
8868 else
8869   { { echo "$as_me:$LINENO: error: readline header not found
8870 If you have libedit already installed, see config.log for details on the
8871 failure.  It is possible the compiler isn't looking in the proper directory.
8872 Use --without-readline to disable libedit support." >&5
8873 echo "$as_me: error: readline header not found
8874 If you have libedit already installed, see config.log for details on the
8875 failure.  It is possible the compiler isn't looking in the proper directory.
8876 Use --without-readline to disable libedit support." >&2;}
8877    { (exit 1); exit 1; }; }
8878 fi
8879
8880 done
8881
8882 fi
8883
8884 done
8885
8886 fi
8887
8888 done
8889
8890
8891 for ac_header in editline/history.h
8892 do
8893 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8894 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8895   echo "$as_me:$LINENO: checking for $ac_header" >&5
8896 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8897 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8898   echo $ECHO_N "(cached) $ECHO_C" >&6
8899 fi
8900 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8901 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8902 else
8903   # Is the header compilable?
8904 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8905 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8906 cat >conftest.$ac_ext <<_ACEOF
8907 /* confdefs.h.  */
8908 _ACEOF
8909 cat confdefs.h >>conftest.$ac_ext
8910 cat >>conftest.$ac_ext <<_ACEOF
8911 /* end confdefs.h.  */
8912 $ac_includes_default
8913 #include <$ac_header>
8914 _ACEOF
8915 rm -f conftest.$ac_objext
8916 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8917   (eval $ac_compile) 2>conftest.er1
8918   ac_status=$?
8919   grep -v '^ *+' conftest.er1 >conftest.err
8920   rm -f conftest.er1
8921   cat conftest.err >&5
8922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8923   (exit $ac_status); } &&
8924          { ac_try='test -z "$ac_c_werror_flag"
8925                          || test ! -s conftest.err'
8926   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8927   (eval $ac_try) 2>&5
8928   ac_status=$?
8929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8930   (exit $ac_status); }; } &&
8931          { ac_try='test -s conftest.$ac_objext'
8932   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8933   (eval $ac_try) 2>&5
8934   ac_status=$?
8935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8936   (exit $ac_status); }; }; then
8937   ac_header_compiler=yes
8938 else
8939   echo "$as_me: failed program was:" >&5
8940 sed 's/^/| /' conftest.$ac_ext >&5
8941
8942 ac_header_compiler=no
8943 fi
8944 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8945 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8946 echo "${ECHO_T}$ac_header_compiler" >&6
8947
8948 # Is the header present?
8949 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8950 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8951 cat >conftest.$ac_ext <<_ACEOF
8952 /* confdefs.h.  */
8953 _ACEOF
8954 cat confdefs.h >>conftest.$ac_ext
8955 cat >>conftest.$ac_ext <<_ACEOF
8956 /* end confdefs.h.  */
8957 #include <$ac_header>
8958 _ACEOF
8959 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8960   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8961   ac_status=$?
8962   grep -v '^ *+' conftest.er1 >conftest.err
8963   rm -f conftest.er1
8964   cat conftest.err >&5
8965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8966   (exit $ac_status); } >/dev/null; then
8967   if test -s conftest.err; then
8968     ac_cpp_err=$ac_c_preproc_warn_flag
8969     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8970   else
8971     ac_cpp_err=
8972   fi
8973 else
8974   ac_cpp_err=yes
8975 fi
8976 if test -z "$ac_cpp_err"; then
8977   ac_header_preproc=yes
8978 else
8979   echo "$as_me: failed program was:" >&5
8980 sed 's/^/| /' conftest.$ac_ext >&5
8981
8982   ac_header_preproc=no
8983 fi
8984 rm -f conftest.err conftest.$ac_ext
8985 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8986 echo "${ECHO_T}$ac_header_preproc" >&6
8987
8988 # So?  What about this header?
8989 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8990   yes:no: )
8991     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8992 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8993     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8994 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8995     ac_header_preproc=yes
8996     ;;
8997   no:yes:* )
8998     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8999 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9000     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9001 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9002     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9003 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9004     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9005 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9006     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9007 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9008     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9009 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9010     (
9011       cat <<\_ASBOX
9012 ## ---------------------------------------- ##
9013 ## Report this to pgsql-bugs@postgresql.org ##
9014 ## ---------------------------------------- ##
9015 _ASBOX
9016     ) |
9017       sed "s/^/$as_me: WARNING:     /" >&2
9018     ;;
9019 esac
9020 echo "$as_me:$LINENO: checking for $ac_header" >&5
9021 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9022 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9023   echo $ECHO_N "(cached) $ECHO_C" >&6
9024 else
9025   eval "$as_ac_Header=\$ac_header_preproc"
9026 fi
9027 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9028 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9029
9030 fi
9031 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9032   cat >>confdefs.h <<_ACEOF
9033 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9034 _ACEOF
9035
9036 else
9037
9038 for ac_header in history.h
9039 do
9040 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9041 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9042   echo "$as_me:$LINENO: checking for $ac_header" >&5
9043 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9044 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9045   echo $ECHO_N "(cached) $ECHO_C" >&6
9046 fi
9047 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9048 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9049 else
9050   # Is the header compilable?
9051 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9052 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9053 cat >conftest.$ac_ext <<_ACEOF
9054 /* confdefs.h.  */
9055 _ACEOF
9056 cat confdefs.h >>conftest.$ac_ext
9057 cat >>conftest.$ac_ext <<_ACEOF
9058 /* end confdefs.h.  */
9059 $ac_includes_default
9060 #include <$ac_header>
9061 _ACEOF
9062 rm -f conftest.$ac_objext
9063 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9064   (eval $ac_compile) 2>conftest.er1
9065   ac_status=$?
9066   grep -v '^ *+' conftest.er1 >conftest.err
9067   rm -f conftest.er1
9068   cat conftest.err >&5
9069   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9070   (exit $ac_status); } &&
9071          { ac_try='test -z "$ac_c_werror_flag"
9072                          || test ! -s conftest.err'
9073   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9074   (eval $ac_try) 2>&5
9075   ac_status=$?
9076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9077   (exit $ac_status); }; } &&
9078          { ac_try='test -s conftest.$ac_objext'
9079   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9080   (eval $ac_try) 2>&5
9081   ac_status=$?
9082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9083   (exit $ac_status); }; }; then
9084   ac_header_compiler=yes
9085 else
9086   echo "$as_me: failed program was:" >&5
9087 sed 's/^/| /' conftest.$ac_ext >&5
9088
9089 ac_header_compiler=no
9090 fi
9091 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9092 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9093 echo "${ECHO_T}$ac_header_compiler" >&6
9094
9095 # Is the header present?
9096 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9097 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9098 cat >conftest.$ac_ext <<_ACEOF
9099 /* confdefs.h.  */
9100 _ACEOF
9101 cat confdefs.h >>conftest.$ac_ext
9102 cat >>conftest.$ac_ext <<_ACEOF
9103 /* end confdefs.h.  */
9104 #include <$ac_header>
9105 _ACEOF
9106 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9107   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9108   ac_status=$?
9109   grep -v '^ *+' conftest.er1 >conftest.err
9110   rm -f conftest.er1
9111   cat conftest.err >&5
9112   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9113   (exit $ac_status); } >/dev/null; then
9114   if test -s conftest.err; then
9115     ac_cpp_err=$ac_c_preproc_warn_flag
9116     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9117   else
9118     ac_cpp_err=
9119   fi
9120 else
9121   ac_cpp_err=yes
9122 fi
9123 if test -z "$ac_cpp_err"; then
9124   ac_header_preproc=yes
9125 else
9126   echo "$as_me: failed program was:" >&5
9127 sed 's/^/| /' conftest.$ac_ext >&5
9128
9129   ac_header_preproc=no
9130 fi
9131 rm -f conftest.err conftest.$ac_ext
9132 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9133 echo "${ECHO_T}$ac_header_preproc" >&6
9134
9135 # So?  What about this header?
9136 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9137   yes:no: )
9138     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9139 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9140     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9141 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9142     ac_header_preproc=yes
9143     ;;
9144   no:yes:* )
9145     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9146 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9147     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9148 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9149     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9150 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9151     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9152 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9153     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9154 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9155     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9156 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9157     (
9158       cat <<\_ASBOX
9159 ## ---------------------------------------- ##
9160 ## Report this to pgsql-bugs@postgresql.org ##
9161 ## ---------------------------------------- ##
9162 _ASBOX
9163     ) |
9164       sed "s/^/$as_me: WARNING:     /" >&2
9165     ;;
9166 esac
9167 echo "$as_me:$LINENO: checking for $ac_header" >&5
9168 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9169 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9170   echo $ECHO_N "(cached) $ECHO_C" >&6
9171 else
9172   eval "$as_ac_Header=\$ac_header_preproc"
9173 fi
9174 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9175 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9176
9177 fi
9178 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9179   cat >>confdefs.h <<_ACEOF
9180 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9181 _ACEOF
9182
9183 else
9184
9185 for ac_header in readline/history.h
9186 do
9187 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9188 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9189   echo "$as_me:$LINENO: checking for $ac_header" >&5
9190 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9191 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9192   echo $ECHO_N "(cached) $ECHO_C" >&6
9193 fi
9194 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9195 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9196 else
9197   # Is the header compilable?
9198 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9199 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9200 cat >conftest.$ac_ext <<_ACEOF
9201 /* confdefs.h.  */
9202 _ACEOF
9203 cat confdefs.h >>conftest.$ac_ext
9204 cat >>conftest.$ac_ext <<_ACEOF
9205 /* end confdefs.h.  */
9206 $ac_includes_default
9207 #include <$ac_header>
9208 _ACEOF
9209 rm -f conftest.$ac_objext
9210 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9211   (eval $ac_compile) 2>conftest.er1
9212   ac_status=$?
9213   grep -v '^ *+' conftest.er1 >conftest.err
9214   rm -f conftest.er1
9215   cat conftest.err >&5
9216   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9217   (exit $ac_status); } &&
9218          { ac_try='test -z "$ac_c_werror_flag"
9219                          || test ! -s conftest.err'
9220   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9221   (eval $ac_try) 2>&5
9222   ac_status=$?
9223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9224   (exit $ac_status); }; } &&
9225          { ac_try='test -s conftest.$ac_objext'
9226   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9227   (eval $ac_try) 2>&5
9228   ac_status=$?
9229   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9230   (exit $ac_status); }; }; then
9231   ac_header_compiler=yes
9232 else
9233   echo "$as_me: failed program was:" >&5
9234 sed 's/^/| /' conftest.$ac_ext >&5
9235
9236 ac_header_compiler=no
9237 fi
9238 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9239 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9240 echo "${ECHO_T}$ac_header_compiler" >&6
9241
9242 # Is the header present?
9243 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9244 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9245 cat >conftest.$ac_ext <<_ACEOF
9246 /* confdefs.h.  */
9247 _ACEOF
9248 cat confdefs.h >>conftest.$ac_ext
9249 cat >>conftest.$ac_ext <<_ACEOF
9250 /* end confdefs.h.  */
9251 #include <$ac_header>
9252 _ACEOF
9253 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9254   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9255   ac_status=$?
9256   grep -v '^ *+' conftest.er1 >conftest.err
9257   rm -f conftest.er1
9258   cat conftest.err >&5
9259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9260   (exit $ac_status); } >/dev/null; then
9261   if test -s conftest.err; then
9262     ac_cpp_err=$ac_c_preproc_warn_flag
9263     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9264   else
9265     ac_cpp_err=
9266   fi
9267 else
9268   ac_cpp_err=yes
9269 fi
9270 if test -z "$ac_cpp_err"; then
9271   ac_header_preproc=yes
9272 else
9273   echo "$as_me: failed program was:" >&5
9274 sed 's/^/| /' conftest.$ac_ext >&5
9275
9276   ac_header_preproc=no
9277 fi
9278 rm -f conftest.err conftest.$ac_ext
9279 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9280 echo "${ECHO_T}$ac_header_preproc" >&6
9281
9282 # So?  What about this header?
9283 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9284   yes:no: )
9285     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9286 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9287     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9288 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9289     ac_header_preproc=yes
9290     ;;
9291   no:yes:* )
9292     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9293 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9294     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9295 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9296     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9297 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9298     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9299 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9300     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9301 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9302     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9303 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9304     (
9305       cat <<\_ASBOX
9306 ## ---------------------------------------- ##
9307 ## Report this to pgsql-bugs@postgresql.org ##
9308 ## ---------------------------------------- ##
9309 _ASBOX
9310     ) |
9311       sed "s/^/$as_me: WARNING:     /" >&2
9312     ;;
9313 esac
9314 echo "$as_me:$LINENO: checking for $ac_header" >&5
9315 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9316 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9317   echo $ECHO_N "(cached) $ECHO_C" >&6
9318 else
9319   eval "$as_ac_Header=\$ac_header_preproc"
9320 fi
9321 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9322 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9323
9324 fi
9325 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9326   cat >>confdefs.h <<_ACEOF
9327 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9328 _ACEOF
9329
9330 else
9331   { { echo "$as_me:$LINENO: error: history header not found
9332 If you have libedit already installed, see config.log for details on the
9333 failure.  It is possible the compiler isn't looking in the proper directory.
9334 Use --without-readline to disable libedit support." >&5
9335 echo "$as_me: error: history header not found
9336 If you have libedit already installed, see config.log for details on the
9337 failure.  It is possible the compiler isn't looking in the proper directory.
9338 Use --without-readline to disable libedit support." >&2;}
9339    { (exit 1); exit 1; }; }
9340 fi
9341
9342 done
9343
9344 fi
9345
9346 done
9347
9348 fi
9349
9350 done
9351
9352 fi
9353
9354 if test "$with_zlib" = yes; then
9355   if test "${ac_cv_header_zlib_h+set}" = set; then
9356   echo "$as_me:$LINENO: checking for zlib.h" >&5
9357 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
9358 if test "${ac_cv_header_zlib_h+set}" = set; then
9359   echo $ECHO_N "(cached) $ECHO_C" >&6
9360 fi
9361 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
9362 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
9363 else
9364   # Is the header compilable?
9365 echo "$as_me:$LINENO: checking zlib.h usability" >&5
9366 echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6
9367 cat >conftest.$ac_ext <<_ACEOF
9368 /* confdefs.h.  */
9369 _ACEOF
9370 cat confdefs.h >>conftest.$ac_ext
9371 cat >>conftest.$ac_ext <<_ACEOF
9372 /* end confdefs.h.  */
9373 $ac_includes_default
9374 #include <zlib.h>
9375 _ACEOF
9376 rm -f conftest.$ac_objext
9377 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9378   (eval $ac_compile) 2>conftest.er1
9379   ac_status=$?
9380   grep -v '^ *+' conftest.er1 >conftest.err
9381   rm -f conftest.er1
9382   cat conftest.err >&5
9383   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9384   (exit $ac_status); } &&
9385          { ac_try='test -z "$ac_c_werror_flag"
9386                          || test ! -s conftest.err'
9387   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9388   (eval $ac_try) 2>&5
9389   ac_status=$?
9390   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9391   (exit $ac_status); }; } &&
9392          { ac_try='test -s conftest.$ac_objext'
9393   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9394   (eval $ac_try) 2>&5
9395   ac_status=$?
9396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9397   (exit $ac_status); }; }; then
9398   ac_header_compiler=yes
9399 else
9400   echo "$as_me: failed program was:" >&5
9401 sed 's/^/| /' conftest.$ac_ext >&5
9402
9403 ac_header_compiler=no
9404 fi
9405 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9406 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9407 echo "${ECHO_T}$ac_header_compiler" >&6
9408
9409 # Is the header present?
9410 echo "$as_me:$LINENO: checking zlib.h presence" >&5
9411 echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6
9412 cat >conftest.$ac_ext <<_ACEOF
9413 /* confdefs.h.  */
9414 _ACEOF
9415 cat confdefs.h >>conftest.$ac_ext
9416 cat >>conftest.$ac_ext <<_ACEOF
9417 /* end confdefs.h.  */
9418 #include <zlib.h>
9419 _ACEOF
9420 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9421   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9422   ac_status=$?
9423   grep -v '^ *+' conftest.er1 >conftest.err
9424   rm -f conftest.er1
9425   cat conftest.err >&5
9426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9427   (exit $ac_status); } >/dev/null; then
9428   if test -s conftest.err; then
9429     ac_cpp_err=$ac_c_preproc_warn_flag
9430     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9431   else
9432     ac_cpp_err=
9433   fi
9434 else
9435   ac_cpp_err=yes
9436 fi
9437 if test -z "$ac_cpp_err"; then
9438   ac_header_preproc=yes
9439 else
9440   echo "$as_me: failed program was:" >&5
9441 sed 's/^/| /' conftest.$ac_ext >&5
9442
9443   ac_header_preproc=no
9444 fi
9445 rm -f conftest.err conftest.$ac_ext
9446 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9447 echo "${ECHO_T}$ac_header_preproc" >&6
9448
9449 # So?  What about this header?
9450 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9451   yes:no: )
9452     { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
9453 echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9454     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
9455 echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
9456     ac_header_preproc=yes
9457     ;;
9458   no:yes:* )
9459     { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
9460 echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
9461     { echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
9462 echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
9463     { echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
9464 echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
9465     { echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
9466 echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9467     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
9468 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
9469     { echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
9470 echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
9471     (
9472       cat <<\_ASBOX
9473 ## ---------------------------------------- ##
9474 ## Report this to pgsql-bugs@postgresql.org ##
9475 ## ---------------------------------------- ##
9476 _ASBOX
9477     ) |
9478       sed "s/^/$as_me: WARNING:     /" >&2
9479     ;;
9480 esac
9481 echo "$as_me:$LINENO: checking for zlib.h" >&5
9482 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
9483 if test "${ac_cv_header_zlib_h+set}" = set; then
9484   echo $ECHO_N "(cached) $ECHO_C" >&6
9485 else
9486   ac_cv_header_zlib_h=$ac_header_preproc
9487 fi
9488 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
9489 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
9490
9491 fi
9492 if test $ac_cv_header_zlib_h = yes; then
9493   :
9494 else
9495   { { echo "$as_me:$LINENO: error: zlib header not found
9496 If you have zlib already installed, see config.log for details on the
9497 failure.  It is possible the compiler isn't looking in the proper directory.
9498 Use --without-zlib to disable zlib support." >&5
9499 echo "$as_me: error: zlib header not found
9500 If you have zlib already installed, see config.log for details on the
9501 failure.  It is possible the compiler isn't looking in the proper directory.
9502 Use --without-zlib to disable zlib support." >&2;}
9503    { (exit 1); exit 1; }; }
9504 fi
9505
9506
9507 fi
9508
9509 if test "$with_krb5" = yes ; then
9510   if test "${ac_cv_header_krb5_h+set}" = set; then
9511   echo "$as_me:$LINENO: checking for krb5.h" >&5
9512 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9513 if test "${ac_cv_header_krb5_h+set}" = set; then
9514   echo $ECHO_N "(cached) $ECHO_C" >&6
9515 fi
9516 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9517 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9518 else
9519   # Is the header compilable?
9520 echo "$as_me:$LINENO: checking krb5.h usability" >&5
9521 echo $ECHO_N "checking krb5.h usability... $ECHO_C" >&6
9522 cat >conftest.$ac_ext <<_ACEOF
9523 /* confdefs.h.  */
9524 _ACEOF
9525 cat confdefs.h >>conftest.$ac_ext
9526 cat >>conftest.$ac_ext <<_ACEOF
9527 /* end confdefs.h.  */
9528 $ac_includes_default
9529 #include <krb5.h>
9530 _ACEOF
9531 rm -f conftest.$ac_objext
9532 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9533   (eval $ac_compile) 2>conftest.er1
9534   ac_status=$?
9535   grep -v '^ *+' conftest.er1 >conftest.err
9536   rm -f conftest.er1
9537   cat conftest.err >&5
9538   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9539   (exit $ac_status); } &&
9540          { ac_try='test -z "$ac_c_werror_flag"
9541                          || test ! -s conftest.err'
9542   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9543   (eval $ac_try) 2>&5
9544   ac_status=$?
9545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9546   (exit $ac_status); }; } &&
9547          { ac_try='test -s conftest.$ac_objext'
9548   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9549   (eval $ac_try) 2>&5
9550   ac_status=$?
9551   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9552   (exit $ac_status); }; }; then
9553   ac_header_compiler=yes
9554 else
9555   echo "$as_me: failed program was:" >&5
9556 sed 's/^/| /' conftest.$ac_ext >&5
9557
9558 ac_header_compiler=no
9559 fi
9560 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9561 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9562 echo "${ECHO_T}$ac_header_compiler" >&6
9563
9564 # Is the header present?
9565 echo "$as_me:$LINENO: checking krb5.h presence" >&5
9566 echo $ECHO_N "checking krb5.h presence... $ECHO_C" >&6
9567 cat >conftest.$ac_ext <<_ACEOF
9568 /* confdefs.h.  */
9569 _ACEOF
9570 cat confdefs.h >>conftest.$ac_ext
9571 cat >>conftest.$ac_ext <<_ACEOF
9572 /* end confdefs.h.  */
9573 #include <krb5.h>
9574 _ACEOF
9575 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9576   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9577   ac_status=$?
9578   grep -v '^ *+' conftest.er1 >conftest.err
9579   rm -f conftest.er1
9580   cat conftest.err >&5
9581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9582   (exit $ac_status); } >/dev/null; then
9583   if test -s conftest.err; then
9584     ac_cpp_err=$ac_c_preproc_warn_flag
9585     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9586   else
9587     ac_cpp_err=
9588   fi
9589 else
9590   ac_cpp_err=yes
9591 fi
9592 if test -z "$ac_cpp_err"; then
9593   ac_header_preproc=yes
9594 else
9595   echo "$as_me: failed program was:" >&5
9596 sed 's/^/| /' conftest.$ac_ext >&5
9597
9598   ac_header_preproc=no
9599 fi
9600 rm -f conftest.err conftest.$ac_ext
9601 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9602 echo "${ECHO_T}$ac_header_preproc" >&6
9603
9604 # So?  What about this header?
9605 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9606   yes:no: )
9607     { echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
9608 echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9609     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
9610 echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
9611     ac_header_preproc=yes
9612     ;;
9613   no:yes:* )
9614     { echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
9615 echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
9616     { echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
9617 echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
9618     { echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
9619 echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
9620     { echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
9621 echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9622     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
9623 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
9624     { echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
9625 echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
9626     (
9627       cat <<\_ASBOX
9628 ## ---------------------------------------- ##
9629 ## Report this to pgsql-bugs@postgresql.org ##
9630 ## ---------------------------------------- ##
9631 _ASBOX
9632     ) |
9633       sed "s/^/$as_me: WARNING:     /" >&2
9634     ;;
9635 esac
9636 echo "$as_me:$LINENO: checking for krb5.h" >&5
9637 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9638 if test "${ac_cv_header_krb5_h+set}" = set; then
9639   echo $ECHO_N "(cached) $ECHO_C" >&6
9640 else
9641   ac_cv_header_krb5_h=$ac_header_preproc
9642 fi
9643 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9644 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9645
9646 fi
9647 if test $ac_cv_header_krb5_h = yes; then
9648   :
9649 else
9650   { { echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
9651 echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
9652    { (exit 1); exit 1; }; }
9653 fi
9654
9655
9656 fi
9657
9658 if test "$with_openssl" = yes ; then
9659   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9660   echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9661 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9662 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9663   echo $ECHO_N "(cached) $ECHO_C" >&6
9664 fi
9665 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9666 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9667 else
9668   # Is the header compilable?
9669 echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
9670 echo $ECHO_N "checking openssl/ssl.h usability... $ECHO_C" >&6
9671 cat >conftest.$ac_ext <<_ACEOF
9672 /* confdefs.h.  */
9673 _ACEOF
9674 cat confdefs.h >>conftest.$ac_ext
9675 cat >>conftest.$ac_ext <<_ACEOF
9676 /* end confdefs.h.  */
9677 $ac_includes_default
9678 #include <openssl/ssl.h>
9679 _ACEOF
9680 rm -f conftest.$ac_objext
9681 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9682   (eval $ac_compile) 2>conftest.er1
9683   ac_status=$?
9684   grep -v '^ *+' conftest.er1 >conftest.err
9685   rm -f conftest.er1
9686   cat conftest.err >&5
9687   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9688   (exit $ac_status); } &&
9689          { ac_try='test -z "$ac_c_werror_flag"
9690                          || test ! -s conftest.err'
9691   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9692   (eval $ac_try) 2>&5
9693   ac_status=$?
9694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9695   (exit $ac_status); }; } &&
9696          { ac_try='test -s conftest.$ac_objext'
9697   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9698   (eval $ac_try) 2>&5
9699   ac_status=$?
9700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9701   (exit $ac_status); }; }; then
9702   ac_header_compiler=yes
9703 else
9704   echo "$as_me: failed program was:" >&5
9705 sed 's/^/| /' conftest.$ac_ext >&5
9706
9707 ac_header_compiler=no
9708 fi
9709 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9710 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9711 echo "${ECHO_T}$ac_header_compiler" >&6
9712
9713 # Is the header present?
9714 echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
9715 echo $ECHO_N "checking openssl/ssl.h presence... $ECHO_C" >&6
9716 cat >conftest.$ac_ext <<_ACEOF
9717 /* confdefs.h.  */
9718 _ACEOF
9719 cat confdefs.h >>conftest.$ac_ext
9720 cat >>conftest.$ac_ext <<_ACEOF
9721 /* end confdefs.h.  */
9722 #include <openssl/ssl.h>
9723 _ACEOF
9724 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9725   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9726   ac_status=$?
9727   grep -v '^ *+' conftest.er1 >conftest.err
9728   rm -f conftest.er1
9729   cat conftest.err >&5
9730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9731   (exit $ac_status); } >/dev/null; then
9732   if test -s conftest.err; then
9733     ac_cpp_err=$ac_c_preproc_warn_flag
9734     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9735   else
9736     ac_cpp_err=
9737   fi
9738 else
9739   ac_cpp_err=yes
9740 fi
9741 if test -z "$ac_cpp_err"; then
9742   ac_header_preproc=yes
9743 else
9744   echo "$as_me: failed program was:" >&5
9745 sed 's/^/| /' conftest.$ac_ext >&5
9746
9747   ac_header_preproc=no
9748 fi
9749 rm -f conftest.err conftest.$ac_ext
9750 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9751 echo "${ECHO_T}$ac_header_preproc" >&6
9752
9753 # So?  What about this header?
9754 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9755   yes:no: )
9756     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
9757 echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9758     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
9759 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
9760     ac_header_preproc=yes
9761     ;;
9762   no:yes:* )
9763     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
9764 echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
9765     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
9766 echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
9767     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
9768 echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
9769     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
9770 echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9771     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
9772 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
9773     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
9774 echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
9775     (
9776       cat <<\_ASBOX
9777 ## ---------------------------------------- ##
9778 ## Report this to pgsql-bugs@postgresql.org ##
9779 ## ---------------------------------------- ##
9780 _ASBOX
9781     ) |
9782       sed "s/^/$as_me: WARNING:     /" >&2
9783     ;;
9784 esac
9785 echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9786 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9787 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9788   echo $ECHO_N "(cached) $ECHO_C" >&6
9789 else
9790   ac_cv_header_openssl_ssl_h=$ac_header_preproc
9791 fi
9792 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9793 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9794
9795 fi
9796 if test $ac_cv_header_openssl_ssl_h = yes; then
9797   :
9798 else
9799   { { echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
9800 echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
9801    { (exit 1); exit 1; }; }
9802 fi
9803
9804
9805   if test "${ac_cv_header_openssl_err_h+set}" = set; then
9806   echo "$as_me:$LINENO: checking for openssl/err.h" >&5
9807 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
9808 if test "${ac_cv_header_openssl_err_h+set}" = set; then
9809   echo $ECHO_N "(cached) $ECHO_C" >&6
9810 fi
9811 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
9812 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
9813 else
9814   # Is the header compilable?
9815 echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
9816 echo $ECHO_N "checking openssl/err.h usability... $ECHO_C" >&6
9817 cat >conftest.$ac_ext <<_ACEOF
9818 /* confdefs.h.  */
9819 _ACEOF
9820 cat confdefs.h >>conftest.$ac_ext
9821 cat >>conftest.$ac_ext <<_ACEOF
9822 /* end confdefs.h.  */
9823 $ac_includes_default
9824 #include <openssl/err.h>
9825 _ACEOF
9826 rm -f conftest.$ac_objext
9827 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9828   (eval $ac_compile) 2>conftest.er1
9829   ac_status=$?
9830   grep -v '^ *+' conftest.er1 >conftest.err
9831   rm -f conftest.er1
9832   cat conftest.err >&5
9833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9834   (exit $ac_status); } &&
9835          { ac_try='test -z "$ac_c_werror_flag"
9836                          || test ! -s conftest.err'
9837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9838   (eval $ac_try) 2>&5
9839   ac_status=$?
9840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9841   (exit $ac_status); }; } &&
9842          { ac_try='test -s conftest.$ac_objext'
9843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9844   (eval $ac_try) 2>&5
9845   ac_status=$?
9846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9847   (exit $ac_status); }; }; then
9848   ac_header_compiler=yes
9849 else
9850   echo "$as_me: failed program was:" >&5
9851 sed 's/^/| /' conftest.$ac_ext >&5
9852
9853 ac_header_compiler=no
9854 fi
9855 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9856 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9857 echo "${ECHO_T}$ac_header_compiler" >&6
9858
9859 # Is the header present?
9860 echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
9861 echo $ECHO_N "checking openssl/err.h presence... $ECHO_C" >&6
9862 cat >conftest.$ac_ext <<_ACEOF
9863 /* confdefs.h.  */
9864 _ACEOF
9865 cat confdefs.h >>conftest.$ac_ext
9866 cat >>conftest.$ac_ext <<_ACEOF
9867 /* end confdefs.h.  */
9868 #include <openssl/err.h>
9869 _ACEOF
9870 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9871   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9872   ac_status=$?
9873   grep -v '^ *+' conftest.er1 >conftest.err
9874   rm -f conftest.er1
9875   cat conftest.err >&5
9876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9877   (exit $ac_status); } >/dev/null; then
9878   if test -s conftest.err; then
9879     ac_cpp_err=$ac_c_preproc_warn_flag
9880     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9881   else
9882     ac_cpp_err=
9883   fi
9884 else
9885   ac_cpp_err=yes
9886 fi
9887 if test -z "$ac_cpp_err"; then
9888   ac_header_preproc=yes
9889 else
9890   echo "$as_me: failed program was:" >&5
9891 sed 's/^/| /' conftest.$ac_ext >&5
9892
9893   ac_header_preproc=no
9894 fi
9895 rm -f conftest.err conftest.$ac_ext
9896 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9897 echo "${ECHO_T}$ac_header_preproc" >&6
9898
9899 # So?  What about this header?
9900 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9901   yes:no: )
9902     { echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
9903 echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9904     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
9905 echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
9906     ac_header_preproc=yes
9907     ;;
9908   no:yes:* )
9909     { echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
9910 echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
9911     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
9912 echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
9913     { echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
9914 echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
9915     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
9916 echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9917     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
9918 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
9919     { echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
9920 echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
9921     (
9922       cat <<\_ASBOX
9923 ## ---------------------------------------- ##
9924 ## Report this to pgsql-bugs@postgresql.org ##
9925 ## ---------------------------------------- ##
9926 _ASBOX
9927     ) |
9928       sed "s/^/$as_me: WARNING:     /" >&2
9929     ;;
9930 esac
9931 echo "$as_me:$LINENO: checking for openssl/err.h" >&5
9932 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
9933 if test "${ac_cv_header_openssl_err_h+set}" = set; then
9934   echo $ECHO_N "(cached) $ECHO_C" >&6
9935 else
9936   ac_cv_header_openssl_err_h=$ac_header_preproc
9937 fi
9938 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
9939 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
9940
9941 fi
9942 if test $ac_cv_header_openssl_err_h = yes; then
9943   :
9944 else
9945   { { echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
9946 echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
9947    { (exit 1); exit 1; }; }
9948 fi
9949
9950
9951 fi
9952
9953 if test "$with_pam" = yes ; then
9954
9955 for ac_header in security/pam_appl.h
9956 do
9957 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9958 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9959   echo "$as_me:$LINENO: checking for $ac_header" >&5
9960 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9961 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9962   echo $ECHO_N "(cached) $ECHO_C" >&6
9963 fi
9964 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9965 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9966 else
9967   # Is the header compilable?
9968 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9969 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9970 cat >conftest.$ac_ext <<_ACEOF
9971 /* confdefs.h.  */
9972 _ACEOF
9973 cat confdefs.h >>conftest.$ac_ext
9974 cat >>conftest.$ac_ext <<_ACEOF
9975 /* end confdefs.h.  */
9976 $ac_includes_default
9977 #include <$ac_header>
9978 _ACEOF
9979 rm -f conftest.$ac_objext
9980 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9981   (eval $ac_compile) 2>conftest.er1
9982   ac_status=$?
9983   grep -v '^ *+' conftest.er1 >conftest.err
9984   rm -f conftest.er1
9985   cat conftest.err >&5
9986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9987   (exit $ac_status); } &&
9988          { ac_try='test -z "$ac_c_werror_flag"
9989                          || test ! -s conftest.err'
9990   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9991   (eval $ac_try) 2>&5
9992   ac_status=$?
9993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9994   (exit $ac_status); }; } &&
9995          { ac_try='test -s conftest.$ac_objext'
9996   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9997   (eval $ac_try) 2>&5
9998   ac_status=$?
9999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10000   (exit $ac_status); }; }; then
10001   ac_header_compiler=yes
10002 else
10003   echo "$as_me: failed program was:" >&5
10004 sed 's/^/| /' conftest.$ac_ext >&5
10005
10006 ac_header_compiler=no
10007 fi
10008 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10009 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10010 echo "${ECHO_T}$ac_header_compiler" >&6
10011
10012 # Is the header present?
10013 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10014 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10015 cat >conftest.$ac_ext <<_ACEOF
10016 /* confdefs.h.  */
10017 _ACEOF
10018 cat confdefs.h >>conftest.$ac_ext
10019 cat >>conftest.$ac_ext <<_ACEOF
10020 /* end confdefs.h.  */
10021 #include <$ac_header>
10022 _ACEOF
10023 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10024   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10025   ac_status=$?
10026   grep -v '^ *+' conftest.er1 >conftest.err
10027   rm -f conftest.er1
10028   cat conftest.err >&5
10029   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10030   (exit $ac_status); } >/dev/null; then
10031   if test -s conftest.err; then
10032     ac_cpp_err=$ac_c_preproc_warn_flag
10033     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10034   else
10035     ac_cpp_err=
10036   fi
10037 else
10038   ac_cpp_err=yes
10039 fi
10040 if test -z "$ac_cpp_err"; then
10041   ac_header_preproc=yes
10042 else
10043   echo "$as_me: failed program was:" >&5
10044 sed 's/^/| /' conftest.$ac_ext >&5
10045
10046   ac_header_preproc=no
10047 fi
10048 rm -f conftest.err conftest.$ac_ext
10049 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10050 echo "${ECHO_T}$ac_header_preproc" >&6
10051
10052 # So?  What about this header?
10053 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10054   yes:no: )
10055     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10056 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10057     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10058 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10059     ac_header_preproc=yes
10060     ;;
10061   no:yes:* )
10062     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10063 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10064     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10065 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10066     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10067 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10068     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10069 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10070     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10071 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10072     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10073 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10074     (
10075       cat <<\_ASBOX
10076 ## ---------------------------------------- ##
10077 ## Report this to pgsql-bugs@postgresql.org ##
10078 ## ---------------------------------------- ##
10079 _ASBOX
10080     ) |
10081       sed "s/^/$as_me: WARNING:     /" >&2
10082     ;;
10083 esac
10084 echo "$as_me:$LINENO: checking for $ac_header" >&5
10085 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10086 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10087   echo $ECHO_N "(cached) $ECHO_C" >&6
10088 else
10089   eval "$as_ac_Header=\$ac_header_preproc"
10090 fi
10091 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10092 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10093
10094 fi
10095 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10096   cat >>confdefs.h <<_ACEOF
10097 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10098 _ACEOF
10099
10100 else
10101
10102 for ac_header in pam/pam_appl.h
10103 do
10104 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10105 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10106   echo "$as_me:$LINENO: checking for $ac_header" >&5
10107 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10108 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10109   echo $ECHO_N "(cached) $ECHO_C" >&6
10110 fi
10111 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10112 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10113 else
10114   # Is the header compilable?
10115 echo "$as_me:$LINENO: checking $ac_header usability" >&5
10116 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10117 cat >conftest.$ac_ext <<_ACEOF
10118 /* confdefs.h.  */
10119 _ACEOF
10120 cat confdefs.h >>conftest.$ac_ext
10121 cat >>conftest.$ac_ext <<_ACEOF
10122 /* end confdefs.h.  */
10123 $ac_includes_default
10124 #include <$ac_header>
10125 _ACEOF
10126 rm -f conftest.$ac_objext
10127 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10128   (eval $ac_compile) 2>conftest.er1
10129   ac_status=$?
10130   grep -v '^ *+' conftest.er1 >conftest.err
10131   rm -f conftest.er1
10132   cat conftest.err >&5
10133   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10134   (exit $ac_status); } &&
10135          { ac_try='test -z "$ac_c_werror_flag"
10136                          || test ! -s conftest.err'
10137   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10138   (eval $ac_try) 2>&5
10139   ac_status=$?
10140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10141   (exit $ac_status); }; } &&
10142          { ac_try='test -s conftest.$ac_objext'
10143   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10144   (eval $ac_try) 2>&5
10145   ac_status=$?
10146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10147   (exit $ac_status); }; }; then
10148   ac_header_compiler=yes
10149 else
10150   echo "$as_me: failed program was:" >&5
10151 sed 's/^/| /' conftest.$ac_ext >&5
10152
10153 ac_header_compiler=no
10154 fi
10155 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10156 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10157 echo "${ECHO_T}$ac_header_compiler" >&6
10158
10159 # Is the header present?
10160 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10161 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10162 cat >conftest.$ac_ext <<_ACEOF
10163 /* confdefs.h.  */
10164 _ACEOF
10165 cat confdefs.h >>conftest.$ac_ext
10166 cat >>conftest.$ac_ext <<_ACEOF
10167 /* end confdefs.h.  */
10168 #include <$ac_header>
10169 _ACEOF
10170 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10171   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10172   ac_status=$?
10173   grep -v '^ *+' conftest.er1 >conftest.err
10174   rm -f conftest.er1
10175   cat conftest.err >&5
10176   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10177   (exit $ac_status); } >/dev/null; then
10178   if test -s conftest.err; then
10179     ac_cpp_err=$ac_c_preproc_warn_flag
10180     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10181   else
10182     ac_cpp_err=
10183   fi
10184 else
10185   ac_cpp_err=yes
10186 fi
10187 if test -z "$ac_cpp_err"; then
10188   ac_header_preproc=yes
10189 else
10190   echo "$as_me: failed program was:" >&5
10191 sed 's/^/| /' conftest.$ac_ext >&5
10192
10193   ac_header_preproc=no
10194 fi
10195 rm -f conftest.err conftest.$ac_ext
10196 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10197 echo "${ECHO_T}$ac_header_preproc" >&6
10198
10199 # So?  What about this header?
10200 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10201   yes:no: )
10202     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10203 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10204     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10205 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10206     ac_header_preproc=yes
10207     ;;
10208   no:yes:* )
10209     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10210 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10211     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10212 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10213     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10214 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10215     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10216 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10217     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10218 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10219     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10220 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10221     (
10222       cat <<\_ASBOX
10223 ## ---------------------------------------- ##
10224 ## Report this to pgsql-bugs@postgresql.org ##
10225 ## ---------------------------------------- ##
10226 _ASBOX
10227     ) |
10228       sed "s/^/$as_me: WARNING:     /" >&2
10229     ;;
10230 esac
10231 echo "$as_me:$LINENO: checking for $ac_header" >&5
10232 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10233 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10234   echo $ECHO_N "(cached) $ECHO_C" >&6
10235 else
10236   eval "$as_ac_Header=\$ac_header_preproc"
10237 fi
10238 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10239 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10240
10241 fi
10242 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10243   cat >>confdefs.h <<_ACEOF
10244 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10245 _ACEOF
10246
10247 else
10248   { { echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
10249 echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
10250    { (exit 1); exit 1; }; }
10251 fi
10252
10253 done
10254
10255 fi
10256
10257 done
10258
10259 fi
10260
10261 if test "$with_bonjour" = yes ; then
10262   if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10263   echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
10264 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
10265 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10266   echo $ECHO_N "(cached) $ECHO_C" >&6
10267 fi
10268 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
10269 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
10270 else
10271   # Is the header compilable?
10272 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h usability" >&5
10273 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h usability... $ECHO_C" >&6
10274 cat >conftest.$ac_ext <<_ACEOF
10275 /* confdefs.h.  */
10276 _ACEOF
10277 cat confdefs.h >>conftest.$ac_ext
10278 cat >>conftest.$ac_ext <<_ACEOF
10279 /* end confdefs.h.  */
10280 $ac_includes_default
10281 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
10282 _ACEOF
10283 rm -f conftest.$ac_objext
10284 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10285   (eval $ac_compile) 2>conftest.er1
10286   ac_status=$?
10287   grep -v '^ *+' conftest.er1 >conftest.err
10288   rm -f conftest.er1
10289   cat conftest.err >&5
10290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10291   (exit $ac_status); } &&
10292          { ac_try='test -z "$ac_c_werror_flag"
10293                          || test ! -s conftest.err'
10294   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10295   (eval $ac_try) 2>&5
10296   ac_status=$?
10297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10298   (exit $ac_status); }; } &&
10299          { ac_try='test -s conftest.$ac_objext'
10300   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10301   (eval $ac_try) 2>&5
10302   ac_status=$?
10303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10304   (exit $ac_status); }; }; then
10305   ac_header_compiler=yes
10306 else
10307   echo "$as_me: failed program was:" >&5
10308 sed 's/^/| /' conftest.$ac_ext >&5
10309
10310 ac_header_compiler=no
10311 fi
10312 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10313 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10314 echo "${ECHO_T}$ac_header_compiler" >&6
10315
10316 # Is the header present?
10317 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h presence" >&5
10318 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h presence... $ECHO_C" >&6
10319 cat >conftest.$ac_ext <<_ACEOF
10320 /* confdefs.h.  */
10321 _ACEOF
10322 cat confdefs.h >>conftest.$ac_ext
10323 cat >>conftest.$ac_ext <<_ACEOF
10324 /* end confdefs.h.  */
10325 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
10326 _ACEOF
10327 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10328   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10329   ac_status=$?
10330   grep -v '^ *+' conftest.er1 >conftest.err
10331   rm -f conftest.er1
10332   cat conftest.err >&5
10333   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10334   (exit $ac_status); } >/dev/null; then
10335   if test -s conftest.err; then
10336     ac_cpp_err=$ac_c_preproc_warn_flag
10337     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10338   else
10339     ac_cpp_err=
10340   fi
10341 else
10342   ac_cpp_err=yes
10343 fi
10344 if test -z "$ac_cpp_err"; then
10345   ac_header_preproc=yes
10346 else
10347   echo "$as_me: failed program was:" >&5
10348 sed 's/^/| /' conftest.$ac_ext >&5
10349
10350   ac_header_preproc=no
10351 fi
10352 rm -f conftest.err conftest.$ac_ext
10353 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10354 echo "${ECHO_T}$ac_header_preproc" >&6
10355
10356 # So?  What about this header?
10357 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10358   yes:no: )
10359     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&5
10360 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10361     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&5
10362 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&2;}
10363     ac_header_preproc=yes
10364     ;;
10365   no:yes:* )
10366     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&5
10367 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&2;}
10368     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&5
10369 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&2;}
10370     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&5
10371 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&2;}
10372     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&5
10373 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10374     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
10375 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;}
10376     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&5
10377 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&2;}
10378     (
10379       cat <<\_ASBOX
10380 ## ---------------------------------------- ##
10381 ## Report this to pgsql-bugs@postgresql.org ##
10382 ## ---------------------------------------- ##
10383 _ASBOX
10384     ) |
10385       sed "s/^/$as_me: WARNING:     /" >&2
10386     ;;
10387 esac
10388 echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
10389 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
10390 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10391   echo $ECHO_N "(cached) $ECHO_C" >&6
10392 else
10393   ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h=$ac_header_preproc
10394 fi
10395 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
10396 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
10397
10398 fi
10399 if test $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h = yes; then
10400   :
10401 else
10402   { { echo "$as_me:$LINENO: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&5
10403 echo "$as_me: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&2;}
10404    { (exit 1); exit 1; }; }
10405 fi
10406
10407
10408 fi
10409
10410
10411 ##
10412 ## Types, structures, compiler characteristics
10413 ##
10414
10415  echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
10416 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
10417 if test "${ac_cv_c_const+set}" = set; then
10418   echo $ECHO_N "(cached) $ECHO_C" >&6
10419 else
10420   cat >conftest.$ac_ext <<_ACEOF
10421 /* confdefs.h.  */
10422 _ACEOF
10423 cat confdefs.h >>conftest.$ac_ext
10424 cat >>conftest.$ac_ext <<_ACEOF
10425 /* end confdefs.h.  */
10426
10427 int
10428 main ()
10429 {
10430 /* FIXME: Include the comments suggested by Paul. */
10431 #ifndef __cplusplus
10432   /* Ultrix mips cc rejects this.  */
10433   typedef int charset[2];
10434   const charset x;
10435   /* SunOS 4.1.1 cc rejects this.  */
10436   char const *const *ccp;
10437   char **p;
10438   /* NEC SVR4.0.2 mips cc rejects this.  */
10439   struct point {int x, y;};
10440   static struct point const zero = {0,0};
10441   /* AIX XL C 1.02.0.0 rejects this.
10442      It does not let you subtract one const X* pointer from another in
10443      an arm of an if-expression whose if-part is not a constant
10444      expression */
10445   const char *g = "string";
10446   ccp = &g + (g ? g-g : 0);
10447   /* HPUX 7.0 cc rejects these. */
10448   ++ccp;
10449   p = (char**) ccp;
10450   ccp = (char const *const *) p;
10451   { /* SCO 3.2v4 cc rejects this.  */
10452     char *t;
10453     char const *s = 0 ? (char *) 0 : (char const *) 0;
10454
10455     *t++ = 0;
10456   }
10457   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
10458     int x[] = {25, 17};
10459     const int *foo = &x[0];
10460     ++foo;
10461   }
10462   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
10463     typedef const int *iptr;
10464     iptr p = 0;
10465     ++p;
10466   }
10467   { /* AIX XL C 1.02.0.0 rejects this saying
10468        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
10469     struct s { int j; const int *ap[3]; };
10470     struct s *b; b->j = 5;
10471   }
10472   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
10473     const int foo = 10;
10474   }
10475 #endif
10476
10477   ;
10478   return 0;
10479 }
10480 _ACEOF
10481 rm -f conftest.$ac_objext
10482 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10483   (eval $ac_compile) 2>conftest.er1
10484   ac_status=$?
10485   grep -v '^ *+' conftest.er1 >conftest.err
10486   rm -f conftest.er1
10487   cat conftest.err >&5
10488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10489   (exit $ac_status); } &&
10490          { ac_try='test -z "$ac_c_werror_flag"
10491                          || test ! -s conftest.err'
10492   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10493   (eval $ac_try) 2>&5
10494   ac_status=$?
10495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10496   (exit $ac_status); }; } &&
10497          { ac_try='test -s conftest.$ac_objext'
10498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10499   (eval $ac_try) 2>&5
10500   ac_status=$?
10501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10502   (exit $ac_status); }; }; then
10503   ac_cv_c_const=yes
10504 else
10505   echo "$as_me: failed program was:" >&5
10506 sed 's/^/| /' conftest.$ac_ext >&5
10507
10508 ac_cv_c_const=no
10509 fi
10510 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10511 fi
10512 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
10513 echo "${ECHO_T}$ac_cv_c_const" >&6
10514 if test $ac_cv_c_const = no; then
10515
10516 cat >>confdefs.h <<\_ACEOF
10517 #define const
10518 _ACEOF
10519
10520 fi
10521
10522
10523 echo "$as_me:$LINENO: checking for inline" >&5
10524 echo $ECHO_N "checking for inline... $ECHO_C" >&6
10525 if test "${ac_cv_c_inline+set}" = set; then
10526   echo $ECHO_N "(cached) $ECHO_C" >&6
10527 else
10528   ac_cv_c_inline=no
10529 for ac_kw in inline __inline__ __inline; do
10530   cat >conftest.$ac_ext <<_ACEOF
10531 /* confdefs.h.  */
10532 _ACEOF
10533 cat confdefs.h >>conftest.$ac_ext
10534 cat >>conftest.$ac_ext <<_ACEOF
10535 /* end confdefs.h.  */
10536 #ifndef __cplusplus
10537 typedef int foo_t;
10538 static $ac_kw foo_t static_foo () {return 0; }
10539 $ac_kw int foo () {return 0; }
10540 #endif
10541
10542 _ACEOF
10543 rm -f conftest.$ac_objext
10544 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10545   (eval $ac_compile) 2>conftest.er1
10546   ac_status=$?
10547   grep -v '^ *+' conftest.er1 >conftest.err
10548   rm -f conftest.er1
10549   cat conftest.err >&5
10550   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10551   (exit $ac_status); } &&
10552          { ac_try='test -z "$ac_c_werror_flag"
10553                          || test ! -s conftest.err'
10554   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10555   (eval $ac_try) 2>&5
10556   ac_status=$?
10557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10558   (exit $ac_status); }; } &&
10559          { ac_try='test -s conftest.$ac_objext'
10560   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10561   (eval $ac_try) 2>&5
10562   ac_status=$?
10563   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10564   (exit $ac_status); }; }; then
10565   ac_cv_c_inline=$ac_kw; break
10566 else
10567   echo "$as_me: failed program was:" >&5
10568 sed 's/^/| /' conftest.$ac_ext >&5
10569
10570 fi
10571 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10572 done
10573
10574 fi
10575 echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
10576 echo "${ECHO_T}$ac_cv_c_inline" >&6
10577 case $ac_cv_c_inline in
10578   inline | yes) ;;
10579   no)
10580 cat >>confdefs.h <<\_ACEOF
10581 #define inline
10582 _ACEOF
10583  ;;
10584   *)  cat >>confdefs.h <<_ACEOF
10585 #define inline $ac_cv_c_inline
10586 _ACEOF
10587  ;;
10588 esac
10589
10590 echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
10591 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6
10592 if test "${ac_cv_c_stringize+set}" = set; then
10593   echo $ECHO_N "(cached) $ECHO_C" >&6
10594 else
10595   cat >conftest.$ac_ext <<_ACEOF
10596 /* confdefs.h.  */
10597 _ACEOF
10598 cat confdefs.h >>conftest.$ac_ext
10599 cat >>conftest.$ac_ext <<_ACEOF
10600 /* end confdefs.h.  */
10601 #define x(y) #y
10602
10603 char *s = x(teststring);
10604 _ACEOF
10605 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10606   $EGREP "#teststring" >/dev/null 2>&1; then
10607   ac_cv_c_stringize=no
10608 else
10609   ac_cv_c_stringize=yes
10610 fi
10611 rm -f conftest*
10612
10613 fi
10614 echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
10615 echo "${ECHO_T}$ac_cv_c_stringize" >&6
10616 if test $ac_cv_c_stringize = yes; then
10617
10618 cat >>confdefs.h <<\_ACEOF
10619 #define HAVE_STRINGIZE 1
10620 _ACEOF
10621
10622 fi
10623
10624 echo "$as_me:$LINENO: checking for signed types" >&5
10625 echo $ECHO_N "checking for signed types... $ECHO_C" >&6
10626 if test "${pgac_cv_c_signed+set}" = set; then
10627   echo $ECHO_N "(cached) $ECHO_C" >&6
10628 else
10629   cat >conftest.$ac_ext <<_ACEOF
10630 /* confdefs.h.  */
10631 _ACEOF
10632 cat confdefs.h >>conftest.$ac_ext
10633 cat >>conftest.$ac_ext <<_ACEOF
10634 /* end confdefs.h.  */
10635
10636 int
10637 main ()
10638 {
10639 signed char c; signed short s; signed int i;
10640   ;
10641   return 0;
10642 }
10643 _ACEOF
10644 rm -f conftest.$ac_objext
10645 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10646   (eval $ac_compile) 2>conftest.er1
10647   ac_status=$?
10648   grep -v '^ *+' conftest.er1 >conftest.err
10649   rm -f conftest.er1
10650   cat conftest.err >&5
10651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10652   (exit $ac_status); } &&
10653          { ac_try='test -z "$ac_c_werror_flag"
10654                          || test ! -s conftest.err'
10655   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10656   (eval $ac_try) 2>&5
10657   ac_status=$?
10658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10659   (exit $ac_status); }; } &&
10660          { ac_try='test -s conftest.$ac_objext'
10661   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10662   (eval $ac_try) 2>&5
10663   ac_status=$?
10664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10665   (exit $ac_status); }; }; then
10666   pgac_cv_c_signed=yes
10667 else
10668   echo "$as_me: failed program was:" >&5
10669 sed 's/^/| /' conftest.$ac_ext >&5
10670
10671 pgac_cv_c_signed=no
10672 fi
10673 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10674 fi
10675 echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
10676 echo "${ECHO_T}$pgac_cv_c_signed" >&6
10677 if test x"$pgac_cv_c_signed" = xno ; then
10678
10679 cat >>confdefs.h <<\_ACEOF
10680 #define signed
10681 _ACEOF
10682
10683 fi
10684 echo "$as_me:$LINENO: checking for working volatile" >&5
10685 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
10686 if test "${ac_cv_c_volatile+set}" = set; then
10687   echo $ECHO_N "(cached) $ECHO_C" >&6
10688 else
10689   cat >conftest.$ac_ext <<_ACEOF
10690 /* confdefs.h.  */
10691 _ACEOF
10692 cat confdefs.h >>conftest.$ac_ext
10693 cat >>conftest.$ac_ext <<_ACEOF
10694 /* end confdefs.h.  */
10695
10696 int
10697 main ()
10698 {
10699
10700 volatile int x;
10701 int * volatile y;
10702   ;
10703   return 0;
10704 }
10705 _ACEOF
10706 rm -f conftest.$ac_objext
10707 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10708   (eval $ac_compile) 2>conftest.er1
10709   ac_status=$?
10710   grep -v '^ *+' conftest.er1 >conftest.err
10711   rm -f conftest.er1
10712   cat conftest.err >&5
10713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10714   (exit $ac_status); } &&
10715          { ac_try='test -z "$ac_c_werror_flag"
10716                          || test ! -s conftest.err'
10717   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10718   (eval $ac_try) 2>&5
10719   ac_status=$?
10720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10721   (exit $ac_status); }; } &&
10722          { ac_try='test -s conftest.$ac_objext'
10723   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10724   (eval $ac_try) 2>&5
10725   ac_status=$?
10726   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10727   (exit $ac_status); }; }; then
10728   ac_cv_c_volatile=yes
10729 else
10730   echo "$as_me: failed program was:" >&5
10731 sed 's/^/| /' conftest.$ac_ext >&5
10732
10733 ac_cv_c_volatile=no
10734 fi
10735 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10736 fi
10737 echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
10738 echo "${ECHO_T}$ac_cv_c_volatile" >&6
10739 if test $ac_cv_c_volatile = no; then
10740
10741 cat >>confdefs.h <<\_ACEOF
10742 #define volatile
10743 _ACEOF
10744
10745 fi
10746
10747 echo "$as_me:$LINENO: checking for __func__" >&5
10748 echo $ECHO_N "checking for __func__... $ECHO_C" >&6
10749 if test "${pgac_cv_funcname_func_support+set}" = set; then
10750   echo $ECHO_N "(cached) $ECHO_C" >&6
10751 else
10752   cat >conftest.$ac_ext <<_ACEOF
10753 /* confdefs.h.  */
10754 _ACEOF
10755 cat confdefs.h >>conftest.$ac_ext
10756 cat >>conftest.$ac_ext <<_ACEOF
10757 /* end confdefs.h.  */
10758 #include <stdio.h>
10759 int
10760 main ()
10761 {
10762 printf("%s\n", __func__);
10763   ;
10764   return 0;
10765 }
10766 _ACEOF
10767 rm -f conftest.$ac_objext
10768 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10769   (eval $ac_compile) 2>conftest.er1
10770   ac_status=$?
10771   grep -v '^ *+' conftest.er1 >conftest.err
10772   rm -f conftest.er1
10773   cat conftest.err >&5
10774   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10775   (exit $ac_status); } &&
10776          { ac_try='test -z "$ac_c_werror_flag"
10777                          || test ! -s conftest.err'
10778   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10779   (eval $ac_try) 2>&5
10780   ac_status=$?
10781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10782   (exit $ac_status); }; } &&
10783          { ac_try='test -s conftest.$ac_objext'
10784   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10785   (eval $ac_try) 2>&5
10786   ac_status=$?
10787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10788   (exit $ac_status); }; }; then
10789   pgac_cv_funcname_func_support=yes
10790 else
10791   echo "$as_me: failed program was:" >&5
10792 sed 's/^/| /' conftest.$ac_ext >&5
10793
10794 pgac_cv_funcname_func_support=no
10795 fi
10796 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10797 fi
10798 echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
10799 echo "${ECHO_T}$pgac_cv_funcname_func_support" >&6
10800 if test x"$pgac_cv_funcname_func_support" = xyes ; then
10801
10802 cat >>confdefs.h <<\_ACEOF
10803 #define HAVE_FUNCNAME__FUNC 1
10804 _ACEOF
10805
10806 else
10807 echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
10808 echo $ECHO_N "checking for __FUNCTION__... $ECHO_C" >&6
10809 if test "${pgac_cv_funcname_function_support+set}" = set; then
10810   echo $ECHO_N "(cached) $ECHO_C" >&6
10811 else
10812   cat >conftest.$ac_ext <<_ACEOF
10813 /* confdefs.h.  */
10814 _ACEOF
10815 cat confdefs.h >>conftest.$ac_ext
10816 cat >>conftest.$ac_ext <<_ACEOF
10817 /* end confdefs.h.  */
10818 #include <stdio.h>
10819 int
10820 main ()
10821 {
10822 printf("%s\n", __FUNCTION__);
10823   ;
10824   return 0;
10825 }
10826 _ACEOF
10827 rm -f conftest.$ac_objext
10828 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10829   (eval $ac_compile) 2>conftest.er1
10830   ac_status=$?
10831   grep -v '^ *+' conftest.er1 >conftest.err
10832   rm -f conftest.er1
10833   cat conftest.err >&5
10834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10835   (exit $ac_status); } &&
10836          { ac_try='test -z "$ac_c_werror_flag"
10837                          || test ! -s conftest.err'
10838   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10839   (eval $ac_try) 2>&5
10840   ac_status=$?
10841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10842   (exit $ac_status); }; } &&
10843          { ac_try='test -s conftest.$ac_objext'
10844   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10845   (eval $ac_try) 2>&5
10846   ac_status=$?
10847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10848   (exit $ac_status); }; }; then
10849   pgac_cv_funcname_function_support=yes
10850 else
10851   echo "$as_me: failed program was:" >&5
10852 sed 's/^/| /' conftest.$ac_ext >&5
10853
10854 pgac_cv_funcname_function_support=no
10855 fi
10856 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10857 fi
10858 echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
10859 echo "${ECHO_T}$pgac_cv_funcname_function_support" >&6
10860 if test x"$pgac_cv_funcname_function_support" = xyes ; then
10861
10862 cat >>confdefs.h <<\_ACEOF
10863 #define HAVE_FUNCNAME__FUNCTION 1
10864 _ACEOF
10865
10866 fi
10867 fi
10868 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
10869 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
10870 if test "${ac_cv_struct_tm+set}" = set; then
10871   echo $ECHO_N "(cached) $ECHO_C" >&6
10872 else
10873   cat >conftest.$ac_ext <<_ACEOF
10874 /* confdefs.h.  */
10875 _ACEOF
10876 cat confdefs.h >>conftest.$ac_ext
10877 cat >>conftest.$ac_ext <<_ACEOF
10878 /* end confdefs.h.  */
10879 #include <sys/types.h>
10880 #include <time.h>
10881
10882 int
10883 main ()
10884 {
10885 struct tm *tp; tp->tm_sec;
10886   ;
10887   return 0;
10888 }
10889 _ACEOF
10890 rm -f conftest.$ac_objext
10891 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10892   (eval $ac_compile) 2>conftest.er1
10893   ac_status=$?
10894   grep -v '^ *+' conftest.er1 >conftest.err
10895   rm -f conftest.er1
10896   cat conftest.err >&5
10897   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10898   (exit $ac_status); } &&
10899          { ac_try='test -z "$ac_c_werror_flag"
10900                          || test ! -s conftest.err'
10901   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10902   (eval $ac_try) 2>&5
10903   ac_status=$?
10904   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10905   (exit $ac_status); }; } &&
10906          { ac_try='test -s conftest.$ac_objext'
10907   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10908   (eval $ac_try) 2>&5
10909   ac_status=$?
10910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10911   (exit $ac_status); }; }; then
10912   ac_cv_struct_tm=time.h
10913 else
10914   echo "$as_me: failed program was:" >&5
10915 sed 's/^/| /' conftest.$ac_ext >&5
10916
10917 ac_cv_struct_tm=sys/time.h
10918 fi
10919 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10920 fi
10921 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
10922 echo "${ECHO_T}$ac_cv_struct_tm" >&6
10923 if test $ac_cv_struct_tm = sys/time.h; then
10924
10925 cat >>confdefs.h <<\_ACEOF
10926 #define TM_IN_SYS_TIME 1
10927 _ACEOF
10928
10929 fi
10930
10931 echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
10932 echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
10933 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
10934   echo $ECHO_N "(cached) $ECHO_C" >&6
10935 else
10936   cat >conftest.$ac_ext <<_ACEOF
10937 /* confdefs.h.  */
10938 _ACEOF
10939 cat confdefs.h >>conftest.$ac_ext
10940 cat >>conftest.$ac_ext <<_ACEOF
10941 /* end confdefs.h.  */
10942 #include <sys/types.h>
10943 #include <$ac_cv_struct_tm>
10944
10945
10946 int
10947 main ()
10948 {
10949 static struct tm ac_aggr;
10950 if (ac_aggr.tm_zone)
10951 return 0;
10952   ;
10953   return 0;
10954 }
10955 _ACEOF
10956 rm -f conftest.$ac_objext
10957 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10958   (eval $ac_compile) 2>conftest.er1
10959   ac_status=$?
10960   grep -v '^ *+' conftest.er1 >conftest.err
10961   rm -f conftest.er1
10962   cat conftest.err >&5
10963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10964   (exit $ac_status); } &&
10965          { ac_try='test -z "$ac_c_werror_flag"
10966                          || test ! -s conftest.err'
10967   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10968   (eval $ac_try) 2>&5
10969   ac_status=$?
10970   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10971   (exit $ac_status); }; } &&
10972          { ac_try='test -s conftest.$ac_objext'
10973   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10974   (eval $ac_try) 2>&5
10975   ac_status=$?
10976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10977   (exit $ac_status); }; }; then
10978   ac_cv_member_struct_tm_tm_zone=yes
10979 else
10980   echo "$as_me: failed program was:" >&5
10981 sed 's/^/| /' conftest.$ac_ext >&5
10982
10983 cat >conftest.$ac_ext <<_ACEOF
10984 /* confdefs.h.  */
10985 _ACEOF
10986 cat confdefs.h >>conftest.$ac_ext
10987 cat >>conftest.$ac_ext <<_ACEOF
10988 /* end confdefs.h.  */
10989 #include <sys/types.h>
10990 #include <$ac_cv_struct_tm>
10991
10992
10993 int
10994 main ()
10995 {
10996 static struct tm ac_aggr;
10997 if (sizeof ac_aggr.tm_zone)
10998 return 0;
10999   ;
11000   return 0;
11001 }
11002 _ACEOF
11003 rm -f conftest.$ac_objext
11004 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11005   (eval $ac_compile) 2>conftest.er1
11006   ac_status=$?
11007   grep -v '^ *+' conftest.er1 >conftest.err
11008   rm -f conftest.er1
11009   cat conftest.err >&5
11010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11011   (exit $ac_status); } &&
11012          { ac_try='test -z "$ac_c_werror_flag"
11013                          || test ! -s conftest.err'
11014   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11015   (eval $ac_try) 2>&5
11016   ac_status=$?
11017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11018   (exit $ac_status); }; } &&
11019          { ac_try='test -s conftest.$ac_objext'
11020   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11021   (eval $ac_try) 2>&5
11022   ac_status=$?
11023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11024   (exit $ac_status); }; }; then
11025   ac_cv_member_struct_tm_tm_zone=yes
11026 else
11027   echo "$as_me: failed program was:" >&5
11028 sed 's/^/| /' conftest.$ac_ext >&5
11029
11030 ac_cv_member_struct_tm_tm_zone=no
11031 fi
11032 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11033 fi
11034 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11035 fi
11036 echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
11037 echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
11038 if test $ac_cv_member_struct_tm_tm_zone = yes; then
11039
11040 cat >>confdefs.h <<_ACEOF
11041 #define HAVE_STRUCT_TM_TM_ZONE 1
11042 _ACEOF
11043
11044
11045 fi
11046
11047 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
11048
11049 cat >>confdefs.h <<\_ACEOF
11050 #define HAVE_TM_ZONE 1
11051 _ACEOF
11052
11053 fi
11054 echo "$as_me:$LINENO: checking for tzname" >&5
11055 echo $ECHO_N "checking for tzname... $ECHO_C" >&6
11056 if test "${ac_cv_var_tzname+set}" = set; then
11057   echo $ECHO_N "(cached) $ECHO_C" >&6
11058 else
11059   cat >conftest.$ac_ext <<_ACEOF
11060 /* confdefs.h.  */
11061 _ACEOF
11062 cat confdefs.h >>conftest.$ac_ext
11063 cat >>conftest.$ac_ext <<_ACEOF
11064 /* end confdefs.h.  */
11065 #include <time.h>
11066 #ifndef tzname /* For SGI.  */
11067 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
11068 #endif
11069
11070 int
11071 main ()
11072 {
11073 atoi(*tzname);
11074   ;
11075   return 0;
11076 }
11077 _ACEOF
11078 rm -f conftest.$ac_objext conftest$ac_exeext
11079 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11080   (eval $ac_link) 2>conftest.er1
11081   ac_status=$?
11082   grep -v '^ *+' conftest.er1 >conftest.err
11083   rm -f conftest.er1
11084   cat conftest.err >&5
11085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11086   (exit $ac_status); } &&
11087          { ac_try='test -z "$ac_c_werror_flag"
11088                          || test ! -s conftest.err'
11089   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11090   (eval $ac_try) 2>&5
11091   ac_status=$?
11092   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11093   (exit $ac_status); }; } &&
11094          { ac_try='test -s conftest$ac_exeext'
11095   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11096   (eval $ac_try) 2>&5
11097   ac_status=$?
11098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11099   (exit $ac_status); }; }; then
11100   ac_cv_var_tzname=yes
11101 else
11102   echo "$as_me: failed program was:" >&5
11103 sed 's/^/| /' conftest.$ac_ext >&5
11104
11105 ac_cv_var_tzname=no
11106 fi
11107 rm -f conftest.err conftest.$ac_objext \
11108       conftest$ac_exeext conftest.$ac_ext
11109 fi
11110 echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
11111 echo "${ECHO_T}$ac_cv_var_tzname" >&6
11112 if test $ac_cv_var_tzname = yes; then
11113
11114 cat >>confdefs.h <<\_ACEOF
11115 #define HAVE_TZNAME 1
11116 _ACEOF
11117
11118 fi
11119
11120 echo "$as_me:$LINENO: checking for union semun" >&5
11121 echo $ECHO_N "checking for union semun... $ECHO_C" >&6
11122 if test "${ac_cv_type_union_semun+set}" = set; then
11123   echo $ECHO_N "(cached) $ECHO_C" >&6
11124 else
11125   cat >conftest.$ac_ext <<_ACEOF
11126 /* confdefs.h.  */
11127 _ACEOF
11128 cat confdefs.h >>conftest.$ac_ext
11129 cat >>conftest.$ac_ext <<_ACEOF
11130 /* end confdefs.h.  */
11131 #include <sys/types.h>
11132 #include <sys/ipc.h>
11133 #include <sys/sem.h>
11134
11135 int
11136 main ()
11137 {
11138 if ((union semun *) 0)
11139   return 0;
11140 if (sizeof (union semun))
11141   return 0;
11142   ;
11143   return 0;
11144 }
11145 _ACEOF
11146 rm -f conftest.$ac_objext
11147 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11148   (eval $ac_compile) 2>conftest.er1
11149   ac_status=$?
11150   grep -v '^ *+' conftest.er1 >conftest.err
11151   rm -f conftest.er1
11152   cat conftest.err >&5
11153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11154   (exit $ac_status); } &&
11155          { ac_try='test -z "$ac_c_werror_flag"
11156                          || test ! -s conftest.err'
11157   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11158   (eval $ac_try) 2>&5
11159   ac_status=$?
11160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11161   (exit $ac_status); }; } &&
11162          { ac_try='test -s conftest.$ac_objext'
11163   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11164   (eval $ac_try) 2>&5
11165   ac_status=$?
11166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11167   (exit $ac_status); }; }; then
11168   ac_cv_type_union_semun=yes
11169 else
11170   echo "$as_me: failed program was:" >&5
11171 sed 's/^/| /' conftest.$ac_ext >&5
11172
11173 ac_cv_type_union_semun=no
11174 fi
11175 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11176 fi
11177 echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
11178 echo "${ECHO_T}$ac_cv_type_union_semun" >&6
11179 if test $ac_cv_type_union_semun = yes; then
11180
11181 cat >>confdefs.h <<_ACEOF
11182 #define HAVE_UNION_SEMUN 1
11183 _ACEOF
11184
11185
11186 fi
11187
11188 echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
11189 echo $ECHO_N "checking for struct sockaddr_un... $ECHO_C" >&6
11190 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
11191   echo $ECHO_N "(cached) $ECHO_C" >&6
11192 else
11193   cat >conftest.$ac_ext <<_ACEOF
11194 /* confdefs.h.  */
11195 _ACEOF
11196 cat confdefs.h >>conftest.$ac_ext
11197 cat >>conftest.$ac_ext <<_ACEOF
11198 /* end confdefs.h.  */
11199 #include <sys/types.h>
11200 #ifdef HAVE_SYS_UN_H
11201 #include <sys/un.h>
11202 #endif
11203
11204
11205 int
11206 main ()
11207 {
11208 if ((struct sockaddr_un *) 0)
11209   return 0;
11210 if (sizeof (struct sockaddr_un))
11211   return 0;
11212   ;
11213   return 0;
11214 }
11215 _ACEOF
11216 rm -f conftest.$ac_objext
11217 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11218   (eval $ac_compile) 2>conftest.er1
11219   ac_status=$?
11220   grep -v '^ *+' conftest.er1 >conftest.err
11221   rm -f conftest.er1
11222   cat conftest.err >&5
11223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11224   (exit $ac_status); } &&
11225          { ac_try='test -z "$ac_c_werror_flag"
11226                          || test ! -s conftest.err'
11227   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11228   (eval $ac_try) 2>&5
11229   ac_status=$?
11230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11231   (exit $ac_status); }; } &&
11232          { ac_try='test -s conftest.$ac_objext'
11233   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11234   (eval $ac_try) 2>&5
11235   ac_status=$?
11236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11237   (exit $ac_status); }; }; then
11238   ac_cv_type_struct_sockaddr_un=yes
11239 else
11240   echo "$as_me: failed program was:" >&5
11241 sed 's/^/| /' conftest.$ac_ext >&5
11242
11243 ac_cv_type_struct_sockaddr_un=no
11244 fi
11245 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11246 fi
11247 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
11248 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_un" >&6
11249 if test $ac_cv_type_struct_sockaddr_un = yes; then
11250
11251 cat >>confdefs.h <<_ACEOF
11252 #define HAVE_STRUCT_SOCKADDR_UN 1
11253 _ACEOF
11254
11255
11256 cat >>confdefs.h <<\_ACEOF
11257 #define HAVE_UNIX_SOCKETS 1
11258 _ACEOF
11259
11260 fi
11261
11262 echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
11263 echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6
11264 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
11265   echo $ECHO_N "(cached) $ECHO_C" >&6
11266 else
11267   cat >conftest.$ac_ext <<_ACEOF
11268 /* confdefs.h.  */
11269 _ACEOF
11270 cat confdefs.h >>conftest.$ac_ext
11271 cat >>conftest.$ac_ext <<_ACEOF
11272 /* end confdefs.h.  */
11273 #include <sys/types.h>
11274 #ifdef HAVE_SYS_SOCKET_H
11275 #include <sys/socket.h>
11276 #endif
11277
11278
11279 int
11280 main ()
11281 {
11282 if ((struct sockaddr_storage *) 0)
11283   return 0;
11284 if (sizeof (struct sockaddr_storage))
11285   return 0;
11286   ;
11287   return 0;
11288 }
11289 _ACEOF
11290 rm -f conftest.$ac_objext
11291 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11292   (eval $ac_compile) 2>conftest.er1
11293   ac_status=$?
11294   grep -v '^ *+' conftest.er1 >conftest.err
11295   rm -f conftest.er1
11296   cat conftest.err >&5
11297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11298   (exit $ac_status); } &&
11299          { ac_try='test -z "$ac_c_werror_flag"
11300                          || test ! -s conftest.err'
11301   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11302   (eval $ac_try) 2>&5
11303   ac_status=$?
11304   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11305   (exit $ac_status); }; } &&
11306          { ac_try='test -s conftest.$ac_objext'
11307   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11308   (eval $ac_try) 2>&5
11309   ac_status=$?
11310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11311   (exit $ac_status); }; }; then
11312   ac_cv_type_struct_sockaddr_storage=yes
11313 else
11314   echo "$as_me: failed program was:" >&5
11315 sed 's/^/| /' conftest.$ac_ext >&5
11316
11317 ac_cv_type_struct_sockaddr_storage=no
11318 fi
11319 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11320 fi
11321 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
11322 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_storage" >&6
11323 if test $ac_cv_type_struct_sockaddr_storage = yes; then
11324
11325 cat >>confdefs.h <<_ACEOF
11326 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
11327 _ACEOF
11328
11329
11330 fi
11331
11332 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
11333 echo $ECHO_N "checking for struct sockaddr_storage.ss_family... $ECHO_C" >&6
11334 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
11335   echo $ECHO_N "(cached) $ECHO_C" >&6
11336 else
11337   cat >conftest.$ac_ext <<_ACEOF
11338 /* confdefs.h.  */
11339 _ACEOF
11340 cat confdefs.h >>conftest.$ac_ext
11341 cat >>conftest.$ac_ext <<_ACEOF
11342 /* end confdefs.h.  */
11343 #include <sys/types.h>
11344 #ifdef HAVE_SYS_SOCKET_H
11345 #include <sys/socket.h>
11346 #endif
11347
11348
11349 int
11350 main ()
11351 {
11352 static struct sockaddr_storage ac_aggr;
11353 if (ac_aggr.ss_family)
11354 return 0;
11355   ;
11356   return 0;
11357 }
11358 _ACEOF
11359 rm -f conftest.$ac_objext
11360 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11361   (eval $ac_compile) 2>conftest.er1
11362   ac_status=$?
11363   grep -v '^ *+' conftest.er1 >conftest.err
11364   rm -f conftest.er1
11365   cat conftest.err >&5
11366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11367   (exit $ac_status); } &&
11368          { ac_try='test -z "$ac_c_werror_flag"
11369                          || test ! -s conftest.err'
11370   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11371   (eval $ac_try) 2>&5
11372   ac_status=$?
11373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11374   (exit $ac_status); }; } &&
11375          { ac_try='test -s conftest.$ac_objext'
11376   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11377   (eval $ac_try) 2>&5
11378   ac_status=$?
11379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11380   (exit $ac_status); }; }; then
11381   ac_cv_member_struct_sockaddr_storage_ss_family=yes
11382 else
11383   echo "$as_me: failed program was:" >&5
11384 sed 's/^/| /' conftest.$ac_ext >&5
11385
11386 cat >conftest.$ac_ext <<_ACEOF
11387 /* confdefs.h.  */
11388 _ACEOF
11389 cat confdefs.h >>conftest.$ac_ext
11390 cat >>conftest.$ac_ext <<_ACEOF
11391 /* end confdefs.h.  */
11392 #include <sys/types.h>
11393 #ifdef HAVE_SYS_SOCKET_H
11394 #include <sys/socket.h>
11395 #endif
11396
11397
11398 int
11399 main ()
11400 {
11401 static struct sockaddr_storage ac_aggr;
11402 if (sizeof ac_aggr.ss_family)
11403 return 0;
11404   ;
11405   return 0;
11406 }
11407 _ACEOF
11408 rm -f conftest.$ac_objext
11409 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11410   (eval $ac_compile) 2>conftest.er1
11411   ac_status=$?
11412   grep -v '^ *+' conftest.er1 >conftest.err
11413   rm -f conftest.er1
11414   cat conftest.err >&5
11415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11416   (exit $ac_status); } &&
11417          { ac_try='test -z "$ac_c_werror_flag"
11418                          || test ! -s conftest.err'
11419   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11420   (eval $ac_try) 2>&5
11421   ac_status=$?
11422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11423   (exit $ac_status); }; } &&
11424          { ac_try='test -s conftest.$ac_objext'
11425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11426   (eval $ac_try) 2>&5
11427   ac_status=$?
11428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11429   (exit $ac_status); }; }; then
11430   ac_cv_member_struct_sockaddr_storage_ss_family=yes
11431 else
11432   echo "$as_me: failed program was:" >&5
11433 sed 's/^/| /' conftest.$ac_ext >&5
11434
11435 ac_cv_member_struct_sockaddr_storage_ss_family=no
11436 fi
11437 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11438 fi
11439 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11440 fi
11441 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
11442 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_family" >&6
11443 if test $ac_cv_member_struct_sockaddr_storage_ss_family = yes; then
11444
11445 cat >>confdefs.h <<_ACEOF
11446 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
11447 _ACEOF
11448
11449
11450 fi
11451 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
11452 echo $ECHO_N "checking for struct sockaddr_storage.__ss_family... $ECHO_C" >&6
11453 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
11454   echo $ECHO_N "(cached) $ECHO_C" >&6
11455 else
11456   cat >conftest.$ac_ext <<_ACEOF
11457 /* confdefs.h.  */
11458 _ACEOF
11459 cat confdefs.h >>conftest.$ac_ext
11460 cat >>conftest.$ac_ext <<_ACEOF
11461 /* end confdefs.h.  */
11462 #include <sys/types.h>
11463 #ifdef HAVE_SYS_SOCKET_H
11464 #include <sys/socket.h>
11465 #endif
11466
11467
11468 int
11469 main ()
11470 {
11471 static struct sockaddr_storage ac_aggr;
11472 if (ac_aggr.__ss_family)
11473 return 0;
11474   ;
11475   return 0;
11476 }
11477 _ACEOF
11478 rm -f conftest.$ac_objext
11479 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11480   (eval $ac_compile) 2>conftest.er1
11481   ac_status=$?
11482   grep -v '^ *+' conftest.er1 >conftest.err
11483   rm -f conftest.er1
11484   cat conftest.err >&5
11485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11486   (exit $ac_status); } &&
11487          { ac_try='test -z "$ac_c_werror_flag"
11488                          || test ! -s conftest.err'
11489   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11490   (eval $ac_try) 2>&5
11491   ac_status=$?
11492   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11493   (exit $ac_status); }; } &&
11494          { ac_try='test -s conftest.$ac_objext'
11495   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11496   (eval $ac_try) 2>&5
11497   ac_status=$?
11498   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11499   (exit $ac_status); }; }; then
11500   ac_cv_member_struct_sockaddr_storage___ss_family=yes
11501 else
11502   echo "$as_me: failed program was:" >&5
11503 sed 's/^/| /' conftest.$ac_ext >&5
11504
11505 cat >conftest.$ac_ext <<_ACEOF
11506 /* confdefs.h.  */
11507 _ACEOF
11508 cat confdefs.h >>conftest.$ac_ext
11509 cat >>conftest.$ac_ext <<_ACEOF
11510 /* end confdefs.h.  */
11511 #include <sys/types.h>
11512 #ifdef HAVE_SYS_SOCKET_H
11513 #include <sys/socket.h>
11514 #endif
11515
11516
11517 int
11518 main ()
11519 {
11520 static struct sockaddr_storage ac_aggr;
11521 if (sizeof ac_aggr.__ss_family)
11522 return 0;
11523   ;
11524   return 0;
11525 }
11526 _ACEOF
11527 rm -f conftest.$ac_objext
11528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11529   (eval $ac_compile) 2>conftest.er1
11530   ac_status=$?
11531   grep -v '^ *+' conftest.er1 >conftest.err
11532   rm -f conftest.er1
11533   cat conftest.err >&5
11534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11535   (exit $ac_status); } &&
11536          { ac_try='test -z "$ac_c_werror_flag"
11537                          || test ! -s conftest.err'
11538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11539   (eval $ac_try) 2>&5
11540   ac_status=$?
11541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11542   (exit $ac_status); }; } &&
11543          { ac_try='test -s conftest.$ac_objext'
11544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11545   (eval $ac_try) 2>&5
11546   ac_status=$?
11547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11548   (exit $ac_status); }; }; then
11549   ac_cv_member_struct_sockaddr_storage___ss_family=yes
11550 else
11551   echo "$as_me: failed program was:" >&5
11552 sed 's/^/| /' conftest.$ac_ext >&5
11553
11554 ac_cv_member_struct_sockaddr_storage___ss_family=no
11555 fi
11556 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11557 fi
11558 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11559 fi
11560 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
11561 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_family" >&6
11562 if test $ac_cv_member_struct_sockaddr_storage___ss_family = yes; then
11563
11564 cat >>confdefs.h <<_ACEOF
11565 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
11566 _ACEOF
11567
11568
11569 fi
11570 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
11571 echo $ECHO_N "checking for struct sockaddr_storage.ss_len... $ECHO_C" >&6
11572 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
11573   echo $ECHO_N "(cached) $ECHO_C" >&6
11574 else
11575   cat >conftest.$ac_ext <<_ACEOF
11576 /* confdefs.h.  */
11577 _ACEOF
11578 cat confdefs.h >>conftest.$ac_ext
11579 cat >>conftest.$ac_ext <<_ACEOF
11580 /* end confdefs.h.  */
11581 #include <sys/types.h>
11582 #ifdef HAVE_SYS_SOCKET_H
11583 #include <sys/socket.h>
11584 #endif
11585
11586
11587 int
11588 main ()
11589 {
11590 static struct sockaddr_storage ac_aggr;
11591 if (ac_aggr.ss_len)
11592 return 0;
11593   ;
11594   return 0;
11595 }
11596 _ACEOF
11597 rm -f conftest.$ac_objext
11598 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11599   (eval $ac_compile) 2>conftest.er1
11600   ac_status=$?
11601   grep -v '^ *+' conftest.er1 >conftest.err
11602   rm -f conftest.er1
11603   cat conftest.err >&5
11604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11605   (exit $ac_status); } &&
11606          { ac_try='test -z "$ac_c_werror_flag"
11607                          || test ! -s conftest.err'
11608   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11609   (eval $ac_try) 2>&5
11610   ac_status=$?
11611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11612   (exit $ac_status); }; } &&
11613          { ac_try='test -s conftest.$ac_objext'
11614   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11615   (eval $ac_try) 2>&5
11616   ac_status=$?
11617   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11618   (exit $ac_status); }; }; then
11619   ac_cv_member_struct_sockaddr_storage_ss_len=yes
11620 else
11621   echo "$as_me: failed program was:" >&5
11622 sed 's/^/| /' conftest.$ac_ext >&5
11623
11624 cat >conftest.$ac_ext <<_ACEOF
11625 /* confdefs.h.  */
11626 _ACEOF
11627 cat confdefs.h >>conftest.$ac_ext
11628 cat >>conftest.$ac_ext <<_ACEOF
11629 /* end confdefs.h.  */
11630 #include <sys/types.h>
11631 #ifdef HAVE_SYS_SOCKET_H
11632 #include <sys/socket.h>
11633 #endif
11634
11635
11636 int
11637 main ()
11638 {
11639 static struct sockaddr_storage ac_aggr;
11640 if (sizeof ac_aggr.ss_len)
11641 return 0;
11642   ;
11643   return 0;
11644 }
11645 _ACEOF
11646 rm -f conftest.$ac_objext
11647 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11648   (eval $ac_compile) 2>conftest.er1
11649   ac_status=$?
11650   grep -v '^ *+' conftest.er1 >conftest.err
11651   rm -f conftest.er1
11652   cat conftest.err >&5
11653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11654   (exit $ac_status); } &&
11655          { ac_try='test -z "$ac_c_werror_flag"
11656                          || test ! -s conftest.err'
11657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11658   (eval $ac_try) 2>&5
11659   ac_status=$?
11660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11661   (exit $ac_status); }; } &&
11662          { ac_try='test -s conftest.$ac_objext'
11663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11664   (eval $ac_try) 2>&5
11665   ac_status=$?
11666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11667   (exit $ac_status); }; }; then
11668   ac_cv_member_struct_sockaddr_storage_ss_len=yes
11669 else
11670   echo "$as_me: failed program was:" >&5
11671 sed 's/^/| /' conftest.$ac_ext >&5
11672
11673 ac_cv_member_struct_sockaddr_storage_ss_len=no
11674 fi
11675 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11676 fi
11677 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11678 fi
11679 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
11680 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_len" >&6
11681 if test $ac_cv_member_struct_sockaddr_storage_ss_len = yes; then
11682
11683 cat >>confdefs.h <<_ACEOF
11684 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
11685 _ACEOF
11686
11687
11688 fi
11689 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
11690 echo $ECHO_N "checking for struct sockaddr_storage.__ss_len... $ECHO_C" >&6
11691 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
11692   echo $ECHO_N "(cached) $ECHO_C" >&6
11693 else
11694   cat >conftest.$ac_ext <<_ACEOF
11695 /* confdefs.h.  */
11696 _ACEOF
11697 cat confdefs.h >>conftest.$ac_ext
11698 cat >>conftest.$ac_ext <<_ACEOF
11699 /* end confdefs.h.  */
11700 #include <sys/types.h>
11701 #ifdef HAVE_SYS_SOCKET_H
11702 #include <sys/socket.h>
11703 #endif
11704
11705
11706 int
11707 main ()
11708 {
11709 static struct sockaddr_storage ac_aggr;
11710 if (ac_aggr.__ss_len)
11711 return 0;
11712   ;
11713   return 0;
11714 }
11715 _ACEOF
11716 rm -f conftest.$ac_objext
11717 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11718   (eval $ac_compile) 2>conftest.er1
11719   ac_status=$?
11720   grep -v '^ *+' conftest.er1 >conftest.err
11721   rm -f conftest.er1
11722   cat conftest.err >&5
11723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11724   (exit $ac_status); } &&
11725          { ac_try='test -z "$ac_c_werror_flag"
11726                          || test ! -s conftest.err'
11727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11728   (eval $ac_try) 2>&5
11729   ac_status=$?
11730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11731   (exit $ac_status); }; } &&
11732          { ac_try='test -s conftest.$ac_objext'
11733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11734   (eval $ac_try) 2>&5
11735   ac_status=$?
11736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11737   (exit $ac_status); }; }; then
11738   ac_cv_member_struct_sockaddr_storage___ss_len=yes
11739 else
11740   echo "$as_me: failed program was:" >&5
11741 sed 's/^/| /' conftest.$ac_ext >&5
11742
11743 cat >conftest.$ac_ext <<_ACEOF
11744 /* confdefs.h.  */
11745 _ACEOF
11746 cat confdefs.h >>conftest.$ac_ext
11747 cat >>conftest.$ac_ext <<_ACEOF
11748 /* end confdefs.h.  */
11749 #include <sys/types.h>
11750 #ifdef HAVE_SYS_SOCKET_H
11751 #include <sys/socket.h>
11752 #endif
11753
11754
11755 int
11756 main ()
11757 {
11758 static struct sockaddr_storage ac_aggr;
11759 if (sizeof ac_aggr.__ss_len)
11760 return 0;
11761   ;
11762   return 0;
11763 }
11764 _ACEOF
11765 rm -f conftest.$ac_objext
11766 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11767   (eval $ac_compile) 2>conftest.er1
11768   ac_status=$?
11769   grep -v '^ *+' conftest.er1 >conftest.err
11770   rm -f conftest.er1
11771   cat conftest.err >&5
11772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11773   (exit $ac_status); } &&
11774          { ac_try='test -z "$ac_c_werror_flag"
11775                          || test ! -s conftest.err'
11776   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11777   (eval $ac_try) 2>&5
11778   ac_status=$?
11779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11780   (exit $ac_status); }; } &&
11781          { ac_try='test -s conftest.$ac_objext'
11782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11783   (eval $ac_try) 2>&5
11784   ac_status=$?
11785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11786   (exit $ac_status); }; }; then
11787   ac_cv_member_struct_sockaddr_storage___ss_len=yes
11788 else
11789   echo "$as_me: failed program was:" >&5
11790 sed 's/^/| /' conftest.$ac_ext >&5
11791
11792 ac_cv_member_struct_sockaddr_storage___ss_len=no
11793 fi
11794 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11795 fi
11796 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11797 fi
11798 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
11799 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_len" >&6
11800 if test $ac_cv_member_struct_sockaddr_storage___ss_len = yes; then
11801
11802 cat >>confdefs.h <<_ACEOF
11803 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
11804 _ACEOF
11805
11806
11807 fi
11808 echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
11809 echo $ECHO_N "checking for struct sockaddr.sa_len... $ECHO_C" >&6
11810 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
11811   echo $ECHO_N "(cached) $ECHO_C" >&6
11812 else
11813   cat >conftest.$ac_ext <<_ACEOF
11814 /* confdefs.h.  */
11815 _ACEOF
11816 cat confdefs.h >>conftest.$ac_ext
11817 cat >>conftest.$ac_ext <<_ACEOF
11818 /* end confdefs.h.  */
11819 #include <sys/types.h>
11820 #ifdef HAVE_SYS_SOCKET_H
11821 #include <sys/socket.h>
11822 #endif
11823
11824
11825 int
11826 main ()
11827 {
11828 static struct sockaddr ac_aggr;
11829 if (ac_aggr.sa_len)
11830 return 0;
11831   ;
11832   return 0;
11833 }
11834 _ACEOF
11835 rm -f conftest.$ac_objext
11836 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11837   (eval $ac_compile) 2>conftest.er1
11838   ac_status=$?
11839   grep -v '^ *+' conftest.er1 >conftest.err
11840   rm -f conftest.er1
11841   cat conftest.err >&5
11842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11843   (exit $ac_status); } &&
11844          { ac_try='test -z "$ac_c_werror_flag"
11845                          || test ! -s conftest.err'
11846   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11847   (eval $ac_try) 2>&5
11848   ac_status=$?
11849   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11850   (exit $ac_status); }; } &&
11851          { ac_try='test -s conftest.$ac_objext'
11852   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11853   (eval $ac_try) 2>&5
11854   ac_status=$?
11855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11856   (exit $ac_status); }; }; then
11857   ac_cv_member_struct_sockaddr_sa_len=yes
11858 else
11859   echo "$as_me: failed program was:" >&5
11860 sed 's/^/| /' conftest.$ac_ext >&5
11861
11862 cat >conftest.$ac_ext <<_ACEOF
11863 /* confdefs.h.  */
11864 _ACEOF
11865 cat confdefs.h >>conftest.$ac_ext
11866 cat >>conftest.$ac_ext <<_ACEOF
11867 /* end confdefs.h.  */
11868 #include <sys/types.h>
11869 #ifdef HAVE_SYS_SOCKET_H
11870 #include <sys/socket.h>
11871 #endif
11872
11873
11874 int
11875 main ()
11876 {
11877 static struct sockaddr ac_aggr;
11878 if (sizeof ac_aggr.sa_len)
11879 return 0;
11880   ;
11881   return 0;
11882 }
11883 _ACEOF
11884 rm -f conftest.$ac_objext
11885 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11886   (eval $ac_compile) 2>conftest.er1
11887   ac_status=$?
11888   grep -v '^ *+' conftest.er1 >conftest.err
11889   rm -f conftest.er1
11890   cat conftest.err >&5
11891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11892   (exit $ac_status); } &&
11893          { ac_try='test -z "$ac_c_werror_flag"
11894                          || test ! -s conftest.err'
11895   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11896   (eval $ac_try) 2>&5
11897   ac_status=$?
11898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11899   (exit $ac_status); }; } &&
11900          { ac_try='test -s conftest.$ac_objext'
11901   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11902   (eval $ac_try) 2>&5
11903   ac_status=$?
11904   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11905   (exit $ac_status); }; }; then
11906   ac_cv_member_struct_sockaddr_sa_len=yes
11907 else
11908   echo "$as_me: failed program was:" >&5
11909 sed 's/^/| /' conftest.$ac_ext >&5
11910
11911 ac_cv_member_struct_sockaddr_sa_len=no
11912 fi
11913 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11914 fi
11915 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11916 fi
11917 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
11918 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_sa_len" >&6
11919 if test $ac_cv_member_struct_sockaddr_sa_len = yes; then
11920
11921 cat >>confdefs.h <<_ACEOF
11922 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
11923 _ACEOF
11924
11925
11926 fi
11927
11928 echo "$as_me:$LINENO: checking for struct addrinfo" >&5
11929 echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6
11930 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
11931   echo $ECHO_N "(cached) $ECHO_C" >&6
11932 else
11933   cat >conftest.$ac_ext <<_ACEOF
11934 /* confdefs.h.  */
11935 _ACEOF
11936 cat confdefs.h >>conftest.$ac_ext
11937 cat >>conftest.$ac_ext <<_ACEOF
11938 /* end confdefs.h.  */
11939 #include <sys/types.h>
11940 #include <sys/socket.h>
11941 #include <netdb.h>
11942
11943
11944 int
11945 main ()
11946 {
11947 if ((struct addrinfo *) 0)
11948   return 0;
11949 if (sizeof (struct addrinfo))
11950   return 0;
11951   ;
11952   return 0;
11953 }
11954 _ACEOF
11955 rm -f conftest.$ac_objext
11956 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11957   (eval $ac_compile) 2>conftest.er1
11958   ac_status=$?
11959   grep -v '^ *+' conftest.er1 >conftest.err
11960   rm -f conftest.er1
11961   cat conftest.err >&5
11962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11963   (exit $ac_status); } &&
11964          { ac_try='test -z "$ac_c_werror_flag"
11965                          || test ! -s conftest.err'
11966   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11967   (eval $ac_try) 2>&5
11968   ac_status=$?
11969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11970   (exit $ac_status); }; } &&
11971          { ac_try='test -s conftest.$ac_objext'
11972   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11973   (eval $ac_try) 2>&5
11974   ac_status=$?
11975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11976   (exit $ac_status); }; }; then
11977   ac_cv_type_struct_addrinfo=yes
11978 else
11979   echo "$as_me: failed program was:" >&5
11980 sed 's/^/| /' conftest.$ac_ext >&5
11981
11982 ac_cv_type_struct_addrinfo=no
11983 fi
11984 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11985 fi
11986 echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
11987 echo "${ECHO_T}$ac_cv_type_struct_addrinfo" >&6
11988 if test $ac_cv_type_struct_addrinfo = yes; then
11989
11990 cat >>confdefs.h <<_ACEOF
11991 #define HAVE_STRUCT_ADDRINFO 1
11992 _ACEOF
11993
11994
11995 fi
11996
11997
11998 echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
11999 echo $ECHO_N "checking for struct cmsgcred... $ECHO_C" >&6
12000 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
12001   echo $ECHO_N "(cached) $ECHO_C" >&6
12002 else
12003   cat >conftest.$ac_ext <<_ACEOF
12004 /* confdefs.h.  */
12005 _ACEOF
12006 cat confdefs.h >>conftest.$ac_ext
12007 cat >>conftest.$ac_ext <<_ACEOF
12008 /* end confdefs.h.  */
12009 #include <sys/param.h>
12010 #include <sys/types.h>
12011 #include <sys/socket.h>
12012 #include <sys/ucred.h>
12013
12014 int
12015 main ()
12016 {
12017 if ((struct cmsgcred *) 0)
12018   return 0;
12019 if (sizeof (struct cmsgcred))
12020   return 0;
12021   ;
12022   return 0;
12023 }
12024 _ACEOF
12025 rm -f conftest.$ac_objext
12026 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12027   (eval $ac_compile) 2>conftest.er1
12028   ac_status=$?
12029   grep -v '^ *+' conftest.er1 >conftest.err
12030   rm -f conftest.er1
12031   cat conftest.err >&5
12032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12033   (exit $ac_status); } &&
12034          { ac_try='test -z "$ac_c_werror_flag"
12035                          || test ! -s conftest.err'
12036   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12037   (eval $ac_try) 2>&5
12038   ac_status=$?
12039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12040   (exit $ac_status); }; } &&
12041          { ac_try='test -s conftest.$ac_objext'
12042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12043   (eval $ac_try) 2>&5
12044   ac_status=$?
12045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12046   (exit $ac_status); }; }; then
12047   ac_cv_type_struct_cmsgcred=yes
12048 else
12049   echo "$as_me: failed program was:" >&5
12050 sed 's/^/| /' conftest.$ac_ext >&5
12051
12052 ac_cv_type_struct_cmsgcred=no
12053 fi
12054 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12055 fi
12056 echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
12057 echo "${ECHO_T}$ac_cv_type_struct_cmsgcred" >&6
12058 if test $ac_cv_type_struct_cmsgcred = yes; then
12059
12060 cat >>confdefs.h <<_ACEOF
12061 #define HAVE_STRUCT_CMSGCRED 1
12062 _ACEOF
12063
12064
12065 fi
12066 echo "$as_me:$LINENO: checking for struct fcred" >&5
12067 echo $ECHO_N "checking for struct fcred... $ECHO_C" >&6
12068 if test "${ac_cv_type_struct_fcred+set}" = set; then
12069   echo $ECHO_N "(cached) $ECHO_C" >&6
12070 else
12071   cat >conftest.$ac_ext <<_ACEOF
12072 /* confdefs.h.  */
12073 _ACEOF
12074 cat confdefs.h >>conftest.$ac_ext
12075 cat >>conftest.$ac_ext <<_ACEOF
12076 /* end confdefs.h.  */
12077 #include <sys/param.h>
12078 #include <sys/types.h>
12079 #include <sys/socket.h>
12080 #include <sys/ucred.h>
12081
12082 int
12083 main ()
12084 {
12085 if ((struct fcred *) 0)
12086   return 0;
12087 if (sizeof (struct fcred))
12088   return 0;
12089   ;
12090   return 0;
12091 }
12092 _ACEOF
12093 rm -f conftest.$ac_objext
12094 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12095   (eval $ac_compile) 2>conftest.er1
12096   ac_status=$?
12097   grep -v '^ *+' conftest.er1 >conftest.err
12098   rm -f conftest.er1
12099   cat conftest.err >&5
12100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12101   (exit $ac_status); } &&
12102          { ac_try='test -z "$ac_c_werror_flag"
12103                          || test ! -s conftest.err'
12104   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12105   (eval $ac_try) 2>&5
12106   ac_status=$?
12107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12108   (exit $ac_status); }; } &&
12109          { ac_try='test -s conftest.$ac_objext'
12110   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12111   (eval $ac_try) 2>&5
12112   ac_status=$?
12113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12114   (exit $ac_status); }; }; then
12115   ac_cv_type_struct_fcred=yes
12116 else
12117   echo "$as_me: failed program was:" >&5
12118 sed 's/^/| /' conftest.$ac_ext >&5
12119
12120 ac_cv_type_struct_fcred=no
12121 fi
12122 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12123 fi
12124 echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
12125 echo "${ECHO_T}$ac_cv_type_struct_fcred" >&6
12126 if test $ac_cv_type_struct_fcred = yes; then
12127
12128 cat >>confdefs.h <<_ACEOF
12129 #define HAVE_STRUCT_FCRED 1
12130 _ACEOF
12131
12132
12133 fi
12134 echo "$as_me:$LINENO: checking for struct sockcred" >&5
12135 echo $ECHO_N "checking for struct sockcred... $ECHO_C" >&6
12136 if test "${ac_cv_type_struct_sockcred+set}" = set; then
12137   echo $ECHO_N "(cached) $ECHO_C" >&6
12138 else
12139   cat >conftest.$ac_ext <<_ACEOF
12140 /* confdefs.h.  */
12141 _ACEOF
12142 cat confdefs.h >>conftest.$ac_ext
12143 cat >>conftest.$ac_ext <<_ACEOF
12144 /* end confdefs.h.  */
12145 #include <sys/param.h>
12146 #include <sys/types.h>
12147 #include <sys/socket.h>
12148 #include <sys/ucred.h>
12149
12150 int
12151 main ()
12152 {
12153 if ((struct sockcred *) 0)
12154   return 0;
12155 if (sizeof (struct sockcred))
12156   return 0;
12157   ;
12158   return 0;
12159 }
12160 _ACEOF
12161 rm -f conftest.$ac_objext
12162 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12163   (eval $ac_compile) 2>conftest.er1
12164   ac_status=$?
12165   grep -v '^ *+' conftest.er1 >conftest.err
12166   rm -f conftest.er1
12167   cat conftest.err >&5
12168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12169   (exit $ac_status); } &&
12170          { ac_try='test -z "$ac_c_werror_flag"
12171                          || test ! -s conftest.err'
12172   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12173   (eval $ac_try) 2>&5
12174   ac_status=$?
12175   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12176   (exit $ac_status); }; } &&
12177          { ac_try='test -s conftest.$ac_objext'
12178   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12179   (eval $ac_try) 2>&5
12180   ac_status=$?
12181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12182   (exit $ac_status); }; }; then
12183   ac_cv_type_struct_sockcred=yes
12184 else
12185   echo "$as_me: failed program was:" >&5
12186 sed 's/^/| /' conftest.$ac_ext >&5
12187
12188 ac_cv_type_struct_sockcred=no
12189 fi
12190 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12191 fi
12192 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
12193 echo "${ECHO_T}$ac_cv_type_struct_sockcred" >&6
12194 if test $ac_cv_type_struct_sockcred = yes; then
12195
12196 cat >>confdefs.h <<_ACEOF
12197 #define HAVE_STRUCT_SOCKCRED 1
12198 _ACEOF
12199
12200
12201 fi
12202
12203
12204 echo "$as_me:$LINENO: checking for struct option" >&5
12205 echo $ECHO_N "checking for struct option... $ECHO_C" >&6
12206 if test "${ac_cv_type_struct_option+set}" = set; then
12207   echo $ECHO_N "(cached) $ECHO_C" >&6
12208 else
12209   cat >conftest.$ac_ext <<_ACEOF
12210 /* confdefs.h.  */
12211 _ACEOF
12212 cat confdefs.h >>conftest.$ac_ext
12213 cat >>conftest.$ac_ext <<_ACEOF
12214 /* end confdefs.h.  */
12215 #ifdef HAVE_GETOPT_H
12216 #include <getopt.h>
12217 #endif
12218
12219 int
12220 main ()
12221 {
12222 if ((struct option *) 0)
12223   return 0;
12224 if (sizeof (struct option))
12225   return 0;
12226   ;
12227   return 0;
12228 }
12229 _ACEOF
12230 rm -f conftest.$ac_objext
12231 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12232   (eval $ac_compile) 2>conftest.er1
12233   ac_status=$?
12234   grep -v '^ *+' conftest.er1 >conftest.err
12235   rm -f conftest.er1
12236   cat conftest.err >&5
12237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12238   (exit $ac_status); } &&
12239          { ac_try='test -z "$ac_c_werror_flag"
12240                          || test ! -s conftest.err'
12241   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12242   (eval $ac_try) 2>&5
12243   ac_status=$?
12244   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12245   (exit $ac_status); }; } &&
12246          { ac_try='test -s conftest.$ac_objext'
12247   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12248   (eval $ac_try) 2>&5
12249   ac_status=$?
12250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12251   (exit $ac_status); }; }; then
12252   ac_cv_type_struct_option=yes
12253 else
12254   echo "$as_me: failed program was:" >&5
12255 sed 's/^/| /' conftest.$ac_ext >&5
12256
12257 ac_cv_type_struct_option=no
12258 fi
12259 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12260 fi
12261 echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
12262 echo "${ECHO_T}$ac_cv_type_struct_option" >&6
12263 if test $ac_cv_type_struct_option = yes; then
12264
12265 cat >>confdefs.h <<_ACEOF
12266 #define HAVE_STRUCT_OPTION 1
12267 _ACEOF
12268
12269
12270 fi
12271
12272
12273 if test "$with_zlib" = yes; then
12274   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
12275   # did not).  While we could work around the lack of z_streamp, it
12276   # seems unwise to encourage people to use such old zlib versions...
12277   echo "$as_me:$LINENO: checking for z_streamp" >&5
12278 echo $ECHO_N "checking for z_streamp... $ECHO_C" >&6
12279 if test "${ac_cv_type_z_streamp+set}" = set; then
12280   echo $ECHO_N "(cached) $ECHO_C" >&6
12281 else
12282   cat >conftest.$ac_ext <<_ACEOF
12283 /* confdefs.h.  */
12284 _ACEOF
12285 cat confdefs.h >>conftest.$ac_ext
12286 cat >>conftest.$ac_ext <<_ACEOF
12287 /* end confdefs.h.  */
12288 #include <zlib.h>
12289
12290 int
12291 main ()
12292 {
12293 if ((z_streamp *) 0)
12294   return 0;
12295 if (sizeof (z_streamp))
12296   return 0;
12297   ;
12298   return 0;
12299 }
12300 _ACEOF
12301 rm -f conftest.$ac_objext
12302 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12303   (eval $ac_compile) 2>conftest.er1
12304   ac_status=$?
12305   grep -v '^ *+' conftest.er1 >conftest.err
12306   rm -f conftest.er1
12307   cat conftest.err >&5
12308   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12309   (exit $ac_status); } &&
12310          { ac_try='test -z "$ac_c_werror_flag"
12311                          || test ! -s conftest.err'
12312   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12313   (eval $ac_try) 2>&5
12314   ac_status=$?
12315   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12316   (exit $ac_status); }; } &&
12317          { ac_try='test -s conftest.$ac_objext'
12318   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12319   (eval $ac_try) 2>&5
12320   ac_status=$?
12321   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12322   (exit $ac_status); }; }; then
12323   ac_cv_type_z_streamp=yes
12324 else
12325   echo "$as_me: failed program was:" >&5
12326 sed 's/^/| /' conftest.$ac_ext >&5
12327
12328 ac_cv_type_z_streamp=no
12329 fi
12330 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12331 fi
12332 echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
12333 echo "${ECHO_T}$ac_cv_type_z_streamp" >&6
12334 if test $ac_cv_type_z_streamp = yes; then
12335   :
12336 else
12337   { { echo "$as_me:$LINENO: error: zlib version is too old
12338 Use --without-zlib to disable zlib support." >&5
12339 echo "$as_me: error: zlib version is too old
12340 Use --without-zlib to disable zlib support." >&2;}
12341    { (exit 1); exit 1; }; }
12342 fi
12343
12344 fi
12345
12346 if test "$with_krb5" = yes; then
12347 # Check for differences between MIT and Heimdal (KTH) releases
12348   echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
12349 echo $ECHO_N "checking for krb5_ticket.enc_part2... $ECHO_C" >&6
12350 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
12351   echo $ECHO_N "(cached) $ECHO_C" >&6
12352 else
12353   cat >conftest.$ac_ext <<_ACEOF
12354 /* confdefs.h.  */
12355 _ACEOF
12356 cat confdefs.h >>conftest.$ac_ext
12357 cat >>conftest.$ac_ext <<_ACEOF
12358 /* end confdefs.h.  */
12359 #include <krb5.h>
12360
12361 int
12362 main ()
12363 {
12364 static krb5_ticket ac_aggr;
12365 if (ac_aggr.enc_part2)
12366 return 0;
12367   ;
12368   return 0;
12369 }
12370 _ACEOF
12371 rm -f conftest.$ac_objext
12372 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12373   (eval $ac_compile) 2>conftest.er1
12374   ac_status=$?
12375   grep -v '^ *+' conftest.er1 >conftest.err
12376   rm -f conftest.er1
12377   cat conftest.err >&5
12378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12379   (exit $ac_status); } &&
12380          { ac_try='test -z "$ac_c_werror_flag"
12381                          || test ! -s conftest.err'
12382   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12383   (eval $ac_try) 2>&5
12384   ac_status=$?
12385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12386   (exit $ac_status); }; } &&
12387          { ac_try='test -s conftest.$ac_objext'
12388   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12389   (eval $ac_try) 2>&5
12390   ac_status=$?
12391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12392   (exit $ac_status); }; }; then
12393   ac_cv_member_krb5_ticket_enc_part2=yes
12394 else
12395   echo "$as_me: failed program was:" >&5
12396 sed 's/^/| /' conftest.$ac_ext >&5
12397
12398 cat >conftest.$ac_ext <<_ACEOF
12399 /* confdefs.h.  */
12400 _ACEOF
12401 cat confdefs.h >>conftest.$ac_ext
12402 cat >>conftest.$ac_ext <<_ACEOF
12403 /* end confdefs.h.  */
12404 #include <krb5.h>
12405
12406 int
12407 main ()
12408 {
12409 static krb5_ticket ac_aggr;
12410 if (sizeof ac_aggr.enc_part2)
12411 return 0;
12412   ;
12413   return 0;
12414 }
12415 _ACEOF
12416 rm -f conftest.$ac_objext
12417 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12418   (eval $ac_compile) 2>conftest.er1
12419   ac_status=$?
12420   grep -v '^ *+' conftest.er1 >conftest.err
12421   rm -f conftest.er1
12422   cat conftest.err >&5
12423   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12424   (exit $ac_status); } &&
12425          { ac_try='test -z "$ac_c_werror_flag"
12426                          || test ! -s conftest.err'
12427   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12428   (eval $ac_try) 2>&5
12429   ac_status=$?
12430   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12431   (exit $ac_status); }; } &&
12432          { ac_try='test -s conftest.$ac_objext'
12433   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12434   (eval $ac_try) 2>&5
12435   ac_status=$?
12436   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12437   (exit $ac_status); }; }; then
12438   ac_cv_member_krb5_ticket_enc_part2=yes
12439 else
12440   echo "$as_me: failed program was:" >&5
12441 sed 's/^/| /' conftest.$ac_ext >&5
12442
12443 ac_cv_member_krb5_ticket_enc_part2=no
12444 fi
12445 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12446 fi
12447 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12448 fi
12449 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
12450 echo "${ECHO_T}$ac_cv_member_krb5_ticket_enc_part2" >&6
12451 if test $ac_cv_member_krb5_ticket_enc_part2 = yes; then
12452
12453 cat >>confdefs.h <<_ACEOF
12454 #define HAVE_KRB5_TICKET_ENC_PART2 1
12455 _ACEOF
12456
12457
12458 else
12459   echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
12460 echo $ECHO_N "checking for krb5_ticket.client... $ECHO_C" >&6
12461 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
12462   echo $ECHO_N "(cached) $ECHO_C" >&6
12463 else
12464   cat >conftest.$ac_ext <<_ACEOF
12465 /* confdefs.h.  */
12466 _ACEOF
12467 cat confdefs.h >>conftest.$ac_ext
12468 cat >>conftest.$ac_ext <<_ACEOF
12469 /* end confdefs.h.  */
12470 #include <krb5.h>
12471
12472 int
12473 main ()
12474 {
12475 static krb5_ticket ac_aggr;
12476 if (ac_aggr.client)
12477 return 0;
12478   ;
12479   return 0;
12480 }
12481 _ACEOF
12482 rm -f conftest.$ac_objext
12483 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12484   (eval $ac_compile) 2>conftest.er1
12485   ac_status=$?
12486   grep -v '^ *+' conftest.er1 >conftest.err
12487   rm -f conftest.er1
12488   cat conftest.err >&5
12489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12490   (exit $ac_status); } &&
12491          { ac_try='test -z "$ac_c_werror_flag"
12492                          || test ! -s conftest.err'
12493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12494   (eval $ac_try) 2>&5
12495   ac_status=$?
12496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12497   (exit $ac_status); }; } &&
12498          { ac_try='test -s conftest.$ac_objext'
12499   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12500   (eval $ac_try) 2>&5
12501   ac_status=$?
12502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12503   (exit $ac_status); }; }; then
12504   ac_cv_member_krb5_ticket_client=yes
12505 else
12506   echo "$as_me: failed program was:" >&5
12507 sed 's/^/| /' conftest.$ac_ext >&5
12508
12509 cat >conftest.$ac_ext <<_ACEOF
12510 /* confdefs.h.  */
12511 _ACEOF
12512 cat confdefs.h >>conftest.$ac_ext
12513 cat >>conftest.$ac_ext <<_ACEOF
12514 /* end confdefs.h.  */
12515 #include <krb5.h>
12516
12517 int
12518 main ()
12519 {
12520 static krb5_ticket ac_aggr;
12521 if (sizeof ac_aggr.client)
12522 return 0;
12523   ;
12524   return 0;
12525 }
12526 _ACEOF
12527 rm -f conftest.$ac_objext
12528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12529   (eval $ac_compile) 2>conftest.er1
12530   ac_status=$?
12531   grep -v '^ *+' conftest.er1 >conftest.err
12532   rm -f conftest.er1
12533   cat conftest.err >&5
12534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12535   (exit $ac_status); } &&
12536          { ac_try='test -z "$ac_c_werror_flag"
12537                          || test ! -s conftest.err'
12538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12539   (eval $ac_try) 2>&5
12540   ac_status=$?
12541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12542   (exit $ac_status); }; } &&
12543          { ac_try='test -s conftest.$ac_objext'
12544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12545   (eval $ac_try) 2>&5
12546   ac_status=$?
12547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12548   (exit $ac_status); }; }; then
12549   ac_cv_member_krb5_ticket_client=yes
12550 else
12551   echo "$as_me: failed program was:" >&5
12552 sed 's/^/| /' conftest.$ac_ext >&5
12553
12554 ac_cv_member_krb5_ticket_client=no
12555 fi
12556 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12557 fi
12558 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12559 fi
12560 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
12561 echo "${ECHO_T}$ac_cv_member_krb5_ticket_client" >&6
12562 if test $ac_cv_member_krb5_ticket_client = yes; then
12563
12564 cat >>confdefs.h <<_ACEOF
12565 #define HAVE_KRB5_TICKET_CLIENT 1
12566 _ACEOF
12567
12568
12569 else
12570   { { echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
12571 echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
12572    { (exit 1); exit 1; }; }
12573 fi
12574
12575 fi
12576
12577   echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
12578 echo $ECHO_N "checking for krb5_error.text.data... $ECHO_C" >&6
12579 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
12580   echo $ECHO_N "(cached) $ECHO_C" >&6
12581 else
12582   cat >conftest.$ac_ext <<_ACEOF
12583 /* confdefs.h.  */
12584 _ACEOF
12585 cat confdefs.h >>conftest.$ac_ext
12586 cat >>conftest.$ac_ext <<_ACEOF
12587 /* end confdefs.h.  */
12588 #include <krb5.h>
12589
12590 int
12591 main ()
12592 {
12593 static krb5_error ac_aggr;
12594 if (ac_aggr.text.data)
12595 return 0;
12596   ;
12597   return 0;
12598 }
12599 _ACEOF
12600 rm -f conftest.$ac_objext
12601 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12602   (eval $ac_compile) 2>conftest.er1
12603   ac_status=$?
12604   grep -v '^ *+' conftest.er1 >conftest.err
12605   rm -f conftest.er1
12606   cat conftest.err >&5
12607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12608   (exit $ac_status); } &&
12609          { ac_try='test -z "$ac_c_werror_flag"
12610                          || test ! -s conftest.err'
12611   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12612   (eval $ac_try) 2>&5
12613   ac_status=$?
12614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12615   (exit $ac_status); }; } &&
12616          { ac_try='test -s conftest.$ac_objext'
12617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12618   (eval $ac_try) 2>&5
12619   ac_status=$?
12620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12621   (exit $ac_status); }; }; then
12622   ac_cv_member_krb5_error_text_data=yes
12623 else
12624   echo "$as_me: failed program was:" >&5
12625 sed 's/^/| /' conftest.$ac_ext >&5
12626
12627 cat >conftest.$ac_ext <<_ACEOF
12628 /* confdefs.h.  */
12629 _ACEOF
12630 cat confdefs.h >>conftest.$ac_ext
12631 cat >>conftest.$ac_ext <<_ACEOF
12632 /* end confdefs.h.  */
12633 #include <krb5.h>
12634
12635 int
12636 main ()
12637 {
12638 static krb5_error ac_aggr;
12639 if (sizeof ac_aggr.text.data)
12640 return 0;
12641   ;
12642   return 0;
12643 }
12644 _ACEOF
12645 rm -f conftest.$ac_objext
12646 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12647   (eval $ac_compile) 2>conftest.er1
12648   ac_status=$?
12649   grep -v '^ *+' conftest.er1 >conftest.err
12650   rm -f conftest.er1
12651   cat conftest.err >&5
12652   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12653   (exit $ac_status); } &&
12654          { ac_try='test -z "$ac_c_werror_flag"
12655                          || test ! -s conftest.err'
12656   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12657   (eval $ac_try) 2>&5
12658   ac_status=$?
12659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12660   (exit $ac_status); }; } &&
12661          { ac_try='test -s conftest.$ac_objext'
12662   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12663   (eval $ac_try) 2>&5
12664   ac_status=$?
12665   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12666   (exit $ac_status); }; }; then
12667   ac_cv_member_krb5_error_text_data=yes
12668 else
12669   echo "$as_me: failed program was:" >&5
12670 sed 's/^/| /' conftest.$ac_ext >&5
12671
12672 ac_cv_member_krb5_error_text_data=no
12673 fi
12674 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12675 fi
12676 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12677 fi
12678 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
12679 echo "${ECHO_T}$ac_cv_member_krb5_error_text_data" >&6
12680 if test $ac_cv_member_krb5_error_text_data = yes; then
12681
12682 cat >>confdefs.h <<_ACEOF
12683 #define HAVE_KRB5_ERROR_TEXT_DATA 1
12684 _ACEOF
12685
12686
12687 else
12688   echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
12689 echo $ECHO_N "checking for krb5_error.e_data... $ECHO_C" >&6
12690 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
12691   echo $ECHO_N "(cached) $ECHO_C" >&6
12692 else
12693   cat >conftest.$ac_ext <<_ACEOF
12694 /* confdefs.h.  */
12695 _ACEOF
12696 cat confdefs.h >>conftest.$ac_ext
12697 cat >>conftest.$ac_ext <<_ACEOF
12698 /* end confdefs.h.  */
12699 #include <krb5.h>
12700
12701 int
12702 main ()
12703 {
12704 static krb5_error ac_aggr;
12705 if (ac_aggr.e_data)
12706 return 0;
12707   ;
12708   return 0;
12709 }
12710 _ACEOF
12711 rm -f conftest.$ac_objext
12712 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12713   (eval $ac_compile) 2>conftest.er1
12714   ac_status=$?
12715   grep -v '^ *+' conftest.er1 >conftest.err
12716   rm -f conftest.er1
12717   cat conftest.err >&5
12718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12719   (exit $ac_status); } &&
12720          { ac_try='test -z "$ac_c_werror_flag"
12721                          || test ! -s conftest.err'
12722   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12723   (eval $ac_try) 2>&5
12724   ac_status=$?
12725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12726   (exit $ac_status); }; } &&
12727          { ac_try='test -s conftest.$ac_objext'
12728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12729   (eval $ac_try) 2>&5
12730   ac_status=$?
12731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12732   (exit $ac_status); }; }; then
12733   ac_cv_member_krb5_error_e_data=yes
12734 else
12735   echo "$as_me: failed program was:" >&5
12736 sed 's/^/| /' conftest.$ac_ext >&5
12737
12738 cat >conftest.$ac_ext <<_ACEOF
12739 /* confdefs.h.  */
12740 _ACEOF
12741 cat confdefs.h >>conftest.$ac_ext
12742 cat >>conftest.$ac_ext <<_ACEOF
12743 /* end confdefs.h.  */
12744 #include <krb5.h>
12745
12746 int
12747 main ()
12748 {
12749 static krb5_error ac_aggr;
12750 if (sizeof ac_aggr.e_data)
12751 return 0;
12752   ;
12753   return 0;
12754 }
12755 _ACEOF
12756 rm -f conftest.$ac_objext
12757 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12758   (eval $ac_compile) 2>conftest.er1
12759   ac_status=$?
12760   grep -v '^ *+' conftest.er1 >conftest.err
12761   rm -f conftest.er1
12762   cat conftest.err >&5
12763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12764   (exit $ac_status); } &&
12765          { ac_try='test -z "$ac_c_werror_flag"
12766                          || test ! -s conftest.err'
12767   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12768   (eval $ac_try) 2>&5
12769   ac_status=$?
12770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12771   (exit $ac_status); }; } &&
12772          { ac_try='test -s conftest.$ac_objext'
12773   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12774   (eval $ac_try) 2>&5
12775   ac_status=$?
12776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12777   (exit $ac_status); }; }; then
12778   ac_cv_member_krb5_error_e_data=yes
12779 else
12780   echo "$as_me: failed program was:" >&5
12781 sed 's/^/| /' conftest.$ac_ext >&5
12782
12783 ac_cv_member_krb5_error_e_data=no
12784 fi
12785 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12786 fi
12787 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12788 fi
12789 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
12790 echo "${ECHO_T}$ac_cv_member_krb5_error_e_data" >&6
12791 if test $ac_cv_member_krb5_error_e_data = yes; then
12792
12793 cat >>confdefs.h <<_ACEOF
12794 #define HAVE_KRB5_ERROR_E_DATA 1
12795 _ACEOF
12796
12797
12798 else
12799   { { echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
12800 echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
12801    { (exit 1); exit 1; }; }
12802 fi
12803
12804 fi
12805
12806 fi
12807
12808 # This is probably only present on Darwin, but may as well check always
12809 echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
12810 echo $ECHO_N "checking whether F_FULLFSYNC is declared... $ECHO_C" >&6
12811 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
12812   echo $ECHO_N "(cached) $ECHO_C" >&6
12813 else
12814   cat >conftest.$ac_ext <<_ACEOF
12815 /* confdefs.h.  */
12816 _ACEOF
12817 cat confdefs.h >>conftest.$ac_ext
12818 cat >>conftest.$ac_ext <<_ACEOF
12819 /* end confdefs.h.  */
12820 #include <fcntl.h>
12821
12822 int
12823 main ()
12824 {
12825 #ifndef F_FULLFSYNC
12826   char *p = (char *) F_FULLFSYNC;
12827 #endif
12828
12829   ;
12830   return 0;
12831 }
12832 _ACEOF
12833 rm -f conftest.$ac_objext
12834 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12835   (eval $ac_compile) 2>conftest.er1
12836   ac_status=$?
12837   grep -v '^ *+' conftest.er1 >conftest.err
12838   rm -f conftest.er1
12839   cat conftest.err >&5
12840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12841   (exit $ac_status); } &&
12842          { ac_try='test -z "$ac_c_werror_flag"
12843                          || test ! -s conftest.err'
12844   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12845   (eval $ac_try) 2>&5
12846   ac_status=$?
12847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12848   (exit $ac_status); }; } &&
12849          { ac_try='test -s conftest.$ac_objext'
12850   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12851   (eval $ac_try) 2>&5
12852   ac_status=$?
12853   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12854   (exit $ac_status); }; }; then
12855   ac_cv_have_decl_F_FULLFSYNC=yes
12856 else
12857   echo "$as_me: failed program was:" >&5
12858 sed 's/^/| /' conftest.$ac_ext >&5
12859
12860 ac_cv_have_decl_F_FULLFSYNC=no
12861 fi
12862 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12863 fi
12864 echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
12865 echo "${ECHO_T}$ac_cv_have_decl_F_FULLFSYNC" >&6
12866 if test $ac_cv_have_decl_F_FULLFSYNC = yes; then
12867
12868 cat >>confdefs.h <<_ACEOF
12869 #define HAVE_DECL_F_FULLFSYNC 1
12870 _ACEOF
12871
12872
12873 else
12874   cat >>confdefs.h <<_ACEOF
12875 #define HAVE_DECL_F_FULLFSYNC 0
12876 _ACEOF
12877
12878
12879 fi
12880
12881
12882
12883 ##
12884 ## Functions, global variables
12885 ##
12886
12887 echo "$as_me:$LINENO: checking for int timezone" >&5
12888 echo $ECHO_N "checking for int timezone... $ECHO_C" >&6
12889 if test "${pgac_cv_var_int_timezone+set}" = set; then
12890   echo $ECHO_N "(cached) $ECHO_C" >&6
12891 else
12892   cat >conftest.$ac_ext <<_ACEOF
12893 /* confdefs.h.  */
12894 _ACEOF
12895 cat confdefs.h >>conftest.$ac_ext
12896 cat >>conftest.$ac_ext <<_ACEOF
12897 /* end confdefs.h.  */
12898 #include <time.h>
12899 int res;
12900 int
12901 main ()
12902 {
12903 #ifndef __CYGWIN__
12904 res = timezone / 60;
12905 #else
12906 res = _timezone / 60;
12907 #endif
12908   ;
12909   return 0;
12910 }
12911 _ACEOF
12912 rm -f conftest.$ac_objext conftest$ac_exeext
12913 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12914   (eval $ac_link) 2>conftest.er1
12915   ac_status=$?
12916   grep -v '^ *+' conftest.er1 >conftest.err
12917   rm -f conftest.er1
12918   cat conftest.err >&5
12919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12920   (exit $ac_status); } &&
12921          { ac_try='test -z "$ac_c_werror_flag"
12922                          || test ! -s conftest.err'
12923   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12924   (eval $ac_try) 2>&5
12925   ac_status=$?
12926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12927   (exit $ac_status); }; } &&
12928          { ac_try='test -s conftest$ac_exeext'
12929   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12930   (eval $ac_try) 2>&5
12931   ac_status=$?
12932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12933   (exit $ac_status); }; }; then
12934   pgac_cv_var_int_timezone=yes
12935 else
12936   echo "$as_me: failed program was:" >&5
12937 sed 's/^/| /' conftest.$ac_ext >&5
12938
12939 pgac_cv_var_int_timezone=no
12940 fi
12941 rm -f conftest.err conftest.$ac_objext \
12942       conftest$ac_exeext conftest.$ac_ext
12943 fi
12944 echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
12945 echo "${ECHO_T}$pgac_cv_var_int_timezone" >&6
12946 if test x"$pgac_cv_var_int_timezone" = xyes ; then
12947
12948 cat >>confdefs.h <<\_ACEOF
12949 #define HAVE_INT_TIMEZONE
12950 _ACEOF
12951
12952 fi
12953 echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
12954 echo $ECHO_N "checking types of arguments for accept()... $ECHO_C" >&6
12955  if test "${ac_cv_func_accept_return+set}" = set; then
12956   echo $ECHO_N "(cached) $ECHO_C" >&6
12957 else
12958    if test "${ac_cv_func_accept_arg1+set}" = set; then
12959   echo $ECHO_N "(cached) $ECHO_C" >&6
12960 else
12961     if test "${ac_cv_func_accept_arg2+set}" = set; then
12962   echo $ECHO_N "(cached) $ECHO_C" >&6
12963 else
12964      if test "${ac_cv_func_accept_arg3+set}" = set; then
12965   echo $ECHO_N "(cached) $ECHO_C" >&6
12966 else
12967       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
12968       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
12969        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
12970         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
12971          cat >conftest.$ac_ext <<_ACEOF
12972 /* confdefs.h.  */
12973 _ACEOF
12974 cat confdefs.h >>conftest.$ac_ext
12975 cat >>conftest.$ac_ext <<_ACEOF
12976 /* end confdefs.h.  */
12977 #ifdef HAVE_SYS_TYPES_H
12978 #include <sys/types.h>
12979 #endif
12980 #ifdef HAVE_SYS_SOCKET_H
12981 #include <sys/socket.h>
12982 #endif
12983 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
12984 int
12985 main ()
12986 {
12987
12988   ;
12989   return 0;
12990 }
12991 _ACEOF
12992 rm -f conftest.$ac_objext
12993 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12994   (eval $ac_compile) 2>conftest.er1
12995   ac_status=$?
12996   grep -v '^ *+' conftest.er1 >conftest.err
12997   rm -f conftest.er1
12998   cat conftest.err >&5
12999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13000   (exit $ac_status); } &&
13001          { ac_try='test -z "$ac_c_werror_flag"
13002                          || test ! -s conftest.err'
13003   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13004   (eval $ac_try) 2>&5
13005   ac_status=$?
13006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13007   (exit $ac_status); }; } &&
13008          { ac_try='test -s conftest.$ac_objext'
13009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13010   (eval $ac_try) 2>&5
13011   ac_status=$?
13012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13013   (exit $ac_status); }; }; then
13014   ac_not_found=no; break 4
13015 else
13016   echo "$as_me: failed program was:" >&5
13017 sed 's/^/| /' conftest.$ac_ext >&5
13018
13019 ac_not_found=yes
13020 fi
13021 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13022        done
13023       done
13024      done
13025     done
13026     if test "$ac_not_found" = yes; then
13027       { { echo "$as_me:$LINENO: error: could not determine argument types" >&5
13028 echo "$as_me: error: could not determine argument types" >&2;}
13029    { (exit 1); exit 1; }; }
13030     fi
13031     if test "$ac_cv_func_accept_arg3" = "void"; then
13032       ac_cv_func_accept_arg3=int
13033     fi
13034
13035 fi
13036
13037 fi
13038
13039 fi
13040
13041 fi
13042  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
13043 echo "${ECHO_T}$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6
13044
13045 cat >>confdefs.h <<_ACEOF
13046 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
13047 _ACEOF
13048
13049
13050 cat >>confdefs.h <<_ACEOF
13051 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
13052 _ACEOF
13053
13054
13055 cat >>confdefs.h <<_ACEOF
13056 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
13057 _ACEOF
13058
13059
13060 cat >>confdefs.h <<_ACEOF
13061 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
13062 _ACEOF
13063
13064
13065 echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
13066 echo $ECHO_N "checking whether gettimeofday takes only one argument... $ECHO_C" >&6
13067 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
13068   echo $ECHO_N "(cached) $ECHO_C" >&6
13069 else
13070   cat >conftest.$ac_ext <<_ACEOF
13071 /* confdefs.h.  */
13072 _ACEOF
13073 cat confdefs.h >>conftest.$ac_ext
13074 cat >>conftest.$ac_ext <<_ACEOF
13075 /* end confdefs.h.  */
13076 #include <sys/time.h>
13077 int
13078 main ()
13079 {
13080 struct timeval *tp;
13081 struct timezone *tzp;
13082 gettimeofday(tp,tzp);
13083   ;
13084   return 0;
13085 }
13086 _ACEOF
13087 rm -f conftest.$ac_objext
13088 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13089   (eval $ac_compile) 2>conftest.er1
13090   ac_status=$?
13091   grep -v '^ *+' conftest.er1 >conftest.err
13092   rm -f conftest.er1
13093   cat conftest.err >&5
13094   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13095   (exit $ac_status); } &&
13096          { ac_try='test -z "$ac_c_werror_flag"
13097                          || test ! -s conftest.err'
13098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13099   (eval $ac_try) 2>&5
13100   ac_status=$?
13101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13102   (exit $ac_status); }; } &&
13103          { ac_try='test -s conftest.$ac_objext'
13104   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13105   (eval $ac_try) 2>&5
13106   ac_status=$?
13107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13108   (exit $ac_status); }; }; then
13109   pgac_cv_func_gettimeofday_1arg=no
13110 else
13111   echo "$as_me: failed program was:" >&5
13112 sed 's/^/| /' conftest.$ac_ext >&5
13113
13114 pgac_cv_func_gettimeofday_1arg=yes
13115 fi
13116 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13117 fi
13118 echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
13119 echo "${ECHO_T}$pgac_cv_func_gettimeofday_1arg" >&6
13120 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
13121
13122 cat >>confdefs.h <<\_ACEOF
13123 #define GETTIMEOFDAY_1ARG
13124 _ACEOF
13125
13126 fi
13127
13128
13129
13130
13131
13132
13133
13134
13135
13136
13137
13138
13139
13140
13141
13142
13143
13144
13145
13146
13147
13148
13149 for ac_func in cbrt dlopen fcvt fdatasync getpeereid memmove poll pstat readlink setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
13150 do
13151 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13152 echo "$as_me:$LINENO: checking for $ac_func" >&5
13153 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13154 if eval "test \"\${$as_ac_var+set}\" = set"; then
13155   echo $ECHO_N "(cached) $ECHO_C" >&6
13156 else
13157   cat >conftest.$ac_ext <<_ACEOF
13158 /* confdefs.h.  */
13159 _ACEOF
13160 cat confdefs.h >>conftest.$ac_ext
13161 cat >>conftest.$ac_ext <<_ACEOF
13162 /* end confdefs.h.  */
13163 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13164    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13165 #define $ac_func innocuous_$ac_func
13166
13167 /* System header to define __stub macros and hopefully few prototypes,
13168     which can conflict with char $ac_func (); below.
13169     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13170     <limits.h> exists even on freestanding compilers.  */
13171
13172 #ifdef __STDC__
13173 # include <limits.h>
13174 #else
13175 # include <assert.h>
13176 #endif
13177
13178 #undef $ac_func
13179
13180 /* Override any gcc2 internal prototype to avoid an error.  */
13181 #ifdef __cplusplus
13182 extern "C"
13183 {
13184 #endif
13185 /* We use char because int might match the return type of a gcc2
13186    builtin and then its argument prototype would still apply.  */
13187 char $ac_func ();
13188 /* The GNU C library defines this for functions which it implements
13189     to always fail with ENOSYS.  Some functions are actually named
13190     something starting with __ and the normal name is an alias.  */
13191 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13192 choke me
13193 #else
13194 char (*f) () = $ac_func;
13195 #endif
13196 #ifdef __cplusplus
13197 }
13198 #endif
13199
13200 int
13201 main ()
13202 {
13203 return f != $ac_func;
13204   ;
13205   return 0;
13206 }
13207 _ACEOF
13208 rm -f conftest.$ac_objext conftest$ac_exeext
13209 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13210   (eval $ac_link) 2>conftest.er1
13211   ac_status=$?
13212   grep -v '^ *+' conftest.er1 >conftest.err
13213   rm -f conftest.er1
13214   cat conftest.err >&5
13215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13216   (exit $ac_status); } &&
13217          { ac_try='test -z "$ac_c_werror_flag"
13218                          || test ! -s conftest.err'
13219   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13220   (eval $ac_try) 2>&5
13221   ac_status=$?
13222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13223   (exit $ac_status); }; } &&
13224          { ac_try='test -s conftest$ac_exeext'
13225   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13226   (eval $ac_try) 2>&5
13227   ac_status=$?
13228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13229   (exit $ac_status); }; }; then
13230   eval "$as_ac_var=yes"
13231 else
13232   echo "$as_me: failed program was:" >&5
13233 sed 's/^/| /' conftest.$ac_ext >&5
13234
13235 eval "$as_ac_var=no"
13236 fi
13237 rm -f conftest.err conftest.$ac_objext \
13238       conftest$ac_exeext conftest.$ac_ext
13239 fi
13240 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13241 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13242 if test `eval echo '${'$as_ac_var'}'` = yes; then
13243   cat >>confdefs.h <<_ACEOF
13244 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13245 _ACEOF
13246
13247 fi
13248 done
13249
13250
13251 echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
13252 echo $ECHO_N "checking whether fdatasync is declared... $ECHO_C" >&6
13253 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
13254   echo $ECHO_N "(cached) $ECHO_C" >&6
13255 else
13256   cat >conftest.$ac_ext <<_ACEOF
13257 /* confdefs.h.  */
13258 _ACEOF
13259 cat confdefs.h >>conftest.$ac_ext
13260 cat >>conftest.$ac_ext <<_ACEOF
13261 /* end confdefs.h.  */
13262 #include <unistd.h>
13263
13264 int
13265 main ()
13266 {
13267 #ifndef fdatasync
13268   char *p = (char *) fdatasync;
13269 #endif
13270
13271   ;
13272   return 0;
13273 }
13274 _ACEOF
13275 rm -f conftest.$ac_objext
13276 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13277   (eval $ac_compile) 2>conftest.er1
13278   ac_status=$?
13279   grep -v '^ *+' conftest.er1 >conftest.err
13280   rm -f conftest.er1
13281   cat conftest.err >&5
13282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13283   (exit $ac_status); } &&
13284          { ac_try='test -z "$ac_c_werror_flag"
13285                          || test ! -s conftest.err'
13286   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13287   (eval $ac_try) 2>&5
13288   ac_status=$?
13289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13290   (exit $ac_status); }; } &&
13291          { ac_try='test -s conftest.$ac_objext'
13292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13293   (eval $ac_try) 2>&5
13294   ac_status=$?
13295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13296   (exit $ac_status); }; }; then
13297   ac_cv_have_decl_fdatasync=yes
13298 else
13299   echo "$as_me: failed program was:" >&5
13300 sed 's/^/| /' conftest.$ac_ext >&5
13301
13302 ac_cv_have_decl_fdatasync=no
13303 fi
13304 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13305 fi
13306 echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
13307 echo "${ECHO_T}$ac_cv_have_decl_fdatasync" >&6
13308 if test $ac_cv_have_decl_fdatasync = yes; then
13309
13310 cat >>confdefs.h <<_ACEOF
13311 #define HAVE_DECL_FDATASYNC 1
13312 _ACEOF
13313
13314
13315 else
13316   cat >>confdefs.h <<_ACEOF
13317 #define HAVE_DECL_FDATASYNC 0
13318 _ACEOF
13319
13320
13321 fi
13322
13323
13324
13325 HAVE_IPV6=no
13326 echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
13327 echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6
13328 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
13329   echo $ECHO_N "(cached) $ECHO_C" >&6
13330 else
13331   cat >conftest.$ac_ext <<_ACEOF
13332 /* confdefs.h.  */
13333 _ACEOF
13334 cat confdefs.h >>conftest.$ac_ext
13335 cat >>conftest.$ac_ext <<_ACEOF
13336 /* end confdefs.h.  */
13337 $ac_includes_default
13338 #include <netinet/in.h>
13339
13340 int
13341 main ()
13342 {
13343 if ((struct sockaddr_in6 *) 0)
13344   return 0;
13345 if (sizeof (struct sockaddr_in6))
13346   return 0;
13347   ;
13348   return 0;
13349 }
13350 _ACEOF
13351 rm -f conftest.$ac_objext
13352 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13353   (eval $ac_compile) 2>conftest.er1
13354   ac_status=$?
13355   grep -v '^ *+' conftest.er1 >conftest.err
13356   rm -f conftest.er1
13357   cat conftest.err >&5
13358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13359   (exit $ac_status); } &&
13360          { ac_try='test -z "$ac_c_werror_flag"
13361                          || test ! -s conftest.err'
13362   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13363   (eval $ac_try) 2>&5
13364   ac_status=$?
13365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13366   (exit $ac_status); }; } &&
13367          { ac_try='test -s conftest.$ac_objext'
13368   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13369   (eval $ac_try) 2>&5
13370   ac_status=$?
13371   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13372   (exit $ac_status); }; }; then
13373   ac_cv_type_struct_sockaddr_in6=yes
13374 else
13375   echo "$as_me: failed program was:" >&5
13376 sed 's/^/| /' conftest.$ac_ext >&5
13377
13378 ac_cv_type_struct_sockaddr_in6=no
13379 fi
13380 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13381 fi
13382 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
13383 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6
13384 if test $ac_cv_type_struct_sockaddr_in6 = yes; then
13385
13386 cat >>confdefs.h <<\_ACEOF
13387 #define HAVE_IPV6 1
13388 _ACEOF
13389
13390          HAVE_IPV6=yes
13391 fi
13392
13393
13394
13395 echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
13396 echo $ECHO_N "checking for PS_STRINGS... $ECHO_C" >&6
13397 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
13398   echo $ECHO_N "(cached) $ECHO_C" >&6
13399 else
13400   cat >conftest.$ac_ext <<_ACEOF
13401 /* confdefs.h.  */
13402 _ACEOF
13403 cat confdefs.h >>conftest.$ac_ext
13404 cat >>conftest.$ac_ext <<_ACEOF
13405 /* end confdefs.h.  */
13406 #include <machine/vmparam.h>
13407 #include <sys/exec.h>
13408
13409 int
13410 main ()
13411 {
13412 PS_STRINGS->ps_nargvstr = 1;
13413 PS_STRINGS->ps_argvstr = "foo";
13414   ;
13415   return 0;
13416 }
13417 _ACEOF
13418 rm -f conftest.$ac_objext conftest$ac_exeext
13419 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13420   (eval $ac_link) 2>conftest.er1
13421   ac_status=$?
13422   grep -v '^ *+' conftest.er1 >conftest.err
13423   rm -f conftest.er1
13424   cat conftest.err >&5
13425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13426   (exit $ac_status); } &&
13427          { ac_try='test -z "$ac_c_werror_flag"
13428                          || test ! -s conftest.err'
13429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13430   (eval $ac_try) 2>&5
13431   ac_status=$?
13432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13433   (exit $ac_status); }; } &&
13434          { ac_try='test -s conftest$ac_exeext'
13435   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13436   (eval $ac_try) 2>&5
13437   ac_status=$?
13438   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13439   (exit $ac_status); }; }; then
13440   pgac_cv_var_PS_STRINGS=yes
13441 else
13442   echo "$as_me: failed program was:" >&5
13443 sed 's/^/| /' conftest.$ac_ext >&5
13444
13445 pgac_cv_var_PS_STRINGS=no
13446 fi
13447 rm -f conftest.err conftest.$ac_objext \
13448       conftest$ac_exeext conftest.$ac_ext
13449 fi
13450 echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
13451 echo "${ECHO_T}$pgac_cv_var_PS_STRINGS" >&6
13452 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
13453
13454 cat >>confdefs.h <<\_ACEOF
13455 #define HAVE_PS_STRINGS
13456 _ACEOF
13457
13458 fi
13459
13460
13461 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
13462 # is missing.  Yes, there are machines that have only one.  We may
13463 # also decide to use snprintf.c if snprintf() is present but does not
13464 # have all the features we need --- see below.
13465
13466 if test "$PORTNAME" = "win32"; then
13467   # Win32 gets snprintf.c built unconditionally.
13468   #
13469   # To properly translate all NLS languages strings, we must support the
13470   # *printf() %$ format, which allows *printf() arguments to be selected
13471   # by position in the translated string.
13472   #
13473   # libintl versions < 0.13 use the native *printf() functions, and Win32
13474   # *printf() doesn't understand %$, so we must use our /port versions,
13475   # which do understand %$. libintl versions >= 0.13 include their own
13476   # *printf versions on Win32.  The libintl 0.13 release note text is:
13477   #
13478   #   C format strings with positions, as they arise when a translator
13479   #   needs to reorder a sentence, are now supported on all platforms.
13480   #   On those few platforms (NetBSD and Woe32) for which the native
13481   #   printf()/fprintf()/... functions don't support such format
13482   #   strings, replacements are provided through <libintl.h>.
13483   #
13484   # We could use libintl >= 0.13's *printf() if we were sure that we had
13485   # a litint >= 0.13 at runtime, but seeing that there is no clean way
13486   # to guarantee that, it is best to just use our own, so we are sure to
13487   # get %$ support. In include/port.h we disable the *printf() macros
13488   # that might have been defined by libintl.
13489   #
13490   # We do this unconditionally whether NLS is used or not so we are sure
13491   # that all Win32 libraries and binaries behave the same.
13492   pgac_need_repl_snprintf=yes
13493 else
13494   pgac_need_repl_snprintf=no
13495
13496 for ac_func in snprintf
13497 do
13498 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13499 echo "$as_me:$LINENO: checking for $ac_func" >&5
13500 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13501 if eval "test \"\${$as_ac_var+set}\" = set"; then
13502   echo $ECHO_N "(cached) $ECHO_C" >&6
13503 else
13504   cat >conftest.$ac_ext <<_ACEOF
13505 /* confdefs.h.  */
13506 _ACEOF
13507 cat confdefs.h >>conftest.$ac_ext
13508 cat >>conftest.$ac_ext <<_ACEOF
13509 /* end confdefs.h.  */
13510 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13511    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13512 #define $ac_func innocuous_$ac_func
13513
13514 /* System header to define __stub macros and hopefully few prototypes,
13515     which can conflict with char $ac_func (); below.
13516     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13517     <limits.h> exists even on freestanding compilers.  */
13518
13519 #ifdef __STDC__
13520 # include <limits.h>
13521 #else
13522 # include <assert.h>
13523 #endif
13524
13525 #undef $ac_func
13526
13527 /* Override any gcc2 internal prototype to avoid an error.  */
13528 #ifdef __cplusplus
13529 extern "C"
13530 {
13531 #endif
13532 /* We use char because int might match the return type of a gcc2
13533    builtin and then its argument prototype would still apply.  */
13534 char $ac_func ();
13535 /* The GNU C library defines this for functions which it implements
13536     to always fail with ENOSYS.  Some functions are actually named
13537     something starting with __ and the normal name is an alias.  */
13538 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13539 choke me
13540 #else
13541 char (*f) () = $ac_func;
13542 #endif
13543 #ifdef __cplusplus
13544 }
13545 #endif
13546
13547 int
13548 main ()
13549 {
13550 return f != $ac_func;
13551   ;
13552   return 0;
13553 }
13554 _ACEOF
13555 rm -f conftest.$ac_objext conftest$ac_exeext
13556 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13557   (eval $ac_link) 2>conftest.er1
13558   ac_status=$?
13559   grep -v '^ *+' conftest.er1 >conftest.err
13560   rm -f conftest.er1
13561   cat conftest.err >&5
13562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13563   (exit $ac_status); } &&
13564          { ac_try='test -z "$ac_c_werror_flag"
13565                          || test ! -s conftest.err'
13566   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13567   (eval $ac_try) 2>&5
13568   ac_status=$?
13569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13570   (exit $ac_status); }; } &&
13571          { ac_try='test -s conftest$ac_exeext'
13572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13573   (eval $ac_try) 2>&5
13574   ac_status=$?
13575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13576   (exit $ac_status); }; }; then
13577   eval "$as_ac_var=yes"
13578 else
13579   echo "$as_me: failed program was:" >&5
13580 sed 's/^/| /' conftest.$ac_ext >&5
13581
13582 eval "$as_ac_var=no"
13583 fi
13584 rm -f conftest.err conftest.$ac_objext \
13585       conftest$ac_exeext conftest.$ac_ext
13586 fi
13587 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13588 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13589 if test `eval echo '${'$as_ac_var'}'` = yes; then
13590   cat >>confdefs.h <<_ACEOF
13591 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13592 _ACEOF
13593
13594 else
13595   pgac_need_repl_snprintf=yes
13596 fi
13597 done
13598
13599
13600 for ac_func in vsnprintf
13601 do
13602 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13603 echo "$as_me:$LINENO: checking for $ac_func" >&5
13604 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13605 if eval "test \"\${$as_ac_var+set}\" = set"; then
13606   echo $ECHO_N "(cached) $ECHO_C" >&6
13607 else
13608   cat >conftest.$ac_ext <<_ACEOF
13609 /* confdefs.h.  */
13610 _ACEOF
13611 cat confdefs.h >>conftest.$ac_ext
13612 cat >>conftest.$ac_ext <<_ACEOF
13613 /* end confdefs.h.  */
13614 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13615    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13616 #define $ac_func innocuous_$ac_func
13617
13618 /* System header to define __stub macros and hopefully few prototypes,
13619     which can conflict with char $ac_func (); below.
13620     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13621     <limits.h> exists even on freestanding compilers.  */
13622
13623 #ifdef __STDC__
13624 # include <limits.h>
13625 #else
13626 # include <assert.h>
13627 #endif
13628
13629 #undef $ac_func
13630
13631 /* Override any gcc2 internal prototype to avoid an error.  */
13632 #ifdef __cplusplus
13633 extern "C"
13634 {
13635 #endif
13636 /* We use char because int might match the return type of a gcc2
13637    builtin and then its argument prototype would still apply.  */
13638 char $ac_func ();
13639 /* The GNU C library defines this for functions which it implements
13640     to always fail with ENOSYS.  Some functions are actually named
13641     something starting with __ and the normal name is an alias.  */
13642 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13643 choke me
13644 #else
13645 char (*f) () = $ac_func;
13646 #endif
13647 #ifdef __cplusplus
13648 }
13649 #endif
13650
13651 int
13652 main ()
13653 {
13654 return f != $ac_func;
13655   ;
13656   return 0;
13657 }
13658 _ACEOF
13659 rm -f conftest.$ac_objext conftest$ac_exeext
13660 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13661   (eval $ac_link) 2>conftest.er1
13662   ac_status=$?
13663   grep -v '^ *+' conftest.er1 >conftest.err
13664   rm -f conftest.er1
13665   cat conftest.err >&5
13666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13667   (exit $ac_status); } &&
13668          { ac_try='test -z "$ac_c_werror_flag"
13669                          || test ! -s conftest.err'
13670   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13671   (eval $ac_try) 2>&5
13672   ac_status=$?
13673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13674   (exit $ac_status); }; } &&
13675          { ac_try='test -s conftest$ac_exeext'
13676   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13677   (eval $ac_try) 2>&5
13678   ac_status=$?
13679   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13680   (exit $ac_status); }; }; then
13681   eval "$as_ac_var=yes"
13682 else
13683   echo "$as_me: failed program was:" >&5
13684 sed 's/^/| /' conftest.$ac_ext >&5
13685
13686 eval "$as_ac_var=no"
13687 fi
13688 rm -f conftest.err conftest.$ac_objext \
13689       conftest$ac_exeext conftest.$ac_ext
13690 fi
13691 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13692 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13693 if test `eval echo '${'$as_ac_var'}'` = yes; then
13694   cat >>confdefs.h <<_ACEOF
13695 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13696 _ACEOF
13697
13698 else
13699   pgac_need_repl_snprintf=yes
13700 fi
13701 done
13702
13703 fi
13704
13705
13706 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
13707 # include/c.h will provide declarations.  Note this is a separate test
13708 # from whether the functions exist in the C library --- there are
13709 # systems that have the functions but don't bother to declare them :-(
13710
13711 echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
13712 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6
13713 if test "${ac_cv_have_decl_snprintf+set}" = set; then
13714   echo $ECHO_N "(cached) $ECHO_C" >&6
13715 else
13716   cat >conftest.$ac_ext <<_ACEOF
13717 /* confdefs.h.  */
13718 _ACEOF
13719 cat confdefs.h >>conftest.$ac_ext
13720 cat >>conftest.$ac_ext <<_ACEOF
13721 /* end confdefs.h.  */
13722 $ac_includes_default
13723 int
13724 main ()
13725 {
13726 #ifndef snprintf
13727   char *p = (char *) snprintf;
13728 #endif
13729
13730   ;
13731   return 0;
13732 }
13733 _ACEOF
13734 rm -f conftest.$ac_objext
13735 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13736   (eval $ac_compile) 2>conftest.er1
13737   ac_status=$?
13738   grep -v '^ *+' conftest.er1 >conftest.err
13739   rm -f conftest.er1
13740   cat conftest.err >&5
13741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13742   (exit $ac_status); } &&
13743          { ac_try='test -z "$ac_c_werror_flag"
13744                          || test ! -s conftest.err'
13745   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13746   (eval $ac_try) 2>&5
13747   ac_status=$?
13748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13749   (exit $ac_status); }; } &&
13750          { ac_try='test -s conftest.$ac_objext'
13751   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13752   (eval $ac_try) 2>&5
13753   ac_status=$?
13754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13755   (exit $ac_status); }; }; then
13756   ac_cv_have_decl_snprintf=yes
13757 else
13758   echo "$as_me: failed program was:" >&5
13759 sed 's/^/| /' conftest.$ac_ext >&5
13760
13761 ac_cv_have_decl_snprintf=no
13762 fi
13763 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13764 fi
13765 echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
13766 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6
13767 if test $ac_cv_have_decl_snprintf = yes; then
13768
13769 cat >>confdefs.h <<_ACEOF
13770 #define HAVE_DECL_SNPRINTF 1
13771 _ACEOF
13772
13773
13774 else
13775   cat >>confdefs.h <<_ACEOF
13776 #define HAVE_DECL_SNPRINTF 0
13777 _ACEOF
13778
13779
13780 fi
13781 echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
13782 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6
13783 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
13784   echo $ECHO_N "(cached) $ECHO_C" >&6
13785 else
13786   cat >conftest.$ac_ext <<_ACEOF
13787 /* confdefs.h.  */
13788 _ACEOF
13789 cat confdefs.h >>conftest.$ac_ext
13790 cat >>conftest.$ac_ext <<_ACEOF
13791 /* end confdefs.h.  */
13792 $ac_includes_default
13793 int
13794 main ()
13795 {
13796 #ifndef vsnprintf
13797   char *p = (char *) vsnprintf;
13798 #endif
13799
13800   ;
13801   return 0;
13802 }
13803 _ACEOF
13804 rm -f conftest.$ac_objext
13805 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13806   (eval $ac_compile) 2>conftest.er1
13807   ac_status=$?
13808   grep -v '^ *+' conftest.er1 >conftest.err
13809   rm -f conftest.er1
13810   cat conftest.err >&5
13811   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13812   (exit $ac_status); } &&
13813          { ac_try='test -z "$ac_c_werror_flag"
13814                          || test ! -s conftest.err'
13815   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13816   (eval $ac_try) 2>&5
13817   ac_status=$?
13818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13819   (exit $ac_status); }; } &&
13820          { ac_try='test -s conftest.$ac_objext'
13821   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13822   (eval $ac_try) 2>&5
13823   ac_status=$?
13824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13825   (exit $ac_status); }; }; then
13826   ac_cv_have_decl_vsnprintf=yes
13827 else
13828   echo "$as_me: failed program was:" >&5
13829 sed 's/^/| /' conftest.$ac_ext >&5
13830
13831 ac_cv_have_decl_vsnprintf=no
13832 fi
13833 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13834 fi
13835 echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
13836 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6
13837 if test $ac_cv_have_decl_vsnprintf = yes; then
13838
13839 cat >>confdefs.h <<_ACEOF
13840 #define HAVE_DECL_VSNPRINTF 1
13841 _ACEOF
13842
13843
13844 else
13845   cat >>confdefs.h <<_ACEOF
13846 #define HAVE_DECL_VSNPRINTF 0
13847 _ACEOF
13848
13849
13850 fi
13851
13852
13853
13854
13855 echo "$as_me:$LINENO: checking for isinf" >&5
13856 echo $ECHO_N "checking for isinf... $ECHO_C" >&6
13857 if test "${ac_cv_func_isinf+set}" = set; then
13858   echo $ECHO_N "(cached) $ECHO_C" >&6
13859 else
13860   cat >conftest.$ac_ext <<_ACEOF
13861 /* confdefs.h.  */
13862 _ACEOF
13863 cat confdefs.h >>conftest.$ac_ext
13864 cat >>conftest.$ac_ext <<_ACEOF
13865 /* end confdefs.h.  */
13866
13867 #include <math.h>
13868 double glob_double;
13869
13870 int
13871 main ()
13872 {
13873 return isinf(glob_double) ? 0 : 1;
13874   ;
13875   return 0;
13876 }
13877 _ACEOF
13878 rm -f conftest.$ac_objext conftest$ac_exeext
13879 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13880   (eval $ac_link) 2>conftest.er1
13881   ac_status=$?
13882   grep -v '^ *+' conftest.er1 >conftest.err
13883   rm -f conftest.er1
13884   cat conftest.err >&5
13885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13886   (exit $ac_status); } &&
13887          { ac_try='test -z "$ac_c_werror_flag"
13888                          || test ! -s conftest.err'
13889   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13890   (eval $ac_try) 2>&5
13891   ac_status=$?
13892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13893   (exit $ac_status); }; } &&
13894          { ac_try='test -s conftest$ac_exeext'
13895   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13896   (eval $ac_try) 2>&5
13897   ac_status=$?
13898   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13899   (exit $ac_status); }; }; then
13900   ac_cv_func_isinf=yes
13901 else
13902   echo "$as_me: failed program was:" >&5
13903 sed 's/^/| /' conftest.$ac_ext >&5
13904
13905 ac_cv_func_isinf=no
13906 fi
13907 rm -f conftest.err conftest.$ac_objext \
13908       conftest$ac_exeext conftest.$ac_ext
13909 fi
13910 echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
13911 echo "${ECHO_T}$ac_cv_func_isinf" >&6
13912
13913 if test $ac_cv_func_isinf = yes ; then
13914
13915 cat >>confdefs.h <<\_ACEOF
13916 #define HAVE_ISINF 1
13917 _ACEOF
13918
13919 else
13920   case $LIBOBJS in
13921     "isinf.$ac_objext"   | \
13922   *" isinf.$ac_objext"   | \
13923     "isinf.$ac_objext "* | \
13924   *" isinf.$ac_objext "* ) ;;
13925   *) LIBOBJS="$LIBOBJS isinf.$ac_objext" ;;
13926 esac
13927
13928   # Look for a way to implement a substitute for isinf()
13929
13930
13931
13932
13933 for ac_func in fpclass fp_class fp_class_d class
13934 do
13935 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13936 echo "$as_me:$LINENO: checking for $ac_func" >&5
13937 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13938 if eval "test \"\${$as_ac_var+set}\" = set"; then
13939   echo $ECHO_N "(cached) $ECHO_C" >&6
13940 else
13941   cat >conftest.$ac_ext <<_ACEOF
13942 /* confdefs.h.  */
13943 _ACEOF
13944 cat confdefs.h >>conftest.$ac_ext
13945 cat >>conftest.$ac_ext <<_ACEOF
13946 /* end confdefs.h.  */
13947 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13948    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13949 #define $ac_func innocuous_$ac_func
13950
13951 /* System header to define __stub macros and hopefully few prototypes,
13952     which can conflict with char $ac_func (); below.
13953     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13954     <limits.h> exists even on freestanding compilers.  */
13955
13956 #ifdef __STDC__
13957 # include <limits.h>
13958 #else
13959 # include <assert.h>
13960 #endif
13961
13962 #undef $ac_func
13963
13964 /* Override any gcc2 internal prototype to avoid an error.  */
13965 #ifdef __cplusplus
13966 extern "C"
13967 {
13968 #endif
13969 /* We use char because int might match the return type of a gcc2
13970    builtin and then its argument prototype would still apply.  */
13971 char $ac_func ();
13972 /* The GNU C library defines this for functions which it implements
13973     to always fail with ENOSYS.  Some functions are actually named
13974     something starting with __ and the normal name is an alias.  */
13975 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13976 choke me
13977 #else
13978 char (*f) () = $ac_func;
13979 #endif
13980 #ifdef __cplusplus
13981 }
13982 #endif
13983
13984 int
13985 main ()
13986 {
13987 return f != $ac_func;
13988   ;
13989   return 0;
13990 }
13991 _ACEOF
13992 rm -f conftest.$ac_objext conftest$ac_exeext
13993 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13994   (eval $ac_link) 2>conftest.er1
13995   ac_status=$?
13996   grep -v '^ *+' conftest.er1 >conftest.err
13997   rm -f conftest.er1
13998   cat conftest.err >&5
13999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14000   (exit $ac_status); } &&
14001          { ac_try='test -z "$ac_c_werror_flag"
14002                          || test ! -s conftest.err'
14003   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14004   (eval $ac_try) 2>&5
14005   ac_status=$?
14006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14007   (exit $ac_status); }; } &&
14008          { ac_try='test -s conftest$ac_exeext'
14009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14010   (eval $ac_try) 2>&5
14011   ac_status=$?
14012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14013   (exit $ac_status); }; }; then
14014   eval "$as_ac_var=yes"
14015 else
14016   echo "$as_me: failed program was:" >&5
14017 sed 's/^/| /' conftest.$ac_ext >&5
14018
14019 eval "$as_ac_var=no"
14020 fi
14021 rm -f conftest.err conftest.$ac_objext \
14022       conftest$ac_exeext conftest.$ac_ext
14023 fi
14024 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14025 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14026 if test `eval echo '${'$as_ac_var'}'` = yes; then
14027   cat >>confdefs.h <<_ACEOF
14028 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14029 _ACEOF
14030  break
14031 fi
14032 done
14033
14034 fi
14035
14036
14037
14038
14039
14040
14041
14042
14043
14044
14045
14046
14047
14048
14049 for ac_func in crypt fseeko getopt getrusage inet_aton random rint srandom strdup strerror strtol strtoul unsetenv
14050 do
14051 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14052 echo "$as_me:$LINENO: checking for $ac_func" >&5
14053 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14054 if eval "test \"\${$as_ac_var+set}\" = set"; then
14055   echo $ECHO_N "(cached) $ECHO_C" >&6
14056 else
14057   cat >conftest.$ac_ext <<_ACEOF
14058 /* confdefs.h.  */
14059 _ACEOF
14060 cat confdefs.h >>conftest.$ac_ext
14061 cat >>conftest.$ac_ext <<_ACEOF
14062 /* end confdefs.h.  */
14063 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14064    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14065 #define $ac_func innocuous_$ac_func
14066
14067 /* System header to define __stub macros and hopefully few prototypes,
14068     which can conflict with char $ac_func (); below.
14069     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14070     <limits.h> exists even on freestanding compilers.  */
14071
14072 #ifdef __STDC__
14073 # include <limits.h>
14074 #else
14075 # include <assert.h>
14076 #endif
14077
14078 #undef $ac_func
14079
14080 /* Override any gcc2 internal prototype to avoid an error.  */
14081 #ifdef __cplusplus
14082 extern "C"
14083 {
14084 #endif
14085 /* We use char because int might match the return type of a gcc2
14086    builtin and then its argument prototype would still apply.  */
14087 char $ac_func ();
14088 /* The GNU C library defines this for functions which it implements
14089     to always fail with ENOSYS.  Some functions are actually named
14090     something starting with __ and the normal name is an alias.  */
14091 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14092 choke me
14093 #else
14094 char (*f) () = $ac_func;
14095 #endif
14096 #ifdef __cplusplus
14097 }
14098 #endif
14099
14100 int
14101 main ()
14102 {
14103 return f != $ac_func;
14104   ;
14105   return 0;
14106 }
14107 _ACEOF
14108 rm -f conftest.$ac_objext conftest$ac_exeext
14109 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14110   (eval $ac_link) 2>conftest.er1
14111   ac_status=$?
14112   grep -v '^ *+' conftest.er1 >conftest.err
14113   rm -f conftest.er1
14114   cat conftest.err >&5
14115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14116   (exit $ac_status); } &&
14117          { ac_try='test -z "$ac_c_werror_flag"
14118                          || test ! -s conftest.err'
14119   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14120   (eval $ac_try) 2>&5
14121   ac_status=$?
14122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14123   (exit $ac_status); }; } &&
14124          { ac_try='test -s conftest$ac_exeext'
14125   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14126   (eval $ac_try) 2>&5
14127   ac_status=$?
14128   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14129   (exit $ac_status); }; }; then
14130   eval "$as_ac_var=yes"
14131 else
14132   echo "$as_me: failed program was:" >&5
14133 sed 's/^/| /' conftest.$ac_ext >&5
14134
14135 eval "$as_ac_var=no"
14136 fi
14137 rm -f conftest.err conftest.$ac_objext \
14138       conftest$ac_exeext conftest.$ac_ext
14139 fi
14140 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14141 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14142 if test `eval echo '${'$as_ac_var'}'` = yes; then
14143   cat >>confdefs.h <<_ACEOF
14144 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14145 _ACEOF
14146
14147 else
14148   case $LIBOBJS in
14149     "$ac_func.$ac_objext"   | \
14150   *" $ac_func.$ac_objext"   | \
14151     "$ac_func.$ac_objext "* | \
14152   *" $ac_func.$ac_objext "* ) ;;
14153   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14154 esac
14155
14156 fi
14157 done
14158
14159
14160
14161 # System's version of getaddrinfo(), if any, may be used only if we found
14162 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
14163 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
14164 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
14165 # because we want to use our own getaddrinfo.c on Windows anyway.)
14166 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
14167
14168 for ac_func in getaddrinfo
14169 do
14170 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14171 echo "$as_me:$LINENO: checking for $ac_func" >&5
14172 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14173 if eval "test \"\${$as_ac_var+set}\" = set"; then
14174   echo $ECHO_N "(cached) $ECHO_C" >&6
14175 else
14176   cat >conftest.$ac_ext <<_ACEOF
14177 /* confdefs.h.  */
14178 _ACEOF
14179 cat confdefs.h >>conftest.$ac_ext
14180 cat >>conftest.$ac_ext <<_ACEOF
14181 /* end confdefs.h.  */
14182 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14183    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14184 #define $ac_func innocuous_$ac_func
14185
14186 /* System header to define __stub macros and hopefully few prototypes,
14187     which can conflict with char $ac_func (); below.
14188     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14189     <limits.h> exists even on freestanding compilers.  */
14190
14191 #ifdef __STDC__
14192 # include <limits.h>
14193 #else
14194 # include <assert.h>
14195 #endif
14196
14197 #undef $ac_func
14198
14199 /* Override any gcc2 internal prototype to avoid an error.  */
14200 #ifdef __cplusplus
14201 extern "C"
14202 {
14203 #endif
14204 /* We use char because int might match the return type of a gcc2
14205    builtin and then its argument prototype would still apply.  */
14206 char $ac_func ();
14207 /* The GNU C library defines this for functions which it implements
14208     to always fail with ENOSYS.  Some functions are actually named
14209     something starting with __ and the normal name is an alias.  */
14210 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14211 choke me
14212 #else
14213 char (*f) () = $ac_func;
14214 #endif
14215 #ifdef __cplusplus
14216 }
14217 #endif
14218
14219 int
14220 main ()
14221 {
14222 return f != $ac_func;
14223   ;
14224   return 0;
14225 }
14226 _ACEOF
14227 rm -f conftest.$ac_objext conftest$ac_exeext
14228 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14229   (eval $ac_link) 2>conftest.er1
14230   ac_status=$?
14231   grep -v '^ *+' conftest.er1 >conftest.err
14232   rm -f conftest.er1
14233   cat conftest.err >&5
14234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14235   (exit $ac_status); } &&
14236          { ac_try='test -z "$ac_c_werror_flag"
14237                          || test ! -s conftest.err'
14238   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14239   (eval $ac_try) 2>&5
14240   ac_status=$?
14241   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14242   (exit $ac_status); }; } &&
14243          { ac_try='test -s conftest$ac_exeext'
14244   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14245   (eval $ac_try) 2>&5
14246   ac_status=$?
14247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14248   (exit $ac_status); }; }; then
14249   eval "$as_ac_var=yes"
14250 else
14251   echo "$as_me: failed program was:" >&5
14252 sed 's/^/| /' conftest.$ac_ext >&5
14253
14254 eval "$as_ac_var=no"
14255 fi
14256 rm -f conftest.err conftest.$ac_objext \
14257       conftest$ac_exeext conftest.$ac_ext
14258 fi
14259 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14260 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14261 if test `eval echo '${'$as_ac_var'}'` = yes; then
14262   cat >>confdefs.h <<_ACEOF
14263 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14264 _ACEOF
14265
14266 else
14267   case $LIBOBJS in
14268     "$ac_func.$ac_objext"   | \
14269   *" $ac_func.$ac_objext"   | \
14270     "$ac_func.$ac_objext "* | \
14271   *" $ac_func.$ac_objext "* ) ;;
14272   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14273 esac
14274
14275 fi
14276 done
14277
14278
14279 else
14280   case $LIBOBJS in
14281     "getaddrinfo.$ac_objext"   | \
14282   *" getaddrinfo.$ac_objext"   | \
14283     "getaddrinfo.$ac_objext "* | \
14284   *" getaddrinfo.$ac_objext "* ) ;;
14285   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext" ;;
14286 esac
14287
14288 fi
14289
14290 # similarly, use system's getopt_long() only if system provides struct option.
14291 if test x"$ac_cv_type_struct_option" = xyes ; then
14292
14293 for ac_func in getopt_long
14294 do
14295 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14296 echo "$as_me:$LINENO: checking for $ac_func" >&5
14297 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14298 if eval "test \"\${$as_ac_var+set}\" = set"; then
14299   echo $ECHO_N "(cached) $ECHO_C" >&6
14300 else
14301   cat >conftest.$ac_ext <<_ACEOF
14302 /* confdefs.h.  */
14303 _ACEOF
14304 cat confdefs.h >>conftest.$ac_ext
14305 cat >>conftest.$ac_ext <<_ACEOF
14306 /* end confdefs.h.  */
14307 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14308    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14309 #define $ac_func innocuous_$ac_func
14310
14311 /* System header to define __stub macros and hopefully few prototypes,
14312     which can conflict with char $ac_func (); below.
14313     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14314     <limits.h> exists even on freestanding compilers.  */
14315
14316 #ifdef __STDC__
14317 # include <limits.h>
14318 #else
14319 # include <assert.h>
14320 #endif
14321
14322 #undef $ac_func
14323
14324 /* Override any gcc2 internal prototype to avoid an error.  */
14325 #ifdef __cplusplus
14326 extern "C"
14327 {
14328 #endif
14329 /* We use char because int might match the return type of a gcc2
14330    builtin and then its argument prototype would still apply.  */
14331 char $ac_func ();
14332 /* The GNU C library defines this for functions which it implements
14333     to always fail with ENOSYS.  Some functions are actually named
14334     something starting with __ and the normal name is an alias.  */
14335 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14336 choke me
14337 #else
14338 char (*f) () = $ac_func;
14339 #endif
14340 #ifdef __cplusplus
14341 }
14342 #endif
14343
14344 int
14345 main ()
14346 {
14347 return f != $ac_func;
14348   ;
14349   return 0;
14350 }
14351 _ACEOF
14352 rm -f conftest.$ac_objext conftest$ac_exeext
14353 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14354   (eval $ac_link) 2>conftest.er1
14355   ac_status=$?
14356   grep -v '^ *+' conftest.er1 >conftest.err
14357   rm -f conftest.er1
14358   cat conftest.err >&5
14359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14360   (exit $ac_status); } &&
14361          { ac_try='test -z "$ac_c_werror_flag"
14362                          || test ! -s conftest.err'
14363   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14364   (eval $ac_try) 2>&5
14365   ac_status=$?
14366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14367   (exit $ac_status); }; } &&
14368          { ac_try='test -s conftest$ac_exeext'
14369   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14370   (eval $ac_try) 2>&5
14371   ac_status=$?
14372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14373   (exit $ac_status); }; }; then
14374   eval "$as_ac_var=yes"
14375 else
14376   echo "$as_me: failed program was:" >&5
14377 sed 's/^/| /' conftest.$ac_ext >&5
14378
14379 eval "$as_ac_var=no"
14380 fi
14381 rm -f conftest.err conftest.$ac_objext \
14382       conftest$ac_exeext conftest.$ac_ext
14383 fi
14384 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14385 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14386 if test `eval echo '${'$as_ac_var'}'` = yes; then
14387   cat >>confdefs.h <<_ACEOF
14388 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14389 _ACEOF
14390
14391 else
14392   case $LIBOBJS in
14393     "$ac_func.$ac_objext"   | \
14394   *" $ac_func.$ac_objext"   | \
14395     "$ac_func.$ac_objext "* | \
14396   *" $ac_func.$ac_objext "* ) ;;
14397   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14398 esac
14399
14400 fi
14401 done
14402
14403
14404 else
14405   case $LIBOBJS in
14406     "getopt_long.$ac_objext"   | \
14407   *" getopt_long.$ac_objext"   | \
14408     "getopt_long.$ac_objext "* | \
14409   *" getopt_long.$ac_objext "* ) ;;
14410   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext" ;;
14411 esac
14412
14413 fi
14414
14415 # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
14416 # We override the previous test that said fseeko/ftello didn't exist
14417 # OS tests are also done in include/c.h and port/fseeko.c
14418 case $host_os in bsdi*|netbsd*)
14419 ac_cv_func_fseeko=yes
14420 esac
14421
14422 # Solaris has a very slow qsort in certain cases, so we replace it:
14423 #   http://forum.sun.com/thread.jspa?forumID=4&threadID=7231
14424 # Supposedly it is fixed in Solaris, but not sure which version, and
14425 # no confirmed testing.  2005-12-16
14426 if test "$PORTNAME" = "solaris"; then
14427 case $LIBOBJS in
14428     "qsort.$ac_objext"   | \
14429   *" qsort.$ac_objext"   | \
14430     "qsort.$ac_objext "* | \
14431   *" qsort.$ac_objext "* ) ;;
14432   *) LIBOBJS="$LIBOBJS qsort.$ac_objext" ;;
14433 esac
14434
14435 fi
14436
14437 # Win32 support
14438 if test "$PORTNAME" = "win32"; then
14439 case $LIBOBJS in
14440     "gettimeofday.$ac_objext"   | \
14441   *" gettimeofday.$ac_objext"   | \
14442     "gettimeofday.$ac_objext "* | \
14443   *" gettimeofday.$ac_objext "* ) ;;
14444   *) LIBOBJS="$LIBOBJS gettimeofday.$ac_objext" ;;
14445 esac
14446
14447 case $LIBOBJS in
14448     "kill.$ac_objext"   | \
14449   *" kill.$ac_objext"   | \
14450     "kill.$ac_objext "* | \
14451   *" kill.$ac_objext "* ) ;;
14452   *) LIBOBJS="$LIBOBJS kill.$ac_objext" ;;
14453 esac
14454
14455 case $LIBOBJS in
14456     "open.$ac_objext"   | \
14457   *" open.$ac_objext"   | \
14458     "open.$ac_objext "* | \
14459   *" open.$ac_objext "* ) ;;
14460   *) LIBOBJS="$LIBOBJS open.$ac_objext" ;;
14461 esac
14462
14463 case $LIBOBJS in
14464     "rand.$ac_objext"   | \
14465   *" rand.$ac_objext"   | \
14466     "rand.$ac_objext "* | \
14467   *" rand.$ac_objext "* ) ;;
14468   *) LIBOBJS="$LIBOBJS rand.$ac_objext" ;;
14469 esac
14470
14471
14472 cat >>confdefs.h <<\_ACEOF
14473 #define HAVE_SYMLINK 1
14474 _ACEOF
14475
14476 fi
14477
14478 if test "$with_readline" = yes; then
14479   echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
14480 echo $ECHO_N "checking for rl_completion_append_character... $ECHO_C" >&6
14481 cat >conftest.$ac_ext <<_ACEOF
14482 /* confdefs.h.  */
14483 _ACEOF
14484 cat confdefs.h >>conftest.$ac_ext
14485 cat >>conftest.$ac_ext <<_ACEOF
14486 /* end confdefs.h.  */
14487 #include <stdio.h>
14488 #ifdef HAVE_READLINE_READLINE_H
14489 # include <readline/readline.h>
14490 #elif defined(HAVE_READLINE_H)
14491 # include <readline.h>
14492 #endif
14493
14494 int
14495 main ()
14496 {
14497 rl_completion_append_character = 'x';
14498   ;
14499   return 0;
14500 }
14501 _ACEOF
14502 rm -f conftest.$ac_objext conftest$ac_exeext
14503 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14504   (eval $ac_link) 2>conftest.er1
14505   ac_status=$?
14506   grep -v '^ *+' conftest.er1 >conftest.err
14507   rm -f conftest.er1
14508   cat conftest.err >&5
14509   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14510   (exit $ac_status); } &&
14511          { ac_try='test -z "$ac_c_werror_flag"
14512                          || test ! -s conftest.err'
14513   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14514   (eval $ac_try) 2>&5
14515   ac_status=$?
14516   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14517   (exit $ac_status); }; } &&
14518          { ac_try='test -s conftest$ac_exeext'
14519   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14520   (eval $ac_try) 2>&5
14521   ac_status=$?
14522   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14523   (exit $ac_status); }; }; then
14524   echo "$as_me:$LINENO: result: yes" >&5
14525 echo "${ECHO_T}yes" >&6
14526
14527 cat >>confdefs.h <<\_ACEOF
14528 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
14529 _ACEOF
14530
14531 else
14532   echo "$as_me: failed program was:" >&5
14533 sed 's/^/| /' conftest.$ac_ext >&5
14534
14535 echo "$as_me:$LINENO: result: no" >&5
14536 echo "${ECHO_T}no" >&6
14537 fi
14538 rm -f conftest.err conftest.$ac_objext \
14539       conftest$ac_exeext conftest.$ac_ext
14540
14541
14542 for ac_func in rl_completion_matches rl_filename_completion_function
14543 do
14544 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14545 echo "$as_me:$LINENO: checking for $ac_func" >&5
14546 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14547 if eval "test \"\${$as_ac_var+set}\" = set"; then
14548   echo $ECHO_N "(cached) $ECHO_C" >&6
14549 else
14550   cat >conftest.$ac_ext <<_ACEOF
14551 /* confdefs.h.  */
14552 _ACEOF
14553 cat confdefs.h >>conftest.$ac_ext
14554 cat >>conftest.$ac_ext <<_ACEOF
14555 /* end confdefs.h.  */
14556 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14557    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14558 #define $ac_func innocuous_$ac_func
14559
14560 /* System header to define __stub macros and hopefully few prototypes,
14561     which can conflict with char $ac_func (); below.
14562     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14563     <limits.h> exists even on freestanding compilers.  */
14564
14565 #ifdef __STDC__
14566 # include <limits.h>
14567 #else
14568 # include <assert.h>
14569 #endif
14570
14571 #undef $ac_func
14572
14573 /* Override any gcc2 internal prototype to avoid an error.  */
14574 #ifdef __cplusplus
14575 extern "C"
14576 {
14577 #endif
14578 /* We use char because int might match the return type of a gcc2
14579    builtin and then its argument prototype would still apply.  */
14580 char $ac_func ();
14581 /* The GNU C library defines this for functions which it implements
14582     to always fail with ENOSYS.  Some functions are actually named
14583     something starting with __ and the normal name is an alias.  */
14584 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14585 choke me
14586 #else
14587 char (*f) () = $ac_func;
14588 #endif
14589 #ifdef __cplusplus
14590 }
14591 #endif
14592
14593 int
14594 main ()
14595 {
14596 return f != $ac_func;
14597   ;
14598   return 0;
14599 }
14600 _ACEOF
14601 rm -f conftest.$ac_objext conftest$ac_exeext
14602 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14603   (eval $ac_link) 2>conftest.er1
14604   ac_status=$?
14605   grep -v '^ *+' conftest.er1 >conftest.err
14606   rm -f conftest.er1
14607   cat conftest.err >&5
14608   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14609   (exit $ac_status); } &&
14610          { ac_try='test -z "$ac_c_werror_flag"
14611                          || test ! -s conftest.err'
14612   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14613   (eval $ac_try) 2>&5
14614   ac_status=$?
14615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14616   (exit $ac_status); }; } &&
14617          { ac_try='test -s conftest$ac_exeext'
14618   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14619   (eval $ac_try) 2>&5
14620   ac_status=$?
14621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14622   (exit $ac_status); }; }; then
14623   eval "$as_ac_var=yes"
14624 else
14625   echo "$as_me: failed program was:" >&5
14626 sed 's/^/| /' conftest.$ac_ext >&5
14627
14628 eval "$as_ac_var=no"
14629 fi
14630 rm -f conftest.err conftest.$ac_objext \
14631       conftest$ac_exeext conftest.$ac_ext
14632 fi
14633 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14634 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14635 if test `eval echo '${'$as_ac_var'}'` = yes; then
14636   cat >>confdefs.h <<_ACEOF
14637 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14638 _ACEOF
14639
14640 fi
14641 done
14642
14643
14644 for ac_func in replace_history_entry
14645 do
14646 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14647 echo "$as_me:$LINENO: checking for $ac_func" >&5
14648 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14649 if eval "test \"\${$as_ac_var+set}\" = set"; then
14650   echo $ECHO_N "(cached) $ECHO_C" >&6
14651 else
14652   cat >conftest.$ac_ext <<_ACEOF
14653 /* confdefs.h.  */
14654 _ACEOF
14655 cat confdefs.h >>conftest.$ac_ext
14656 cat >>conftest.$ac_ext <<_ACEOF
14657 /* end confdefs.h.  */
14658 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14659    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14660 #define $ac_func innocuous_$ac_func
14661
14662 /* System header to define __stub macros and hopefully few prototypes,
14663     which can conflict with char $ac_func (); below.
14664     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14665     <limits.h> exists even on freestanding compilers.  */
14666
14667 #ifdef __STDC__
14668 # include <limits.h>
14669 #else
14670 # include <assert.h>
14671 #endif
14672
14673 #undef $ac_func
14674
14675 /* Override any gcc2 internal prototype to avoid an error.  */
14676 #ifdef __cplusplus
14677 extern "C"
14678 {
14679 #endif
14680 /* We use char because int might match the return type of a gcc2
14681    builtin and then its argument prototype would still apply.  */
14682 char $ac_func ();
14683 /* The GNU C library defines this for functions which it implements
14684     to always fail with ENOSYS.  Some functions are actually named
14685     something starting with __ and the normal name is an alias.  */
14686 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14687 choke me
14688 #else
14689 char (*f) () = $ac_func;
14690 #endif
14691 #ifdef __cplusplus
14692 }
14693 #endif
14694
14695 int
14696 main ()
14697 {
14698 return f != $ac_func;
14699   ;
14700   return 0;
14701 }
14702 _ACEOF
14703 rm -f conftest.$ac_objext conftest$ac_exeext
14704 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14705   (eval $ac_link) 2>conftest.er1
14706   ac_status=$?
14707   grep -v '^ *+' conftest.er1 >conftest.err
14708   rm -f conftest.er1
14709   cat conftest.err >&5
14710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14711   (exit $ac_status); } &&
14712          { ac_try='test -z "$ac_c_werror_flag"
14713                          || test ! -s conftest.err'
14714   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14715   (eval $ac_try) 2>&5
14716   ac_status=$?
14717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14718   (exit $ac_status); }; } &&
14719          { ac_try='test -s conftest$ac_exeext'
14720   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14721   (eval $ac_try) 2>&5
14722   ac_status=$?
14723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14724   (exit $ac_status); }; }; then
14725   eval "$as_ac_var=yes"
14726 else
14727   echo "$as_me: failed program was:" >&5
14728 sed 's/^/| /' conftest.$ac_ext >&5
14729
14730 eval "$as_ac_var=no"
14731 fi
14732 rm -f conftest.err conftest.$ac_objext \
14733       conftest$ac_exeext conftest.$ac_ext
14734 fi
14735 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14736 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14737 if test `eval echo '${'$as_ac_var'}'` = yes; then
14738   cat >>confdefs.h <<_ACEOF
14739 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14740 _ACEOF
14741
14742 fi
14743 done
14744
14745 fi
14746
14747
14748 echo "$as_me:$LINENO: checking for finite" >&5
14749 echo $ECHO_N "checking for finite... $ECHO_C" >&6
14750 cat >conftest.$ac_ext <<_ACEOF
14751 /* confdefs.h.  */
14752 _ACEOF
14753 cat confdefs.h >>conftest.$ac_ext
14754 cat >>conftest.$ac_ext <<_ACEOF
14755 /* end confdefs.h.  */
14756
14757 #include <math.h>
14758 double glob_double;
14759
14760 int
14761 main ()
14762 {
14763 return finite(glob_double) ? 0 : 1;
14764   ;
14765   return 0;
14766 }
14767 _ACEOF
14768 rm -f conftest.$ac_objext conftest$ac_exeext
14769 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14770   (eval $ac_link) 2>conftest.er1
14771   ac_status=$?
14772   grep -v '^ *+' conftest.er1 >conftest.err
14773   rm -f conftest.er1
14774   cat conftest.err >&5
14775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14776   (exit $ac_status); } &&
14777          { ac_try='test -z "$ac_c_werror_flag"
14778                          || test ! -s conftest.err'
14779   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14780   (eval $ac_try) 2>&5
14781   ac_status=$?
14782   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14783   (exit $ac_status); }; } &&
14784          { ac_try='test -s conftest$ac_exeext'
14785   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14786   (eval $ac_try) 2>&5
14787   ac_status=$?
14788   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14789   (exit $ac_status); }; }; then
14790
14791 cat >>confdefs.h <<\_ACEOF
14792 #define HAVE_FINITE 1
14793 _ACEOF
14794
14795 echo "$as_me:$LINENO: result: yes" >&5
14796 echo "${ECHO_T}yes" >&6
14797 else
14798   echo "$as_me: failed program was:" >&5
14799 sed 's/^/| /' conftest.$ac_ext >&5
14800
14801 echo "$as_me:$LINENO: result: no" >&5
14802 echo "${ECHO_T}no" >&6
14803 fi
14804 rm -f conftest.err conftest.$ac_objext \
14805       conftest$ac_exeext conftest.$ac_ext
14806
14807 echo "$as_me:$LINENO: checking for sigsetjmp" >&5
14808 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6
14809 cat >conftest.$ac_ext <<_ACEOF
14810 /* confdefs.h.  */
14811 _ACEOF
14812 cat confdefs.h >>conftest.$ac_ext
14813 cat >>conftest.$ac_ext <<_ACEOF
14814 /* end confdefs.h.  */
14815 #include <setjmp.h>
14816 int
14817 main ()
14818 {
14819 sigjmp_buf x; sigsetjmp(x, 1);
14820   ;
14821   return 0;
14822 }
14823 _ACEOF
14824 rm -f conftest.$ac_objext conftest$ac_exeext
14825 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14826   (eval $ac_link) 2>conftest.er1
14827   ac_status=$?
14828   grep -v '^ *+' conftest.er1 >conftest.err
14829   rm -f conftest.er1
14830   cat conftest.err >&5
14831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14832   (exit $ac_status); } &&
14833          { ac_try='test -z "$ac_c_werror_flag"
14834                          || test ! -s conftest.err'
14835   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14836   (eval $ac_try) 2>&5
14837   ac_status=$?
14838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14839   (exit $ac_status); }; } &&
14840          { ac_try='test -s conftest$ac_exeext'
14841   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14842   (eval $ac_try) 2>&5
14843   ac_status=$?
14844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14845   (exit $ac_status); }; }; then
14846
14847 cat >>confdefs.h <<\_ACEOF
14848 #define HAVE_SIGSETJMP 1
14849 _ACEOF
14850
14851 echo "$as_me:$LINENO: result: yes" >&5
14852 echo "${ECHO_T}yes" >&6
14853 else
14854   echo "$as_me: failed program was:" >&5
14855 sed 's/^/| /' conftest.$ac_ext >&5
14856
14857 echo "$as_me:$LINENO: result: no" >&5
14858 echo "${ECHO_T}no" >&6
14859 fi
14860 rm -f conftest.err conftest.$ac_objext \
14861       conftest$ac_exeext conftest.$ac_ext
14862
14863 echo "$as_me:$LINENO: checking for syslog" >&5
14864 echo $ECHO_N "checking for syslog... $ECHO_C" >&6
14865 if test "${ac_cv_func_syslog+set}" = set; then
14866   echo $ECHO_N "(cached) $ECHO_C" >&6
14867 else
14868   cat >conftest.$ac_ext <<_ACEOF
14869 /* confdefs.h.  */
14870 _ACEOF
14871 cat confdefs.h >>conftest.$ac_ext
14872 cat >>conftest.$ac_ext <<_ACEOF
14873 /* end confdefs.h.  */
14874 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
14875    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14876 #define syslog innocuous_syslog
14877
14878 /* System header to define __stub macros and hopefully few prototypes,
14879     which can conflict with char syslog (); below.
14880     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14881     <limits.h> exists even on freestanding compilers.  */
14882
14883 #ifdef __STDC__
14884 # include <limits.h>
14885 #else
14886 # include <assert.h>
14887 #endif
14888
14889 #undef syslog
14890
14891 /* Override any gcc2 internal prototype to avoid an error.  */
14892 #ifdef __cplusplus
14893 extern "C"
14894 {
14895 #endif
14896 /* We use char because int might match the return type of a gcc2
14897    builtin and then its argument prototype would still apply.  */
14898 char syslog ();
14899 /* The GNU C library defines this for functions which it implements
14900     to always fail with ENOSYS.  Some functions are actually named
14901     something starting with __ and the normal name is an alias.  */
14902 #if defined (__stub_syslog) || defined (__stub___syslog)
14903 choke me
14904 #else
14905 char (*f) () = syslog;
14906 #endif
14907 #ifdef __cplusplus
14908 }
14909 #endif
14910
14911 int
14912 main ()
14913 {
14914 return f != syslog;
14915   ;
14916   return 0;
14917 }
14918 _ACEOF
14919 rm -f conftest.$ac_objext conftest$ac_exeext
14920 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14921   (eval $ac_link) 2>conftest.er1
14922   ac_status=$?
14923   grep -v '^ *+' conftest.er1 >conftest.err
14924   rm -f conftest.er1
14925   cat conftest.err >&5
14926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14927   (exit $ac_status); } &&
14928          { ac_try='test -z "$ac_c_werror_flag"
14929                          || test ! -s conftest.err'
14930   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14931   (eval $ac_try) 2>&5
14932   ac_status=$?
14933   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14934   (exit $ac_status); }; } &&
14935          { ac_try='test -s conftest$ac_exeext'
14936   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14937   (eval $ac_try) 2>&5
14938   ac_status=$?
14939   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14940   (exit $ac_status); }; }; then
14941   ac_cv_func_syslog=yes
14942 else
14943   echo "$as_me: failed program was:" >&5
14944 sed 's/^/| /' conftest.$ac_ext >&5
14945
14946 ac_cv_func_syslog=no
14947 fi
14948 rm -f conftest.err conftest.$ac_objext \
14949       conftest$ac_exeext conftest.$ac_ext
14950 fi
14951 echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
14952 echo "${ECHO_T}$ac_cv_func_syslog" >&6
14953 if test $ac_cv_func_syslog = yes; then
14954   if test "${ac_cv_header_syslog_h+set}" = set; then
14955   echo "$as_me:$LINENO: checking for syslog.h" >&5
14956 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
14957 if test "${ac_cv_header_syslog_h+set}" = set; then
14958   echo $ECHO_N "(cached) $ECHO_C" >&6
14959 fi
14960 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
14961 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
14962 else
14963   # Is the header compilable?
14964 echo "$as_me:$LINENO: checking syslog.h usability" >&5
14965 echo $ECHO_N "checking syslog.h usability... $ECHO_C" >&6
14966 cat >conftest.$ac_ext <<_ACEOF
14967 /* confdefs.h.  */
14968 _ACEOF
14969 cat confdefs.h >>conftest.$ac_ext
14970 cat >>conftest.$ac_ext <<_ACEOF
14971 /* end confdefs.h.  */
14972 $ac_includes_default
14973 #include <syslog.h>
14974 _ACEOF
14975 rm -f conftest.$ac_objext
14976 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14977   (eval $ac_compile) 2>conftest.er1
14978   ac_status=$?
14979   grep -v '^ *+' conftest.er1 >conftest.err
14980   rm -f conftest.er1
14981   cat conftest.err >&5
14982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14983   (exit $ac_status); } &&
14984          { ac_try='test -z "$ac_c_werror_flag"
14985                          || test ! -s conftest.err'
14986   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14987   (eval $ac_try) 2>&5
14988   ac_status=$?
14989   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14990   (exit $ac_status); }; } &&
14991          { ac_try='test -s conftest.$ac_objext'
14992   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14993   (eval $ac_try) 2>&5
14994   ac_status=$?
14995   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14996   (exit $ac_status); }; }; then
14997   ac_header_compiler=yes
14998 else
14999   echo "$as_me: failed program was:" >&5
15000 sed 's/^/| /' conftest.$ac_ext >&5
15001
15002 ac_header_compiler=no
15003 fi
15004 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15005 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15006 echo "${ECHO_T}$ac_header_compiler" >&6
15007
15008 # Is the header present?
15009 echo "$as_me:$LINENO: checking syslog.h presence" >&5
15010 echo $ECHO_N "checking syslog.h presence... $ECHO_C" >&6
15011 cat >conftest.$ac_ext <<_ACEOF
15012 /* confdefs.h.  */
15013 _ACEOF
15014 cat confdefs.h >>conftest.$ac_ext
15015 cat >>conftest.$ac_ext <<_ACEOF
15016 /* end confdefs.h.  */
15017 #include <syslog.h>
15018 _ACEOF
15019 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15020   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15021   ac_status=$?
15022   grep -v '^ *+' conftest.er1 >conftest.err
15023   rm -f conftest.er1
15024   cat conftest.err >&5
15025   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15026   (exit $ac_status); } >/dev/null; then
15027   if test -s conftest.err; then
15028     ac_cpp_err=$ac_c_preproc_warn_flag
15029     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15030   else
15031     ac_cpp_err=
15032   fi
15033 else
15034   ac_cpp_err=yes
15035 fi
15036 if test -z "$ac_cpp_err"; then
15037   ac_header_preproc=yes
15038 else
15039   echo "$as_me: failed program was:" >&5
15040 sed 's/^/| /' conftest.$ac_ext >&5
15041
15042   ac_header_preproc=no
15043 fi
15044 rm -f conftest.err conftest.$ac_ext
15045 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15046 echo "${ECHO_T}$ac_header_preproc" >&6
15047
15048 # So?  What about this header?
15049 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15050   yes:no: )
15051     { echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
15052 echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15053     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
15054 echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
15055     ac_header_preproc=yes
15056     ;;
15057   no:yes:* )
15058     { echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
15059 echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
15060     { echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
15061 echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
15062     { echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
15063 echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
15064     { echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
15065 echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
15066     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
15067 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
15068     { echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
15069 echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
15070     (
15071       cat <<\_ASBOX
15072 ## ---------------------------------------- ##
15073 ## Report this to pgsql-bugs@postgresql.org ##
15074 ## ---------------------------------------- ##
15075 _ASBOX
15076     ) |
15077       sed "s/^/$as_me: WARNING:     /" >&2
15078     ;;
15079 esac
15080 echo "$as_me:$LINENO: checking for syslog.h" >&5
15081 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
15082 if test "${ac_cv_header_syslog_h+set}" = set; then
15083   echo $ECHO_N "(cached) $ECHO_C" >&6
15084 else
15085   ac_cv_header_syslog_h=$ac_header_preproc
15086 fi
15087 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
15088 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
15089
15090 fi
15091 if test $ac_cv_header_syslog_h = yes; then
15092
15093 cat >>confdefs.h <<\_ACEOF
15094 #define HAVE_SYSLOG 1
15095 _ACEOF
15096
15097 fi
15098
15099
15100 fi
15101
15102
15103 echo "$as_me:$LINENO: checking for optreset" >&5
15104 echo $ECHO_N "checking for optreset... $ECHO_C" >&6
15105 if test "${pgac_cv_var_int_optreset+set}" = set; then
15106   echo $ECHO_N "(cached) $ECHO_C" >&6
15107 else
15108   cat >conftest.$ac_ext <<_ACEOF
15109 /* confdefs.h.  */
15110 _ACEOF
15111 cat confdefs.h >>conftest.$ac_ext
15112 cat >>conftest.$ac_ext <<_ACEOF
15113 /* end confdefs.h.  */
15114 #include <unistd.h>
15115 int
15116 main ()
15117 {
15118 extern int optreset; optreset = 1;
15119   ;
15120   return 0;
15121 }
15122 _ACEOF
15123 rm -f conftest.$ac_objext conftest$ac_exeext
15124 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15125   (eval $ac_link) 2>conftest.er1
15126   ac_status=$?
15127   grep -v '^ *+' conftest.er1 >conftest.err
15128   rm -f conftest.er1
15129   cat conftest.err >&5
15130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15131   (exit $ac_status); } &&
15132          { ac_try='test -z "$ac_c_werror_flag"
15133                          || test ! -s conftest.err'
15134   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15135   (eval $ac_try) 2>&5
15136   ac_status=$?
15137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15138   (exit $ac_status); }; } &&
15139          { ac_try='test -s conftest$ac_exeext'
15140   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15141   (eval $ac_try) 2>&5
15142   ac_status=$?
15143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15144   (exit $ac_status); }; }; then
15145   pgac_cv_var_int_optreset=yes
15146 else
15147   echo "$as_me: failed program was:" >&5
15148 sed 's/^/| /' conftest.$ac_ext >&5
15149
15150 pgac_cv_var_int_optreset=no
15151 fi
15152 rm -f conftest.err conftest.$ac_objext \
15153       conftest$ac_exeext conftest.$ac_ext
15154 fi
15155 echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
15156 echo "${ECHO_T}$pgac_cv_var_int_optreset" >&6
15157 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
15158
15159 cat >>confdefs.h <<\_ACEOF
15160 #define HAVE_INT_OPTRESET 1
15161 _ACEOF
15162
15163 fi
15164
15165
15166
15167 for ac_func in strtoll strtoq
15168 do
15169 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15170 echo "$as_me:$LINENO: checking for $ac_func" >&5
15171 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15172 if eval "test \"\${$as_ac_var+set}\" = set"; then
15173   echo $ECHO_N "(cached) $ECHO_C" >&6
15174 else
15175   cat >conftest.$ac_ext <<_ACEOF
15176 /* confdefs.h.  */
15177 _ACEOF
15178 cat confdefs.h >>conftest.$ac_ext
15179 cat >>conftest.$ac_ext <<_ACEOF
15180 /* end confdefs.h.  */
15181 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15182    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15183 #define $ac_func innocuous_$ac_func
15184
15185 /* System header to define __stub macros and hopefully few prototypes,
15186     which can conflict with char $ac_func (); below.
15187     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15188     <limits.h> exists even on freestanding compilers.  */
15189
15190 #ifdef __STDC__
15191 # include <limits.h>
15192 #else
15193 # include <assert.h>
15194 #endif
15195
15196 #undef $ac_func
15197
15198 /* Override any gcc2 internal prototype to avoid an error.  */
15199 #ifdef __cplusplus
15200 extern "C"
15201 {
15202 #endif
15203 /* We use char because int might match the return type of a gcc2
15204    builtin and then its argument prototype would still apply.  */
15205 char $ac_func ();
15206 /* The GNU C library defines this for functions which it implements
15207     to always fail with ENOSYS.  Some functions are actually named
15208     something starting with __ and the normal name is an alias.  */
15209 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15210 choke me
15211 #else
15212 char (*f) () = $ac_func;
15213 #endif
15214 #ifdef __cplusplus
15215 }
15216 #endif
15217
15218 int
15219 main ()
15220 {
15221 return f != $ac_func;
15222   ;
15223   return 0;
15224 }
15225 _ACEOF
15226 rm -f conftest.$ac_objext conftest$ac_exeext
15227 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15228   (eval $ac_link) 2>conftest.er1
15229   ac_status=$?
15230   grep -v '^ *+' conftest.er1 >conftest.err
15231   rm -f conftest.er1
15232   cat conftest.err >&5
15233   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15234   (exit $ac_status); } &&
15235          { ac_try='test -z "$ac_c_werror_flag"
15236                          || test ! -s conftest.err'
15237   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15238   (eval $ac_try) 2>&5
15239   ac_status=$?
15240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15241   (exit $ac_status); }; } &&
15242          { ac_try='test -s conftest$ac_exeext'
15243   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15244   (eval $ac_try) 2>&5
15245   ac_status=$?
15246   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15247   (exit $ac_status); }; }; then
15248   eval "$as_ac_var=yes"
15249 else
15250   echo "$as_me: failed program was:" >&5
15251 sed 's/^/| /' conftest.$ac_ext >&5
15252
15253 eval "$as_ac_var=no"
15254 fi
15255 rm -f conftest.err conftest.$ac_objext \
15256       conftest$ac_exeext conftest.$ac_ext
15257 fi
15258 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15259 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15260 if test `eval echo '${'$as_ac_var'}'` = yes; then
15261   cat >>confdefs.h <<_ACEOF
15262 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15263 _ACEOF
15264  break
15265 fi
15266 done
15267
15268
15269
15270 for ac_func in strtoull strtouq
15271 do
15272 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15273 echo "$as_me:$LINENO: checking for $ac_func" >&5
15274 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15275 if eval "test \"\${$as_ac_var+set}\" = set"; then
15276   echo $ECHO_N "(cached) $ECHO_C" >&6
15277 else
15278   cat >conftest.$ac_ext <<_ACEOF
15279 /* confdefs.h.  */
15280 _ACEOF
15281 cat confdefs.h >>conftest.$ac_ext
15282 cat >>conftest.$ac_ext <<_ACEOF
15283 /* end confdefs.h.  */
15284 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15285    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15286 #define $ac_func innocuous_$ac_func
15287
15288 /* System header to define __stub macros and hopefully few prototypes,
15289     which can conflict with char $ac_func (); below.
15290     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15291     <limits.h> exists even on freestanding compilers.  */
15292
15293 #ifdef __STDC__
15294 # include <limits.h>
15295 #else
15296 # include <assert.h>
15297 #endif
15298
15299 #undef $ac_func
15300
15301 /* Override any gcc2 internal prototype to avoid an error.  */
15302 #ifdef __cplusplus
15303 extern "C"
15304 {
15305 #endif
15306 /* We use char because int might match the return type of a gcc2
15307    builtin and then its argument prototype would still apply.  */
15308 char $ac_func ();
15309 /* The GNU C library defines this for functions which it implements
15310     to always fail with ENOSYS.  Some functions are actually named
15311     something starting with __ and the normal name is an alias.  */
15312 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15313 choke me
15314 #else
15315 char (*f) () = $ac_func;
15316 #endif
15317 #ifdef __cplusplus
15318 }
15319 #endif
15320
15321 int
15322 main ()
15323 {
15324 return f != $ac_func;
15325   ;
15326   return 0;
15327 }
15328 _ACEOF
15329 rm -f conftest.$ac_objext conftest$ac_exeext
15330 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15331   (eval $ac_link) 2>conftest.er1
15332   ac_status=$?
15333   grep -v '^ *+' conftest.er1 >conftest.err
15334   rm -f conftest.er1
15335   cat conftest.err >&5
15336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15337   (exit $ac_status); } &&
15338          { ac_try='test -z "$ac_c_werror_flag"
15339                          || test ! -s conftest.err'
15340   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15341   (eval $ac_try) 2>&5
15342   ac_status=$?
15343   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15344   (exit $ac_status); }; } &&
15345          { ac_try='test -s conftest$ac_exeext'
15346   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15347   (eval $ac_try) 2>&5
15348   ac_status=$?
15349   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15350   (exit $ac_status); }; }; then
15351   eval "$as_ac_var=yes"
15352 else
15353   echo "$as_me: failed program was:" >&5
15354 sed 's/^/| /' conftest.$ac_ext >&5
15355
15356 eval "$as_ac_var=no"
15357 fi
15358 rm -f conftest.err conftest.$ac_objext \
15359       conftest$ac_exeext conftest.$ac_ext
15360 fi
15361 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15362 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15363 if test `eval echo '${'$as_ac_var'}'` = yes; then
15364   cat >>confdefs.h <<_ACEOF
15365 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15366 _ACEOF
15367  break
15368 fi
15369 done
15370
15371
15372 # Check for one of atexit() or on_exit()
15373
15374 for ac_func in atexit
15375 do
15376 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15377 echo "$as_me:$LINENO: checking for $ac_func" >&5
15378 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15379 if eval "test \"\${$as_ac_var+set}\" = set"; then
15380   echo $ECHO_N "(cached) $ECHO_C" >&6
15381 else
15382   cat >conftest.$ac_ext <<_ACEOF
15383 /* confdefs.h.  */
15384 _ACEOF
15385 cat confdefs.h >>conftest.$ac_ext
15386 cat >>conftest.$ac_ext <<_ACEOF
15387 /* end confdefs.h.  */
15388 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15389    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15390 #define $ac_func innocuous_$ac_func
15391
15392 /* System header to define __stub macros and hopefully few prototypes,
15393     which can conflict with char $ac_func (); below.
15394     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15395     <limits.h> exists even on freestanding compilers.  */
15396
15397 #ifdef __STDC__
15398 # include <limits.h>
15399 #else
15400 # include <assert.h>
15401 #endif
15402
15403 #undef $ac_func
15404
15405 /* Override any gcc2 internal prototype to avoid an error.  */
15406 #ifdef __cplusplus
15407 extern "C"
15408 {
15409 #endif
15410 /* We use char because int might match the return type of a gcc2
15411    builtin and then its argument prototype would still apply.  */
15412 char $ac_func ();
15413 /* The GNU C library defines this for functions which it implements
15414     to always fail with ENOSYS.  Some functions are actually named
15415     something starting with __ and the normal name is an alias.  */
15416 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15417 choke me
15418 #else
15419 char (*f) () = $ac_func;
15420 #endif
15421 #ifdef __cplusplus
15422 }
15423 #endif
15424
15425 int
15426 main ()
15427 {
15428 return f != $ac_func;
15429   ;
15430   return 0;
15431 }
15432 _ACEOF
15433 rm -f conftest.$ac_objext conftest$ac_exeext
15434 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15435   (eval $ac_link) 2>conftest.er1
15436   ac_status=$?
15437   grep -v '^ *+' conftest.er1 >conftest.err
15438   rm -f conftest.er1
15439   cat conftest.err >&5
15440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15441   (exit $ac_status); } &&
15442          { ac_try='test -z "$ac_c_werror_flag"
15443                          || test ! -s conftest.err'
15444   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15445   (eval $ac_try) 2>&5
15446   ac_status=$?
15447   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15448   (exit $ac_status); }; } &&
15449          { ac_try='test -s conftest$ac_exeext'
15450   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15451   (eval $ac_try) 2>&5
15452   ac_status=$?
15453   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15454   (exit $ac_status); }; }; then
15455   eval "$as_ac_var=yes"
15456 else
15457   echo "$as_me: failed program was:" >&5
15458 sed 's/^/| /' conftest.$ac_ext >&5
15459
15460 eval "$as_ac_var=no"
15461 fi
15462 rm -f conftest.err conftest.$ac_objext \
15463       conftest$ac_exeext conftest.$ac_ext
15464 fi
15465 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15466 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15467 if test `eval echo '${'$as_ac_var'}'` = yes; then
15468   cat >>confdefs.h <<_ACEOF
15469 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15470 _ACEOF
15471
15472 else
15473
15474 for ac_func in on_exit
15475 do
15476 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15477 echo "$as_me:$LINENO: checking for $ac_func" >&5
15478 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15479 if eval "test \"\${$as_ac_var+set}\" = set"; then
15480   echo $ECHO_N "(cached) $ECHO_C" >&6
15481 else
15482   cat >conftest.$ac_ext <<_ACEOF
15483 /* confdefs.h.  */
15484 _ACEOF
15485 cat confdefs.h >>conftest.$ac_ext
15486 cat >>conftest.$ac_ext <<_ACEOF
15487 /* end confdefs.h.  */
15488 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15489    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15490 #define $ac_func innocuous_$ac_func
15491
15492 /* System header to define __stub macros and hopefully few prototypes,
15493     which can conflict with char $ac_func (); below.
15494     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15495     <limits.h> exists even on freestanding compilers.  */
15496
15497 #ifdef __STDC__
15498 # include <limits.h>
15499 #else
15500 # include <assert.h>
15501 #endif
15502
15503 #undef $ac_func
15504
15505 /* Override any gcc2 internal prototype to avoid an error.  */
15506 #ifdef __cplusplus
15507 extern "C"
15508 {
15509 #endif
15510 /* We use char because int might match the return type of a gcc2
15511    builtin and then its argument prototype would still apply.  */
15512 char $ac_func ();
15513 /* The GNU C library defines this for functions which it implements
15514     to always fail with ENOSYS.  Some functions are actually named
15515     something starting with __ and the normal name is an alias.  */
15516 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15517 choke me
15518 #else
15519 char (*f) () = $ac_func;
15520 #endif
15521 #ifdef __cplusplus
15522 }
15523 #endif
15524
15525 int
15526 main ()
15527 {
15528 return f != $ac_func;
15529   ;
15530   return 0;
15531 }
15532 _ACEOF
15533 rm -f conftest.$ac_objext conftest$ac_exeext
15534 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15535   (eval $ac_link) 2>conftest.er1
15536   ac_status=$?
15537   grep -v '^ *+' conftest.er1 >conftest.err
15538   rm -f conftest.er1
15539   cat conftest.err >&5
15540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15541   (exit $ac_status); } &&
15542          { ac_try='test -z "$ac_c_werror_flag"
15543                          || test ! -s conftest.err'
15544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15545   (eval $ac_try) 2>&5
15546   ac_status=$?
15547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15548   (exit $ac_status); }; } &&
15549          { ac_try='test -s conftest$ac_exeext'
15550   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15551   (eval $ac_try) 2>&5
15552   ac_status=$?
15553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15554   (exit $ac_status); }; }; then
15555   eval "$as_ac_var=yes"
15556 else
15557   echo "$as_me: failed program was:" >&5
15558 sed 's/^/| /' conftest.$ac_ext >&5
15559
15560 eval "$as_ac_var=no"
15561 fi
15562 rm -f conftest.err conftest.$ac_objext \
15563       conftest$ac_exeext conftest.$ac_ext
15564 fi
15565 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15566 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15567 if test `eval echo '${'$as_ac_var'}'` = yes; then
15568   cat >>confdefs.h <<_ACEOF
15569 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15570 _ACEOF
15571
15572 else
15573   { { echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
15574 echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
15575    { (exit 1); exit 1; }; }
15576 fi
15577 done
15578
15579 fi
15580 done
15581
15582
15583 echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15584 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
15585 if test "${ac_cv_sys_largefile_source+set}" = set; then
15586   echo $ECHO_N "(cached) $ECHO_C" >&6
15587 else
15588   while :; do
15589   ac_cv_sys_largefile_source=no
15590   cat >conftest.$ac_ext <<_ACEOF
15591 /* confdefs.h.  */
15592 _ACEOF
15593 cat confdefs.h >>conftest.$ac_ext
15594 cat >>conftest.$ac_ext <<_ACEOF
15595 /* end confdefs.h.  */
15596 #include <stdio.h>
15597 int
15598 main ()
15599 {
15600 return !fseeko;
15601   ;
15602   return 0;
15603 }
15604 _ACEOF
15605 rm -f conftest.$ac_objext
15606 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15607   (eval $ac_compile) 2>conftest.er1
15608   ac_status=$?
15609   grep -v '^ *+' conftest.er1 >conftest.err
15610   rm -f conftest.er1
15611   cat conftest.err >&5
15612   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15613   (exit $ac_status); } &&
15614          { ac_try='test -z "$ac_c_werror_flag"
15615                          || test ! -s conftest.err'
15616   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15617   (eval $ac_try) 2>&5
15618   ac_status=$?
15619   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15620   (exit $ac_status); }; } &&
15621          { ac_try='test -s conftest.$ac_objext'
15622   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15623   (eval $ac_try) 2>&5
15624   ac_status=$?
15625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15626   (exit $ac_status); }; }; then
15627   break
15628 else
15629   echo "$as_me: failed program was:" >&5
15630 sed 's/^/| /' conftest.$ac_ext >&5
15631
15632 fi
15633 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15634   cat >conftest.$ac_ext <<_ACEOF
15635 /* confdefs.h.  */
15636 _ACEOF
15637 cat confdefs.h >>conftest.$ac_ext
15638 cat >>conftest.$ac_ext <<_ACEOF
15639 /* end confdefs.h.  */
15640 #define _LARGEFILE_SOURCE 1
15641 #include <stdio.h>
15642 int
15643 main ()
15644 {
15645 return !fseeko;
15646   ;
15647   return 0;
15648 }
15649 _ACEOF
15650 rm -f conftest.$ac_objext
15651 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15652   (eval $ac_compile) 2>conftest.er1
15653   ac_status=$?
15654   grep -v '^ *+' conftest.er1 >conftest.err
15655   rm -f conftest.er1
15656   cat conftest.err >&5
15657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15658   (exit $ac_status); } &&
15659          { ac_try='test -z "$ac_c_werror_flag"
15660                          || test ! -s conftest.err'
15661   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15662   (eval $ac_try) 2>&5
15663   ac_status=$?
15664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15665   (exit $ac_status); }; } &&
15666          { ac_try='test -s conftest.$ac_objext'
15667   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15668   (eval $ac_try) 2>&5
15669   ac_status=$?
15670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15671   (exit $ac_status); }; }; then
15672   ac_cv_sys_largefile_source=1; break
15673 else
15674   echo "$as_me: failed program was:" >&5
15675 sed 's/^/| /' conftest.$ac_ext >&5
15676
15677 fi
15678 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15679   break
15680 done
15681 fi
15682 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
15683 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
15684 if test "$ac_cv_sys_largefile_source" != no; then
15685
15686 cat >>confdefs.h <<_ACEOF
15687 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15688 _ACEOF
15689
15690 fi
15691 rm -f conftest*
15692
15693 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15694 # in glibc 2.1.3, but that breaks too many other things.
15695 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15696 echo "$as_me:$LINENO: checking for fseeko" >&5
15697 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
15698 if test "${ac_cv_func_fseeko+set}" = set; then
15699   echo $ECHO_N "(cached) $ECHO_C" >&6
15700 else
15701   cat >conftest.$ac_ext <<_ACEOF
15702 /* confdefs.h.  */
15703 _ACEOF
15704 cat confdefs.h >>conftest.$ac_ext
15705 cat >>conftest.$ac_ext <<_ACEOF
15706 /* end confdefs.h.  */
15707 #include <stdio.h>
15708 int
15709 main ()
15710 {
15711 return fseeko && fseeko (stdin, 0, 0);
15712   ;
15713   return 0;
15714 }
15715 _ACEOF
15716 rm -f conftest.$ac_objext conftest$ac_exeext
15717 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15718   (eval $ac_link) 2>conftest.er1
15719   ac_status=$?
15720   grep -v '^ *+' conftest.er1 >conftest.err
15721   rm -f conftest.er1
15722   cat conftest.err >&5
15723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15724   (exit $ac_status); } &&
15725          { ac_try='test -z "$ac_c_werror_flag"
15726                          || test ! -s conftest.err'
15727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15728   (eval $ac_try) 2>&5
15729   ac_status=$?
15730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15731   (exit $ac_status); }; } &&
15732          { ac_try='test -s conftest$ac_exeext'
15733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15734   (eval $ac_try) 2>&5
15735   ac_status=$?
15736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15737   (exit $ac_status); }; }; then
15738   ac_cv_func_fseeko=yes
15739 else
15740   echo "$as_me: failed program was:" >&5
15741 sed 's/^/| /' conftest.$ac_ext >&5
15742
15743 ac_cv_func_fseeko=no
15744 fi
15745 rm -f conftest.err conftest.$ac_objext \
15746       conftest$ac_exeext conftest.$ac_ext
15747 fi
15748 echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
15749 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
15750 if test $ac_cv_func_fseeko = yes; then
15751
15752 cat >>confdefs.h <<\_ACEOF
15753 #define HAVE_FSEEKO 1
15754 _ACEOF
15755
15756 fi
15757
15758
15759 #
15760 # Pthreads
15761 #
15762 # For each platform, we need to know about any special compile and link
15763 # libraries, and whether the normal C function names are thread-safe.
15764 # See the comment at the top of src/port/thread.c for more information.
15765 #
15766 if test "$enable_thread_safety" = yes; then
15767
15768
15769
15770
15771 ac_ext=c
15772 ac_cpp='$CPP $CPPFLAGS'
15773 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15774 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15775 ac_compiler_gnu=$ac_cv_c_compiler_gnu
15776
15777 acx_pthread_ok=no
15778
15779 # We used to check for pthread.h first, but this fails if pthread.h
15780 # requires special compiler flags (e.g. on True64 or Sequent).
15781 # It gets checked for in the link test anyway.
15782
15783 # First of all, check if the user has set any of the PTHREAD_LIBS,
15784 # etcetera environment variables, and if threads linking works using
15785 # them:
15786 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
15787         save_CFLAGS="$CFLAGS"
15788         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
15789         save_LIBS="$LIBS"
15790         LIBS="$PTHREAD_LIBS $LIBS"
15791         echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
15792 echo $ECHO_N "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... $ECHO_C" >&6
15793         cat >conftest.$ac_ext <<_ACEOF
15794 /* confdefs.h.  */
15795 _ACEOF
15796 cat confdefs.h >>conftest.$ac_ext
15797 cat >>conftest.$ac_ext <<_ACEOF
15798 /* end confdefs.h.  */
15799
15800 /* Override any gcc2 internal prototype to avoid an error.  */
15801 #ifdef __cplusplus
15802 extern "C"
15803 #endif
15804 /* We use char because int might match the return type of a gcc2
15805    builtin and then its argument prototype would still apply.  */
15806 char pthread_join ();
15807 int
15808 main ()
15809 {
15810 pthread_join ();
15811   ;
15812   return 0;
15813 }
15814 _ACEOF
15815 rm -f conftest.$ac_objext conftest$ac_exeext
15816 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15817   (eval $ac_link) 2>conftest.er1
15818   ac_status=$?
15819   grep -v '^ *+' conftest.er1 >conftest.err
15820   rm -f conftest.er1
15821   cat conftest.err >&5
15822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15823   (exit $ac_status); } &&
15824          { ac_try='test -z "$ac_c_werror_flag"
15825                          || test ! -s conftest.err'
15826   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15827   (eval $ac_try) 2>&5
15828   ac_status=$?
15829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15830   (exit $ac_status); }; } &&
15831          { ac_try='test -s conftest$ac_exeext'
15832   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15833   (eval $ac_try) 2>&5
15834   ac_status=$?
15835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15836   (exit $ac_status); }; }; then
15837   acx_pthread_ok=yes
15838 else
15839   echo "$as_me: failed program was:" >&5
15840 sed 's/^/| /' conftest.$ac_ext >&5
15841
15842 fi
15843 rm -f conftest.err conftest.$ac_objext \
15844       conftest$ac_exeext conftest.$ac_ext
15845         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
15846 echo "${ECHO_T}$acx_pthread_ok" >&6
15847         if test x"$acx_pthread_ok" = xno; then
15848                 PTHREAD_LIBS=""
15849                 PTHREAD_CFLAGS=""
15850         fi
15851         LIBS="$save_LIBS"
15852         CFLAGS="$save_CFLAGS"
15853 fi
15854
15855 # We must check for the threads library under a number of different
15856 # names; the ordering is very important because some systems
15857 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
15858 # libraries is broken (non-POSIX).
15859
15860 # Create a list of thread flags to try.  Items starting with a "-" are
15861 # C compiler flags, and other items are library names, except for "none"
15862 # which indicates that we try without any flags at all, and "pthread-config"
15863 # which is a program returning the flags for the Pth emulation library.
15864
15865 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
15866
15867 # The ordering *is* (sometimes) important.  Some notes on the
15868 # individual items follow:
15869
15870 # pthreads: AIX (must check this before -lpthread)
15871 # none: in case threads are in libc; should be tried before -Kthread and
15872 #       other compiler flags to prevent continual compiler warnings
15873 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
15874 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
15875 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
15876 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
15877 # -pthreads: Solaris/gcc
15878 # -mthreads: Mingw32/gcc, Lynx/gcc
15879 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
15880 #      doesn't hurt to check since this sometimes defines pthreads too;
15881 #      also defines -D_REENTRANT)
15882 # pthread: Linux, etcetera
15883 # --thread-safe: KAI C++
15884 # pthread-config: use pthread-config program (for GNU Pth library)
15885
15886 case "${host_cpu}-${host_os}" in
15887         *solaris*)
15888
15889         # On Solaris (at least, for some versions), libc contains stubbed
15890         # (non-functional) versions of the pthreads routines, so link-based
15891         # tests will erroneously succeed.  (We need to link with -pthread or
15892         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
15893         # a function called by this macro, so we could check for that, but
15894         # who knows whether they'll stub that too in a future libc.)  So,
15895         # we'll just look for -pthreads and -lpthread first:
15896
15897         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
15898         ;;
15899 esac
15900
15901 if test x"$acx_pthread_ok" = xno; then
15902 for flag in $acx_pthread_flags; do
15903
15904         tryPTHREAD_CFLAGS=""
15905         tryPTHREAD_LIBS=""
15906         case $flag in
15907                 none)
15908                 echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
15909 echo $ECHO_N "checking whether pthreads work without any flags... $ECHO_C" >&6
15910                 ;;
15911
15912                 -*)
15913                 echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
15914 echo $ECHO_N "checking whether pthreads work with $flag... $ECHO_C" >&6
15915                 tryPTHREAD_CFLAGS="$flag"
15916                 ;;
15917
15918                 pthread-config)
15919                 # skip this if we already have flags defined, for PostgreSQL
15920                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
15921                 # Extract the first word of "pthread-config", so it can be a program name with args.
15922 set dummy pthread-config; ac_word=$2
15923 echo "$as_me:$LINENO: checking for $ac_word" >&5
15924 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15925 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
15926   echo $ECHO_N "(cached) $ECHO_C" >&6
15927 else
15928   if test -n "$acx_pthread_config"; then
15929   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
15930 else
15931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15932 for as_dir in $PATH
15933 do
15934   IFS=$as_save_IFS
15935   test -z "$as_dir" && as_dir=.
15936   for ac_exec_ext in '' $ac_executable_extensions; do
15937   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15938     ac_cv_prog_acx_pthread_config="yes"
15939     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15940     break 2
15941   fi
15942 done
15943 done
15944
15945   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
15946 fi
15947 fi
15948 acx_pthread_config=$ac_cv_prog_acx_pthread_config
15949 if test -n "$acx_pthread_config"; then
15950   echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
15951 echo "${ECHO_T}$acx_pthread_config" >&6
15952 else
15953   echo "$as_me:$LINENO: result: no" >&5
15954 echo "${ECHO_T}no" >&6
15955 fi
15956
15957                 if test x"$acx_pthread_config" = xno; then continue; fi
15958                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
15959                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
15960                 ;;
15961
15962                 *)
15963                 echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
15964 echo $ECHO_N "checking for the pthreads library -l$flag... $ECHO_C" >&6
15965                 tryPTHREAD_LIBS="-l$flag"
15966                 ;;
15967         esac
15968
15969         save_LIBS="$LIBS"
15970         save_CFLAGS="$CFLAGS"
15971         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
15972         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
15973
15974         # Check for various functions.  We must include pthread.h,
15975         # since some functions may be macros.  (On the Sequent, we
15976         # need a special flag -Kthread to make this header compile.)
15977         # We check for pthread_join because it is in -lpthread on IRIX
15978         # while pthread_create is in libc.  We check for pthread_attr_init
15979         # due to DEC craziness with -lpthreads.  We check for
15980         # pthread_cleanup_push because it is one of the few pthread
15981         # functions on Solaris that doesn't have a non-functional libc stub.
15982         # We try pthread_create on general principles.
15983         cat >conftest.$ac_ext <<_ACEOF
15984 /* confdefs.h.  */
15985 _ACEOF
15986 cat confdefs.h >>conftest.$ac_ext
15987 cat >>conftest.$ac_ext <<_ACEOF
15988 /* end confdefs.h.  */
15989 #include <pthread.h>
15990 int
15991 main ()
15992 {
15993 pthread_t th; pthread_join(th, 0);
15994                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
15995                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
15996   ;
15997   return 0;
15998 }
15999 _ACEOF
16000 rm -f conftest.$ac_objext conftest$ac_exeext
16001 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16002   (eval $ac_link) 2>conftest.er1
16003   ac_status=$?
16004   grep -v '^ *+' conftest.er1 >conftest.err
16005   rm -f conftest.er1
16006   cat conftest.err >&5
16007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16008   (exit $ac_status); } &&
16009          { ac_try='test -z "$ac_c_werror_flag"
16010                          || test ! -s conftest.err'
16011   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16012   (eval $ac_try) 2>&5
16013   ac_status=$?
16014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16015   (exit $ac_status); }; } &&
16016          { ac_try='test -s conftest$ac_exeext'
16017   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16018   (eval $ac_try) 2>&5
16019   ac_status=$?
16020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16021   (exit $ac_status); }; }; then
16022   acx_pthread_ok=yes
16023 else
16024   echo "$as_me: failed program was:" >&5
16025 sed 's/^/| /' conftest.$ac_ext >&5
16026
16027 acx_pthread_ok=no
16028 fi
16029 rm -f conftest.err conftest.$ac_objext \
16030       conftest$ac_exeext conftest.$ac_ext
16031
16032         if test "x$acx_pthread_ok" = xyes; then
16033             # Don't use options that are ignored by the compiler.
16034             # We find them by checking stderror.
16035             cat >conftest.$ac_ext <<_ACEOF
16036 int
16037 main (int argc, char **argv)
16038 {
16039   (void) argc;
16040   (void) argv;
16041   return 0;
16042 }
16043 _ACEOF
16044             rm -f conftest.$ac_objext conftest$ac_exeext
16045             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
16046                 # we continue with more flags because Linux needs -lpthread
16047                 # for libpq builds on PostgreSQL.  The test above only
16048                 # tests for building binaries, not shared libraries.
16049                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
16050                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
16051             else   acx_pthread_ok=no
16052             fi
16053         fi
16054
16055         LIBS="$save_LIBS"
16056         CFLAGS="$save_CFLAGS"
16057
16058         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
16059 echo "${ECHO_T}$acx_pthread_ok" >&6
16060 done
16061 fi
16062
16063 # Various other checks:
16064 if test "x$acx_pthread_ok" = xyes; then
16065         save_LIBS="$LIBS"
16066         LIBS="$PTHREAD_LIBS $LIBS"
16067         save_CFLAGS="$CFLAGS"
16068         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16069
16070         # Detect AIX lossage: threads are created detached by default
16071         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
16072         echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
16073 echo $ECHO_N "checking for joinable pthread attribute... $ECHO_C" >&6
16074         cat >conftest.$ac_ext <<_ACEOF
16075 /* confdefs.h.  */
16076 _ACEOF
16077 cat confdefs.h >>conftest.$ac_ext
16078 cat >>conftest.$ac_ext <<_ACEOF
16079 /* end confdefs.h.  */
16080 #include <pthread.h>
16081 int
16082 main ()
16083 {
16084 int attr=PTHREAD_CREATE_JOINABLE;
16085   ;
16086   return 0;
16087 }
16088 _ACEOF
16089 rm -f conftest.$ac_objext conftest$ac_exeext
16090 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16091   (eval $ac_link) 2>conftest.er1
16092   ac_status=$?
16093   grep -v '^ *+' conftest.er1 >conftest.err
16094   rm -f conftest.er1
16095   cat conftest.err >&5
16096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16097   (exit $ac_status); } &&
16098          { ac_try='test -z "$ac_c_werror_flag"
16099                          || test ! -s conftest.err'
16100   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16101   (eval $ac_try) 2>&5
16102   ac_status=$?
16103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16104   (exit $ac_status); }; } &&
16105          { ac_try='test -s conftest$ac_exeext'
16106   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16107   (eval $ac_try) 2>&5
16108   ac_status=$?
16109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16110   (exit $ac_status); }; }; then
16111   ok=PTHREAD_CREATE_JOINABLE
16112 else
16113   echo "$as_me: failed program was:" >&5
16114 sed 's/^/| /' conftest.$ac_ext >&5
16115
16116 ok=unknown
16117 fi
16118 rm -f conftest.err conftest.$ac_objext \
16119       conftest$ac_exeext conftest.$ac_ext
16120         if test x"$ok" = xunknown; then
16121                 cat >conftest.$ac_ext <<_ACEOF
16122 /* confdefs.h.  */
16123 _ACEOF
16124 cat confdefs.h >>conftest.$ac_ext
16125 cat >>conftest.$ac_ext <<_ACEOF
16126 /* end confdefs.h.  */
16127 #include <pthread.h>
16128 int
16129 main ()
16130 {
16131 int attr=PTHREAD_CREATE_UNDETACHED;
16132   ;
16133   return 0;
16134 }
16135 _ACEOF
16136 rm -f conftest.$ac_objext conftest$ac_exeext
16137 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16138   (eval $ac_link) 2>conftest.er1
16139   ac_status=$?
16140   grep -v '^ *+' conftest.er1 >conftest.err
16141   rm -f conftest.er1
16142   cat conftest.err >&5
16143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16144   (exit $ac_status); } &&
16145          { ac_try='test -z "$ac_c_werror_flag"
16146                          || test ! -s conftest.err'
16147   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16148   (eval $ac_try) 2>&5
16149   ac_status=$?
16150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16151   (exit $ac_status); }; } &&
16152          { ac_try='test -s conftest$ac_exeext'
16153   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16154   (eval $ac_try) 2>&5
16155   ac_status=$?
16156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16157   (exit $ac_status); }; }; then
16158   ok=PTHREAD_CREATE_UNDETACHED
16159 else
16160   echo "$as_me: failed program was:" >&5
16161 sed 's/^/| /' conftest.$ac_ext >&5
16162
16163 ok=unknown
16164 fi
16165 rm -f conftest.err conftest.$ac_objext \
16166       conftest$ac_exeext conftest.$ac_ext
16167         fi
16168         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
16169
16170 cat >>confdefs.h <<\_ACEOF
16171 #define PTHREAD_CREATE_JOINABLE $ok
16172 _ACEOF
16173
16174         fi
16175         echo "$as_me:$LINENO: result: ${ok}" >&5
16176 echo "${ECHO_T}${ok}" >&6
16177         if test x"$ok" = xunknown; then
16178                 { echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
16179 echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
16180         fi
16181
16182         echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
16183 echo $ECHO_N "checking if more special flags are required for pthreads... $ECHO_C" >&6
16184         flag=no
16185 # We always add these in PostgreSQL
16186 #       case "${host_cpu}-${host_os}" in
16187 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
16188 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
16189 #       esac
16190         echo "$as_me:$LINENO: result: ${flag}" >&5
16191 echo "${ECHO_T}${flag}" >&6
16192         if test "x$flag" != xno; then
16193                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
16194         fi
16195
16196         LIBS="$save_LIBS"
16197         CFLAGS="$save_CFLAGS"
16198
16199 # Supporting cc_r would require a special CC in all places that
16200 # use libpq, and that is ugly, so we don't do it.  Users can still
16201 # define their compiler as cc_r to do thread builds of everything.
16202         # More AIX lossage: must compile with cc_r
16203         # Extract the first word of "cc_r", so it can be a program name with args.
16204 set dummy cc_r; ac_word=$2
16205 echo "$as_me:$LINENO: checking for $ac_word" >&5
16206 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16207 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
16208   echo $ECHO_N "(cached) $ECHO_C" >&6
16209 else
16210   if test -n "$PTHREAD_CC"; then
16211   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
16212 else
16213 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16214 for as_dir in $PATH
16215 do
16216   IFS=$as_save_IFS
16217   test -z "$as_dir" && as_dir=.
16218   for ac_exec_ext in '' $ac_executable_extensions; do
16219   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16220     ac_cv_prog_PTHREAD_CC="cc_r"
16221     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16222     break 2
16223   fi
16224 done
16225 done
16226
16227   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
16228 fi
16229 fi
16230 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
16231 if test -n "$PTHREAD_CC"; then
16232   echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
16233 echo "${ECHO_T}$PTHREAD_CC" >&6
16234 else
16235   echo "$as_me:$LINENO: result: no" >&5
16236 echo "${ECHO_T}no" >&6
16237 fi
16238
16239 else
16240         PTHREAD_CC="$CC"
16241 fi
16242
16243
16244
16245
16246
16247 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
16248 if test x"$acx_pthread_ok" = xyes; then
16249
16250 cat >>confdefs.h <<\_ACEOF
16251 #define HAVE_PTHREAD 1
16252 _ACEOF
16253
16254         :
16255 else
16256         acx_pthread_ok=no
16257
16258 fi
16259 ac_ext=c
16260 ac_cpp='$CPP $CPPFLAGS'
16261 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16262 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16263 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16264
16265         # set thread flags
16266
16267 # Some platforms use these, so just defineed them.  They can't hurt if they
16268 # are not supported.
16269 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
16270
16271
16272 # At this point, we don't want to muck with the compiler name for threading.
16273 # Let's see who fails, perhaps AIX.  2004-04-23
16274 if test "$PTHREAD_CC" != "$CC"; then
16275 { { echo "$as_me:$LINENO: error:
16276 PostgreSQL does not support platforms that require a special
16277 compiler binary for thread-safety.
16278 " >&5
16279 echo "$as_me: error:
16280 PostgreSQL does not support platforms that require a special
16281 compiler binary for thread-safety.
16282 " >&2;}
16283    { (exit 1); exit 1; }; }
16284 fi
16285
16286 if test "$THREAD_SUPPORT" = no; then
16287 { { echo "$as_me:$LINENO: error:
16288 Cannot enable threads on your platform.
16289 Your platform is known to not support thread-safe programs.
16290 For details, compile and run src/bin/pg_thread_test.
16291 " >&5
16292 echo "$as_me: error:
16293 Cannot enable threads on your platform.
16294 Your platform is known to not support thread-safe programs.
16295 For details, compile and run src/bin/pg_thread_test.
16296 " >&2;}
16297    { (exit 1); exit 1; }; }
16298 fi
16299
16300 # Check for *_r functions
16301 _CFLAGS="$CFLAGS"
16302 _LIBS="$LIBS"
16303 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16304 LIBS="$LIBS $PTHREAD_LIBS"
16305
16306 if test "${ac_cv_header_pthread_h+set}" = set; then
16307   echo "$as_me:$LINENO: checking for pthread.h" >&5
16308 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
16309 if test "${ac_cv_header_pthread_h+set}" = set; then
16310   echo $ECHO_N "(cached) $ECHO_C" >&6
16311 fi
16312 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
16313 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
16314 else
16315   # Is the header compilable?
16316 echo "$as_me:$LINENO: checking pthread.h usability" >&5
16317 echo $ECHO_N "checking pthread.h usability... $ECHO_C" >&6
16318 cat >conftest.$ac_ext <<_ACEOF
16319 /* confdefs.h.  */
16320 _ACEOF
16321 cat confdefs.h >>conftest.$ac_ext
16322 cat >>conftest.$ac_ext <<_ACEOF
16323 /* end confdefs.h.  */
16324 $ac_includes_default
16325 #include <pthread.h>
16326 _ACEOF
16327 rm -f conftest.$ac_objext
16328 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16329   (eval $ac_compile) 2>conftest.er1
16330   ac_status=$?
16331   grep -v '^ *+' conftest.er1 >conftest.err
16332   rm -f conftest.er1
16333   cat conftest.err >&5
16334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16335   (exit $ac_status); } &&
16336          { ac_try='test -z "$ac_c_werror_flag"
16337                          || test ! -s conftest.err'
16338   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16339   (eval $ac_try) 2>&5
16340   ac_status=$?
16341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16342   (exit $ac_status); }; } &&
16343          { ac_try='test -s conftest.$ac_objext'
16344   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16345   (eval $ac_try) 2>&5
16346   ac_status=$?
16347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16348   (exit $ac_status); }; }; then
16349   ac_header_compiler=yes
16350 else
16351   echo "$as_me: failed program was:" >&5
16352 sed 's/^/| /' conftest.$ac_ext >&5
16353
16354 ac_header_compiler=no
16355 fi
16356 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16357 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16358 echo "${ECHO_T}$ac_header_compiler" >&6
16359
16360 # Is the header present?
16361 echo "$as_me:$LINENO: checking pthread.h presence" >&5
16362 echo $ECHO_N "checking pthread.h presence... $ECHO_C" >&6
16363 cat >conftest.$ac_ext <<_ACEOF
16364 /* confdefs.h.  */
16365 _ACEOF
16366 cat confdefs.h >>conftest.$ac_ext
16367 cat >>conftest.$ac_ext <<_ACEOF
16368 /* end confdefs.h.  */
16369 #include <pthread.h>
16370 _ACEOF
16371 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16372   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16373   ac_status=$?
16374   grep -v '^ *+' conftest.er1 >conftest.err
16375   rm -f conftest.er1
16376   cat conftest.err >&5
16377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16378   (exit $ac_status); } >/dev/null; then
16379   if test -s conftest.err; then
16380     ac_cpp_err=$ac_c_preproc_warn_flag
16381     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16382   else
16383     ac_cpp_err=
16384   fi
16385 else
16386   ac_cpp_err=yes
16387 fi
16388 if test -z "$ac_cpp_err"; then
16389   ac_header_preproc=yes
16390 else
16391   echo "$as_me: failed program was:" >&5
16392 sed 's/^/| /' conftest.$ac_ext >&5
16393
16394   ac_header_preproc=no
16395 fi
16396 rm -f conftest.err conftest.$ac_ext
16397 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16398 echo "${ECHO_T}$ac_header_preproc" >&6
16399
16400 # So?  What about this header?
16401 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16402   yes:no: )
16403     { echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
16404 echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
16405     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
16406 echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
16407     ac_header_preproc=yes
16408     ;;
16409   no:yes:* )
16410     { echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
16411 echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
16412     { echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
16413 echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
16414     { echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
16415 echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
16416     { echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
16417 echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
16418     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
16419 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
16420     { echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
16421 echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
16422     (
16423       cat <<\_ASBOX
16424 ## ---------------------------------------- ##
16425 ## Report this to pgsql-bugs@postgresql.org ##
16426 ## ---------------------------------------- ##
16427 _ASBOX
16428     ) |
16429       sed "s/^/$as_me: WARNING:     /" >&2
16430     ;;
16431 esac
16432 echo "$as_me:$LINENO: checking for pthread.h" >&5
16433 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
16434 if test "${ac_cv_header_pthread_h+set}" = set; then
16435   echo $ECHO_N "(cached) $ECHO_C" >&6
16436 else
16437   ac_cv_header_pthread_h=$ac_header_preproc
16438 fi
16439 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
16440 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
16441
16442 fi
16443 if test $ac_cv_header_pthread_h = yes; then
16444   :
16445 else
16446   { { echo "$as_me:$LINENO: error: pthread.h not found, required for --enable-thread-safety" >&5
16447 echo "$as_me: error: pthread.h not found, required for --enable-thread-safety" >&2;}
16448    { (exit 1); exit 1; }; }
16449 fi
16450
16451
16452
16453
16454
16455
16456 for ac_func in strerror_r getpwuid_r gethostbyname_r
16457 do
16458 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16459 echo "$as_me:$LINENO: checking for $ac_func" >&5
16460 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16461 if eval "test \"\${$as_ac_var+set}\" = set"; then
16462   echo $ECHO_N "(cached) $ECHO_C" >&6
16463 else
16464   cat >conftest.$ac_ext <<_ACEOF
16465 /* confdefs.h.  */
16466 _ACEOF
16467 cat confdefs.h >>conftest.$ac_ext
16468 cat >>conftest.$ac_ext <<_ACEOF
16469 /* end confdefs.h.  */
16470 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16471    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16472 #define $ac_func innocuous_$ac_func
16473
16474 /* System header to define __stub macros and hopefully few prototypes,
16475     which can conflict with char $ac_func (); below.
16476     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16477     <limits.h> exists even on freestanding compilers.  */
16478
16479 #ifdef __STDC__
16480 # include <limits.h>
16481 #else
16482 # include <assert.h>
16483 #endif
16484
16485 #undef $ac_func
16486
16487 /* Override any gcc2 internal prototype to avoid an error.  */
16488 #ifdef __cplusplus
16489 extern "C"
16490 {
16491 #endif
16492 /* We use char because int might match the return type of a gcc2
16493    builtin and then its argument prototype would still apply.  */
16494 char $ac_func ();
16495 /* The GNU C library defines this for functions which it implements
16496     to always fail with ENOSYS.  Some functions are actually named
16497     something starting with __ and the normal name is an alias.  */
16498 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16499 choke me
16500 #else
16501 char (*f) () = $ac_func;
16502 #endif
16503 #ifdef __cplusplus
16504 }
16505 #endif
16506
16507 int
16508 main ()
16509 {
16510 return f != $ac_func;
16511   ;
16512   return 0;
16513 }
16514 _ACEOF
16515 rm -f conftest.$ac_objext conftest$ac_exeext
16516 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16517   (eval $ac_link) 2>conftest.er1
16518   ac_status=$?
16519   grep -v '^ *+' conftest.er1 >conftest.err
16520   rm -f conftest.er1
16521   cat conftest.err >&5
16522   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16523   (exit $ac_status); } &&
16524          { ac_try='test -z "$ac_c_werror_flag"
16525                          || test ! -s conftest.err'
16526   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16527   (eval $ac_try) 2>&5
16528   ac_status=$?
16529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16530   (exit $ac_status); }; } &&
16531          { ac_try='test -s conftest$ac_exeext'
16532   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16533   (eval $ac_try) 2>&5
16534   ac_status=$?
16535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16536   (exit $ac_status); }; }; then
16537   eval "$as_ac_var=yes"
16538 else
16539   echo "$as_me: failed program was:" >&5
16540 sed 's/^/| /' conftest.$ac_ext >&5
16541
16542 eval "$as_ac_var=no"
16543 fi
16544 rm -f conftest.err conftest.$ac_objext \
16545       conftest$ac_exeext conftest.$ac_ext
16546 fi
16547 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16548 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16549 if test `eval echo '${'$as_ac_var'}'` = yes; then
16550   cat >>confdefs.h <<_ACEOF
16551 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16552 _ACEOF
16553
16554 fi
16555 done
16556
16557
16558 # Do test here with the proper thread flags
16559 echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
16560 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6
16561 if test "${pgac_func_getpwuid_r_5arg+set}" = set; then
16562   echo $ECHO_N "(cached) $ECHO_C" >&6
16563 else
16564   cat >conftest.$ac_ext <<_ACEOF
16565 /* confdefs.h.  */
16566 _ACEOF
16567 cat confdefs.h >>conftest.$ac_ext
16568 cat >>conftest.$ac_ext <<_ACEOF
16569 /* end confdefs.h.  */
16570 #include <sys/types.h>
16571 #include <pwd.h>
16572 int
16573 main ()
16574 {
16575 uid_t uid;
16576 struct passwd *space;
16577 char *buf;
16578 size_t bufsize;
16579 struct passwd **result;
16580 getpwuid_r(uid, space, buf, bufsize, result);
16581   ;
16582   return 0;
16583 }
16584 _ACEOF
16585 rm -f conftest.$ac_objext
16586 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16587   (eval $ac_compile) 2>conftest.er1
16588   ac_status=$?
16589   grep -v '^ *+' conftest.er1 >conftest.err
16590   rm -f conftest.er1
16591   cat conftest.err >&5
16592   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16593   (exit $ac_status); } &&
16594          { ac_try='test -z "$ac_c_werror_flag"
16595                          || test ! -s conftest.err'
16596   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16597   (eval $ac_try) 2>&5
16598   ac_status=$?
16599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16600   (exit $ac_status); }; } &&
16601          { ac_try='test -s conftest.$ac_objext'
16602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16603   (eval $ac_try) 2>&5
16604   ac_status=$?
16605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16606   (exit $ac_status); }; }; then
16607   pgac_func_getpwuid_r_5arg=yes
16608 else
16609   echo "$as_me: failed program was:" >&5
16610 sed 's/^/| /' conftest.$ac_ext >&5
16611
16612 pgac_func_getpwuid_r_5arg=no
16613 fi
16614 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16615 fi
16616 echo "$as_me:$LINENO: result: $pgac_func_getpwuid_r_5arg" >&5
16617 echo "${ECHO_T}$pgac_func_getpwuid_r_5arg" >&6
16618 if test x"$pgac_func_getpwuid_r_5arg" = xyes ; then
16619
16620 cat >>confdefs.h <<\_ACEOF
16621 #define GETPWUID_R_5ARG
16622 _ACEOF
16623
16624 fi
16625
16626 echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
16627 echo $ECHO_N "checking whether strerror_r returns int... $ECHO_C" >&6
16628 if test "${pgac_func_strerror_r_int+set}" = set; then
16629   echo $ECHO_N "(cached) $ECHO_C" >&6
16630 else
16631   cat >conftest.$ac_ext <<_ACEOF
16632 /* confdefs.h.  */
16633 _ACEOF
16634 cat confdefs.h >>conftest.$ac_ext
16635 cat >>conftest.$ac_ext <<_ACEOF
16636 /* end confdefs.h.  */
16637 #include <string.h>
16638 int
16639 main ()
16640 {
16641 #ifndef _AIX
16642 int strerror_r(int, char *, size_t);
16643 #else
16644 /* Older AIX has 'int' for the third argument so we don't test the args. */
16645 int strerror_r();
16646 #endif
16647   ;
16648   return 0;
16649 }
16650 _ACEOF
16651 rm -f conftest.$ac_objext
16652 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16653   (eval $ac_compile) 2>conftest.er1
16654   ac_status=$?
16655   grep -v '^ *+' conftest.er1 >conftest.err
16656   rm -f conftest.er1
16657   cat conftest.err >&5
16658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16659   (exit $ac_status); } &&
16660          { ac_try='test -z "$ac_c_werror_flag"
16661                          || test ! -s conftest.err'
16662   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16663   (eval $ac_try) 2>&5
16664   ac_status=$?
16665   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16666   (exit $ac_status); }; } &&
16667          { ac_try='test -s conftest.$ac_objext'
16668   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16669   (eval $ac_try) 2>&5
16670   ac_status=$?
16671   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16672   (exit $ac_status); }; }; then
16673   pgac_func_strerror_r_int=yes
16674 else
16675   echo "$as_me: failed program was:" >&5
16676 sed 's/^/| /' conftest.$ac_ext >&5
16677
16678 pgac_func_strerror_r_int=no
16679 fi
16680 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16681 fi
16682 echo "$as_me:$LINENO: result: $pgac_func_strerror_r_int" >&5
16683 echo "${ECHO_T}$pgac_func_strerror_r_int" >&6
16684 if test x"$pgac_func_strerror_r_int" = xyes ; then
16685
16686 cat >>confdefs.h <<\_ACEOF
16687 #define STRERROR_R_INT
16688 _ACEOF
16689
16690 fi
16691
16692
16693 CFLAGS="$_CFLAGS"
16694 LIBS="$_LIBS"
16695
16696 else
16697 # do not use values from template file
16698 PTHREAD_CFLAGS=
16699 PTHREAD_LIBS=
16700 fi
16701
16702
16703
16704
16705
16706 # This test makes sure that run tests work at all.  Sometimes a shared
16707 # library is found by the linker, but the runtime linker can't find it.
16708 # This check should come after all modifications of compiler or linker
16709 # variables, and before any other run tests.
16710 echo "$as_me:$LINENO: checking test program" >&5
16711 echo $ECHO_N "checking test program... $ECHO_C" >&6
16712 if test "$cross_compiling" = yes; then
16713   echo "$as_me:$LINENO: result: cross-compiling" >&5
16714 echo "${ECHO_T}cross-compiling" >&6
16715 else
16716   cat >conftest.$ac_ext <<_ACEOF
16717 /* confdefs.h.  */
16718 _ACEOF
16719 cat confdefs.h >>conftest.$ac_ext
16720 cat >>conftest.$ac_ext <<_ACEOF
16721 /* end confdefs.h.  */
16722 int main() { return 0; }
16723 _ACEOF
16724 rm -f conftest$ac_exeext
16725 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16726   (eval $ac_link) 2>&5
16727   ac_status=$?
16728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16729   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16730   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16731   (eval $ac_try) 2>&5
16732   ac_status=$?
16733   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16734   (exit $ac_status); }; }; then
16735   echo "$as_me:$LINENO: result: ok" >&5
16736 echo "${ECHO_T}ok" >&6
16737 else
16738   echo "$as_me: program exited with status $ac_status" >&5
16739 echo "$as_me: failed program was:" >&5
16740 sed 's/^/| /' conftest.$ac_ext >&5
16741
16742 ( exit $ac_status )
16743 echo "$as_me:$LINENO: result: failed" >&5
16744 echo "${ECHO_T}failed" >&6
16745 { { echo "$as_me:$LINENO: error:
16746 *** Could not execute a simple test program.  This may be a problem
16747 *** related to locating shared libraries.  Check the file 'config.log'
16748 *** for the exact reason." >&5
16749 echo "$as_me: error:
16750 *** Could not execute a simple test program.  This may be a problem
16751 *** related to locating shared libraries.  Check the file 'config.log'
16752 *** for the exact reason." >&2;}
16753    { (exit 1); exit 1; }; }
16754 fi
16755 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16756 fi
16757
16758 # --------------------
16759 # Run tests below here
16760 # --------------------
16761
16762 # Force use of our snprintf if system's doesn't do arg control
16763 # See comment above at snprintf test for details.
16764 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
16765   echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
16766 echo $ECHO_N "checking whether printf supports argument control... $ECHO_C" >&6
16767 if test "${pgac_cv_printf_arg_control+set}" = set; then
16768   echo $ECHO_N "(cached) $ECHO_C" >&6
16769 else
16770   if test "$cross_compiling" = yes; then
16771   pgac_cv_printf_arg_control=cross
16772 else
16773   cat >conftest.$ac_ext <<_ACEOF
16774 /* confdefs.h.  */
16775 _ACEOF
16776 cat confdefs.h >>conftest.$ac_ext
16777 cat >>conftest.$ac_ext <<_ACEOF
16778 /* end confdefs.h.  */
16779 #include <stdio.h>
16780 #include <string.h>
16781
16782 int main()
16783 {
16784   char buf[100];
16785
16786   /* can it swap arguments? */
16787   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
16788   if (strcmp(buf, "4 3") != 0)
16789     return 1;
16790   return 0;
16791 }
16792 _ACEOF
16793 rm -f conftest$ac_exeext
16794 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16795   (eval $ac_link) 2>&5
16796   ac_status=$?
16797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16798   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16799   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16800   (eval $ac_try) 2>&5
16801   ac_status=$?
16802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16803   (exit $ac_status); }; }; then
16804   pgac_cv_printf_arg_control=yes
16805 else
16806   echo "$as_me: program exited with status $ac_status" >&5
16807 echo "$as_me: failed program was:" >&5
16808 sed 's/^/| /' conftest.$ac_ext >&5
16809
16810 ( exit $ac_status )
16811 pgac_cv_printf_arg_control=no
16812 fi
16813 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16814 fi
16815
16816 fi
16817 echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
16818 echo "${ECHO_T}$pgac_cv_printf_arg_control" >&6
16819
16820   if test $pgac_cv_printf_arg_control != yes ; then
16821     pgac_need_repl_snprintf=yes
16822   fi
16823 fi
16824
16825
16826
16827 echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
16828 echo $ECHO_N "checking whether long int is 64 bits... $ECHO_C" >&6
16829 if test "${pgac_cv_type_long_int_64+set}" = set; then
16830   echo $ECHO_N "(cached) $ECHO_C" >&6
16831 else
16832   if test "$cross_compiling" = yes; then
16833   # If cross-compiling, check the size reported by the compiler and
16834 # trust that the arithmetic works.
16835 cat >conftest.$ac_ext <<_ACEOF
16836 /* confdefs.h.  */
16837 _ACEOF
16838 cat confdefs.h >>conftest.$ac_ext
16839 cat >>conftest.$ac_ext <<_ACEOF
16840 /* end confdefs.h.  */
16841
16842 int
16843 main ()
16844 {
16845 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
16846 test_array [0] = 0
16847
16848   ;
16849   return 0;
16850 }
16851 _ACEOF
16852 rm -f conftest.$ac_objext
16853 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16854   (eval $ac_compile) 2>conftest.er1
16855   ac_status=$?
16856   grep -v '^ *+' conftest.er1 >conftest.err
16857   rm -f conftest.er1
16858   cat conftest.err >&5
16859   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16860   (exit $ac_status); } &&
16861          { ac_try='test -z "$ac_c_werror_flag"
16862                          || test ! -s conftest.err'
16863   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16864   (eval $ac_try) 2>&5
16865   ac_status=$?
16866   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16867   (exit $ac_status); }; } &&
16868          { ac_try='test -s conftest.$ac_objext'
16869   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16870   (eval $ac_try) 2>&5
16871   ac_status=$?
16872   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16873   (exit $ac_status); }; }; then
16874   pgac_cv_type_long_int_64=yes
16875 else
16876   echo "$as_me: failed program was:" >&5
16877 sed 's/^/| /' conftest.$ac_ext >&5
16878
16879 pgac_cv_type_long_int_64=no
16880 fi
16881 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16882 else
16883   cat >conftest.$ac_ext <<_ACEOF
16884 /* confdefs.h.  */
16885 _ACEOF
16886 cat confdefs.h >>conftest.$ac_ext
16887 cat >>conftest.$ac_ext <<_ACEOF
16888 /* end confdefs.h.  */
16889 typedef long int ac_int64;
16890
16891 /*
16892  * These are globals to discourage the compiler from folding all the
16893  * arithmetic tests down to compile-time constants.
16894  */
16895 ac_int64 a = 20000001;
16896 ac_int64 b = 40000005;
16897
16898 int does_int64_work()
16899 {
16900   ac_int64 c,d;
16901
16902   if (sizeof(ac_int64) != 8)
16903     return 0;                   /* definitely not the right size */
16904
16905   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
16906   c = a * b;
16907   d = (c + b) / b;
16908   if (d != a+1)
16909     return 0;
16910   return 1;
16911 }
16912 main() {
16913   exit(! does_int64_work());
16914 }
16915 _ACEOF
16916 rm -f conftest$ac_exeext
16917 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16918   (eval $ac_link) 2>&5
16919   ac_status=$?
16920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16921   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16922   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16923   (eval $ac_try) 2>&5
16924   ac_status=$?
16925   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16926   (exit $ac_status); }; }; then
16927   pgac_cv_type_long_int_64=yes
16928 else
16929   echo "$as_me: program exited with status $ac_status" >&5
16930 echo "$as_me: failed program was:" >&5
16931 sed 's/^/| /' conftest.$ac_ext >&5
16932
16933 ( exit $ac_status )
16934 pgac_cv_type_long_int_64=no
16935 fi
16936 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16937 fi
16938 fi
16939 echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
16940 echo "${ECHO_T}$pgac_cv_type_long_int_64" >&6
16941
16942 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
16943 if test x"$pgac_cv_type_long_int_64" = xyes ; then
16944
16945 cat >>confdefs.h <<\_ACEOF
16946 #define HAVE_LONG_INT_64
16947 _ACEOF
16948
16949 fi
16950
16951
16952 if test x"$HAVE_LONG_INT_64" = x"no" ; then
16953   echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
16954 echo $ECHO_N "checking whether long long int is 64 bits... $ECHO_C" >&6
16955 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
16956   echo $ECHO_N "(cached) $ECHO_C" >&6
16957 else
16958   if test "$cross_compiling" = yes; then
16959   # If cross-compiling, check the size reported by the compiler and
16960 # trust that the arithmetic works.
16961 cat >conftest.$ac_ext <<_ACEOF
16962 /* confdefs.h.  */
16963 _ACEOF
16964 cat confdefs.h >>conftest.$ac_ext
16965 cat >>conftest.$ac_ext <<_ACEOF
16966 /* end confdefs.h.  */
16967
16968 int
16969 main ()
16970 {
16971 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
16972 test_array [0] = 0
16973
16974   ;
16975   return 0;
16976 }
16977 _ACEOF
16978 rm -f conftest.$ac_objext
16979 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16980   (eval $ac_compile) 2>conftest.er1
16981   ac_status=$?
16982   grep -v '^ *+' conftest.er1 >conftest.err
16983   rm -f conftest.er1
16984   cat conftest.err >&5
16985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16986   (exit $ac_status); } &&
16987          { ac_try='test -z "$ac_c_werror_flag"
16988                          || test ! -s conftest.err'
16989   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16990   (eval $ac_try) 2>&5
16991   ac_status=$?
16992   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16993   (exit $ac_status); }; } &&
16994          { ac_try='test -s conftest.$ac_objext'
16995   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16996   (eval $ac_try) 2>&5
16997   ac_status=$?
16998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16999   (exit $ac_status); }; }; then
17000   pgac_cv_type_long_long_int_64=yes
17001 else
17002   echo "$as_me: failed program was:" >&5
17003 sed 's/^/| /' conftest.$ac_ext >&5
17004
17005 pgac_cv_type_long_long_int_64=no
17006 fi
17007 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17008 else
17009   cat >conftest.$ac_ext <<_ACEOF
17010 /* confdefs.h.  */
17011 _ACEOF
17012 cat confdefs.h >>conftest.$ac_ext
17013 cat >>conftest.$ac_ext <<_ACEOF
17014 /* end confdefs.h.  */
17015 typedef long long int ac_int64;
17016
17017 /*
17018  * These are globals to discourage the compiler from folding all the
17019  * arithmetic tests down to compile-time constants.
17020  */
17021 ac_int64 a = 20000001;
17022 ac_int64 b = 40000005;
17023
17024 int does_int64_work()
17025 {
17026   ac_int64 c,d;
17027
17028   if (sizeof(ac_int64) != 8)
17029     return 0;                   /* definitely not the right size */
17030
17031   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
17032   c = a * b;
17033   d = (c + b) / b;
17034   if (d != a+1)
17035     return 0;
17036   return 1;
17037 }
17038 main() {
17039   exit(! does_int64_work());
17040 }
17041 _ACEOF
17042 rm -f conftest$ac_exeext
17043 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17044   (eval $ac_link) 2>&5
17045   ac_status=$?
17046   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17047   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17048   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17049   (eval $ac_try) 2>&5
17050   ac_status=$?
17051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17052   (exit $ac_status); }; }; then
17053   pgac_cv_type_long_long_int_64=yes
17054 else
17055   echo "$as_me: program exited with status $ac_status" >&5
17056 echo "$as_me: failed program was:" >&5
17057 sed 's/^/| /' conftest.$ac_ext >&5
17058
17059 ( exit $ac_status )
17060 pgac_cv_type_long_long_int_64=no
17061 fi
17062 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17063 fi
17064 fi
17065 echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
17066 echo "${ECHO_T}$pgac_cv_type_long_long_int_64" >&6
17067
17068 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
17069 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
17070
17071 cat >>confdefs.h <<\_ACEOF
17072 #define HAVE_LONG_LONG_INT_64
17073 _ACEOF
17074
17075 fi
17076
17077 fi
17078
17079
17080
17081 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
17082   cat >conftest.$ac_ext <<_ACEOF
17083 /* confdefs.h.  */
17084 _ACEOF
17085 cat confdefs.h >>conftest.$ac_ext
17086 cat >>conftest.$ac_ext <<_ACEOF
17087 /* end confdefs.h.  */
17088
17089 #define INT64CONST(x)  x##LL
17090 long long int foo = INT64CONST(0x1234567890123456);
17091
17092 int
17093 main ()
17094 {
17095
17096   ;
17097   return 0;
17098 }
17099 _ACEOF
17100 rm -f conftest.$ac_objext
17101 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17102   (eval $ac_compile) 2>conftest.er1
17103   ac_status=$?
17104   grep -v '^ *+' conftest.er1 >conftest.err
17105   rm -f conftest.er1
17106   cat conftest.err >&5
17107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17108   (exit $ac_status); } &&
17109          { ac_try='test -z "$ac_c_werror_flag"
17110                          || test ! -s conftest.err'
17111   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17112   (eval $ac_try) 2>&5
17113   ac_status=$?
17114   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17115   (exit $ac_status); }; } &&
17116          { ac_try='test -s conftest.$ac_objext'
17117   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17118   (eval $ac_try) 2>&5
17119   ac_status=$?
17120   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17121   (exit $ac_status); }; }; then
17122
17123 cat >>confdefs.h <<\_ACEOF
17124 #define HAVE_LL_CONSTANTS 1
17125 _ACEOF
17126
17127 else
17128   echo "$as_me: failed program was:" >&5
17129 sed 's/^/| /' conftest.$ac_ext >&5
17130
17131 fi
17132 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17133 fi
17134
17135
17136 # If we found "long int" is 64 bits, assume snprintf handles it.  If
17137 # we found we need to use "long long int", better check.  We cope with
17138 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
17139 # work, fall back to our own snprintf emulation (which we know uses %lld).
17140
17141 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
17142   if test $pgac_need_repl_snprintf = no; then
17143     echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
17144 echo $ECHO_N "checking snprintf format for long long int... $ECHO_C" >&6
17145 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
17146   echo $ECHO_N "(cached) $ECHO_C" >&6
17147 else
17148   for pgac_format in '%lld' '%qd' '%I64d'; do
17149 if test "$cross_compiling" = yes; then
17150   pgac_cv_snprintf_long_long_int_format=cross; break
17151 else
17152   cat >conftest.$ac_ext <<_ACEOF
17153 /* confdefs.h.  */
17154 _ACEOF
17155 cat confdefs.h >>conftest.$ac_ext
17156 cat >>conftest.$ac_ext <<_ACEOF
17157 /* end confdefs.h.  */
17158 #include <stdio.h>
17159 typedef long long int ac_int64;
17160 #define INT64_FORMAT "$pgac_format"
17161
17162 ac_int64 a = 20000001;
17163 ac_int64 b = 40000005;
17164
17165 int does_int64_snprintf_work()
17166 {
17167   ac_int64 c;
17168   char buf[100];
17169
17170   if (sizeof(ac_int64) != 8)
17171     return 0;                   /* doesn't look like the right size */
17172
17173   c = a * b;
17174   snprintf(buf, 100, INT64_FORMAT, c);
17175   if (strcmp(buf, "800000140000005") != 0)
17176     return 0;                   /* either multiply or snprintf is busted */
17177   return 1;
17178 }
17179 main() {
17180   exit(! does_int64_snprintf_work());
17181 }
17182 _ACEOF
17183 rm -f conftest$ac_exeext
17184 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17185   (eval $ac_link) 2>&5
17186   ac_status=$?
17187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17188   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17189   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17190   (eval $ac_try) 2>&5
17191   ac_status=$?
17192   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17193   (exit $ac_status); }; }; then
17194   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
17195 else
17196   echo "$as_me: program exited with status $ac_status" >&5
17197 echo "$as_me: failed program was:" >&5
17198 sed 's/^/| /' conftest.$ac_ext >&5
17199
17200 fi
17201 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17202 fi
17203 done
17204 fi
17205
17206 LONG_LONG_INT_FORMAT=''
17207
17208 case $pgac_cv_snprintf_long_long_int_format in
17209   cross) echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
17210 echo "${ECHO_T}cannot test (not on host machine)" >&6;;
17211   ?*)    echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
17212 echo "${ECHO_T}$pgac_cv_snprintf_long_long_int_format" >&6
17213          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
17214   *)     echo "$as_me:$LINENO: result: none" >&5
17215 echo "${ECHO_T}none" >&6;;
17216 esac
17217     if test "$LONG_LONG_INT_FORMAT" = ""; then
17218       # Force usage of our own snprintf, since system snprintf is broken
17219       pgac_need_repl_snprintf=yes
17220       LONG_LONG_INT_FORMAT='%lld'
17221     fi
17222   else
17223     # Here if we previously decided we needed to use our own snprintf
17224     LONG_LONG_INT_FORMAT='%lld'
17225   fi
17226   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
17227   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
17228   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
17229 else
17230   # Here if we are not using 'long long int' at all
17231   INT64_FORMAT='"%ld"'
17232   UINT64_FORMAT='"%lu"'
17233 fi
17234
17235
17236 cat >>confdefs.h <<_ACEOF
17237 #define INT64_FORMAT $INT64_FORMAT
17238 _ACEOF
17239
17240
17241
17242 cat >>confdefs.h <<_ACEOF
17243 #define UINT64_FORMAT $UINT64_FORMAT
17244 _ACEOF
17245
17246
17247 # Now we have checked all the reasons to replace snprintf
17248 if test $pgac_need_repl_snprintf = yes; then
17249
17250 cat >>confdefs.h <<\_ACEOF
17251 #define USE_REPL_SNPRINTF 1
17252 _ACEOF
17253
17254   case $LIBOBJS in
17255     "snprintf.$ac_objext"   | \
17256   *" snprintf.$ac_objext"   | \
17257     "snprintf.$ac_objext "* | \
17258   *" snprintf.$ac_objext "* ) ;;
17259   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" ;;
17260 esac
17261
17262 fi
17263
17264 # Need a #define for the size of Datum (unsigned long)
17265 echo "$as_me:$LINENO: checking for unsigned long" >&5
17266 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6
17267 if test "${ac_cv_type_unsigned_long+set}" = set; then
17268   echo $ECHO_N "(cached) $ECHO_C" >&6
17269 else
17270   cat >conftest.$ac_ext <<_ACEOF
17271 /* confdefs.h.  */
17272 _ACEOF
17273 cat confdefs.h >>conftest.$ac_ext
17274 cat >>conftest.$ac_ext <<_ACEOF
17275 /* end confdefs.h.  */
17276 $ac_includes_default
17277 int
17278 main ()
17279 {
17280 if ((unsigned long *) 0)
17281   return 0;
17282 if (sizeof (unsigned long))
17283   return 0;
17284   ;
17285   return 0;
17286 }
17287 _ACEOF
17288 rm -f conftest.$ac_objext
17289 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17290   (eval $ac_compile) 2>conftest.er1
17291   ac_status=$?
17292   grep -v '^ *+' conftest.er1 >conftest.err
17293   rm -f conftest.er1
17294   cat conftest.err >&5
17295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17296   (exit $ac_status); } &&
17297          { ac_try='test -z "$ac_c_werror_flag"
17298                          || test ! -s conftest.err'
17299   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17300   (eval $ac_try) 2>&5
17301   ac_status=$?
17302   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17303   (exit $ac_status); }; } &&
17304          { ac_try='test -s conftest.$ac_objext'
17305   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17306   (eval $ac_try) 2>&5
17307   ac_status=$?
17308   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17309   (exit $ac_status); }; }; then
17310   ac_cv_type_unsigned_long=yes
17311 else
17312   echo "$as_me: failed program was:" >&5
17313 sed 's/^/| /' conftest.$ac_ext >&5
17314
17315 ac_cv_type_unsigned_long=no
17316 fi
17317 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17318 fi
17319 echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
17320 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6
17321
17322 echo "$as_me:$LINENO: checking size of unsigned long" >&5
17323 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6
17324 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
17325   echo $ECHO_N "(cached) $ECHO_C" >&6
17326 else
17327   if test "$ac_cv_type_unsigned_long" = yes; then
17328   # The cast to unsigned long works around a bug in the HP C Compiler
17329   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17330   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
17331   # This bug is HP SR number 8606223364.
17332   if test "$cross_compiling" = yes; then
17333   # Depending upon the size, compute the lo and hi bounds.
17334 cat >conftest.$ac_ext <<_ACEOF
17335 /* confdefs.h.  */
17336 _ACEOF
17337 cat confdefs.h >>conftest.$ac_ext
17338 cat >>conftest.$ac_ext <<_ACEOF
17339 /* end confdefs.h.  */
17340 $ac_includes_default
17341 int
17342 main ()
17343 {
17344 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= 0)];
17345 test_array [0] = 0
17346
17347   ;
17348   return 0;
17349 }
17350 _ACEOF
17351 rm -f conftest.$ac_objext
17352 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17353   (eval $ac_compile) 2>conftest.er1
17354   ac_status=$?
17355   grep -v '^ *+' conftest.er1 >conftest.err
17356   rm -f conftest.er1
17357   cat conftest.err >&5
17358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17359   (exit $ac_status); } &&
17360          { ac_try='test -z "$ac_c_werror_flag"
17361                          || test ! -s conftest.err'
17362   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17363   (eval $ac_try) 2>&5
17364   ac_status=$?
17365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17366   (exit $ac_status); }; } &&
17367          { ac_try='test -s conftest.$ac_objext'
17368   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17369   (eval $ac_try) 2>&5
17370   ac_status=$?
17371   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17372   (exit $ac_status); }; }; then
17373   ac_lo=0 ac_mid=0
17374   while :; do
17375     cat >conftest.$ac_ext <<_ACEOF
17376 /* confdefs.h.  */
17377 _ACEOF
17378 cat confdefs.h >>conftest.$ac_ext
17379 cat >>conftest.$ac_ext <<_ACEOF
17380 /* end confdefs.h.  */
17381 $ac_includes_default
17382 int
17383 main ()
17384 {
17385 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
17386 test_array [0] = 0
17387
17388   ;
17389   return 0;
17390 }
17391 _ACEOF
17392 rm -f conftest.$ac_objext
17393 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17394   (eval $ac_compile) 2>conftest.er1
17395   ac_status=$?
17396   grep -v '^ *+' conftest.er1 >conftest.err
17397   rm -f conftest.er1
17398   cat conftest.err >&5
17399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17400   (exit $ac_status); } &&
17401          { ac_try='test -z "$ac_c_werror_flag"
17402                          || test ! -s conftest.err'
17403   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17404   (eval $ac_try) 2>&5
17405   ac_status=$?
17406   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17407   (exit $ac_status); }; } &&
17408          { ac_try='test -s conftest.$ac_objext'
17409   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17410   (eval $ac_try) 2>&5
17411   ac_status=$?
17412   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17413   (exit $ac_status); }; }; then
17414   ac_hi=$ac_mid; break
17415 else
17416   echo "$as_me: failed program was:" >&5
17417 sed 's/^/| /' conftest.$ac_ext >&5
17418
17419 ac_lo=`expr $ac_mid + 1`
17420                     if test $ac_lo -le $ac_mid; then
17421                       ac_lo= ac_hi=
17422                       break
17423                     fi
17424                     ac_mid=`expr 2 '*' $ac_mid + 1`
17425 fi
17426 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17427   done
17428 else
17429   echo "$as_me: failed program was:" >&5
17430 sed 's/^/| /' conftest.$ac_ext >&5
17431
17432 cat >conftest.$ac_ext <<_ACEOF
17433 /* confdefs.h.  */
17434 _ACEOF
17435 cat confdefs.h >>conftest.$ac_ext
17436 cat >>conftest.$ac_ext <<_ACEOF
17437 /* end confdefs.h.  */
17438 $ac_includes_default
17439 int
17440 main ()
17441 {
17442 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) < 0)];
17443 test_array [0] = 0
17444
17445   ;
17446   return 0;
17447 }
17448 _ACEOF
17449 rm -f conftest.$ac_objext
17450 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17451   (eval $ac_compile) 2>conftest.er1
17452   ac_status=$?
17453   grep -v '^ *+' conftest.er1 >conftest.err
17454   rm -f conftest.er1
17455   cat conftest.err >&5
17456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17457   (exit $ac_status); } &&
17458          { ac_try='test -z "$ac_c_werror_flag"
17459                          || test ! -s conftest.err'
17460   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17461   (eval $ac_try) 2>&5
17462   ac_status=$?
17463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17464   (exit $ac_status); }; } &&
17465          { ac_try='test -s conftest.$ac_objext'
17466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17467   (eval $ac_try) 2>&5
17468   ac_status=$?
17469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17470   (exit $ac_status); }; }; then
17471   ac_hi=-1 ac_mid=-1
17472   while :; do
17473     cat >conftest.$ac_ext <<_ACEOF
17474 /* confdefs.h.  */
17475 _ACEOF
17476 cat confdefs.h >>conftest.$ac_ext
17477 cat >>conftest.$ac_ext <<_ACEOF
17478 /* end confdefs.h.  */
17479 $ac_includes_default
17480 int
17481 main ()
17482 {
17483 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= $ac_mid)];
17484 test_array [0] = 0
17485
17486   ;
17487   return 0;
17488 }
17489 _ACEOF
17490 rm -f conftest.$ac_objext
17491 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17492   (eval $ac_compile) 2>conftest.er1
17493   ac_status=$?
17494   grep -v '^ *+' conftest.er1 >conftest.err
17495   rm -f conftest.er1
17496   cat conftest.err >&5
17497   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17498   (exit $ac_status); } &&
17499          { ac_try='test -z "$ac_c_werror_flag"
17500                          || test ! -s conftest.err'
17501   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17502   (eval $ac_try) 2>&5
17503   ac_status=$?
17504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17505   (exit $ac_status); }; } &&
17506          { ac_try='test -s conftest.$ac_objext'
17507   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17508   (eval $ac_try) 2>&5
17509   ac_status=$?
17510   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17511   (exit $ac_status); }; }; then
17512   ac_lo=$ac_mid; break
17513 else
17514   echo "$as_me: failed program was:" >&5
17515 sed 's/^/| /' conftest.$ac_ext >&5
17516
17517 ac_hi=`expr '(' $ac_mid ')' - 1`
17518                        if test $ac_mid -le $ac_hi; then
17519                          ac_lo= ac_hi=
17520                          break
17521                        fi
17522                        ac_mid=`expr 2 '*' $ac_mid`
17523 fi
17524 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17525   done
17526 else
17527   echo "$as_me: failed program was:" >&5
17528 sed 's/^/| /' conftest.$ac_ext >&5
17529
17530 ac_lo= ac_hi=
17531 fi
17532 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17533 fi
17534 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17535 # Binary search between lo and hi bounds.
17536 while test "x$ac_lo" != "x$ac_hi"; do
17537   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
17538   cat >conftest.$ac_ext <<_ACEOF
17539 /* confdefs.h.  */
17540 _ACEOF
17541 cat confdefs.h >>conftest.$ac_ext
17542 cat >>conftest.$ac_ext <<_ACEOF
17543 /* end confdefs.h.  */
17544 $ac_includes_default
17545 int
17546 main ()
17547 {
17548 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
17549 test_array [0] = 0
17550
17551   ;
17552   return 0;
17553 }
17554 _ACEOF
17555 rm -f conftest.$ac_objext
17556 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17557   (eval $ac_compile) 2>conftest.er1
17558   ac_status=$?
17559   grep -v '^ *+' conftest.er1 >conftest.err
17560   rm -f conftest.er1
17561   cat conftest.err >&5
17562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17563   (exit $ac_status); } &&
17564          { ac_try='test -z "$ac_c_werror_flag"
17565                          || test ! -s conftest.err'
17566   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17567   (eval $ac_try) 2>&5
17568   ac_status=$?
17569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17570   (exit $ac_status); }; } &&
17571          { ac_try='test -s conftest.$ac_objext'
17572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17573   (eval $ac_try) 2>&5
17574   ac_status=$?
17575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17576   (exit $ac_status); }; }; then
17577   ac_hi=$ac_mid
17578 else
17579   echo "$as_me: failed program was:" >&5
17580 sed 's/^/| /' conftest.$ac_ext >&5
17581
17582 ac_lo=`expr '(' $ac_mid ')' + 1`
17583 fi
17584 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17585 done
17586 case $ac_lo in
17587 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
17588 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77
17589 See \`config.log' for more details." >&5
17590 echo "$as_me: error: cannot compute sizeof (unsigned long), 77
17591 See \`config.log' for more details." >&2;}
17592    { (exit 1); exit 1; }; } ;;
17593 esac
17594 else
17595   if test "$cross_compiling" = yes; then
17596   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
17597 See \`config.log' for more details." >&5
17598 echo "$as_me: error: cannot run test program while cross compiling
17599 See \`config.log' for more details." >&2;}
17600    { (exit 1); exit 1; }; }
17601 else
17602   cat >conftest.$ac_ext <<_ACEOF
17603 /* confdefs.h.  */
17604 _ACEOF
17605 cat confdefs.h >>conftest.$ac_ext
17606 cat >>conftest.$ac_ext <<_ACEOF
17607 /* end confdefs.h.  */
17608 $ac_includes_default
17609 long longval () { return (long) (sizeof (unsigned long)); }
17610 unsigned long ulongval () { return (long) (sizeof (unsigned long)); }
17611 #include <stdio.h>
17612 #include <stdlib.h>
17613 int
17614 main ()
17615 {
17616
17617   FILE *f = fopen ("conftest.val", "w");
17618   if (! f)
17619     exit (1);
17620   if (((long) (sizeof (unsigned long))) < 0)
17621     {
17622       long i = longval ();
17623       if (i != ((long) (sizeof (unsigned long))))
17624         exit (1);
17625       fprintf (f, "%ld\n", i);
17626     }
17627   else
17628     {
17629       unsigned long i = ulongval ();
17630       if (i != ((long) (sizeof (unsigned long))))
17631         exit (1);
17632       fprintf (f, "%lu\n", i);
17633     }
17634   exit (ferror (f) || fclose (f) != 0);
17635
17636   ;
17637   return 0;
17638 }
17639 _ACEOF
17640 rm -f conftest$ac_exeext
17641 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17642   (eval $ac_link) 2>&5
17643   ac_status=$?
17644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17645   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17646   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17647   (eval $ac_try) 2>&5
17648   ac_status=$?
17649   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17650   (exit $ac_status); }; }; then
17651   ac_cv_sizeof_unsigned_long=`cat conftest.val`
17652 else
17653   echo "$as_me: program exited with status $ac_status" >&5
17654 echo "$as_me: failed program was:" >&5
17655 sed 's/^/| /' conftest.$ac_ext >&5
17656
17657 ( exit $ac_status )
17658 { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77
17659 See \`config.log' for more details." >&5
17660 echo "$as_me: error: cannot compute sizeof (unsigned long), 77
17661 See \`config.log' for more details." >&2;}
17662    { (exit 1); exit 1; }; }
17663 fi
17664 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17665 fi
17666 fi
17667 rm -f conftest.val
17668 else
17669   ac_cv_sizeof_unsigned_long=0
17670 fi
17671 fi
17672 echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
17673 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6
17674 cat >>confdefs.h <<_ACEOF
17675 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
17676 _ACEOF
17677
17678
17679
17680 # And one for the size of size_t (enables tweaks for > 32bit address space)
17681 echo "$as_me:$LINENO: checking for size_t" >&5
17682 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
17683 if test "${ac_cv_type_size_t+set}" = set; then
17684   echo $ECHO_N "(cached) $ECHO_C" >&6
17685 else
17686   cat >conftest.$ac_ext <<_ACEOF
17687 /* confdefs.h.  */
17688 _ACEOF
17689 cat confdefs.h >>conftest.$ac_ext
17690 cat >>conftest.$ac_ext <<_ACEOF
17691 /* end confdefs.h.  */
17692 $ac_includes_default
17693 int
17694 main ()
17695 {
17696 if ((size_t *) 0)
17697   return 0;
17698 if (sizeof (size_t))
17699   return 0;
17700   ;
17701   return 0;
17702 }
17703 _ACEOF
17704 rm -f conftest.$ac_objext
17705 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17706   (eval $ac_compile) 2>conftest.er1
17707   ac_status=$?
17708   grep -v '^ *+' conftest.er1 >conftest.err
17709   rm -f conftest.er1
17710   cat conftest.err >&5
17711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17712   (exit $ac_status); } &&
17713          { ac_try='test -z "$ac_c_werror_flag"
17714                          || test ! -s conftest.err'
17715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17716   (eval $ac_try) 2>&5
17717   ac_status=$?
17718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17719   (exit $ac_status); }; } &&
17720          { ac_try='test -s conftest.$ac_objext'
17721   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17722   (eval $ac_try) 2>&5
17723   ac_status=$?
17724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17725   (exit $ac_status); }; }; then
17726   ac_cv_type_size_t=yes
17727 else
17728   echo "$as_me: failed program was:" >&5
17729 sed 's/^/| /' conftest.$ac_ext >&5
17730
17731 ac_cv_type_size_t=no
17732 fi
17733 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17734 fi
17735 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
17736 echo "${ECHO_T}$ac_cv_type_size_t" >&6
17737
17738 echo "$as_me:$LINENO: checking size of size_t" >&5
17739 echo $ECHO_N "checking size of size_t... $ECHO_C" >&6
17740 if test "${ac_cv_sizeof_size_t+set}" = set; then
17741   echo $ECHO_N "(cached) $ECHO_C" >&6
17742 else
17743   if test "$ac_cv_type_size_t" = yes; then
17744   # The cast to unsigned long works around a bug in the HP C Compiler
17745   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17746   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
17747   # This bug is HP SR number 8606223364.
17748   if test "$cross_compiling" = yes; then
17749   # Depending upon the size, compute the lo and hi bounds.
17750 cat >conftest.$ac_ext <<_ACEOF
17751 /* confdefs.h.  */
17752 _ACEOF
17753 cat confdefs.h >>conftest.$ac_ext
17754 cat >>conftest.$ac_ext <<_ACEOF
17755 /* end confdefs.h.  */
17756 $ac_includes_default
17757 int
17758 main ()
17759 {
17760 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) >= 0)];
17761 test_array [0] = 0
17762
17763   ;
17764   return 0;
17765 }
17766 _ACEOF
17767 rm -f conftest.$ac_objext
17768 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17769   (eval $ac_compile) 2>conftest.er1
17770   ac_status=$?
17771   grep -v '^ *+' conftest.er1 >conftest.err
17772   rm -f conftest.er1
17773   cat conftest.err >&5
17774   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17775   (exit $ac_status); } &&
17776          { ac_try='test -z "$ac_c_werror_flag"
17777                          || test ! -s conftest.err'
17778   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17779   (eval $ac_try) 2>&5
17780   ac_status=$?
17781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17782   (exit $ac_status); }; } &&
17783          { ac_try='test -s conftest.$ac_objext'
17784   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17785   (eval $ac_try) 2>&5
17786   ac_status=$?
17787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17788   (exit $ac_status); }; }; then
17789   ac_lo=0 ac_mid=0
17790   while :; do
17791     cat >conftest.$ac_ext <<_ACEOF
17792 /* confdefs.h.  */
17793 _ACEOF
17794 cat confdefs.h >>conftest.$ac_ext
17795 cat >>conftest.$ac_ext <<_ACEOF
17796 /* end confdefs.h.  */
17797 $ac_includes_default
17798 int
17799 main ()
17800 {
17801 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) <= $ac_mid)];
17802 test_array [0] = 0
17803
17804   ;
17805   return 0;
17806 }
17807 _ACEOF
17808 rm -f conftest.$ac_objext
17809 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17810   (eval $ac_compile) 2>conftest.er1
17811   ac_status=$?
17812   grep -v '^ *+' conftest.er1 >conftest.err
17813   rm -f conftest.er1
17814   cat conftest.err >&5
17815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17816   (exit $ac_status); } &&
17817          { ac_try='test -z "$ac_c_werror_flag"
17818                          || test ! -s conftest.err'
17819   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17820   (eval $ac_try) 2>&5
17821   ac_status=$?
17822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17823   (exit $ac_status); }; } &&
17824          { ac_try='test -s conftest.$ac_objext'
17825   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17826   (eval $ac_try) 2>&5
17827   ac_status=$?
17828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17829   (exit $ac_status); }; }; then
17830   ac_hi=$ac_mid; break
17831 else
17832   echo "$as_me: failed program was:" >&5
17833 sed 's/^/| /' conftest.$ac_ext >&5
17834
17835 ac_lo=`expr $ac_mid + 1`
17836                     if test $ac_lo -le $ac_mid; then
17837                       ac_lo= ac_hi=
17838                       break
17839                     fi
17840                     ac_mid=`expr 2 '*' $ac_mid + 1`
17841 fi
17842 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17843   done
17844 else
17845   echo "$as_me: failed program was:" >&5
17846 sed 's/^/| /' conftest.$ac_ext >&5
17847
17848 cat >conftest.$ac_ext <<_ACEOF
17849 /* confdefs.h.  */
17850 _ACEOF
17851 cat confdefs.h >>conftest.$ac_ext
17852 cat >>conftest.$ac_ext <<_ACEOF
17853 /* end confdefs.h.  */
17854 $ac_includes_default
17855 int
17856 main ()
17857 {
17858 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) < 0)];
17859 test_array [0] = 0
17860
17861   ;
17862   return 0;
17863 }
17864 _ACEOF
17865 rm -f conftest.$ac_objext
17866 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17867   (eval $ac_compile) 2>conftest.er1
17868   ac_status=$?
17869   grep -v '^ *+' conftest.er1 >conftest.err
17870   rm -f conftest.er1
17871   cat conftest.err >&5
17872   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17873   (exit $ac_status); } &&
17874          { ac_try='test -z "$ac_c_werror_flag"
17875                          || test ! -s conftest.err'
17876   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17877   (eval $ac_try) 2>&5
17878   ac_status=$?
17879   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17880   (exit $ac_status); }; } &&
17881          { ac_try='test -s conftest.$ac_objext'
17882   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17883   (eval $ac_try) 2>&5
17884   ac_status=$?
17885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17886   (exit $ac_status); }; }; then
17887   ac_hi=-1 ac_mid=-1
17888   while :; do
17889     cat >conftest.$ac_ext <<_ACEOF
17890 /* confdefs.h.  */
17891 _ACEOF
17892 cat confdefs.h >>conftest.$ac_ext
17893 cat >>conftest.$ac_ext <<_ACEOF
17894 /* end confdefs.h.  */
17895 $ac_includes_default
17896 int
17897 main ()
17898 {
17899 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) >= $ac_mid)];
17900 test_array [0] = 0
17901
17902   ;
17903   return 0;
17904 }
17905 _ACEOF
17906 rm -f conftest.$ac_objext
17907 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17908   (eval $ac_compile) 2>conftest.er1
17909   ac_status=$?
17910   grep -v '^ *+' conftest.er1 >conftest.err
17911   rm -f conftest.er1
17912   cat conftest.err >&5
17913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17914   (exit $ac_status); } &&
17915          { ac_try='test -z "$ac_c_werror_flag"
17916                          || test ! -s conftest.err'
17917   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17918   (eval $ac_try) 2>&5
17919   ac_status=$?
17920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17921   (exit $ac_status); }; } &&
17922          { ac_try='test -s conftest.$ac_objext'
17923   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17924   (eval $ac_try) 2>&5
17925   ac_status=$?
17926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17927   (exit $ac_status); }; }; then
17928   ac_lo=$ac_mid; break
17929 else
17930   echo "$as_me: failed program was:" >&5
17931 sed 's/^/| /' conftest.$ac_ext >&5
17932
17933 ac_hi=`expr '(' $ac_mid ')' - 1`
17934                        if test $ac_mid -le $ac_hi; then
17935                          ac_lo= ac_hi=
17936                          break
17937                        fi
17938                        ac_mid=`expr 2 '*' $ac_mid`
17939 fi
17940 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17941   done
17942 else
17943   echo "$as_me: failed program was:" >&5
17944 sed 's/^/| /' conftest.$ac_ext >&5
17945
17946 ac_lo= ac_hi=
17947 fi
17948 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17949 fi
17950 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17951 # Binary search between lo and hi bounds.
17952 while test "x$ac_lo" != "x$ac_hi"; do
17953   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
17954   cat >conftest.$ac_ext <<_ACEOF
17955 /* confdefs.h.  */
17956 _ACEOF
17957 cat confdefs.h >>conftest.$ac_ext
17958 cat >>conftest.$ac_ext <<_ACEOF
17959 /* end confdefs.h.  */
17960 $ac_includes_default
17961 int
17962 main ()
17963 {
17964 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) <= $ac_mid)];
17965 test_array [0] = 0
17966
17967   ;
17968   return 0;
17969 }
17970 _ACEOF
17971 rm -f conftest.$ac_objext
17972 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17973   (eval $ac_compile) 2>conftest.er1
17974   ac_status=$?
17975   grep -v '^ *+' conftest.er1 >conftest.err
17976   rm -f conftest.er1
17977   cat conftest.err >&5
17978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17979   (exit $ac_status); } &&
17980          { ac_try='test -z "$ac_c_werror_flag"
17981                          || test ! -s conftest.err'
17982   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17983   (eval $ac_try) 2>&5
17984   ac_status=$?
17985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17986   (exit $ac_status); }; } &&
17987          { ac_try='test -s conftest.$ac_objext'
17988   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17989   (eval $ac_try) 2>&5
17990   ac_status=$?
17991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17992   (exit $ac_status); }; }; then
17993   ac_hi=$ac_mid
17994 else
17995   echo "$as_me: failed program was:" >&5
17996 sed 's/^/| /' conftest.$ac_ext >&5
17997
17998 ac_lo=`expr '(' $ac_mid ')' + 1`
17999 fi
18000 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18001 done
18002 case $ac_lo in
18003 ?*) ac_cv_sizeof_size_t=$ac_lo;;
18004 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t), 77
18005 See \`config.log' for more details." >&5
18006 echo "$as_me: error: cannot compute sizeof (size_t), 77
18007 See \`config.log' for more details." >&2;}
18008    { (exit 1); exit 1; }; } ;;
18009 esac
18010 else
18011   if test "$cross_compiling" = yes; then
18012   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18013 See \`config.log' for more details." >&5
18014 echo "$as_me: error: cannot run test program while cross compiling
18015 See \`config.log' for more details." >&2;}
18016    { (exit 1); exit 1; }; }
18017 else
18018   cat >conftest.$ac_ext <<_ACEOF
18019 /* confdefs.h.  */
18020 _ACEOF
18021 cat confdefs.h >>conftest.$ac_ext
18022 cat >>conftest.$ac_ext <<_ACEOF
18023 /* end confdefs.h.  */
18024 $ac_includes_default
18025 long longval () { return (long) (sizeof (size_t)); }
18026 unsigned long ulongval () { return (long) (sizeof (size_t)); }
18027 #include <stdio.h>
18028 #include <stdlib.h>
18029 int
18030 main ()
18031 {
18032
18033   FILE *f = fopen ("conftest.val", "w");
18034   if (! f)
18035     exit (1);
18036   if (((long) (sizeof (size_t))) < 0)
18037     {
18038       long i = longval ();
18039       if (i != ((long) (sizeof (size_t))))
18040         exit (1);
18041       fprintf (f, "%ld\n", i);
18042     }
18043   else
18044     {
18045       unsigned long i = ulongval ();
18046       if (i != ((long) (sizeof (size_t))))
18047         exit (1);
18048       fprintf (f, "%lu\n", i);
18049     }
18050   exit (ferror (f) || fclose (f) != 0);
18051
18052   ;
18053   return 0;
18054 }
18055 _ACEOF
18056 rm -f conftest$ac_exeext
18057 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18058   (eval $ac_link) 2>&5
18059   ac_status=$?
18060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18061   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18062   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18063   (eval $ac_try) 2>&5
18064   ac_status=$?
18065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18066   (exit $ac_status); }; }; then
18067   ac_cv_sizeof_size_t=`cat conftest.val`
18068 else
18069   echo "$as_me: program exited with status $ac_status" >&5
18070 echo "$as_me: failed program was:" >&5
18071 sed 's/^/| /' conftest.$ac_ext >&5
18072
18073 ( exit $ac_status )
18074 { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t), 77
18075 See \`config.log' for more details." >&5
18076 echo "$as_me: error: cannot compute sizeof (size_t), 77
18077 See \`config.log' for more details." >&2;}
18078    { (exit 1); exit 1; }; }
18079 fi
18080 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18081 fi
18082 fi
18083 rm -f conftest.val
18084 else
18085   ac_cv_sizeof_size_t=0
18086 fi
18087 fi
18088 echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
18089 echo "${ECHO_T}$ac_cv_sizeof_size_t" >&6
18090 cat >>confdefs.h <<_ACEOF
18091 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
18092 _ACEOF
18093
18094
18095
18096 # Determine memory alignment requirements for the basic C data types.
18097
18098 echo "$as_me:$LINENO: checking for short" >&5
18099 echo $ECHO_N "checking for short... $ECHO_C" >&6
18100 if test "${ac_cv_type_short+set}" = set; then
18101   echo $ECHO_N "(cached) $ECHO_C" >&6
18102 else
18103   cat >conftest.$ac_ext <<_ACEOF
18104 /* confdefs.h.  */
18105 _ACEOF
18106 cat confdefs.h >>conftest.$ac_ext
18107 cat >>conftest.$ac_ext <<_ACEOF
18108 /* end confdefs.h.  */
18109 $ac_includes_default
18110 int
18111 main ()
18112 {
18113 if ((short *) 0)
18114   return 0;
18115 if (sizeof (short))
18116   return 0;
18117   ;
18118   return 0;
18119 }
18120 _ACEOF
18121 rm -f conftest.$ac_objext
18122 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18123   (eval $ac_compile) 2>conftest.er1
18124   ac_status=$?
18125   grep -v '^ *+' conftest.er1 >conftest.err
18126   rm -f conftest.er1
18127   cat conftest.err >&5
18128   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18129   (exit $ac_status); } &&
18130          { ac_try='test -z "$ac_c_werror_flag"
18131                          || test ! -s conftest.err'
18132   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18133   (eval $ac_try) 2>&5
18134   ac_status=$?
18135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18136   (exit $ac_status); }; } &&
18137          { ac_try='test -s conftest.$ac_objext'
18138   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18139   (eval $ac_try) 2>&5
18140   ac_status=$?
18141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18142   (exit $ac_status); }; }; then
18143   ac_cv_type_short=yes
18144 else
18145   echo "$as_me: failed program was:" >&5
18146 sed 's/^/| /' conftest.$ac_ext >&5
18147
18148 ac_cv_type_short=no
18149 fi
18150 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18151 fi
18152 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
18153 echo "${ECHO_T}$ac_cv_type_short" >&6
18154
18155 echo "$as_me:$LINENO: checking alignment of short" >&5
18156 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6
18157 if test "${pgac_cv_alignof_short+set}" = set; then
18158   echo $ECHO_N "(cached) $ECHO_C" >&6
18159 else
18160   if test "$ac_cv_type_short" = yes; then
18161   if test "$cross_compiling" = yes; then
18162   # Depending upon the size, compute the lo and hi bounds.
18163 cat >conftest.$ac_ext <<_ACEOF
18164 /* confdefs.h.  */
18165 _ACEOF
18166 cat confdefs.h >>conftest.$ac_ext
18167 cat >>conftest.$ac_ext <<_ACEOF
18168 /* end confdefs.h.  */
18169 $ac_includes_default
18170 struct { char filler; short field; } pgac_struct;
18171 int
18172 main ()
18173 {
18174 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
18175 test_array [0] = 0
18176
18177   ;
18178   return 0;
18179 }
18180 _ACEOF
18181 rm -f conftest.$ac_objext
18182 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18183   (eval $ac_compile) 2>conftest.er1
18184   ac_status=$?
18185   grep -v '^ *+' conftest.er1 >conftest.err
18186   rm -f conftest.er1
18187   cat conftest.err >&5
18188   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18189   (exit $ac_status); } &&
18190          { ac_try='test -z "$ac_c_werror_flag"
18191                          || test ! -s conftest.err'
18192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18193   (eval $ac_try) 2>&5
18194   ac_status=$?
18195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18196   (exit $ac_status); }; } &&
18197          { ac_try='test -s conftest.$ac_objext'
18198   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18199   (eval $ac_try) 2>&5
18200   ac_status=$?
18201   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18202   (exit $ac_status); }; }; then
18203   ac_lo=0 ac_mid=0
18204   while :; do
18205     cat >conftest.$ac_ext <<_ACEOF
18206 /* confdefs.h.  */
18207 _ACEOF
18208 cat confdefs.h >>conftest.$ac_ext
18209 cat >>conftest.$ac_ext <<_ACEOF
18210 /* end confdefs.h.  */
18211 $ac_includes_default
18212 struct { char filler; short field; } pgac_struct;
18213 int
18214 main ()
18215 {
18216 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18217 test_array [0] = 0
18218
18219   ;
18220   return 0;
18221 }
18222 _ACEOF
18223 rm -f conftest.$ac_objext
18224 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18225   (eval $ac_compile) 2>conftest.er1
18226   ac_status=$?
18227   grep -v '^ *+' conftest.er1 >conftest.err
18228   rm -f conftest.er1
18229   cat conftest.err >&5
18230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18231   (exit $ac_status); } &&
18232          { ac_try='test -z "$ac_c_werror_flag"
18233                          || test ! -s conftest.err'
18234   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18235   (eval $ac_try) 2>&5
18236   ac_status=$?
18237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18238   (exit $ac_status); }; } &&
18239          { ac_try='test -s conftest.$ac_objext'
18240   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18241   (eval $ac_try) 2>&5
18242   ac_status=$?
18243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18244   (exit $ac_status); }; }; then
18245   ac_hi=$ac_mid; break
18246 else
18247   echo "$as_me: failed program was:" >&5
18248 sed 's/^/| /' conftest.$ac_ext >&5
18249
18250 ac_lo=`expr $ac_mid + 1`
18251                     if test $ac_lo -le $ac_mid; then
18252                       ac_lo= ac_hi=
18253                       break
18254                     fi
18255                     ac_mid=`expr 2 '*' $ac_mid + 1`
18256 fi
18257 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18258   done
18259 else
18260   echo "$as_me: failed program was:" >&5
18261 sed 's/^/| /' conftest.$ac_ext >&5
18262
18263 cat >conftest.$ac_ext <<_ACEOF
18264 /* confdefs.h.  */
18265 _ACEOF
18266 cat confdefs.h >>conftest.$ac_ext
18267 cat >>conftest.$ac_ext <<_ACEOF
18268 /* end confdefs.h.  */
18269 $ac_includes_default
18270 struct { char filler; short field; } pgac_struct;
18271 int
18272 main ()
18273 {
18274 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
18275 test_array [0] = 0
18276
18277   ;
18278   return 0;
18279 }
18280 _ACEOF
18281 rm -f conftest.$ac_objext
18282 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18283   (eval $ac_compile) 2>conftest.er1
18284   ac_status=$?
18285   grep -v '^ *+' conftest.er1 >conftest.err
18286   rm -f conftest.er1
18287   cat conftest.err >&5
18288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18289   (exit $ac_status); } &&
18290          { ac_try='test -z "$ac_c_werror_flag"
18291                          || test ! -s conftest.err'
18292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18293   (eval $ac_try) 2>&5
18294   ac_status=$?
18295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18296   (exit $ac_status); }; } &&
18297          { ac_try='test -s conftest.$ac_objext'
18298   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18299   (eval $ac_try) 2>&5
18300   ac_status=$?
18301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18302   (exit $ac_status); }; }; then
18303   ac_hi=-1 ac_mid=-1
18304   while :; do
18305     cat >conftest.$ac_ext <<_ACEOF
18306 /* confdefs.h.  */
18307 _ACEOF
18308 cat confdefs.h >>conftest.$ac_ext
18309 cat >>conftest.$ac_ext <<_ACEOF
18310 /* end confdefs.h.  */
18311 $ac_includes_default
18312 struct { char filler; short field; } pgac_struct;
18313 int
18314 main ()
18315 {
18316 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
18317 test_array [0] = 0
18318
18319   ;
18320   return 0;
18321 }
18322 _ACEOF
18323 rm -f conftest.$ac_objext
18324 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18325   (eval $ac_compile) 2>conftest.er1
18326   ac_status=$?
18327   grep -v '^ *+' conftest.er1 >conftest.err
18328   rm -f conftest.er1
18329   cat conftest.err >&5
18330   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18331   (exit $ac_status); } &&
18332          { ac_try='test -z "$ac_c_werror_flag"
18333                          || test ! -s conftest.err'
18334   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18335   (eval $ac_try) 2>&5
18336   ac_status=$?
18337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18338   (exit $ac_status); }; } &&
18339          { ac_try='test -s conftest.$ac_objext'
18340   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18341   (eval $ac_try) 2>&5
18342   ac_status=$?
18343   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18344   (exit $ac_status); }; }; then
18345   ac_lo=$ac_mid; break
18346 else
18347   echo "$as_me: failed program was:" >&5
18348 sed 's/^/| /' conftest.$ac_ext >&5
18349
18350 ac_hi=`expr '(' $ac_mid ')' - 1`
18351                        if test $ac_mid -le $ac_hi; then
18352                          ac_lo= ac_hi=
18353                          break
18354                        fi
18355                        ac_mid=`expr 2 '*' $ac_mid`
18356 fi
18357 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18358   done
18359 else
18360   echo "$as_me: failed program was:" >&5
18361 sed 's/^/| /' conftest.$ac_ext >&5
18362
18363 ac_lo= ac_hi=
18364 fi
18365 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18366 fi
18367 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18368 # Binary search between lo and hi bounds.
18369 while test "x$ac_lo" != "x$ac_hi"; do
18370   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18371   cat >conftest.$ac_ext <<_ACEOF
18372 /* confdefs.h.  */
18373 _ACEOF
18374 cat confdefs.h >>conftest.$ac_ext
18375 cat >>conftest.$ac_ext <<_ACEOF
18376 /* end confdefs.h.  */
18377 $ac_includes_default
18378 struct { char filler; short field; } pgac_struct;
18379 int
18380 main ()
18381 {
18382 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18383 test_array [0] = 0
18384
18385   ;
18386   return 0;
18387 }
18388 _ACEOF
18389 rm -f conftest.$ac_objext
18390 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18391   (eval $ac_compile) 2>conftest.er1
18392   ac_status=$?
18393   grep -v '^ *+' conftest.er1 >conftest.err
18394   rm -f conftest.er1
18395   cat conftest.err >&5
18396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18397   (exit $ac_status); } &&
18398          { ac_try='test -z "$ac_c_werror_flag"
18399                          || test ! -s conftest.err'
18400   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18401   (eval $ac_try) 2>&5
18402   ac_status=$?
18403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18404   (exit $ac_status); }; } &&
18405          { ac_try='test -s conftest.$ac_objext'
18406   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18407   (eval $ac_try) 2>&5
18408   ac_status=$?
18409   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18410   (exit $ac_status); }; }; then
18411   ac_hi=$ac_mid
18412 else
18413   echo "$as_me: failed program was:" >&5
18414 sed 's/^/| /' conftest.$ac_ext >&5
18415
18416 ac_lo=`expr '(' $ac_mid ')' + 1`
18417 fi
18418 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18419 done
18420 case $ac_lo in
18421 ?*) pgac_cv_alignof_short=$ac_lo;;
18422 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
18423 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
18424    { (exit 1); exit 1; }; } ;;
18425 esac
18426 else
18427   if test "$cross_compiling" = yes; then
18428   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18429 See \`config.log' for more details." >&5
18430 echo "$as_me: error: cannot run test program while cross compiling
18431 See \`config.log' for more details." >&2;}
18432    { (exit 1); exit 1; }; }
18433 else
18434   cat >conftest.$ac_ext <<_ACEOF
18435 /* confdefs.h.  */
18436 _ACEOF
18437 cat confdefs.h >>conftest.$ac_ext
18438 cat >>conftest.$ac_ext <<_ACEOF
18439 /* end confdefs.h.  */
18440 $ac_includes_default
18441 struct { char filler; short field; } pgac_struct;
18442 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18443 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18444 #include <stdio.h>
18445 #include <stdlib.h>
18446 int
18447 main ()
18448 {
18449
18450   FILE *f = fopen ("conftest.val", "w");
18451   if (! f)
18452     exit (1);
18453   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
18454     {
18455       long i = longval ();
18456       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18457         exit (1);
18458       fprintf (f, "%ld\n", i);
18459     }
18460   else
18461     {
18462       unsigned long i = ulongval ();
18463       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18464         exit (1);
18465       fprintf (f, "%lu\n", i);
18466     }
18467   exit (ferror (f) || fclose (f) != 0);
18468
18469   ;
18470   return 0;
18471 }
18472 _ACEOF
18473 rm -f conftest$ac_exeext
18474 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18475   (eval $ac_link) 2>&5
18476   ac_status=$?
18477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18478   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18480   (eval $ac_try) 2>&5
18481   ac_status=$?
18482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18483   (exit $ac_status); }; }; then
18484   pgac_cv_alignof_short=`cat conftest.val`
18485 else
18486   echo "$as_me: program exited with status $ac_status" >&5
18487 echo "$as_me: failed program was:" >&5
18488 sed 's/^/| /' conftest.$ac_ext >&5
18489
18490 ( exit $ac_status )
18491 { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
18492 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
18493    { (exit 1); exit 1; }; }
18494 fi
18495 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18496 fi
18497 fi
18498 rm -f conftest.val
18499 else
18500   pgac_cv_alignof_short=0
18501 fi
18502 fi
18503 echo "$as_me:$LINENO: result: $pgac_cv_alignof_short" >&5
18504 echo "${ECHO_T}$pgac_cv_alignof_short" >&6
18505 cat >>confdefs.h <<_ACEOF
18506 #define ALIGNOF_SHORT $pgac_cv_alignof_short
18507 _ACEOF
18508
18509
18510 echo "$as_me:$LINENO: checking for int" >&5
18511 echo $ECHO_N "checking for int... $ECHO_C" >&6
18512 if test "${ac_cv_type_int+set}" = set; then
18513   echo $ECHO_N "(cached) $ECHO_C" >&6
18514 else
18515   cat >conftest.$ac_ext <<_ACEOF
18516 /* confdefs.h.  */
18517 _ACEOF
18518 cat confdefs.h >>conftest.$ac_ext
18519 cat >>conftest.$ac_ext <<_ACEOF
18520 /* end confdefs.h.  */
18521 $ac_includes_default
18522 int
18523 main ()
18524 {
18525 if ((int *) 0)
18526   return 0;
18527 if (sizeof (int))
18528   return 0;
18529   ;
18530   return 0;
18531 }
18532 _ACEOF
18533 rm -f conftest.$ac_objext
18534 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18535   (eval $ac_compile) 2>conftest.er1
18536   ac_status=$?
18537   grep -v '^ *+' conftest.er1 >conftest.err
18538   rm -f conftest.er1
18539   cat conftest.err >&5
18540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18541   (exit $ac_status); } &&
18542          { ac_try='test -z "$ac_c_werror_flag"
18543                          || test ! -s conftest.err'
18544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18545   (eval $ac_try) 2>&5
18546   ac_status=$?
18547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18548   (exit $ac_status); }; } &&
18549          { ac_try='test -s conftest.$ac_objext'
18550   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18551   (eval $ac_try) 2>&5
18552   ac_status=$?
18553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18554   (exit $ac_status); }; }; then
18555   ac_cv_type_int=yes
18556 else
18557   echo "$as_me: failed program was:" >&5
18558 sed 's/^/| /' conftest.$ac_ext >&5
18559
18560 ac_cv_type_int=no
18561 fi
18562 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18563 fi
18564 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
18565 echo "${ECHO_T}$ac_cv_type_int" >&6
18566
18567 echo "$as_me:$LINENO: checking alignment of int" >&5
18568 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6
18569 if test "${pgac_cv_alignof_int+set}" = set; then
18570   echo $ECHO_N "(cached) $ECHO_C" >&6
18571 else
18572   if test "$ac_cv_type_int" = yes; then
18573   if test "$cross_compiling" = yes; then
18574   # Depending upon the size, compute the lo and hi bounds.
18575 cat >conftest.$ac_ext <<_ACEOF
18576 /* confdefs.h.  */
18577 _ACEOF
18578 cat confdefs.h >>conftest.$ac_ext
18579 cat >>conftest.$ac_ext <<_ACEOF
18580 /* end confdefs.h.  */
18581 $ac_includes_default
18582 struct { char filler; int field; } pgac_struct;
18583 int
18584 main ()
18585 {
18586 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
18587 test_array [0] = 0
18588
18589   ;
18590   return 0;
18591 }
18592 _ACEOF
18593 rm -f conftest.$ac_objext
18594 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18595   (eval $ac_compile) 2>conftest.er1
18596   ac_status=$?
18597   grep -v '^ *+' conftest.er1 >conftest.err
18598   rm -f conftest.er1
18599   cat conftest.err >&5
18600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18601   (exit $ac_status); } &&
18602          { ac_try='test -z "$ac_c_werror_flag"
18603                          || test ! -s conftest.err'
18604   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18605   (eval $ac_try) 2>&5
18606   ac_status=$?
18607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18608   (exit $ac_status); }; } &&
18609          { ac_try='test -s conftest.$ac_objext'
18610   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18611   (eval $ac_try) 2>&5
18612   ac_status=$?
18613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18614   (exit $ac_status); }; }; then
18615   ac_lo=0 ac_mid=0
18616   while :; do
18617     cat >conftest.$ac_ext <<_ACEOF
18618 /* confdefs.h.  */
18619 _ACEOF
18620 cat confdefs.h >>conftest.$ac_ext
18621 cat >>conftest.$ac_ext <<_ACEOF
18622 /* end confdefs.h.  */
18623 $ac_includes_default
18624 struct { char filler; int field; } pgac_struct;
18625 int
18626 main ()
18627 {
18628 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18629 test_array [0] = 0
18630
18631   ;
18632   return 0;
18633 }
18634 _ACEOF
18635 rm -f conftest.$ac_objext
18636 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18637   (eval $ac_compile) 2>conftest.er1
18638   ac_status=$?
18639   grep -v '^ *+' conftest.er1 >conftest.err
18640   rm -f conftest.er1
18641   cat conftest.err >&5
18642   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18643   (exit $ac_status); } &&
18644          { ac_try='test -z "$ac_c_werror_flag"
18645                          || test ! -s conftest.err'
18646   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18647   (eval $ac_try) 2>&5
18648   ac_status=$?
18649   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18650   (exit $ac_status); }; } &&
18651          { ac_try='test -s conftest.$ac_objext'
18652   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18653   (eval $ac_try) 2>&5
18654   ac_status=$?
18655   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18656   (exit $ac_status); }; }; then
18657   ac_hi=$ac_mid; break
18658 else
18659   echo "$as_me: failed program was:" >&5
18660 sed 's/^/| /' conftest.$ac_ext >&5
18661
18662 ac_lo=`expr $ac_mid + 1`
18663                     if test $ac_lo -le $ac_mid; then
18664                       ac_lo= ac_hi=
18665                       break
18666                     fi
18667                     ac_mid=`expr 2 '*' $ac_mid + 1`
18668 fi
18669 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18670   done
18671 else
18672   echo "$as_me: failed program was:" >&5
18673 sed 's/^/| /' conftest.$ac_ext >&5
18674
18675 cat >conftest.$ac_ext <<_ACEOF
18676 /* confdefs.h.  */
18677 _ACEOF
18678 cat confdefs.h >>conftest.$ac_ext
18679 cat >>conftest.$ac_ext <<_ACEOF
18680 /* end confdefs.h.  */
18681 $ac_includes_default
18682 struct { char filler; int field; } pgac_struct;
18683 int
18684 main ()
18685 {
18686 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
18687 test_array [0] = 0
18688
18689   ;
18690   return 0;
18691 }
18692 _ACEOF
18693 rm -f conftest.$ac_objext
18694 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18695   (eval $ac_compile) 2>conftest.er1
18696   ac_status=$?
18697   grep -v '^ *+' conftest.er1 >conftest.err
18698   rm -f conftest.er1
18699   cat conftest.err >&5
18700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18701   (exit $ac_status); } &&
18702          { ac_try='test -z "$ac_c_werror_flag"
18703                          || test ! -s conftest.err'
18704   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18705   (eval $ac_try) 2>&5
18706   ac_status=$?
18707   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18708   (exit $ac_status); }; } &&
18709          { ac_try='test -s conftest.$ac_objext'
18710   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18711   (eval $ac_try) 2>&5
18712   ac_status=$?
18713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18714   (exit $ac_status); }; }; then
18715   ac_hi=-1 ac_mid=-1
18716   while :; do
18717     cat >conftest.$ac_ext <<_ACEOF
18718 /* confdefs.h.  */
18719 _ACEOF
18720 cat confdefs.h >>conftest.$ac_ext
18721 cat >>conftest.$ac_ext <<_ACEOF
18722 /* end confdefs.h.  */
18723 $ac_includes_default
18724 struct { char filler; int field; } pgac_struct;
18725 int
18726 main ()
18727 {
18728 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
18729 test_array [0] = 0
18730
18731   ;
18732   return 0;
18733 }
18734 _ACEOF
18735 rm -f conftest.$ac_objext
18736 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18737   (eval $ac_compile) 2>conftest.er1
18738   ac_status=$?
18739   grep -v '^ *+' conftest.er1 >conftest.err
18740   rm -f conftest.er1
18741   cat conftest.err >&5
18742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18743   (exit $ac_status); } &&
18744          { ac_try='test -z "$ac_c_werror_flag"
18745                          || test ! -s conftest.err'
18746   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18747   (eval $ac_try) 2>&5
18748   ac_status=$?
18749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18750   (exit $ac_status); }; } &&
18751          { ac_try='test -s conftest.$ac_objext'
18752   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18753   (eval $ac_try) 2>&5
18754   ac_status=$?
18755   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18756   (exit $ac_status); }; }; then
18757   ac_lo=$ac_mid; break
18758 else
18759   echo "$as_me: failed program was:" >&5
18760 sed 's/^/| /' conftest.$ac_ext >&5
18761
18762 ac_hi=`expr '(' $ac_mid ')' - 1`
18763                        if test $ac_mid -le $ac_hi; then
18764                          ac_lo= ac_hi=
18765                          break
18766                        fi
18767                        ac_mid=`expr 2 '*' $ac_mid`
18768 fi
18769 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18770   done
18771 else
18772   echo "$as_me: failed program was:" >&5
18773 sed 's/^/| /' conftest.$ac_ext >&5
18774
18775 ac_lo= ac_hi=
18776 fi
18777 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18778 fi
18779 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18780 # Binary search between lo and hi bounds.
18781 while test "x$ac_lo" != "x$ac_hi"; do
18782   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18783   cat >conftest.$ac_ext <<_ACEOF
18784 /* confdefs.h.  */
18785 _ACEOF
18786 cat confdefs.h >>conftest.$ac_ext
18787 cat >>conftest.$ac_ext <<_ACEOF
18788 /* end confdefs.h.  */
18789 $ac_includes_default
18790 struct { char filler; int field; } pgac_struct;
18791 int
18792 main ()
18793 {
18794 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18795 test_array [0] = 0
18796
18797   ;
18798   return 0;
18799 }
18800 _ACEOF
18801 rm -f conftest.$ac_objext
18802 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18803   (eval $ac_compile) 2>conftest.er1
18804   ac_status=$?
18805   grep -v '^ *+' conftest.er1 >conftest.err
18806   rm -f conftest.er1
18807   cat conftest.err >&5
18808   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18809   (exit $ac_status); } &&
18810          { ac_try='test -z "$ac_c_werror_flag"
18811                          || test ! -s conftest.err'
18812   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18813   (eval $ac_try) 2>&5
18814   ac_status=$?
18815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18816   (exit $ac_status); }; } &&
18817          { ac_try='test -s conftest.$ac_objext'
18818   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18819   (eval $ac_try) 2>&5
18820   ac_status=$?
18821   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18822   (exit $ac_status); }; }; then
18823   ac_hi=$ac_mid
18824 else
18825   echo "$as_me: failed program was:" >&5
18826 sed 's/^/| /' conftest.$ac_ext >&5
18827
18828 ac_lo=`expr '(' $ac_mid ')' + 1`
18829 fi
18830 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18831 done
18832 case $ac_lo in
18833 ?*) pgac_cv_alignof_int=$ac_lo;;
18834 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
18835 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
18836    { (exit 1); exit 1; }; } ;;
18837 esac
18838 else
18839   if test "$cross_compiling" = yes; then
18840   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18841 See \`config.log' for more details." >&5
18842 echo "$as_me: error: cannot run test program while cross compiling
18843 See \`config.log' for more details." >&2;}
18844    { (exit 1); exit 1; }; }
18845 else
18846   cat >conftest.$ac_ext <<_ACEOF
18847 /* confdefs.h.  */
18848 _ACEOF
18849 cat confdefs.h >>conftest.$ac_ext
18850 cat >>conftest.$ac_ext <<_ACEOF
18851 /* end confdefs.h.  */
18852 $ac_includes_default
18853 struct { char filler; int field; } pgac_struct;
18854 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18855 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18856 #include <stdio.h>
18857 #include <stdlib.h>
18858 int
18859 main ()
18860 {
18861
18862   FILE *f = fopen ("conftest.val", "w");
18863   if (! f)
18864     exit (1);
18865   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
18866     {
18867       long i = longval ();
18868       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18869         exit (1);
18870       fprintf (f, "%ld\n", i);
18871     }
18872   else
18873     {
18874       unsigned long i = ulongval ();
18875       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18876         exit (1);
18877       fprintf (f, "%lu\n", i);
18878     }
18879   exit (ferror (f) || fclose (f) != 0);
18880
18881   ;
18882   return 0;
18883 }
18884 _ACEOF
18885 rm -f conftest$ac_exeext
18886 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18887   (eval $ac_link) 2>&5
18888   ac_status=$?
18889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18890   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18891   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18892   (eval $ac_try) 2>&5
18893   ac_status=$?
18894   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18895   (exit $ac_status); }; }; then
18896   pgac_cv_alignof_int=`cat conftest.val`
18897 else
18898   echo "$as_me: program exited with status $ac_status" >&5
18899 echo "$as_me: failed program was:" >&5
18900 sed 's/^/| /' conftest.$ac_ext >&5
18901
18902 ( exit $ac_status )
18903 { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
18904 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
18905    { (exit 1); exit 1; }; }
18906 fi
18907 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18908 fi
18909 fi
18910 rm -f conftest.val
18911 else
18912   pgac_cv_alignof_int=0
18913 fi
18914 fi
18915 echo "$as_me:$LINENO: result: $pgac_cv_alignof_int" >&5
18916 echo "${ECHO_T}$pgac_cv_alignof_int" >&6
18917 cat >>confdefs.h <<_ACEOF
18918 #define ALIGNOF_INT $pgac_cv_alignof_int
18919 _ACEOF
18920
18921
18922 echo "$as_me:$LINENO: checking for long" >&5
18923 echo $ECHO_N "checking for long... $ECHO_C" >&6
18924 if test "${ac_cv_type_long+set}" = set; then
18925   echo $ECHO_N "(cached) $ECHO_C" >&6
18926 else
18927   cat >conftest.$ac_ext <<_ACEOF
18928 /* confdefs.h.  */
18929 _ACEOF
18930 cat confdefs.h >>conftest.$ac_ext
18931 cat >>conftest.$ac_ext <<_ACEOF
18932 /* end confdefs.h.  */
18933 $ac_includes_default
18934 int
18935 main ()
18936 {
18937 if ((long *) 0)
18938   return 0;
18939 if (sizeof (long))
18940   return 0;
18941   ;
18942   return 0;
18943 }
18944 _ACEOF
18945 rm -f conftest.$ac_objext
18946 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18947   (eval $ac_compile) 2>conftest.er1
18948   ac_status=$?
18949   grep -v '^ *+' conftest.er1 >conftest.err
18950   rm -f conftest.er1
18951   cat conftest.err >&5
18952   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18953   (exit $ac_status); } &&
18954          { ac_try='test -z "$ac_c_werror_flag"
18955                          || test ! -s conftest.err'
18956   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18957   (eval $ac_try) 2>&5
18958   ac_status=$?
18959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18960   (exit $ac_status); }; } &&
18961          { ac_try='test -s conftest.$ac_objext'
18962   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18963   (eval $ac_try) 2>&5
18964   ac_status=$?
18965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18966   (exit $ac_status); }; }; then
18967   ac_cv_type_long=yes
18968 else
18969   echo "$as_me: failed program was:" >&5
18970 sed 's/^/| /' conftest.$ac_ext >&5
18971
18972 ac_cv_type_long=no
18973 fi
18974 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18975 fi
18976 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
18977 echo "${ECHO_T}$ac_cv_type_long" >&6
18978
18979 echo "$as_me:$LINENO: checking alignment of long" >&5
18980 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6
18981 if test "${pgac_cv_alignof_long+set}" = set; then
18982   echo $ECHO_N "(cached) $ECHO_C" >&6
18983 else
18984   if test "$ac_cv_type_long" = yes; then
18985   if test "$cross_compiling" = yes; then
18986   # Depending upon the size, compute the lo and hi bounds.
18987 cat >conftest.$ac_ext <<_ACEOF
18988 /* confdefs.h.  */
18989 _ACEOF
18990 cat confdefs.h >>conftest.$ac_ext
18991 cat >>conftest.$ac_ext <<_ACEOF
18992 /* end confdefs.h.  */
18993 $ac_includes_default
18994 struct { char filler; long field; } pgac_struct;
18995 int
18996 main ()
18997 {
18998 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
18999 test_array [0] = 0
19000
19001   ;
19002   return 0;
19003 }
19004 _ACEOF
19005 rm -f conftest.$ac_objext
19006 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19007   (eval $ac_compile) 2>conftest.er1
19008   ac_status=$?
19009   grep -v '^ *+' conftest.er1 >conftest.err
19010   rm -f conftest.er1
19011   cat conftest.err >&5
19012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19013   (exit $ac_status); } &&
19014          { ac_try='test -z "$ac_c_werror_flag"
19015                          || test ! -s conftest.err'
19016   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19017   (eval $ac_try) 2>&5
19018   ac_status=$?
19019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19020   (exit $ac_status); }; } &&
19021          { ac_try='test -s conftest.$ac_objext'
19022   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19023   (eval $ac_try) 2>&5
19024   ac_status=$?
19025   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19026   (exit $ac_status); }; }; then
19027   ac_lo=0 ac_mid=0
19028   while :; do
19029     cat >conftest.$ac_ext <<_ACEOF
19030 /* confdefs.h.  */
19031 _ACEOF
19032 cat confdefs.h >>conftest.$ac_ext
19033 cat >>conftest.$ac_ext <<_ACEOF
19034 /* end confdefs.h.  */
19035 $ac_includes_default
19036 struct { char filler; long field; } pgac_struct;
19037 int
19038 main ()
19039 {
19040 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19041 test_array [0] = 0
19042
19043   ;
19044   return 0;
19045 }
19046 _ACEOF
19047 rm -f conftest.$ac_objext
19048 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19049   (eval $ac_compile) 2>conftest.er1
19050   ac_status=$?
19051   grep -v '^ *+' conftest.er1 >conftest.err
19052   rm -f conftest.er1
19053   cat conftest.err >&5
19054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19055   (exit $ac_status); } &&
19056          { ac_try='test -z "$ac_c_werror_flag"
19057                          || test ! -s conftest.err'
19058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19059   (eval $ac_try) 2>&5
19060   ac_status=$?
19061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19062   (exit $ac_status); }; } &&
19063          { ac_try='test -s conftest.$ac_objext'
19064   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19065   (eval $ac_try) 2>&5
19066   ac_status=$?
19067   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19068   (exit $ac_status); }; }; then
19069   ac_hi=$ac_mid; break
19070 else
19071   echo "$as_me: failed program was:" >&5
19072 sed 's/^/| /' conftest.$ac_ext >&5
19073
19074 ac_lo=`expr $ac_mid + 1`
19075                     if test $ac_lo -le $ac_mid; then
19076                       ac_lo= ac_hi=
19077                       break
19078                     fi
19079                     ac_mid=`expr 2 '*' $ac_mid + 1`
19080 fi
19081 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19082   done
19083 else
19084   echo "$as_me: failed program was:" >&5
19085 sed 's/^/| /' conftest.$ac_ext >&5
19086
19087 cat >conftest.$ac_ext <<_ACEOF
19088 /* confdefs.h.  */
19089 _ACEOF
19090 cat confdefs.h >>conftest.$ac_ext
19091 cat >>conftest.$ac_ext <<_ACEOF
19092 /* end confdefs.h.  */
19093 $ac_includes_default
19094 struct { char filler; long field; } pgac_struct;
19095 int
19096 main ()
19097 {
19098 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19099 test_array [0] = 0
19100
19101   ;
19102   return 0;
19103 }
19104 _ACEOF
19105 rm -f conftest.$ac_objext
19106 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19107   (eval $ac_compile) 2>conftest.er1
19108   ac_status=$?
19109   grep -v '^ *+' conftest.er1 >conftest.err
19110   rm -f conftest.er1
19111   cat conftest.err >&5
19112   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19113   (exit $ac_status); } &&
19114          { ac_try='test -z "$ac_c_werror_flag"
19115                          || test ! -s conftest.err'
19116   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19117   (eval $ac_try) 2>&5
19118   ac_status=$?
19119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19120   (exit $ac_status); }; } &&
19121          { ac_try='test -s conftest.$ac_objext'
19122   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19123   (eval $ac_try) 2>&5
19124   ac_status=$?
19125   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19126   (exit $ac_status); }; }; then
19127   ac_hi=-1 ac_mid=-1
19128   while :; do
19129     cat >conftest.$ac_ext <<_ACEOF
19130 /* confdefs.h.  */
19131 _ACEOF
19132 cat confdefs.h >>conftest.$ac_ext
19133 cat >>conftest.$ac_ext <<_ACEOF
19134 /* end confdefs.h.  */
19135 $ac_includes_default
19136 struct { char filler; long field; } pgac_struct;
19137 int
19138 main ()
19139 {
19140 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19141 test_array [0] = 0
19142
19143   ;
19144   return 0;
19145 }
19146 _ACEOF
19147 rm -f conftest.$ac_objext
19148 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19149   (eval $ac_compile) 2>conftest.er1
19150   ac_status=$?
19151   grep -v '^ *+' conftest.er1 >conftest.err
19152   rm -f conftest.er1
19153   cat conftest.err >&5
19154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19155   (exit $ac_status); } &&
19156          { ac_try='test -z "$ac_c_werror_flag"
19157                          || test ! -s conftest.err'
19158   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19159   (eval $ac_try) 2>&5
19160   ac_status=$?
19161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19162   (exit $ac_status); }; } &&
19163          { ac_try='test -s conftest.$ac_objext'
19164   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19165   (eval $ac_try) 2>&5
19166   ac_status=$?
19167   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19168   (exit $ac_status); }; }; then
19169   ac_lo=$ac_mid; break
19170 else
19171   echo "$as_me: failed program was:" >&5
19172 sed 's/^/| /' conftest.$ac_ext >&5
19173
19174 ac_hi=`expr '(' $ac_mid ')' - 1`
19175                        if test $ac_mid -le $ac_hi; then
19176                          ac_lo= ac_hi=
19177                          break
19178                        fi
19179                        ac_mid=`expr 2 '*' $ac_mid`
19180 fi
19181 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19182   done
19183 else
19184   echo "$as_me: failed program was:" >&5
19185 sed 's/^/| /' conftest.$ac_ext >&5
19186
19187 ac_lo= ac_hi=
19188 fi
19189 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19190 fi
19191 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19192 # Binary search between lo and hi bounds.
19193 while test "x$ac_lo" != "x$ac_hi"; do
19194   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19195   cat >conftest.$ac_ext <<_ACEOF
19196 /* confdefs.h.  */
19197 _ACEOF
19198 cat confdefs.h >>conftest.$ac_ext
19199 cat >>conftest.$ac_ext <<_ACEOF
19200 /* end confdefs.h.  */
19201 $ac_includes_default
19202 struct { char filler; long field; } pgac_struct;
19203 int
19204 main ()
19205 {
19206 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19207 test_array [0] = 0
19208
19209   ;
19210   return 0;
19211 }
19212 _ACEOF
19213 rm -f conftest.$ac_objext
19214 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19215   (eval $ac_compile) 2>conftest.er1
19216   ac_status=$?
19217   grep -v '^ *+' conftest.er1 >conftest.err
19218   rm -f conftest.er1
19219   cat conftest.err >&5
19220   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19221   (exit $ac_status); } &&
19222          { ac_try='test -z "$ac_c_werror_flag"
19223                          || test ! -s conftest.err'
19224   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19225   (eval $ac_try) 2>&5
19226   ac_status=$?
19227   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19228   (exit $ac_status); }; } &&
19229          { ac_try='test -s conftest.$ac_objext'
19230   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19231   (eval $ac_try) 2>&5
19232   ac_status=$?
19233   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19234   (exit $ac_status); }; }; then
19235   ac_hi=$ac_mid
19236 else
19237   echo "$as_me: failed program was:" >&5
19238 sed 's/^/| /' conftest.$ac_ext >&5
19239
19240 ac_lo=`expr '(' $ac_mid ')' + 1`
19241 fi
19242 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19243 done
19244 case $ac_lo in
19245 ?*) pgac_cv_alignof_long=$ac_lo;;
19246 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
19247 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
19248    { (exit 1); exit 1; }; } ;;
19249 esac
19250 else
19251   if test "$cross_compiling" = yes; then
19252   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19253 See \`config.log' for more details." >&5
19254 echo "$as_me: error: cannot run test program while cross compiling
19255 See \`config.log' for more details." >&2;}
19256    { (exit 1); exit 1; }; }
19257 else
19258   cat >conftest.$ac_ext <<_ACEOF
19259 /* confdefs.h.  */
19260 _ACEOF
19261 cat confdefs.h >>conftest.$ac_ext
19262 cat >>conftest.$ac_ext <<_ACEOF
19263 /* end confdefs.h.  */
19264 $ac_includes_default
19265 struct { char filler; long field; } pgac_struct;
19266 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19267 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19268 #include <stdio.h>
19269 #include <stdlib.h>
19270 int
19271 main ()
19272 {
19273
19274   FILE *f = fopen ("conftest.val", "w");
19275   if (! f)
19276     exit (1);
19277   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
19278     {
19279       long i = longval ();
19280       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19281         exit (1);
19282       fprintf (f, "%ld\n", i);
19283     }
19284   else
19285     {
19286       unsigned long i = ulongval ();
19287       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19288         exit (1);
19289       fprintf (f, "%lu\n", i);
19290     }
19291   exit (ferror (f) || fclose (f) != 0);
19292
19293   ;
19294   return 0;
19295 }
19296 _ACEOF
19297 rm -f conftest$ac_exeext
19298 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19299   (eval $ac_link) 2>&5
19300   ac_status=$?
19301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19302   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19304   (eval $ac_try) 2>&5
19305   ac_status=$?
19306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19307   (exit $ac_status); }; }; then
19308   pgac_cv_alignof_long=`cat conftest.val`
19309 else
19310   echo "$as_me: program exited with status $ac_status" >&5
19311 echo "$as_me: failed program was:" >&5
19312 sed 's/^/| /' conftest.$ac_ext >&5
19313
19314 ( exit $ac_status )
19315 { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
19316 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
19317    { (exit 1); exit 1; }; }
19318 fi
19319 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19320 fi
19321 fi
19322 rm -f conftest.val
19323 else
19324   pgac_cv_alignof_long=0
19325 fi
19326 fi
19327 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long" >&5
19328 echo "${ECHO_T}$pgac_cv_alignof_long" >&6
19329 cat >>confdefs.h <<_ACEOF
19330 #define ALIGNOF_LONG $pgac_cv_alignof_long
19331 _ACEOF
19332
19333
19334 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
19335   echo "$as_me:$LINENO: checking for long long int" >&5
19336 echo $ECHO_N "checking for long long int... $ECHO_C" >&6
19337 if test "${ac_cv_type_long_long_int+set}" = set; then
19338   echo $ECHO_N "(cached) $ECHO_C" >&6
19339 else
19340   cat >conftest.$ac_ext <<_ACEOF
19341 /* confdefs.h.  */
19342 _ACEOF
19343 cat confdefs.h >>conftest.$ac_ext
19344 cat >>conftest.$ac_ext <<_ACEOF
19345 /* end confdefs.h.  */
19346 $ac_includes_default
19347 int
19348 main ()
19349 {
19350 if ((long long int *) 0)
19351   return 0;
19352 if (sizeof (long long int))
19353   return 0;
19354   ;
19355   return 0;
19356 }
19357 _ACEOF
19358 rm -f conftest.$ac_objext
19359 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19360   (eval $ac_compile) 2>conftest.er1
19361   ac_status=$?
19362   grep -v '^ *+' conftest.er1 >conftest.err
19363   rm -f conftest.er1
19364   cat conftest.err >&5
19365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19366   (exit $ac_status); } &&
19367          { ac_try='test -z "$ac_c_werror_flag"
19368                          || test ! -s conftest.err'
19369   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19370   (eval $ac_try) 2>&5
19371   ac_status=$?
19372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19373   (exit $ac_status); }; } &&
19374          { ac_try='test -s conftest.$ac_objext'
19375   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19376   (eval $ac_try) 2>&5
19377   ac_status=$?
19378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19379   (exit $ac_status); }; }; then
19380   ac_cv_type_long_long_int=yes
19381 else
19382   echo "$as_me: failed program was:" >&5
19383 sed 's/^/| /' conftest.$ac_ext >&5
19384
19385 ac_cv_type_long_long_int=no
19386 fi
19387 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19388 fi
19389 echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
19390 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6
19391
19392 echo "$as_me:$LINENO: checking alignment of long long int" >&5
19393 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6
19394 if test "${pgac_cv_alignof_long_long_int+set}" = set; then
19395   echo $ECHO_N "(cached) $ECHO_C" >&6
19396 else
19397   if test "$ac_cv_type_long_long_int" = yes; then
19398   if test "$cross_compiling" = yes; then
19399   # Depending upon the size, compute the lo and hi bounds.
19400 cat >conftest.$ac_ext <<_ACEOF
19401 /* confdefs.h.  */
19402 _ACEOF
19403 cat confdefs.h >>conftest.$ac_ext
19404 cat >>conftest.$ac_ext <<_ACEOF
19405 /* end confdefs.h.  */
19406 $ac_includes_default
19407 struct { char filler; long long int field; } pgac_struct;
19408 int
19409 main ()
19410 {
19411 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
19412 test_array [0] = 0
19413
19414   ;
19415   return 0;
19416 }
19417 _ACEOF
19418 rm -f conftest.$ac_objext
19419 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19420   (eval $ac_compile) 2>conftest.er1
19421   ac_status=$?
19422   grep -v '^ *+' conftest.er1 >conftest.err
19423   rm -f conftest.er1
19424   cat conftest.err >&5
19425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19426   (exit $ac_status); } &&
19427          { ac_try='test -z "$ac_c_werror_flag"
19428                          || test ! -s conftest.err'
19429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19430   (eval $ac_try) 2>&5
19431   ac_status=$?
19432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19433   (exit $ac_status); }; } &&
19434          { ac_try='test -s conftest.$ac_objext'
19435   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19436   (eval $ac_try) 2>&5
19437   ac_status=$?
19438   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19439   (exit $ac_status); }; }; then
19440   ac_lo=0 ac_mid=0
19441   while :; do
19442     cat >conftest.$ac_ext <<_ACEOF
19443 /* confdefs.h.  */
19444 _ACEOF
19445 cat confdefs.h >>conftest.$ac_ext
19446 cat >>conftest.$ac_ext <<_ACEOF
19447 /* end confdefs.h.  */
19448 $ac_includes_default
19449 struct { char filler; long long int field; } pgac_struct;
19450 int
19451 main ()
19452 {
19453 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19454 test_array [0] = 0
19455
19456   ;
19457   return 0;
19458 }
19459 _ACEOF
19460 rm -f conftest.$ac_objext
19461 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19462   (eval $ac_compile) 2>conftest.er1
19463   ac_status=$?
19464   grep -v '^ *+' conftest.er1 >conftest.err
19465   rm -f conftest.er1
19466   cat conftest.err >&5
19467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19468   (exit $ac_status); } &&
19469          { ac_try='test -z "$ac_c_werror_flag"
19470                          || test ! -s conftest.err'
19471   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19472   (eval $ac_try) 2>&5
19473   ac_status=$?
19474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19475   (exit $ac_status); }; } &&
19476          { ac_try='test -s conftest.$ac_objext'
19477   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19478   (eval $ac_try) 2>&5
19479   ac_status=$?
19480   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19481   (exit $ac_status); }; }; then
19482   ac_hi=$ac_mid; break
19483 else
19484   echo "$as_me: failed program was:" >&5
19485 sed 's/^/| /' conftest.$ac_ext >&5
19486
19487 ac_lo=`expr $ac_mid + 1`
19488                     if test $ac_lo -le $ac_mid; then
19489                       ac_lo= ac_hi=
19490                       break
19491                     fi
19492                     ac_mid=`expr 2 '*' $ac_mid + 1`
19493 fi
19494 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19495   done
19496 else
19497   echo "$as_me: failed program was:" >&5
19498 sed 's/^/| /' conftest.$ac_ext >&5
19499
19500 cat >conftest.$ac_ext <<_ACEOF
19501 /* confdefs.h.  */
19502 _ACEOF
19503 cat confdefs.h >>conftest.$ac_ext
19504 cat >>conftest.$ac_ext <<_ACEOF
19505 /* end confdefs.h.  */
19506 $ac_includes_default
19507 struct { char filler; long long int field; } pgac_struct;
19508 int
19509 main ()
19510 {
19511 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19512 test_array [0] = 0
19513
19514   ;
19515   return 0;
19516 }
19517 _ACEOF
19518 rm -f conftest.$ac_objext
19519 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19520   (eval $ac_compile) 2>conftest.er1
19521   ac_status=$?
19522   grep -v '^ *+' conftest.er1 >conftest.err
19523   rm -f conftest.er1
19524   cat conftest.err >&5
19525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19526   (exit $ac_status); } &&
19527          { ac_try='test -z "$ac_c_werror_flag"
19528                          || test ! -s conftest.err'
19529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19530   (eval $ac_try) 2>&5
19531   ac_status=$?
19532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19533   (exit $ac_status); }; } &&
19534          { ac_try='test -s conftest.$ac_objext'
19535   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19536   (eval $ac_try) 2>&5
19537   ac_status=$?
19538   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19539   (exit $ac_status); }; }; then
19540   ac_hi=-1 ac_mid=-1
19541   while :; do
19542     cat >conftest.$ac_ext <<_ACEOF
19543 /* confdefs.h.  */
19544 _ACEOF
19545 cat confdefs.h >>conftest.$ac_ext
19546 cat >>conftest.$ac_ext <<_ACEOF
19547 /* end confdefs.h.  */
19548 $ac_includes_default
19549 struct { char filler; long long int field; } pgac_struct;
19550 int
19551 main ()
19552 {
19553 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19554 test_array [0] = 0
19555
19556   ;
19557   return 0;
19558 }
19559 _ACEOF
19560 rm -f conftest.$ac_objext
19561 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19562   (eval $ac_compile) 2>conftest.er1
19563   ac_status=$?
19564   grep -v '^ *+' conftest.er1 >conftest.err
19565   rm -f conftest.er1
19566   cat conftest.err >&5
19567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19568   (exit $ac_status); } &&
19569          { ac_try='test -z "$ac_c_werror_flag"
19570                          || test ! -s conftest.err'
19571   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19572   (eval $ac_try) 2>&5
19573   ac_status=$?
19574   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19575   (exit $ac_status); }; } &&
19576          { ac_try='test -s conftest.$ac_objext'
19577   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19578   (eval $ac_try) 2>&5
19579   ac_status=$?
19580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19581   (exit $ac_status); }; }; then
19582   ac_lo=$ac_mid; break
19583 else
19584   echo "$as_me: failed program was:" >&5
19585 sed 's/^/| /' conftest.$ac_ext >&5
19586
19587 ac_hi=`expr '(' $ac_mid ')' - 1`
19588                        if test $ac_mid -le $ac_hi; then
19589                          ac_lo= ac_hi=
19590                          break
19591                        fi
19592                        ac_mid=`expr 2 '*' $ac_mid`
19593 fi
19594 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19595   done
19596 else
19597   echo "$as_me: failed program was:" >&5
19598 sed 's/^/| /' conftest.$ac_ext >&5
19599
19600 ac_lo= ac_hi=
19601 fi
19602 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19603 fi
19604 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19605 # Binary search between lo and hi bounds.
19606 while test "x$ac_lo" != "x$ac_hi"; do
19607   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19608   cat >conftest.$ac_ext <<_ACEOF
19609 /* confdefs.h.  */
19610 _ACEOF
19611 cat confdefs.h >>conftest.$ac_ext
19612 cat >>conftest.$ac_ext <<_ACEOF
19613 /* end confdefs.h.  */
19614 $ac_includes_default
19615 struct { char filler; long long int field; } pgac_struct;
19616 int
19617 main ()
19618 {
19619 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19620 test_array [0] = 0
19621
19622   ;
19623   return 0;
19624 }
19625 _ACEOF
19626 rm -f conftest.$ac_objext
19627 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19628   (eval $ac_compile) 2>conftest.er1
19629   ac_status=$?
19630   grep -v '^ *+' conftest.er1 >conftest.err
19631   rm -f conftest.er1
19632   cat conftest.err >&5
19633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19634   (exit $ac_status); } &&
19635          { ac_try='test -z "$ac_c_werror_flag"
19636                          || test ! -s conftest.err'
19637   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19638   (eval $ac_try) 2>&5
19639   ac_status=$?
19640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19641   (exit $ac_status); }; } &&
19642          { ac_try='test -s conftest.$ac_objext'
19643   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19644   (eval $ac_try) 2>&5
19645   ac_status=$?
19646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19647   (exit $ac_status); }; }; then
19648   ac_hi=$ac_mid
19649 else
19650   echo "$as_me: failed program was:" >&5
19651 sed 's/^/| /' conftest.$ac_ext >&5
19652
19653 ac_lo=`expr '(' $ac_mid ')' + 1`
19654 fi
19655 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19656 done
19657 case $ac_lo in
19658 ?*) pgac_cv_alignof_long_long_int=$ac_lo;;
19659 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
19660 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
19661    { (exit 1); exit 1; }; } ;;
19662 esac
19663 else
19664   if test "$cross_compiling" = yes; then
19665   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19666 See \`config.log' for more details." >&5
19667 echo "$as_me: error: cannot run test program while cross compiling
19668 See \`config.log' for more details." >&2;}
19669    { (exit 1); exit 1; }; }
19670 else
19671   cat >conftest.$ac_ext <<_ACEOF
19672 /* confdefs.h.  */
19673 _ACEOF
19674 cat confdefs.h >>conftest.$ac_ext
19675 cat >>conftest.$ac_ext <<_ACEOF
19676 /* end confdefs.h.  */
19677 $ac_includes_default
19678 struct { char filler; long long int field; } pgac_struct;
19679 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19680 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19681 #include <stdio.h>
19682 #include <stdlib.h>
19683 int
19684 main ()
19685 {
19686
19687   FILE *f = fopen ("conftest.val", "w");
19688   if (! f)
19689     exit (1);
19690   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
19691     {
19692       long i = longval ();
19693       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19694         exit (1);
19695       fprintf (f, "%ld\n", i);
19696     }
19697   else
19698     {
19699       unsigned long i = ulongval ();
19700       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19701         exit (1);
19702       fprintf (f, "%lu\n", i);
19703     }
19704   exit (ferror (f) || fclose (f) != 0);
19705
19706   ;
19707   return 0;
19708 }
19709 _ACEOF
19710 rm -f conftest$ac_exeext
19711 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19712   (eval $ac_link) 2>&5
19713   ac_status=$?
19714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19715   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19716   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19717   (eval $ac_try) 2>&5
19718   ac_status=$?
19719   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19720   (exit $ac_status); }; }; then
19721   pgac_cv_alignof_long_long_int=`cat conftest.val`
19722 else
19723   echo "$as_me: program exited with status $ac_status" >&5
19724 echo "$as_me: failed program was:" >&5
19725 sed 's/^/| /' conftest.$ac_ext >&5
19726
19727 ( exit $ac_status )
19728 { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
19729 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
19730    { (exit 1); exit 1; }; }
19731 fi
19732 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19733 fi
19734 fi
19735 rm -f conftest.val
19736 else
19737   pgac_cv_alignof_long_long_int=0
19738 fi
19739 fi
19740 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long_long_int" >&5
19741 echo "${ECHO_T}$pgac_cv_alignof_long_long_int" >&6
19742 cat >>confdefs.h <<_ACEOF
19743 #define ALIGNOF_LONG_LONG_INT $pgac_cv_alignof_long_long_int
19744 _ACEOF
19745
19746
19747 fi
19748 echo "$as_me:$LINENO: checking for double" >&5
19749 echo $ECHO_N "checking for double... $ECHO_C" >&6
19750 if test "${ac_cv_type_double+set}" = set; then
19751   echo $ECHO_N "(cached) $ECHO_C" >&6
19752 else
19753   cat >conftest.$ac_ext <<_ACEOF
19754 /* confdefs.h.  */
19755 _ACEOF
19756 cat confdefs.h >>conftest.$ac_ext
19757 cat >>conftest.$ac_ext <<_ACEOF
19758 /* end confdefs.h.  */
19759 $ac_includes_default
19760 int
19761 main ()
19762 {
19763 if ((double *) 0)
19764   return 0;
19765 if (sizeof (double))
19766   return 0;
19767   ;
19768   return 0;
19769 }
19770 _ACEOF
19771 rm -f conftest.$ac_objext
19772 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19773   (eval $ac_compile) 2>conftest.er1
19774   ac_status=$?
19775   grep -v '^ *+' conftest.er1 >conftest.err
19776   rm -f conftest.er1
19777   cat conftest.err >&5
19778   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19779   (exit $ac_status); } &&
19780          { ac_try='test -z "$ac_c_werror_flag"
19781                          || test ! -s conftest.err'
19782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19783   (eval $ac_try) 2>&5
19784   ac_status=$?
19785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19786   (exit $ac_status); }; } &&
19787          { ac_try='test -s conftest.$ac_objext'
19788   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19789   (eval $ac_try) 2>&5
19790   ac_status=$?
19791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19792   (exit $ac_status); }; }; then
19793   ac_cv_type_double=yes
19794 else
19795   echo "$as_me: failed program was:" >&5
19796 sed 's/^/| /' conftest.$ac_ext >&5
19797
19798 ac_cv_type_double=no
19799 fi
19800 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19801 fi
19802 echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
19803 echo "${ECHO_T}$ac_cv_type_double" >&6
19804
19805 echo "$as_me:$LINENO: checking alignment of double" >&5
19806 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6
19807 if test "${pgac_cv_alignof_double+set}" = set; then
19808   echo $ECHO_N "(cached) $ECHO_C" >&6
19809 else
19810   if test "$ac_cv_type_double" = yes; then
19811   if test "$cross_compiling" = yes; then
19812   # Depending upon the size, compute the lo and hi bounds.
19813 cat >conftest.$ac_ext <<_ACEOF
19814 /* confdefs.h.  */
19815 _ACEOF
19816 cat confdefs.h >>conftest.$ac_ext
19817 cat >>conftest.$ac_ext <<_ACEOF
19818 /* end confdefs.h.  */
19819 $ac_includes_default
19820 struct { char filler; double field; } pgac_struct;
19821 int
19822 main ()
19823 {
19824 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
19825 test_array [0] = 0
19826
19827   ;
19828   return 0;
19829 }
19830 _ACEOF
19831 rm -f conftest.$ac_objext
19832 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19833   (eval $ac_compile) 2>conftest.er1
19834   ac_status=$?
19835   grep -v '^ *+' conftest.er1 >conftest.err
19836   rm -f conftest.er1
19837   cat conftest.err >&5
19838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19839   (exit $ac_status); } &&
19840          { ac_try='test -z "$ac_c_werror_flag"
19841                          || test ! -s conftest.err'
19842   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19843   (eval $ac_try) 2>&5
19844   ac_status=$?
19845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19846   (exit $ac_status); }; } &&
19847          { ac_try='test -s conftest.$ac_objext'
19848   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19849   (eval $ac_try) 2>&5
19850   ac_status=$?
19851   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19852   (exit $ac_status); }; }; then
19853   ac_lo=0 ac_mid=0
19854   while :; do
19855     cat >conftest.$ac_ext <<_ACEOF
19856 /* confdefs.h.  */
19857 _ACEOF
19858 cat confdefs.h >>conftest.$ac_ext
19859 cat >>conftest.$ac_ext <<_ACEOF
19860 /* end confdefs.h.  */
19861 $ac_includes_default
19862 struct { char filler; double field; } pgac_struct;
19863 int
19864 main ()
19865 {
19866 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19867 test_array [0] = 0
19868
19869   ;
19870   return 0;
19871 }
19872 _ACEOF
19873 rm -f conftest.$ac_objext
19874 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19875   (eval $ac_compile) 2>conftest.er1
19876   ac_status=$?
19877   grep -v '^ *+' conftest.er1 >conftest.err
19878   rm -f conftest.er1
19879   cat conftest.err >&5
19880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19881   (exit $ac_status); } &&
19882          { ac_try='test -z "$ac_c_werror_flag"
19883                          || test ! -s conftest.err'
19884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19885   (eval $ac_try) 2>&5
19886   ac_status=$?
19887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19888   (exit $ac_status); }; } &&
19889          { ac_try='test -s conftest.$ac_objext'
19890   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19891   (eval $ac_try) 2>&5
19892   ac_status=$?
19893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19894   (exit $ac_status); }; }; then
19895   ac_hi=$ac_mid; break
19896 else
19897   echo "$as_me: failed program was:" >&5
19898 sed 's/^/| /' conftest.$ac_ext >&5
19899
19900 ac_lo=`expr $ac_mid + 1`
19901                     if test $ac_lo -le $ac_mid; then
19902                       ac_lo= ac_hi=
19903                       break
19904                     fi
19905                     ac_mid=`expr 2 '*' $ac_mid + 1`
19906 fi
19907 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19908   done
19909 else
19910   echo "$as_me: failed program was:" >&5
19911 sed 's/^/| /' conftest.$ac_ext >&5
19912
19913 cat >conftest.$ac_ext <<_ACEOF
19914 /* confdefs.h.  */
19915 _ACEOF
19916 cat confdefs.h >>conftest.$ac_ext
19917 cat >>conftest.$ac_ext <<_ACEOF
19918 /* end confdefs.h.  */
19919 $ac_includes_default
19920 struct { char filler; double field; } pgac_struct;
19921 int
19922 main ()
19923 {
19924 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19925 test_array [0] = 0
19926
19927   ;
19928   return 0;
19929 }
19930 _ACEOF
19931 rm -f conftest.$ac_objext
19932 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19933   (eval $ac_compile) 2>conftest.er1
19934   ac_status=$?
19935   grep -v '^ *+' conftest.er1 >conftest.err
19936   rm -f conftest.er1
19937   cat conftest.err >&5
19938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19939   (exit $ac_status); } &&
19940          { ac_try='test -z "$ac_c_werror_flag"
19941                          || test ! -s conftest.err'
19942   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19943   (eval $ac_try) 2>&5
19944   ac_status=$?
19945   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19946   (exit $ac_status); }; } &&
19947          { ac_try='test -s conftest.$ac_objext'
19948   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19949   (eval $ac_try) 2>&5
19950   ac_status=$?
19951   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19952   (exit $ac_status); }; }; then
19953   ac_hi=-1 ac_mid=-1
19954   while :; do
19955     cat >conftest.$ac_ext <<_ACEOF
19956 /* confdefs.h.  */
19957 _ACEOF
19958 cat confdefs.h >>conftest.$ac_ext
19959 cat >>conftest.$ac_ext <<_ACEOF
19960 /* end confdefs.h.  */
19961 $ac_includes_default
19962 struct { char filler; double field; } pgac_struct;
19963 int
19964 main ()
19965 {
19966 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19967 test_array [0] = 0
19968
19969   ;
19970   return 0;
19971 }
19972 _ACEOF
19973 rm -f conftest.$ac_objext
19974 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19975   (eval $ac_compile) 2>conftest.er1
19976   ac_status=$?
19977   grep -v '^ *+' conftest.er1 >conftest.err
19978   rm -f conftest.er1
19979   cat conftest.err >&5
19980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19981   (exit $ac_status); } &&
19982          { ac_try='test -z "$ac_c_werror_flag"
19983                          || test ! -s conftest.err'
19984   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19985   (eval $ac_try) 2>&5
19986   ac_status=$?
19987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19988   (exit $ac_status); }; } &&
19989          { ac_try='test -s conftest.$ac_objext'
19990   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19991   (eval $ac_try) 2>&5
19992   ac_status=$?
19993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19994   (exit $ac_status); }; }; then
19995   ac_lo=$ac_mid; break
19996 else
19997   echo "$as_me: failed program was:" >&5
19998 sed 's/^/| /' conftest.$ac_ext >&5
19999
20000 ac_hi=`expr '(' $ac_mid ')' - 1`
20001                        if test $ac_mid -le $ac_hi; then
20002                          ac_lo= ac_hi=
20003                          break
20004                        fi
20005                        ac_mid=`expr 2 '*' $ac_mid`
20006 fi
20007 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20008   done
20009 else
20010   echo "$as_me: failed program was:" >&5
20011 sed 's/^/| /' conftest.$ac_ext >&5
20012
20013 ac_lo= ac_hi=
20014 fi
20015 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20016 fi
20017 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20018 # Binary search between lo and hi bounds.
20019 while test "x$ac_lo" != "x$ac_hi"; do
20020   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20021   cat >conftest.$ac_ext <<_ACEOF
20022 /* confdefs.h.  */
20023 _ACEOF
20024 cat confdefs.h >>conftest.$ac_ext
20025 cat >>conftest.$ac_ext <<_ACEOF
20026 /* end confdefs.h.  */
20027 $ac_includes_default
20028 struct { char filler; double field; } pgac_struct;
20029 int
20030 main ()
20031 {
20032 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
20033 test_array [0] = 0
20034
20035   ;
20036   return 0;
20037 }
20038 _ACEOF
20039 rm -f conftest.$ac_objext
20040 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20041   (eval $ac_compile) 2>conftest.er1
20042   ac_status=$?
20043   grep -v '^ *+' conftest.er1 >conftest.err
20044   rm -f conftest.er1
20045   cat conftest.err >&5
20046   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20047   (exit $ac_status); } &&
20048          { ac_try='test -z "$ac_c_werror_flag"
20049                          || test ! -s conftest.err'
20050   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20051   (eval $ac_try) 2>&5
20052   ac_status=$?
20053   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20054   (exit $ac_status); }; } &&
20055          { ac_try='test -s conftest.$ac_objext'
20056   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20057   (eval $ac_try) 2>&5
20058   ac_status=$?
20059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20060   (exit $ac_status); }; }; then
20061   ac_hi=$ac_mid
20062 else
20063   echo "$as_me: failed program was:" >&5
20064 sed 's/^/| /' conftest.$ac_ext >&5
20065
20066 ac_lo=`expr '(' $ac_mid ')' + 1`
20067 fi
20068 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20069 done
20070 case $ac_lo in
20071 ?*) pgac_cv_alignof_double=$ac_lo;;
20072 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
20073 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
20074    { (exit 1); exit 1; }; } ;;
20075 esac
20076 else
20077   if test "$cross_compiling" = yes; then
20078   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
20079 See \`config.log' for more details." >&5
20080 echo "$as_me: error: cannot run test program while cross compiling
20081 See \`config.log' for more details." >&2;}
20082    { (exit 1); exit 1; }; }
20083 else
20084   cat >conftest.$ac_ext <<_ACEOF
20085 /* confdefs.h.  */
20086 _ACEOF
20087 cat confdefs.h >>conftest.$ac_ext
20088 cat >>conftest.$ac_ext <<_ACEOF
20089 /* end confdefs.h.  */
20090 $ac_includes_default
20091 struct { char filler; double field; } pgac_struct;
20092 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20093 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20094 #include <stdio.h>
20095 #include <stdlib.h>
20096 int
20097 main ()
20098 {
20099
20100   FILE *f = fopen ("conftest.val", "w");
20101   if (! f)
20102     exit (1);
20103   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
20104     {
20105       long i = longval ();
20106       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20107         exit (1);
20108       fprintf (f, "%ld\n", i);
20109     }
20110   else
20111     {
20112       unsigned long i = ulongval ();
20113       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20114         exit (1);
20115       fprintf (f, "%lu\n", i);
20116     }
20117   exit (ferror (f) || fclose (f) != 0);
20118
20119   ;
20120   return 0;
20121 }
20122 _ACEOF
20123 rm -f conftest$ac_exeext
20124 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20125   (eval $ac_link) 2>&5
20126   ac_status=$?
20127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20128   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20129   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20130   (eval $ac_try) 2>&5
20131   ac_status=$?
20132   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20133   (exit $ac_status); }; }; then
20134   pgac_cv_alignof_double=`cat conftest.val`
20135 else
20136   echo "$as_me: program exited with status $ac_status" >&5
20137 echo "$as_me: failed program was:" >&5
20138 sed 's/^/| /' conftest.$ac_ext >&5
20139
20140 ( exit $ac_status )
20141 { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
20142 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
20143    { (exit 1); exit 1; }; }
20144 fi
20145 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20146 fi
20147 fi
20148 rm -f conftest.val
20149 else
20150   pgac_cv_alignof_double=0
20151 fi
20152 fi
20153 echo "$as_me:$LINENO: result: $pgac_cv_alignof_double" >&5
20154 echo "${ECHO_T}$pgac_cv_alignof_double" >&6
20155 cat >>confdefs.h <<_ACEOF
20156 #define ALIGNOF_DOUBLE $pgac_cv_alignof_double
20157 _ACEOF
20158
20159
20160
20161 # Compute maximum alignment of any basic type.
20162 # We assume long's alignment is at least as strong as char, short, or int;
20163 # but we must check long long (if it exists) and double.
20164
20165 MAX_ALIGNOF=$pgac_cv_alignof_long
20166 if test $MAX_ALIGNOF -lt $pgac_cv_alignof_double ; then
20167   MAX_ALIGNOF=$pgac_cv_alignof_double
20168 fi
20169 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $pgac_cv_alignof_long_long_int ; then
20170   MAX_ALIGNOF="$pgac_cv_alignof_long_long_int"
20171 fi
20172
20173 cat >>confdefs.h <<_ACEOF
20174 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
20175 _ACEOF
20176
20177
20178
20179 # Some platforms predefine the types int8, int16, etc.  Only check
20180 # a (hopefully) representative subset.
20181 echo "$as_me:$LINENO: checking for int8" >&5
20182 echo $ECHO_N "checking for int8... $ECHO_C" >&6
20183 if test "${ac_cv_type_int8+set}" = set; then
20184   echo $ECHO_N "(cached) $ECHO_C" >&6
20185 else
20186   cat >conftest.$ac_ext <<_ACEOF
20187 /* confdefs.h.  */
20188 _ACEOF
20189 cat confdefs.h >>conftest.$ac_ext
20190 cat >>conftest.$ac_ext <<_ACEOF
20191 /* end confdefs.h.  */
20192 #include <stdio.h>
20193 #ifdef HAVE_SUPPORTDEFS_H
20194 #include <SupportDefs.h>
20195 #endif
20196
20197 int
20198 main ()
20199 {
20200 if ((int8 *) 0)
20201   return 0;
20202 if (sizeof (int8))
20203   return 0;
20204   ;
20205   return 0;
20206 }
20207 _ACEOF
20208 rm -f conftest.$ac_objext
20209 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20210   (eval $ac_compile) 2>conftest.er1
20211   ac_status=$?
20212   grep -v '^ *+' conftest.er1 >conftest.err
20213   rm -f conftest.er1
20214   cat conftest.err >&5
20215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20216   (exit $ac_status); } &&
20217          { ac_try='test -z "$ac_c_werror_flag"
20218                          || test ! -s conftest.err'
20219   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20220   (eval $ac_try) 2>&5
20221   ac_status=$?
20222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20223   (exit $ac_status); }; } &&
20224          { ac_try='test -s conftest.$ac_objext'
20225   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20226   (eval $ac_try) 2>&5
20227   ac_status=$?
20228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20229   (exit $ac_status); }; }; then
20230   ac_cv_type_int8=yes
20231 else
20232   echo "$as_me: failed program was:" >&5
20233 sed 's/^/| /' conftest.$ac_ext >&5
20234
20235 ac_cv_type_int8=no
20236 fi
20237 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20238 fi
20239 echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
20240 echo "${ECHO_T}$ac_cv_type_int8" >&6
20241 if test $ac_cv_type_int8 = yes; then
20242
20243 cat >>confdefs.h <<_ACEOF
20244 #define HAVE_INT8 1
20245 _ACEOF
20246
20247
20248 fi
20249 echo "$as_me:$LINENO: checking for uint8" >&5
20250 echo $ECHO_N "checking for uint8... $ECHO_C" >&6
20251 if test "${ac_cv_type_uint8+set}" = set; then
20252   echo $ECHO_N "(cached) $ECHO_C" >&6
20253 else
20254   cat >conftest.$ac_ext <<_ACEOF
20255 /* confdefs.h.  */
20256 _ACEOF
20257 cat confdefs.h >>conftest.$ac_ext
20258 cat >>conftest.$ac_ext <<_ACEOF
20259 /* end confdefs.h.  */
20260 #include <stdio.h>
20261 #ifdef HAVE_SUPPORTDEFS_H
20262 #include <SupportDefs.h>
20263 #endif
20264
20265 int
20266 main ()
20267 {
20268 if ((uint8 *) 0)
20269   return 0;
20270 if (sizeof (uint8))
20271   return 0;
20272   ;
20273   return 0;
20274 }
20275 _ACEOF
20276 rm -f conftest.$ac_objext
20277 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20278   (eval $ac_compile) 2>conftest.er1
20279   ac_status=$?
20280   grep -v '^ *+' conftest.er1 >conftest.err
20281   rm -f conftest.er1
20282   cat conftest.err >&5
20283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20284   (exit $ac_status); } &&
20285          { ac_try='test -z "$ac_c_werror_flag"
20286                          || test ! -s conftest.err'
20287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20288   (eval $ac_try) 2>&5
20289   ac_status=$?
20290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20291   (exit $ac_status); }; } &&
20292          { ac_try='test -s conftest.$ac_objext'
20293   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20294   (eval $ac_try) 2>&5
20295   ac_status=$?
20296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20297   (exit $ac_status); }; }; then
20298   ac_cv_type_uint8=yes
20299 else
20300   echo "$as_me: failed program was:" >&5
20301 sed 's/^/| /' conftest.$ac_ext >&5
20302
20303 ac_cv_type_uint8=no
20304 fi
20305 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20306 fi
20307 echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
20308 echo "${ECHO_T}$ac_cv_type_uint8" >&6
20309 if test $ac_cv_type_uint8 = yes; then
20310
20311 cat >>confdefs.h <<_ACEOF
20312 #define HAVE_UINT8 1
20313 _ACEOF
20314
20315
20316 fi
20317 echo "$as_me:$LINENO: checking for int64" >&5
20318 echo $ECHO_N "checking for int64... $ECHO_C" >&6
20319 if test "${ac_cv_type_int64+set}" = set; then
20320   echo $ECHO_N "(cached) $ECHO_C" >&6
20321 else
20322   cat >conftest.$ac_ext <<_ACEOF
20323 /* confdefs.h.  */
20324 _ACEOF
20325 cat confdefs.h >>conftest.$ac_ext
20326 cat >>conftest.$ac_ext <<_ACEOF
20327 /* end confdefs.h.  */
20328 #include <stdio.h>
20329 #ifdef HAVE_SUPPORTDEFS_H
20330 #include <SupportDefs.h>
20331 #endif
20332
20333 int
20334 main ()
20335 {
20336 if ((int64 *) 0)
20337   return 0;
20338 if (sizeof (int64))
20339   return 0;
20340   ;
20341   return 0;
20342 }
20343 _ACEOF
20344 rm -f conftest.$ac_objext
20345 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20346   (eval $ac_compile) 2>conftest.er1
20347   ac_status=$?
20348   grep -v '^ *+' conftest.er1 >conftest.err
20349   rm -f conftest.er1
20350   cat conftest.err >&5
20351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20352   (exit $ac_status); } &&
20353          { ac_try='test -z "$ac_c_werror_flag"
20354                          || test ! -s conftest.err'
20355   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20356   (eval $ac_try) 2>&5
20357   ac_status=$?
20358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20359   (exit $ac_status); }; } &&
20360          { ac_try='test -s conftest.$ac_objext'
20361   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20362   (eval $ac_try) 2>&5
20363   ac_status=$?
20364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20365   (exit $ac_status); }; }; then
20366   ac_cv_type_int64=yes
20367 else
20368   echo "$as_me: failed program was:" >&5
20369 sed 's/^/| /' conftest.$ac_ext >&5
20370
20371 ac_cv_type_int64=no
20372 fi
20373 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20374 fi
20375 echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
20376 echo "${ECHO_T}$ac_cv_type_int64" >&6
20377 if test $ac_cv_type_int64 = yes; then
20378
20379 cat >>confdefs.h <<_ACEOF
20380 #define HAVE_INT64 1
20381 _ACEOF
20382
20383
20384 fi
20385 echo "$as_me:$LINENO: checking for uint64" >&5
20386 echo $ECHO_N "checking for uint64... $ECHO_C" >&6
20387 if test "${ac_cv_type_uint64+set}" = set; then
20388   echo $ECHO_N "(cached) $ECHO_C" >&6
20389 else
20390   cat >conftest.$ac_ext <<_ACEOF
20391 /* confdefs.h.  */
20392 _ACEOF
20393 cat confdefs.h >>conftest.$ac_ext
20394 cat >>conftest.$ac_ext <<_ACEOF
20395 /* end confdefs.h.  */
20396 #include <stdio.h>
20397 #ifdef HAVE_SUPPORTDEFS_H
20398 #include <SupportDefs.h>
20399 #endif
20400
20401 int
20402 main ()
20403 {
20404 if ((uint64 *) 0)
20405   return 0;
20406 if (sizeof (uint64))
20407   return 0;
20408   ;
20409   return 0;
20410 }
20411 _ACEOF
20412 rm -f conftest.$ac_objext
20413 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20414   (eval $ac_compile) 2>conftest.er1
20415   ac_status=$?
20416   grep -v '^ *+' conftest.er1 >conftest.err
20417   rm -f conftest.er1
20418   cat conftest.err >&5
20419   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20420   (exit $ac_status); } &&
20421          { ac_try='test -z "$ac_c_werror_flag"
20422                          || test ! -s conftest.err'
20423   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20424   (eval $ac_try) 2>&5
20425   ac_status=$?
20426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20427   (exit $ac_status); }; } &&
20428          { ac_try='test -s conftest.$ac_objext'
20429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20430   (eval $ac_try) 2>&5
20431   ac_status=$?
20432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20433   (exit $ac_status); }; }; then
20434   ac_cv_type_uint64=yes
20435 else
20436   echo "$as_me: failed program was:" >&5
20437 sed 's/^/| /' conftest.$ac_ext >&5
20438
20439 ac_cv_type_uint64=no
20440 fi
20441 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20442 fi
20443 echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
20444 echo "${ECHO_T}$ac_cv_type_uint64" >&6
20445 if test $ac_cv_type_uint64 = yes; then
20446
20447 cat >>confdefs.h <<_ACEOF
20448 #define HAVE_UINT64 1
20449 _ACEOF
20450
20451
20452 fi
20453
20454
20455 # We also check for sig_atomic_t, which *should* be defined per ANSI
20456 # C, but is missing on some old platforms.
20457 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
20458 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
20459 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
20460   echo $ECHO_N "(cached) $ECHO_C" >&6
20461 else
20462   cat >conftest.$ac_ext <<_ACEOF
20463 /* confdefs.h.  */
20464 _ACEOF
20465 cat confdefs.h >>conftest.$ac_ext
20466 cat >>conftest.$ac_ext <<_ACEOF
20467 /* end confdefs.h.  */
20468 #include <signal.h>
20469
20470 int
20471 main ()
20472 {
20473 if ((sig_atomic_t *) 0)
20474   return 0;
20475 if (sizeof (sig_atomic_t))
20476   return 0;
20477   ;
20478   return 0;
20479 }
20480 _ACEOF
20481 rm -f conftest.$ac_objext
20482 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20483   (eval $ac_compile) 2>conftest.er1
20484   ac_status=$?
20485   grep -v '^ *+' conftest.er1 >conftest.err
20486   rm -f conftest.er1
20487   cat conftest.err >&5
20488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20489   (exit $ac_status); } &&
20490          { ac_try='test -z "$ac_c_werror_flag"
20491                          || test ! -s conftest.err'
20492   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20493   (eval $ac_try) 2>&5
20494   ac_status=$?
20495   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20496   (exit $ac_status); }; } &&
20497          { ac_try='test -s conftest.$ac_objext'
20498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20499   (eval $ac_try) 2>&5
20500   ac_status=$?
20501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20502   (exit $ac_status); }; }; then
20503   ac_cv_type_sig_atomic_t=yes
20504 else
20505   echo "$as_me: failed program was:" >&5
20506 sed 's/^/| /' conftest.$ac_ext >&5
20507
20508 ac_cv_type_sig_atomic_t=no
20509 fi
20510 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20511 fi
20512 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
20513 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
20514 if test $ac_cv_type_sig_atomic_t = yes; then
20515
20516 cat >>confdefs.h <<_ACEOF
20517 #define HAVE_SIG_ATOMIC_T 1
20518 _ACEOF
20519
20520
20521 fi
20522
20523
20524
20525 if test x"$template" != x"win32"
20526 then
20527 echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
20528 echo $ECHO_N "checking for POSIX signal interface... $ECHO_C" >&6
20529 if test "${pgac_cv_func_posix_signals+set}" = set; then
20530   echo $ECHO_N "(cached) $ECHO_C" >&6
20531 else
20532   cat >conftest.$ac_ext <<_ACEOF
20533 /* confdefs.h.  */
20534 _ACEOF
20535 cat confdefs.h >>conftest.$ac_ext
20536 cat >>conftest.$ac_ext <<_ACEOF
20537 /* end confdefs.h.  */
20538 #include <signal.h>
20539
20540 int
20541 main ()
20542 {
20543 struct sigaction act, oact;
20544 sigemptyset(&act.sa_mask);
20545 act.sa_flags = SA_RESTART;
20546 sigaction(0, &act, &oact);
20547   ;
20548   return 0;
20549 }
20550 _ACEOF
20551 rm -f conftest.$ac_objext conftest$ac_exeext
20552 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20553   (eval $ac_link) 2>conftest.er1
20554   ac_status=$?
20555   grep -v '^ *+' conftest.er1 >conftest.err
20556   rm -f conftest.er1
20557   cat conftest.err >&5
20558   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20559   (exit $ac_status); } &&
20560          { ac_try='test -z "$ac_c_werror_flag"
20561                          || test ! -s conftest.err'
20562   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20563   (eval $ac_try) 2>&5
20564   ac_status=$?
20565   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20566   (exit $ac_status); }; } &&
20567          { ac_try='test -s conftest$ac_exeext'
20568   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20569   (eval $ac_try) 2>&5
20570   ac_status=$?
20571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20572   (exit $ac_status); }; }; then
20573   pgac_cv_func_posix_signals=yes
20574 else
20575   echo "$as_me: failed program was:" >&5
20576 sed 's/^/| /' conftest.$ac_ext >&5
20577
20578 pgac_cv_func_posix_signals=no
20579 fi
20580 rm -f conftest.err conftest.$ac_objext \
20581       conftest$ac_exeext conftest.$ac_ext
20582 fi
20583 echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
20584 echo "${ECHO_T}$pgac_cv_func_posix_signals" >&6
20585 if test x"$pgac_cv_func_posix_signals" = xyes ; then
20586
20587 cat >>confdefs.h <<\_ACEOF
20588 #define HAVE_POSIX_SIGNALS
20589 _ACEOF
20590
20591 fi
20592 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
20593
20594 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
20595   { { echo "$as_me:$LINENO: error:
20596 *** Thread-safety requires POSIX signals, which are not supported by your
20597 *** operating system.
20598 " >&5
20599 echo "$as_me: error:
20600 *** Thread-safety requires POSIX signals, which are not supported by your
20601 *** operating system.
20602 " >&2;}
20603    { (exit 1); exit 1; }; }
20604 fi
20605 fi
20606
20607 if test $ac_cv_func_fseeko = yes; then
20608 # Check whether --enable-largefile or --disable-largefile was given.
20609 if test "${enable_largefile+set}" = set; then
20610   enableval="$enable_largefile"
20611
20612 fi;
20613 if test "$enable_largefile" != no; then
20614
20615   echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
20616 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
20617 if test "${ac_cv_sys_largefile_CC+set}" = set; then
20618   echo $ECHO_N "(cached) $ECHO_C" >&6
20619 else
20620   ac_cv_sys_largefile_CC=no
20621      if test "$GCC" != yes; then
20622        ac_save_CC=$CC
20623        while :; do
20624          # IRIX 6.2 and later do not support large files by default,
20625          # so use the C compiler's -n32 option if that helps.
20626          cat >conftest.$ac_ext <<_ACEOF
20627 /* confdefs.h.  */
20628 _ACEOF
20629 cat confdefs.h >>conftest.$ac_ext
20630 cat >>conftest.$ac_ext <<_ACEOF
20631 /* end confdefs.h.  */
20632 #include <sys/types.h>
20633  /* Check that off_t can represent 2**63 - 1 correctly.
20634     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20635     since some C++ compilers masquerading as C compilers
20636     incorrectly reject 9223372036854775807.  */
20637 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20638   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20639                        && LARGE_OFF_T % 2147483647 == 1)
20640                       ? 1 : -1];
20641 int
20642 main ()
20643 {
20644
20645   ;
20646   return 0;
20647 }
20648 _ACEOF
20649          rm -f conftest.$ac_objext
20650 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20651   (eval $ac_compile) 2>conftest.er1
20652   ac_status=$?
20653   grep -v '^ *+' conftest.er1 >conftest.err
20654   rm -f conftest.er1
20655   cat conftest.err >&5
20656   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20657   (exit $ac_status); } &&
20658          { ac_try='test -z "$ac_c_werror_flag"
20659                          || test ! -s conftest.err'
20660   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20661   (eval $ac_try) 2>&5
20662   ac_status=$?
20663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20664   (exit $ac_status); }; } &&
20665          { ac_try='test -s conftest.$ac_objext'
20666   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20667   (eval $ac_try) 2>&5
20668   ac_status=$?
20669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20670   (exit $ac_status); }; }; then
20671   break
20672 else
20673   echo "$as_me: failed program was:" >&5
20674 sed 's/^/| /' conftest.$ac_ext >&5
20675
20676 fi
20677 rm -f conftest.err conftest.$ac_objext
20678          CC="$CC -n32"
20679          rm -f conftest.$ac_objext
20680 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20681   (eval $ac_compile) 2>conftest.er1
20682   ac_status=$?
20683   grep -v '^ *+' conftest.er1 >conftest.err
20684   rm -f conftest.er1
20685   cat conftest.err >&5
20686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20687   (exit $ac_status); } &&
20688          { ac_try='test -z "$ac_c_werror_flag"
20689                          || test ! -s conftest.err'
20690   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20691   (eval $ac_try) 2>&5
20692   ac_status=$?
20693   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20694   (exit $ac_status); }; } &&
20695          { ac_try='test -s conftest.$ac_objext'
20696   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20697   (eval $ac_try) 2>&5
20698   ac_status=$?
20699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20700   (exit $ac_status); }; }; then
20701   ac_cv_sys_largefile_CC=' -n32'; break
20702 else
20703   echo "$as_me: failed program was:" >&5
20704 sed 's/^/| /' conftest.$ac_ext >&5
20705
20706 fi
20707 rm -f conftest.err conftest.$ac_objext
20708          break
20709        done
20710        CC=$ac_save_CC
20711        rm -f conftest.$ac_ext
20712     fi
20713 fi
20714 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
20715 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
20716   if test "$ac_cv_sys_largefile_CC" != no; then
20717     CC=$CC$ac_cv_sys_largefile_CC
20718   fi
20719
20720   echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
20721 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
20722 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
20723   echo $ECHO_N "(cached) $ECHO_C" >&6
20724 else
20725   while :; do
20726   ac_cv_sys_file_offset_bits=no
20727   cat >conftest.$ac_ext <<_ACEOF
20728 /* confdefs.h.  */
20729 _ACEOF
20730 cat confdefs.h >>conftest.$ac_ext
20731 cat >>conftest.$ac_ext <<_ACEOF
20732 /* end confdefs.h.  */
20733 #include <sys/types.h>
20734  /* Check that off_t can represent 2**63 - 1 correctly.
20735     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20736     since some C++ compilers masquerading as C compilers
20737     incorrectly reject 9223372036854775807.  */
20738 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20739   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20740                        && LARGE_OFF_T % 2147483647 == 1)
20741                       ? 1 : -1];
20742 int
20743 main ()
20744 {
20745
20746   ;
20747   return 0;
20748 }
20749 _ACEOF
20750 rm -f conftest.$ac_objext
20751 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20752   (eval $ac_compile) 2>conftest.er1
20753   ac_status=$?
20754   grep -v '^ *+' conftest.er1 >conftest.err
20755   rm -f conftest.er1
20756   cat conftest.err >&5
20757   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20758   (exit $ac_status); } &&
20759          { ac_try='test -z "$ac_c_werror_flag"
20760                          || test ! -s conftest.err'
20761   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20762   (eval $ac_try) 2>&5
20763   ac_status=$?
20764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20765   (exit $ac_status); }; } &&
20766          { ac_try='test -s conftest.$ac_objext'
20767   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20768   (eval $ac_try) 2>&5
20769   ac_status=$?
20770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20771   (exit $ac_status); }; }; then
20772   break
20773 else
20774   echo "$as_me: failed program was:" >&5
20775 sed 's/^/| /' conftest.$ac_ext >&5
20776
20777 fi
20778 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20779   cat >conftest.$ac_ext <<_ACEOF
20780 /* confdefs.h.  */
20781 _ACEOF
20782 cat confdefs.h >>conftest.$ac_ext
20783 cat >>conftest.$ac_ext <<_ACEOF
20784 /* end confdefs.h.  */
20785 #define _FILE_OFFSET_BITS 64
20786 #include <sys/types.h>
20787  /* Check that off_t can represent 2**63 - 1 correctly.
20788     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20789     since some C++ compilers masquerading as C compilers
20790     incorrectly reject 9223372036854775807.  */
20791 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20792   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20793                        && LARGE_OFF_T % 2147483647 == 1)
20794                       ? 1 : -1];
20795 int
20796 main ()
20797 {
20798
20799   ;
20800   return 0;
20801 }
20802 _ACEOF
20803 rm -f conftest.$ac_objext
20804 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20805   (eval $ac_compile) 2>conftest.er1
20806   ac_status=$?
20807   grep -v '^ *+' conftest.er1 >conftest.err
20808   rm -f conftest.er1
20809   cat conftest.err >&5
20810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20811   (exit $ac_status); } &&
20812          { ac_try='test -z "$ac_c_werror_flag"
20813                          || test ! -s conftest.err'
20814   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20815   (eval $ac_try) 2>&5
20816   ac_status=$?
20817   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20818   (exit $ac_status); }; } &&
20819          { ac_try='test -s conftest.$ac_objext'
20820   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20821   (eval $ac_try) 2>&5
20822   ac_status=$?
20823   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20824   (exit $ac_status); }; }; then
20825   ac_cv_sys_file_offset_bits=64; break
20826 else
20827   echo "$as_me: failed program was:" >&5
20828 sed 's/^/| /' conftest.$ac_ext >&5
20829
20830 fi
20831 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20832   break
20833 done
20834 fi
20835 echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
20836 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
20837 if test "$ac_cv_sys_file_offset_bits" != no; then
20838
20839 cat >>confdefs.h <<_ACEOF
20840 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
20841 _ACEOF
20842
20843 fi
20844 rm -f conftest*
20845   echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
20846 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
20847 if test "${ac_cv_sys_large_files+set}" = set; then
20848   echo $ECHO_N "(cached) $ECHO_C" >&6
20849 else
20850   while :; do
20851   ac_cv_sys_large_files=no
20852   cat >conftest.$ac_ext <<_ACEOF
20853 /* confdefs.h.  */
20854 _ACEOF
20855 cat confdefs.h >>conftest.$ac_ext
20856 cat >>conftest.$ac_ext <<_ACEOF
20857 /* end confdefs.h.  */
20858 #include <sys/types.h>
20859  /* Check that off_t can represent 2**63 - 1 correctly.
20860     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20861     since some C++ compilers masquerading as C compilers
20862     incorrectly reject 9223372036854775807.  */
20863 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20864   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20865                        && LARGE_OFF_T % 2147483647 == 1)
20866                       ? 1 : -1];
20867 int
20868 main ()
20869 {
20870
20871   ;
20872   return 0;
20873 }
20874 _ACEOF
20875 rm -f conftest.$ac_objext
20876 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20877   (eval $ac_compile) 2>conftest.er1
20878   ac_status=$?
20879   grep -v '^ *+' conftest.er1 >conftest.err
20880   rm -f conftest.er1
20881   cat conftest.err >&5
20882   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20883   (exit $ac_status); } &&
20884          { ac_try='test -z "$ac_c_werror_flag"
20885                          || test ! -s conftest.err'
20886   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20887   (eval $ac_try) 2>&5
20888   ac_status=$?
20889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20890   (exit $ac_status); }; } &&
20891          { ac_try='test -s conftest.$ac_objext'
20892   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20893   (eval $ac_try) 2>&5
20894   ac_status=$?
20895   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20896   (exit $ac_status); }; }; then
20897   break
20898 else
20899   echo "$as_me: failed program was:" >&5
20900 sed 's/^/| /' conftest.$ac_ext >&5
20901
20902 fi
20903 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20904   cat >conftest.$ac_ext <<_ACEOF
20905 /* confdefs.h.  */
20906 _ACEOF
20907 cat confdefs.h >>conftest.$ac_ext
20908 cat >>conftest.$ac_ext <<_ACEOF
20909 /* end confdefs.h.  */
20910 #define _LARGE_FILES 1
20911 #include <sys/types.h>
20912  /* Check that off_t can represent 2**63 - 1 correctly.
20913     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20914     since some C++ compilers masquerading as C compilers
20915     incorrectly reject 9223372036854775807.  */
20916 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20917   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20918                        && LARGE_OFF_T % 2147483647 == 1)
20919                       ? 1 : -1];
20920 int
20921 main ()
20922 {
20923
20924   ;
20925   return 0;
20926 }
20927 _ACEOF
20928 rm -f conftest.$ac_objext
20929 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20930   (eval $ac_compile) 2>conftest.er1
20931   ac_status=$?
20932   grep -v '^ *+' conftest.er1 >conftest.err
20933   rm -f conftest.er1
20934   cat conftest.err >&5
20935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20936   (exit $ac_status); } &&
20937          { ac_try='test -z "$ac_c_werror_flag"
20938                          || test ! -s conftest.err'
20939   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20940   (eval $ac_try) 2>&5
20941   ac_status=$?
20942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20943   (exit $ac_status); }; } &&
20944          { ac_try='test -s conftest.$ac_objext'
20945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20946   (eval $ac_try) 2>&5
20947   ac_status=$?
20948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20949   (exit $ac_status); }; }; then
20950   ac_cv_sys_large_files=1; break
20951 else
20952   echo "$as_me: failed program was:" >&5
20953 sed 's/^/| /' conftest.$ac_ext >&5
20954
20955 fi
20956 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20957   break
20958 done
20959 fi
20960 echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
20961 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
20962 if test "$ac_cv_sys_large_files" != no; then
20963
20964 cat >>confdefs.h <<_ACEOF
20965 #define _LARGE_FILES $ac_cv_sys_large_files
20966 _ACEOF
20967
20968 fi
20969 rm -f conftest*
20970 fi
20971
20972 fi
20973
20974 # SunOS doesn't handle negative byte comparisons properly with +/- return
20975 echo "$as_me:$LINENO: checking for working memcmp" >&5
20976 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
20977 if test "${ac_cv_func_memcmp_working+set}" = set; then
20978   echo $ECHO_N "(cached) $ECHO_C" >&6
20979 else
20980   if test "$cross_compiling" = yes; then
20981   ac_cv_func_memcmp_working=no
20982 else
20983   cat >conftest.$ac_ext <<_ACEOF
20984 /* confdefs.h.  */
20985 _ACEOF
20986 cat confdefs.h >>conftest.$ac_ext
20987 cat >>conftest.$ac_ext <<_ACEOF
20988 /* end confdefs.h.  */
20989 $ac_includes_default
20990 int
20991 main ()
20992 {
20993
20994   /* Some versions of memcmp are not 8-bit clean.  */
20995   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
20996   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
20997     exit (1);
20998
20999   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
21000      or more and with at least one buffer not starting on a 4-byte boundary.
21001      William Lewis provided this test program.   */
21002   {
21003     char foo[21];
21004     char bar[21];
21005     int i;
21006     for (i = 0; i < 4; i++)
21007       {
21008         char *a = foo + i;
21009         char *b = bar + i;
21010         strcpy (a, "--------01111111");
21011         strcpy (b, "--------10000000");
21012         if (memcmp (a, b, 16) >= 0)
21013           exit (1);
21014       }
21015     exit (0);
21016   }
21017
21018   ;
21019   return 0;
21020 }
21021 _ACEOF
21022 rm -f conftest$ac_exeext
21023 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21024   (eval $ac_link) 2>&5
21025   ac_status=$?
21026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21027   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21028   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21029   (eval $ac_try) 2>&5
21030   ac_status=$?
21031   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21032   (exit $ac_status); }; }; then
21033   ac_cv_func_memcmp_working=yes
21034 else
21035   echo "$as_me: program exited with status $ac_status" >&5
21036 echo "$as_me: failed program was:" >&5
21037 sed 's/^/| /' conftest.$ac_ext >&5
21038
21039 ( exit $ac_status )
21040 ac_cv_func_memcmp_working=no
21041 fi
21042 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21043 fi
21044 fi
21045 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
21046 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
21047 test $ac_cv_func_memcmp_working = no && case $LIBOBJS in
21048     "memcmp.$ac_objext"   | \
21049   *" memcmp.$ac_objext"   | \
21050     "memcmp.$ac_objext "* | \
21051   *" memcmp.$ac_objext "* ) ;;
21052   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" ;;
21053 esac
21054
21055
21056
21057
21058 # Select semaphore implementation type.
21059 if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
21060
21061 cat >>confdefs.h <<\_ACEOF
21062 #define USE_NAMED_POSIX_SEMAPHORES 1
21063 _ACEOF
21064
21065   SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21066 else
21067   if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
21068
21069 cat >>confdefs.h <<\_ACEOF
21070 #define USE_UNNAMED_POSIX_SEMAPHORES 1
21071 _ACEOF
21072
21073     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21074   else
21075
21076 cat >>confdefs.h <<\_ACEOF
21077 #define USE_SYSV_SEMAPHORES 1
21078 _ACEOF
21079
21080     SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
21081   fi
21082 fi
21083
21084
21085 # Select shared-memory implementation type.
21086
21087 cat >>confdefs.h <<\_ACEOF
21088 #define USE_SYSV_SHARED_MEMORY 1
21089 _ACEOF
21090
21091 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
21092
21093
21094 # If not set in template file, set bytes to use libc memset()
21095 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
21096   MEMSET_LOOP_LIMIT=1024
21097 fi
21098
21099 cat >>confdefs.h <<_ACEOF
21100 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
21101 _ACEOF
21102
21103
21104
21105 if test "$enable_nls" = yes ; then
21106
21107   echo "$as_me:$LINENO: checking for library containing gettext" >&5
21108 echo $ECHO_N "checking for library containing gettext... $ECHO_C" >&6
21109 if test "${ac_cv_search_gettext+set}" = set; then
21110   echo $ECHO_N "(cached) $ECHO_C" >&6
21111 else
21112   ac_func_search_save_LIBS=$LIBS
21113 ac_cv_search_gettext=no
21114 cat >conftest.$ac_ext <<_ACEOF
21115 /* confdefs.h.  */
21116 _ACEOF
21117 cat confdefs.h >>conftest.$ac_ext
21118 cat >>conftest.$ac_ext <<_ACEOF
21119 /* end confdefs.h.  */
21120
21121 /* Override any gcc2 internal prototype to avoid an error.  */
21122 #ifdef __cplusplus
21123 extern "C"
21124 #endif
21125 /* We use char because int might match the return type of a gcc2
21126    builtin and then its argument prototype would still apply.  */
21127 char gettext ();
21128 int
21129 main ()
21130 {
21131 gettext ();
21132   ;
21133   return 0;
21134 }
21135 _ACEOF
21136 rm -f conftest.$ac_objext conftest$ac_exeext
21137 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21138   (eval $ac_link) 2>conftest.er1
21139   ac_status=$?
21140   grep -v '^ *+' conftest.er1 >conftest.err
21141   rm -f conftest.er1
21142   cat conftest.err >&5
21143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21144   (exit $ac_status); } &&
21145          { ac_try='test -z "$ac_c_werror_flag"
21146                          || test ! -s conftest.err'
21147   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21148   (eval $ac_try) 2>&5
21149   ac_status=$?
21150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21151   (exit $ac_status); }; } &&
21152          { ac_try='test -s conftest$ac_exeext'
21153   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21154   (eval $ac_try) 2>&5
21155   ac_status=$?
21156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21157   (exit $ac_status); }; }; then
21158   ac_cv_search_gettext="none required"
21159 else
21160   echo "$as_me: failed program was:" >&5
21161 sed 's/^/| /' conftest.$ac_ext >&5
21162
21163 fi
21164 rm -f conftest.err conftest.$ac_objext \
21165       conftest$ac_exeext conftest.$ac_ext
21166 if test "$ac_cv_search_gettext" = no; then
21167   for ac_lib in intl; do
21168     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21169     cat >conftest.$ac_ext <<_ACEOF
21170 /* confdefs.h.  */
21171 _ACEOF
21172 cat confdefs.h >>conftest.$ac_ext
21173 cat >>conftest.$ac_ext <<_ACEOF
21174 /* end confdefs.h.  */
21175
21176 /* Override any gcc2 internal prototype to avoid an error.  */
21177 #ifdef __cplusplus
21178 extern "C"
21179 #endif
21180 /* We use char because int might match the return type of a gcc2
21181    builtin and then its argument prototype would still apply.  */
21182 char gettext ();
21183 int
21184 main ()
21185 {
21186 gettext ();
21187   ;
21188   return 0;
21189 }
21190 _ACEOF
21191 rm -f conftest.$ac_objext conftest$ac_exeext
21192 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21193   (eval $ac_link) 2>conftest.er1
21194   ac_status=$?
21195   grep -v '^ *+' conftest.er1 >conftest.err
21196   rm -f conftest.er1
21197   cat conftest.err >&5
21198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21199   (exit $ac_status); } &&
21200          { ac_try='test -z "$ac_c_werror_flag"
21201                          || test ! -s conftest.err'
21202   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21203   (eval $ac_try) 2>&5
21204   ac_status=$?
21205   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21206   (exit $ac_status); }; } &&
21207          { ac_try='test -s conftest$ac_exeext'
21208   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21209   (eval $ac_try) 2>&5
21210   ac_status=$?
21211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21212   (exit $ac_status); }; }; then
21213   ac_cv_search_gettext="-l$ac_lib"
21214 break
21215 else
21216   echo "$as_me: failed program was:" >&5
21217 sed 's/^/| /' conftest.$ac_ext >&5
21218
21219 fi
21220 rm -f conftest.err conftest.$ac_objext \
21221       conftest$ac_exeext conftest.$ac_ext
21222   done
21223 fi
21224 LIBS=$ac_func_search_save_LIBS
21225 fi
21226 echo "$as_me:$LINENO: result: $ac_cv_search_gettext" >&5
21227 echo "${ECHO_T}$ac_cv_search_gettext" >&6
21228 if test "$ac_cv_search_gettext" != no; then
21229   test "$ac_cv_search_gettext" = "none required" || LIBS="$ac_cv_search_gettext $LIBS"
21230
21231 else
21232   { { echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
21233 echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
21234    { (exit 1); exit 1; }; }
21235 fi
21236
21237   if test "${ac_cv_header_libintl_h+set}" = set; then
21238   echo "$as_me:$LINENO: checking for libintl.h" >&5
21239 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
21240 if test "${ac_cv_header_libintl_h+set}" = set; then
21241   echo $ECHO_N "(cached) $ECHO_C" >&6
21242 fi
21243 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
21244 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
21245 else
21246   # Is the header compilable?
21247 echo "$as_me:$LINENO: checking libintl.h usability" >&5
21248 echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6
21249 cat >conftest.$ac_ext <<_ACEOF
21250 /* confdefs.h.  */
21251 _ACEOF
21252 cat confdefs.h >>conftest.$ac_ext
21253 cat >>conftest.$ac_ext <<_ACEOF
21254 /* end confdefs.h.  */
21255 $ac_includes_default
21256 #include <libintl.h>
21257 _ACEOF
21258 rm -f conftest.$ac_objext
21259 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21260   (eval $ac_compile) 2>conftest.er1
21261   ac_status=$?
21262   grep -v '^ *+' conftest.er1 >conftest.err
21263   rm -f conftest.er1
21264   cat conftest.err >&5
21265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21266   (exit $ac_status); } &&
21267          { ac_try='test -z "$ac_c_werror_flag"
21268                          || test ! -s conftest.err'
21269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21270   (eval $ac_try) 2>&5
21271   ac_status=$?
21272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21273   (exit $ac_status); }; } &&
21274          { ac_try='test -s conftest.$ac_objext'
21275   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21276   (eval $ac_try) 2>&5
21277   ac_status=$?
21278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21279   (exit $ac_status); }; }; then
21280   ac_header_compiler=yes
21281 else
21282   echo "$as_me: failed program was:" >&5
21283 sed 's/^/| /' conftest.$ac_ext >&5
21284
21285 ac_header_compiler=no
21286 fi
21287 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21288 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21289 echo "${ECHO_T}$ac_header_compiler" >&6
21290
21291 # Is the header present?
21292 echo "$as_me:$LINENO: checking libintl.h presence" >&5
21293 echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6
21294 cat >conftest.$ac_ext <<_ACEOF
21295 /* confdefs.h.  */
21296 _ACEOF
21297 cat confdefs.h >>conftest.$ac_ext
21298 cat >>conftest.$ac_ext <<_ACEOF
21299 /* end confdefs.h.  */
21300 #include <libintl.h>
21301 _ACEOF
21302 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21303   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21304   ac_status=$?
21305   grep -v '^ *+' conftest.er1 >conftest.err
21306   rm -f conftest.er1
21307   cat conftest.err >&5
21308   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21309   (exit $ac_status); } >/dev/null; then
21310   if test -s conftest.err; then
21311     ac_cpp_err=$ac_c_preproc_warn_flag
21312     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
21313   else
21314     ac_cpp_err=
21315   fi
21316 else
21317   ac_cpp_err=yes
21318 fi
21319 if test -z "$ac_cpp_err"; then
21320   ac_header_preproc=yes
21321 else
21322   echo "$as_me: failed program was:" >&5
21323 sed 's/^/| /' conftest.$ac_ext >&5
21324
21325   ac_header_preproc=no
21326 fi
21327 rm -f conftest.err conftest.$ac_ext
21328 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21329 echo "${ECHO_T}$ac_header_preproc" >&6
21330
21331 # So?  What about this header?
21332 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21333   yes:no: )
21334     { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
21335 echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21336     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
21337 echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
21338     ac_header_preproc=yes
21339     ;;
21340   no:yes:* )
21341     { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
21342 echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
21343     { echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
21344 echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
21345     { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
21346 echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
21347     { echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
21348 echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21349     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
21350 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
21351     { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
21352 echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
21353     (
21354       cat <<\_ASBOX
21355 ## ---------------------------------------- ##
21356 ## Report this to pgsql-bugs@postgresql.org ##
21357 ## ---------------------------------------- ##
21358 _ASBOX
21359     ) |
21360       sed "s/^/$as_me: WARNING:     /" >&2
21361     ;;
21362 esac
21363 echo "$as_me:$LINENO: checking for libintl.h" >&5
21364 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
21365 if test "${ac_cv_header_libintl_h+set}" = set; then
21366   echo $ECHO_N "(cached) $ECHO_C" >&6
21367 else
21368   ac_cv_header_libintl_h=$ac_header_preproc
21369 fi
21370 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
21371 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
21372
21373 fi
21374 if test $ac_cv_header_libintl_h = yes; then
21375   :
21376 else
21377   { { echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
21378 echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
21379    { (exit 1); exit 1; }; }
21380 fi
21381
21382
21383   for ac_prog in msgfmt
21384 do
21385   # Extract the first word of "$ac_prog", so it can be a program name with args.
21386 set dummy $ac_prog; ac_word=$2
21387 echo "$as_me:$LINENO: checking for $ac_word" >&5
21388 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21389 if test "${ac_cv_prog_MSGFMT+set}" = set; then
21390   echo $ECHO_N "(cached) $ECHO_C" >&6
21391 else
21392   if test -n "$MSGFMT"; then
21393   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
21394 else
21395 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21396 for as_dir in $PATH
21397 do
21398   IFS=$as_save_IFS
21399   test -z "$as_dir" && as_dir=.
21400   for ac_exec_ext in '' $ac_executable_extensions; do
21401   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21402     ac_cv_prog_MSGFMT="$ac_prog"
21403     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21404     break 2
21405   fi
21406 done
21407 done
21408
21409 fi
21410 fi
21411 MSGFMT=$ac_cv_prog_MSGFMT
21412 if test -n "$MSGFMT"; then
21413   echo "$as_me:$LINENO: result: $MSGFMT" >&5
21414 echo "${ECHO_T}$MSGFMT" >&6
21415 else
21416   echo "$as_me:$LINENO: result: no" >&5
21417 echo "${ECHO_T}no" >&6
21418 fi
21419
21420   test -n "$MSGFMT" && break
21421 done
21422
21423   if test -z "$MSGFMT"; then
21424     { { echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
21425 echo "$as_me: error: msgfmt is required for NLS" >&2;}
21426    { (exit 1); exit 1; }; }
21427   fi
21428   for ac_prog in msgmerge
21429 do
21430   # Extract the first word of "$ac_prog", so it can be a program name with args.
21431 set dummy $ac_prog; ac_word=$2
21432 echo "$as_me:$LINENO: checking for $ac_word" >&5
21433 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21434 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
21435   echo $ECHO_N "(cached) $ECHO_C" >&6
21436 else
21437   if test -n "$MSGMERGE"; then
21438   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
21439 else
21440 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21441 for as_dir in $PATH
21442 do
21443   IFS=$as_save_IFS
21444   test -z "$as_dir" && as_dir=.
21445   for ac_exec_ext in '' $ac_executable_extensions; do
21446   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21447     ac_cv_prog_MSGMERGE="$ac_prog"
21448     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21449     break 2
21450   fi
21451 done
21452 done
21453
21454 fi
21455 fi
21456 MSGMERGE=$ac_cv_prog_MSGMERGE
21457 if test -n "$MSGMERGE"; then
21458   echo "$as_me:$LINENO: result: $MSGMERGE" >&5
21459 echo "${ECHO_T}$MSGMERGE" >&6
21460 else
21461   echo "$as_me:$LINENO: result: no" >&5
21462 echo "${ECHO_T}no" >&6
21463 fi
21464
21465   test -n "$MSGMERGE" && break
21466 done
21467
21468   for ac_prog in xgettext
21469 do
21470   # Extract the first word of "$ac_prog", so it can be a program name with args.
21471 set dummy $ac_prog; ac_word=$2
21472 echo "$as_me:$LINENO: checking for $ac_word" >&5
21473 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21474 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
21475   echo $ECHO_N "(cached) $ECHO_C" >&6
21476 else
21477   if test -n "$XGETTEXT"; then
21478   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
21479 else
21480 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21481 for as_dir in $PATH
21482 do
21483   IFS=$as_save_IFS
21484   test -z "$as_dir" && as_dir=.
21485   for ac_exec_ext in '' $ac_executable_extensions; do
21486   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21487     ac_cv_prog_XGETTEXT="$ac_prog"
21488     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21489     break 2
21490   fi
21491 done
21492 done
21493
21494 fi
21495 fi
21496 XGETTEXT=$ac_cv_prog_XGETTEXT
21497 if test -n "$XGETTEXT"; then
21498   echo "$as_me:$LINENO: result: $XGETTEXT" >&5
21499 echo "${ECHO_T}$XGETTEXT" >&6
21500 else
21501   echo "$as_me:$LINENO: result: no" >&5
21502 echo "${ECHO_T}no" >&6
21503 fi
21504
21505   test -n "$XGETTEXT" && break
21506 done
21507
21508
21509   # Note: share/locale is always the default, independent of $datadir
21510   localedir='${prefix}/share/locale'
21511   if test x"$prefix" = x"NONE"; then
21512     exp_localedir="$ac_default_prefix/share/locale"
21513   else
21514     exp_localedir="$prefix/share/locale"
21515   fi
21516
21517
21518
21519 cat >>confdefs.h <<_ACEOF
21520 #define LOCALEDIR "$exp_localedir"
21521 _ACEOF
21522
21523
21524 fi
21525
21526 # Check for Tcl configuration script tclConfig.sh
21527 if test "$with_tcl" = yes; then
21528     for ac_prog in tclsh tcl
21529 do
21530   # Extract the first word of "$ac_prog", so it can be a program name with args.
21531 set dummy $ac_prog; ac_word=$2
21532 echo "$as_me:$LINENO: checking for $ac_word" >&5
21533 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21534 if test "${ac_cv_path_TCLSH+set}" = set; then
21535   echo $ECHO_N "(cached) $ECHO_C" >&6
21536 else
21537   case $TCLSH in
21538   [\\/]* | ?:[\\/]*)
21539   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
21540   ;;
21541   *)
21542   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21543 for as_dir in $PATH
21544 do
21545   IFS=$as_save_IFS
21546   test -z "$as_dir" && as_dir=.
21547   for ac_exec_ext in '' $ac_executable_extensions; do
21548   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21549     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
21550     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21551     break 2
21552   fi
21553 done
21554 done
21555
21556   ;;
21557 esac
21558 fi
21559 TCLSH=$ac_cv_path_TCLSH
21560
21561 if test -n "$TCLSH"; then
21562   echo "$as_me:$LINENO: result: $TCLSH" >&5
21563 echo "${ECHO_T}$TCLSH" >&6
21564 else
21565   echo "$as_me:$LINENO: result: no" >&5
21566 echo "${ECHO_T}no" >&6
21567 fi
21568
21569   test -n "$TCLSH" && break
21570 done
21571
21572 echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
21573 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6
21574 # Let user override test
21575 if test -z "$TCL_CONFIG_SH"; then
21576     pgac_test_dirs="$with_tclconfig"
21577
21578     set X $pgac_test_dirs; shift
21579     if test $# -eq 0; then
21580         test -z "$TCLSH" && { { echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
21581 echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
21582    { (exit 1); exit 1; }; }
21583         set X `echo 'puts $auto_path' | $TCLSH`; shift
21584     fi
21585
21586     for pgac_dir do
21587         if test -r "$pgac_dir/tclConfig.sh"; then
21588             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
21589             break
21590         fi
21591     done
21592 fi
21593
21594 if test -z "$TCL_CONFIG_SH"; then
21595     echo "$as_me:$LINENO: result: no" >&5
21596 echo "${ECHO_T}no" >&6
21597     { { echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
21598 echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
21599    { (exit 1); exit 1; }; }
21600 else
21601     echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
21602 echo "${ECHO_T}$TCL_CONFIG_SH" >&6
21603 fi
21604
21605
21606
21607     . "$TCL_CONFIG_SH"
21608 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
21609 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
21610 eval TCL_LIBS=\"$TCL_LIBS\"
21611 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
21612 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
21613
21614         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
21615     ac_save_CPPFLAGS=$CPPFLAGS
21616     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
21617     if test "${ac_cv_header_tcl_h+set}" = set; then
21618   echo "$as_me:$LINENO: checking for tcl.h" >&5
21619 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
21620 if test "${ac_cv_header_tcl_h+set}" = set; then
21621   echo $ECHO_N "(cached) $ECHO_C" >&6
21622 fi
21623 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
21624 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
21625 else
21626   # Is the header compilable?
21627 echo "$as_me:$LINENO: checking tcl.h usability" >&5
21628 echo $ECHO_N "checking tcl.h usability... $ECHO_C" >&6
21629 cat >conftest.$ac_ext <<_ACEOF
21630 /* confdefs.h.  */
21631 _ACEOF
21632 cat confdefs.h >>conftest.$ac_ext
21633 cat >>conftest.$ac_ext <<_ACEOF
21634 /* end confdefs.h.  */
21635 $ac_includes_default
21636 #include <tcl.h>
21637 _ACEOF
21638 rm -f conftest.$ac_objext
21639 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21640   (eval $ac_compile) 2>conftest.er1
21641   ac_status=$?
21642   grep -v '^ *+' conftest.er1 >conftest.err
21643   rm -f conftest.er1
21644   cat conftest.err >&5
21645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21646   (exit $ac_status); } &&
21647          { ac_try='test -z "$ac_c_werror_flag"
21648                          || test ! -s conftest.err'
21649   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21650   (eval $ac_try) 2>&5
21651   ac_status=$?
21652   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21653   (exit $ac_status); }; } &&
21654          { ac_try='test -s conftest.$ac_objext'
21655   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21656   (eval $ac_try) 2>&5
21657   ac_status=$?
21658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21659   (exit $ac_status); }; }; then
21660   ac_header_compiler=yes
21661 else
21662   echo "$as_me: failed program was:" >&5
21663 sed 's/^/| /' conftest.$ac_ext >&5
21664
21665 ac_header_compiler=no
21666 fi
21667 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21668 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21669 echo "${ECHO_T}$ac_header_compiler" >&6
21670
21671 # Is the header present?
21672 echo "$as_me:$LINENO: checking tcl.h presence" >&5
21673 echo $ECHO_N "checking tcl.h presence... $ECHO_C" >&6
21674 cat >conftest.$ac_ext <<_ACEOF
21675 /* confdefs.h.  */
21676 _ACEOF
21677 cat confdefs.h >>conftest.$ac_ext
21678 cat >>conftest.$ac_ext <<_ACEOF
21679 /* end confdefs.h.  */
21680 #include <tcl.h>
21681 _ACEOF
21682 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21683   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21684   ac_status=$?
21685   grep -v '^ *+' conftest.er1 >conftest.err
21686   rm -f conftest.er1
21687   cat conftest.err >&5
21688   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21689   (exit $ac_status); } >/dev/null; then
21690   if test -s conftest.err; then
21691     ac_cpp_err=$ac_c_preproc_warn_flag
21692     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
21693   else
21694     ac_cpp_err=
21695   fi
21696 else
21697   ac_cpp_err=yes
21698 fi
21699 if test -z "$ac_cpp_err"; then
21700   ac_header_preproc=yes
21701 else
21702   echo "$as_me: failed program was:" >&5
21703 sed 's/^/| /' conftest.$ac_ext >&5
21704
21705   ac_header_preproc=no
21706 fi
21707 rm -f conftest.err conftest.$ac_ext
21708 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21709 echo "${ECHO_T}$ac_header_preproc" >&6
21710
21711 # So?  What about this header?
21712 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21713   yes:no: )
21714     { echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
21715 echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21716     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
21717 echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
21718     ac_header_preproc=yes
21719     ;;
21720   no:yes:* )
21721     { echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
21722 echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
21723     { echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
21724 echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
21725     { echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
21726 echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
21727     { echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
21728 echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21729     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
21730 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
21731     { echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
21732 echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
21733     (
21734       cat <<\_ASBOX
21735 ## ---------------------------------------- ##
21736 ## Report this to pgsql-bugs@postgresql.org ##
21737 ## ---------------------------------------- ##
21738 _ASBOX
21739     ) |
21740       sed "s/^/$as_me: WARNING:     /" >&2
21741     ;;
21742 esac
21743 echo "$as_me:$LINENO: checking for tcl.h" >&5
21744 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
21745 if test "${ac_cv_header_tcl_h+set}" = set; then
21746   echo $ECHO_N "(cached) $ECHO_C" >&6
21747 else
21748   ac_cv_header_tcl_h=$ac_header_preproc
21749 fi
21750 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
21751 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
21752
21753 fi
21754 if test $ac_cv_header_tcl_h = yes; then
21755   :
21756 else
21757   { { echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
21758 echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
21759    { (exit 1); exit 1; }; }
21760 fi
21761
21762
21763     CPPFLAGS=$ac_save_CPPFLAGS
21764 fi
21765
21766 #
21767 # Check for DocBook and tools
21768 #
21769 for ac_prog in onsgmls nsgmls
21770 do
21771   # Extract the first word of "$ac_prog", so it can be a program name with args.
21772 set dummy $ac_prog; ac_word=$2
21773 echo "$as_me:$LINENO: checking for $ac_word" >&5
21774 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21775 if test "${ac_cv_prog_NSGMLS+set}" = set; then
21776   echo $ECHO_N "(cached) $ECHO_C" >&6
21777 else
21778   if test -n "$NSGMLS"; then
21779   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
21780 else
21781 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21782 for as_dir in $PATH
21783 do
21784   IFS=$as_save_IFS
21785   test -z "$as_dir" && as_dir=.
21786   for ac_exec_ext in '' $ac_executable_extensions; do
21787   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21788     ac_cv_prog_NSGMLS="$ac_prog"
21789     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21790     break 2
21791   fi
21792 done
21793 done
21794
21795 fi
21796 fi
21797 NSGMLS=$ac_cv_prog_NSGMLS
21798 if test -n "$NSGMLS"; then
21799   echo "$as_me:$LINENO: result: $NSGMLS" >&5
21800 echo "${ECHO_T}$NSGMLS" >&6
21801 else
21802   echo "$as_me:$LINENO: result: no" >&5
21803 echo "${ECHO_T}no" >&6
21804 fi
21805
21806   test -n "$NSGMLS" && break
21807 done
21808
21809 for ac_prog in openjade jade
21810 do
21811   # Extract the first word of "$ac_prog", so it can be a program name with args.
21812 set dummy $ac_prog; ac_word=$2
21813 echo "$as_me:$LINENO: checking for $ac_word" >&5
21814 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21815 if test "${ac_cv_prog_JADE+set}" = set; then
21816   echo $ECHO_N "(cached) $ECHO_C" >&6
21817 else
21818   if test -n "$JADE"; then
21819   ac_cv_prog_JADE="$JADE" # Let the user override the test.
21820 else
21821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21822 for as_dir in $PATH
21823 do
21824   IFS=$as_save_IFS
21825   test -z "$as_dir" && as_dir=.
21826   for ac_exec_ext in '' $ac_executable_extensions; do
21827   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21828     ac_cv_prog_JADE="$ac_prog"
21829     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21830     break 2
21831   fi
21832 done
21833 done
21834
21835 fi
21836 fi
21837 JADE=$ac_cv_prog_JADE
21838 if test -n "$JADE"; then
21839   echo "$as_me:$LINENO: result: $JADE" >&5
21840 echo "${ECHO_T}$JADE" >&6
21841 else
21842   echo "$as_me:$LINENO: result: no" >&5
21843 echo "${ECHO_T}no" >&6
21844 fi
21845
21846   test -n "$JADE" && break
21847 done
21848
21849
21850 echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
21851 echo $ECHO_N "checking for DocBook V4.2... $ECHO_C" >&6
21852 if test "${pgac_cv_check_docbook+set}" = set; then
21853   echo $ECHO_N "(cached) $ECHO_C" >&6
21854 else
21855   cat >conftest.sgml <<EOF
21856 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
21857 <book>
21858  <title>test</title>
21859  <chapter>
21860   <title>random</title>
21861    <sect1>
21862     <title>testsect</title>
21863     <para>text</para>
21864   </sect1>
21865  </chapter>
21866 </book>
21867 EOF
21868
21869 pgac_cv_check_docbook=no
21870
21871 if test -n "$NSGMLS"; then
21872   $NSGMLS -s conftest.sgml 1>&5 2>&1
21873   if test $? -eq 0; then
21874     pgac_cv_check_docbook=yes
21875   fi
21876 fi
21877 rm -f conftest.sgml
21878 fi
21879 echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
21880 echo "${ECHO_T}$pgac_cv_check_docbook" >&6
21881
21882 have_docbook=$pgac_cv_check_docbook
21883
21884
21885 echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
21886 echo $ECHO_N "checking for DocBook stylesheets... $ECHO_C" >&6
21887 if test "${pgac_cv_path_stylesheets+set}" = set; then
21888   echo $ECHO_N "(cached) $ECHO_C" >&6
21889 else
21890   if test -n "$DOCBOOKSTYLE"; then
21891   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
21892 else
21893   for pgac_prefix in /usr /usr/local /opt; do
21894     for pgac_infix in share lib; do
21895       for pgac_postfix in \
21896         sgml/stylesheets/nwalsh-modular \
21897         sgml/stylesheets/docbook \
21898                 sgml/docbook-dsssl \
21899         sgml/docbook/dsssl/modular \
21900         sgml/docbook/stylesheet/dsssl/modular \
21901         sgml/docbook/dsssl-stylesheets
21902       do
21903         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
21904         if test -r "$pgac_candidate/html/docbook.dsl" \
21905            && test -r "$pgac_candidate/print/docbook.dsl"
21906         then
21907           pgac_cv_path_stylesheets=$pgac_candidate
21908           break 3
21909         fi
21910       done
21911     done
21912   done
21913 fi
21914 fi
21915
21916 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
21917
21918 if test -n "$DOCBOOKSTYLE"; then
21919   echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
21920 echo "${ECHO_T}$DOCBOOKSTYLE" >&6
21921 else
21922   echo "$as_me:$LINENO: result: no" >&5
21923 echo "${ECHO_T}no" >&6
21924 fi
21925 if test -n "$DOCBOOKSTYLE"; then
21926   for ac_prog in collateindex.pl
21927 do
21928   # Extract the first word of "$ac_prog", so it can be a program name with args.
21929 set dummy $ac_prog; ac_word=$2
21930 echo "$as_me:$LINENO: checking for $ac_word" >&5
21931 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21932 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
21933   echo $ECHO_N "(cached) $ECHO_C" >&6
21934 else
21935   case $COLLATEINDEX in
21936   [\\/]* | ?:[\\/]*)
21937   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
21938   ;;
21939   *)
21940   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21941 for as_dir in $DOCBOOKSTYLE/bin $PATH
21942 do
21943   IFS=$as_save_IFS
21944   test -z "$as_dir" && as_dir=.
21945   for ac_exec_ext in '' $ac_executable_extensions; do
21946   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21947     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
21948     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21949     break 2
21950   fi
21951 done
21952 done
21953
21954   ;;
21955 esac
21956 fi
21957 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
21958
21959 if test -n "$COLLATEINDEX"; then
21960   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
21961 echo "${ECHO_T}$COLLATEINDEX" >&6
21962 else
21963   echo "$as_me:$LINENO: result: no" >&5
21964 echo "${ECHO_T}no" >&6
21965 fi
21966
21967   test -n "$COLLATEINDEX" && break
21968 done
21969
21970 else
21971   for ac_prog in collateindex.pl
21972 do
21973   # Extract the first word of "$ac_prog", so it can be a program name with args.
21974 set dummy $ac_prog; ac_word=$2
21975 echo "$as_me:$LINENO: checking for $ac_word" >&5
21976 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21977 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
21978   echo $ECHO_N "(cached) $ECHO_C" >&6
21979 else
21980   case $COLLATEINDEX in
21981   [\\/]* | ?:[\\/]*)
21982   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
21983   ;;
21984   *)
21985   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21986 for as_dir in $PATH
21987 do
21988   IFS=$as_save_IFS
21989   test -z "$as_dir" && as_dir=.
21990   for ac_exec_ext in '' $ac_executable_extensions; do
21991   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21992     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
21993     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21994     break 2
21995   fi
21996 done
21997 done
21998
21999   ;;
22000 esac
22001 fi
22002 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
22003
22004 if test -n "$COLLATEINDEX"; then
22005   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
22006 echo "${ECHO_T}$COLLATEINDEX" >&6
22007 else
22008   echo "$as_me:$LINENO: result: no" >&5
22009 echo "${ECHO_T}no" >&6
22010 fi
22011
22012   test -n "$COLLATEINDEX" && break
22013 done
22014
22015 fi
22016 for ac_prog in sgmlspl
22017 do
22018   # Extract the first word of "$ac_prog", so it can be a program name with args.
22019 set dummy $ac_prog; ac_word=$2
22020 echo "$as_me:$LINENO: checking for $ac_word" >&5
22021 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22022 if test "${ac_cv_prog_SGMLSPL+set}" = set; then
22023   echo $ECHO_N "(cached) $ECHO_C" >&6
22024 else
22025   if test -n "$SGMLSPL"; then
22026   ac_cv_prog_SGMLSPL="$SGMLSPL" # Let the user override the test.
22027 else
22028 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22029 for as_dir in $PATH
22030 do
22031   IFS=$as_save_IFS
22032   test -z "$as_dir" && as_dir=.
22033   for ac_exec_ext in '' $ac_executable_extensions; do
22034   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22035     ac_cv_prog_SGMLSPL="$ac_prog"
22036     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22037     break 2
22038   fi
22039 done
22040 done
22041
22042 fi
22043 fi
22044 SGMLSPL=$ac_cv_prog_SGMLSPL
22045 if test -n "$SGMLSPL"; then
22046   echo "$as_me:$LINENO: result: $SGMLSPL" >&5
22047 echo "${ECHO_T}$SGMLSPL" >&6
22048 else
22049   echo "$as_me:$LINENO: result: no" >&5
22050 echo "${ECHO_T}no" >&6
22051 fi
22052
22053   test -n "$SGMLSPL" && break
22054 done
22055
22056
22057 # Thread testing
22058
22059 # We have to run the thread test near the end so we have all our symbols
22060 # defined.  Cross compiling throws a warning.
22061 #
22062 if test "$enable_thread_safety_force" = yes; then
22063 if test x"$template" != x"win32"
22064 then
22065   { echo "$as_me:$LINENO: WARNING:
22066 *** Skipping thread test program.  --enable-thread-safety-force was used.
22067 *** Run the program in src/test/thread on the your machine and add
22068 proper locking function calls to your applications to guarantee thread
22069 safety.
22070 " >&5
22071 echo "$as_me: WARNING:
22072 *** Skipping thread test program.  --enable-thread-safety-force was used.
22073 *** Run the program in src/test/thread on the your machine and add
22074 proper locking function calls to your applications to guarantee thread
22075 safety.
22076 " >&2;}
22077 else
22078 { echo "$as_me:$LINENO: WARNING: *** Skipping thread test on Win32" >&5
22079 echo "$as_me: WARNING: *** Skipping thread test on Win32" >&2;}
22080 fi
22081 elif test "$enable_thread_safety" = yes; then
22082 if test x"$template" != x"win32"
22083 then
22084 echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
22085 echo $ECHO_N "checking thread safety of required library functions... $ECHO_C" >&6
22086
22087 _CFLAGS="$CFLAGS"
22088 _LIBS="$LIBS"
22089 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
22090 LIBS="$LIBS $PTHREAD_LIBS"
22091 if test "$cross_compiling" = yes; then
22092   echo "$as_me:$LINENO: result: maybe" >&5
22093 echo "${ECHO_T}maybe" >&6
22094   { echo "$as_me:$LINENO: WARNING:
22095 *** Skipping thread test program because of cross-compile build.
22096 *** Run the program in src/test/thread on the target machine.
22097 " >&5
22098 echo "$as_me: WARNING:
22099 *** Skipping thread test program because of cross-compile build.
22100 *** Run the program in src/test/thread on the target machine.
22101 " >&2;}
22102 else
22103   cat >conftest.$ac_ext <<_ACEOF
22104 /* confdefs.h.  */
22105 _ACEOF
22106 cat confdefs.h >>conftest.$ac_ext
22107 cat >>conftest.$ac_ext <<_ACEOF
22108 /* end confdefs.h.  */
22109 #include "$srcdir/src/test/thread/thread_test.c"
22110 _ACEOF
22111 rm -f conftest$ac_exeext
22112 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22113   (eval $ac_link) 2>&5
22114   ac_status=$?
22115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22116   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22117   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22118   (eval $ac_try) 2>&5
22119   ac_status=$?
22120   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22121   (exit $ac_status); }; }; then
22122   echo "$as_me:$LINENO: result: yes" >&5
22123 echo "${ECHO_T}yes" >&6
22124 else
22125   echo "$as_me: program exited with status $ac_status" >&5
22126 echo "$as_me: failed program was:" >&5
22127 sed 's/^/| /' conftest.$ac_ext >&5
22128
22129 ( exit $ac_status )
22130 echo "$as_me:$LINENO: result: no" >&5
22131 echo "${ECHO_T}no" >&6
22132   { { echo "$as_me:$LINENO: error:
22133 *** Thread test program failed.  Your platform is not thread-safe.
22134 *** Check the file 'config.log'for the exact reason.
22135 ***
22136 *** You can use the configure option --enable-thread-safety-force
22137 *** to force threads to be enabled.  However, you must then run
22138 *** the program in src/test/thread and add locking function calls
22139 *** to your applications to guarantee thread safety.
22140 " >&5
22141 echo "$as_me: error:
22142 *** Thread test program failed.  Your platform is not thread-safe.
22143 *** Check the file 'config.log'for the exact reason.
22144 ***
22145 *** You can use the configure option --enable-thread-safety-force
22146 *** to force threads to be enabled.  However, you must then run
22147 *** the program in src/test/thread and add locking function calls
22148 *** to your applications to guarantee thread safety.
22149 " >&2;}
22150    { (exit 1); exit 1; }; }
22151 fi
22152 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22153 fi
22154 CFLAGS="$_CFLAGS"
22155 LIBS="$_LIBS"
22156 else
22157 { echo "$as_me:$LINENO: WARNING: *** Skipping thread test on Win32" >&5
22158 echo "$as_me: WARNING: *** Skipping thread test on Win32" >&2;}
22159 fi
22160 fi
22161
22162 # prepare build tree if outside source tree
22163 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
22164 # Note 2: /bin/pwd might be better than shell's built-in at getting
22165 #         a symlink-free name.
22166 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
22167   vpath_build=no
22168 else
22169   vpath_build=yes
22170   if test "$no_create" != yes; then
22171     echo $ECHO_N "preparing build tree... $ECHO_C" >&6
22172     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
22173     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
22174       || { { echo "$as_me:$LINENO: error: failed" >&5
22175 echo "$as_me: error: failed" >&2;}
22176    { (exit 1); exit 1; }; }
22177     echo "$as_me:$LINENO: result: done" >&5
22178 echo "${ECHO_T}done" >&6
22179   fi
22180 fi
22181
22182
22183
22184                     ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
22185
22186
22187                                                             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}"
22188
22189
22190 if test "$PORTNAME" = "win32"; then
22191           ac_config_commands="$ac_config_commands check_win32_symlinks"
22192
22193 fi
22194
22195           ac_config_headers="$ac_config_headers src/include/pg_config.h"
22196
22197
22198 cat >confcache <<\_ACEOF
22199 # This file is a shell script that caches the results of configure
22200 # tests run on this system so they can be shared between configure
22201 # scripts and configure runs, see configure's option --config-cache.
22202 # It is not useful on other systems.  If it contains results you don't
22203 # want to keep, you may remove or edit it.
22204 #
22205 # config.status only pays attention to the cache file if you give it
22206 # the --recheck option to rerun configure.
22207 #
22208 # `ac_cv_env_foo' variables (set or unset) will be overridden when
22209 # loading this file, other *unset* `ac_cv_foo' will be assigned the
22210 # following values.
22211
22212 _ACEOF
22213
22214 # The following way of writing the cache mishandles newlines in values,
22215 # but we know of no workaround that is simple, portable, and efficient.
22216 # So, don't put newlines in cache variables' values.
22217 # Ultrix sh set writes to stderr and can't be redirected directly,
22218 # and sets the high bit in the cache file unless we assign to the vars.
22219 {
22220   (set) 2>&1 |
22221     case `(ac_space=' '; set | grep ac_space) 2>&1` in
22222     *ac_space=\ *)
22223       # `set' does not quote correctly, so add quotes (double-quote
22224       # substitution turns \\\\ into \\, and sed turns \\ into \).
22225       sed -n \
22226         "s/'/'\\\\''/g;
22227           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22228       ;;
22229     *)
22230       # `set' quotes correctly as required by POSIX, so do not add quotes.
22231       sed -n \
22232         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
22233       ;;
22234     esac;
22235 } |
22236   sed '
22237      t clear
22238      : clear
22239      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22240      t end
22241      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22242      : end' >>confcache
22243 if diff $cache_file confcache >/dev/null 2>&1; then :; else
22244   if test -w $cache_file; then
22245     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
22246     cat confcache >$cache_file
22247   else
22248     echo "not updating unwritable cache $cache_file"
22249   fi
22250 fi
22251 rm -f confcache
22252
22253 test "x$prefix" = xNONE && prefix=$ac_default_prefix
22254 # Let make expand exec_prefix.
22255 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22256
22257 # VPATH may cause trouble with some makes, so we remove $(srcdir),
22258 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
22259 # trailing colons and then remove the whole line if VPATH becomes empty
22260 # (actually we leave an empty line to preserve line numbers).
22261 if test "x$srcdir" = x.; then
22262   ac_vpsub='/^[  ]*VPATH[        ]*=/{
22263 s/:*\$(srcdir):*/:/;
22264 s/:*\${srcdir}:*/:/;
22265 s/:*@srcdir@:*/:/;
22266 s/^\([^=]*=[     ]*\):*/\1/;
22267 s/:*$//;
22268 s/^[^=]*=[       ]*$//;
22269 }'
22270 fi
22271
22272 DEFS=-DHAVE_CONFIG_H
22273
22274 ac_libobjs=
22275 ac_ltlibobjs=
22276 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
22277   # 1. Remove the extension, and $U if already installed.
22278   ac_i=`echo "$ac_i" |
22279          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
22280   # 2. Add them.
22281   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
22282   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
22283 done
22284 LIBOBJS=$ac_libobjs
22285
22286 LTLIBOBJS=$ac_ltlibobjs
22287
22288
22289
22290 : ${CONFIG_STATUS=./config.status}
22291 ac_clean_files_save=$ac_clean_files
22292 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
22293 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
22294 echo "$as_me: creating $CONFIG_STATUS" >&6;}
22295 cat >$CONFIG_STATUS <<_ACEOF
22296 #! $SHELL
22297 # Generated by $as_me.
22298 # Run this file to recreate the current configuration.
22299 # Compiler output produced by configure, useful for debugging
22300 # configure, is in config.log if it exists.
22301
22302 debug=false
22303 ac_cs_recheck=false
22304 ac_cs_silent=false
22305 SHELL=\${CONFIG_SHELL-$SHELL}
22306 _ACEOF
22307
22308 cat >>$CONFIG_STATUS <<\_ACEOF
22309 ## --------------------- ##
22310 ## M4sh Initialization.  ##
22311 ## --------------------- ##
22312
22313 # Be Bourne compatible
22314 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
22315   emulate sh
22316   NULLCMD=:
22317   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
22318   # is contrary to our usage.  Disable this feature.
22319   alias -g '${1+"$@"}'='"$@"'
22320 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
22321   set -o posix
22322 fi
22323 DUALCASE=1; export DUALCASE # for MKS sh
22324
22325 # Support unset when possible.
22326 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
22327   as_unset=unset
22328 else
22329   as_unset=false
22330 fi
22331
22332
22333 # Work around bugs in pre-3.0 UWIN ksh.
22334 $as_unset ENV MAIL MAILPATH
22335 PS1='$ '
22336 PS2='> '
22337 PS4='+ '
22338
22339 # NLS nuisances.
22340 for as_var in \
22341   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
22342   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
22343   LC_TELEPHONE LC_TIME
22344 do
22345   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
22346     eval $as_var=C; export $as_var
22347   else
22348     $as_unset $as_var
22349   fi
22350 done
22351
22352 # Required to use basename.
22353 if expr a : '\(a\)' >/dev/null 2>&1; then
22354   as_expr=expr
22355 else
22356   as_expr=false
22357 fi
22358
22359 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
22360   as_basename=basename
22361 else
22362   as_basename=false
22363 fi
22364
22365
22366 # Name of the executable.
22367 as_me=`$as_basename "$0" ||
22368 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
22369          X"$0" : 'X\(//\)$' \| \
22370          X"$0" : 'X\(/\)$' \| \
22371          .     : '\(.\)' 2>/dev/null ||
22372 echo X/"$0" |
22373     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
22374           /^X\/\(\/\/\)$/{ s//\1/; q; }
22375           /^X\/\(\/\).*/{ s//\1/; q; }
22376           s/.*/./; q'`
22377
22378
22379 # PATH needs CR, and LINENO needs CR and PATH.
22380 # Avoid depending upon Character Ranges.
22381 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
22382 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
22383 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
22384 as_cr_digits='0123456789'
22385 as_cr_alnum=$as_cr_Letters$as_cr_digits
22386
22387 # The user is always right.
22388 if test "${PATH_SEPARATOR+set}" != set; then
22389   echo "#! /bin/sh" >conf$$.sh
22390   echo  "exit 0"   >>conf$$.sh
22391   chmod +x conf$$.sh
22392   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
22393     PATH_SEPARATOR=';'
22394   else
22395     PATH_SEPARATOR=:
22396   fi
22397   rm -f conf$$.sh
22398 fi
22399
22400
22401   as_lineno_1=$LINENO
22402   as_lineno_2=$LINENO
22403   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
22404   test "x$as_lineno_1" != "x$as_lineno_2" &&
22405   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
22406   # Find who we are.  Look in the path if we contain no path at all
22407   # relative or not.
22408   case $0 in
22409     *[\\/]* ) as_myself=$0 ;;
22410     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22411 for as_dir in $PATH
22412 do
22413   IFS=$as_save_IFS
22414   test -z "$as_dir" && as_dir=.
22415   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
22416 done
22417
22418        ;;
22419   esac
22420   # We did not find ourselves, most probably we were run as `sh COMMAND'
22421   # in which case we are not to be found in the path.
22422   if test "x$as_myself" = x; then
22423     as_myself=$0
22424   fi
22425   if test ! -f "$as_myself"; then
22426     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
22427 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
22428    { (exit 1); exit 1; }; }
22429   fi
22430   case $CONFIG_SHELL in
22431   '')
22432     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22433 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
22434 do
22435   IFS=$as_save_IFS
22436   test -z "$as_dir" && as_dir=.
22437   for as_base in sh bash ksh sh5; do
22438          case $as_dir in
22439          /*)
22440            if ("$as_dir/$as_base" -c '
22441   as_lineno_1=$LINENO
22442   as_lineno_2=$LINENO
22443   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
22444   test "x$as_lineno_1" != "x$as_lineno_2" &&
22445   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
22446              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
22447              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
22448              CONFIG_SHELL=$as_dir/$as_base
22449              export CONFIG_SHELL
22450              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
22451            fi;;
22452          esac
22453        done
22454 done
22455 ;;
22456   esac
22457
22458   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
22459   # uniformly replaced by the line number.  The first 'sed' inserts a
22460   # line-number line before each line; the second 'sed' does the real
22461   # work.  The second script uses 'N' to pair each line-number line
22462   # with the numbered line, and appends trailing '-' during
22463   # substitution so that $LINENO is not a special case at line end.
22464   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
22465   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
22466   sed '=' <$as_myself |
22467     sed '
22468       N
22469       s,$,-,
22470       : loop
22471       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
22472       t loop
22473       s,-$,,
22474       s,^['$as_cr_digits']*\n,,
22475     ' >$as_me.lineno &&
22476   chmod +x $as_me.lineno ||
22477     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
22478 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
22479    { (exit 1); exit 1; }; }
22480
22481   # Don't try to exec as it changes $[0], causing all sort of problems
22482   # (the dirname of $[0] is not the place where we might find the
22483   # original and so on.  Autoconf is especially sensible to this).
22484   . ./$as_me.lineno
22485   # Exit status is that of the last command.
22486   exit
22487 }
22488
22489
22490 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
22491   *c*,-n*) ECHO_N= ECHO_C='
22492 ' ECHO_T='      ' ;;
22493   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
22494   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
22495 esac
22496
22497 if expr a : '\(a\)' >/dev/null 2>&1; then
22498   as_expr=expr
22499 else
22500   as_expr=false
22501 fi
22502
22503 rm -f conf$$ conf$$.exe conf$$.file
22504 echo >conf$$.file
22505 if ln -s conf$$.file conf$$ 2>/dev/null; then
22506   # We could just check for DJGPP; but this test a) works b) is more generic
22507   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
22508   if test -f conf$$.exe; then
22509     # Don't use ln at all; we don't have any links
22510     as_ln_s='cp -p'
22511   else
22512     as_ln_s='ln -s'
22513   fi
22514 elif ln conf$$.file conf$$ 2>/dev/null; then
22515   as_ln_s=ln
22516 else
22517   as_ln_s='cp -p'
22518 fi
22519 rm -f conf$$ conf$$.exe conf$$.file
22520
22521 if mkdir -p . 2>/dev/null; then
22522   as_mkdir_p=:
22523 else
22524   test -d ./-p && rmdir ./-p
22525   as_mkdir_p=false
22526 fi
22527
22528 as_executable_p="test -f"
22529
22530 # Sed expression to map a string onto a valid CPP name.
22531 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
22532
22533 # Sed expression to map a string onto a valid variable name.
22534 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
22535
22536
22537 # IFS
22538 # We need space, tab and new line, in precisely that order.
22539 as_nl='
22540 '
22541 IFS="   $as_nl"
22542
22543 # CDPATH.
22544 $as_unset CDPATH
22545
22546 exec 6>&1
22547
22548 # Open the log real soon, to keep \$[0] and so on meaningful, and to
22549 # report actual input values of CONFIG_FILES etc. instead of their
22550 # values after options handling.  Logging --version etc. is OK.
22551 exec 5>>config.log
22552 {
22553   echo
22554   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
22555 ## Running $as_me. ##
22556 _ASBOX
22557 } >&5
22558 cat >&5 <<_CSEOF
22559
22560 This file was extended by PostgreSQL $as_me 8.2devel, which was
22561 generated by GNU Autoconf 2.59.  Invocation command line was
22562
22563   CONFIG_FILES    = $CONFIG_FILES
22564   CONFIG_HEADERS  = $CONFIG_HEADERS
22565   CONFIG_LINKS    = $CONFIG_LINKS
22566   CONFIG_COMMANDS = $CONFIG_COMMANDS
22567   $ $0 $@
22568
22569 _CSEOF
22570 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
22571 echo >&5
22572 _ACEOF
22573
22574 # Files that config.status was made for.
22575 if test -n "$ac_config_files"; then
22576   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
22577 fi
22578
22579 if test -n "$ac_config_headers"; then
22580   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
22581 fi
22582
22583 if test -n "$ac_config_links"; then
22584   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
22585 fi
22586
22587 if test -n "$ac_config_commands"; then
22588   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
22589 fi
22590
22591 cat >>$CONFIG_STATUS <<\_ACEOF
22592
22593 ac_cs_usage="\
22594 \`$as_me' instantiates files from templates according to the
22595 current configuration.
22596
22597 Usage: $0 [OPTIONS] [FILE]...
22598
22599   -h, --help       print this help, then exit
22600   -V, --version    print version number, then exit
22601   -q, --quiet      do not print progress messages
22602   -d, --debug      don't remove temporary files
22603       --recheck    update $as_me by reconfiguring in the same conditions
22604   --file=FILE[:TEMPLATE]
22605                    instantiate the configuration file FILE
22606   --header=FILE[:TEMPLATE]
22607                    instantiate the configuration header FILE
22608
22609 Configuration files:
22610 $config_files
22611
22612 Configuration headers:
22613 $config_headers
22614
22615 Configuration links:
22616 $config_links
22617
22618 Configuration commands:
22619 $config_commands
22620
22621 Report bugs to <bug-autoconf@gnu.org>."
22622 _ACEOF
22623
22624 cat >>$CONFIG_STATUS <<_ACEOF
22625 ac_cs_version="\\
22626 PostgreSQL config.status 8.2devel
22627 configured by $0, generated by GNU Autoconf 2.59,
22628   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
22629
22630 Copyright (C) 2003 Free Software Foundation, Inc.
22631 This config.status script is free software; the Free Software Foundation
22632 gives unlimited permission to copy, distribute and modify it."
22633 srcdir=$srcdir
22634 _ACEOF
22635
22636 cat >>$CONFIG_STATUS <<\_ACEOF
22637 # If no file are specified by the user, then we need to provide default
22638 # value.  By we need to know if files were specified by the user.
22639 ac_need_defaults=:
22640 while test $# != 0
22641 do
22642   case $1 in
22643   --*=*)
22644     ac_option=`expr "x$1" : 'x\([^=]*\)='`
22645     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
22646     ac_shift=:
22647     ;;
22648   -*)
22649     ac_option=$1
22650     ac_optarg=$2
22651     ac_shift=shift
22652     ;;
22653   *) # This is not an option, so the user has probably given explicit
22654      # arguments.
22655      ac_option=$1
22656      ac_need_defaults=false;;
22657   esac
22658
22659   case $ac_option in
22660   # Handling of the options.
22661 _ACEOF
22662 cat >>$CONFIG_STATUS <<\_ACEOF
22663   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
22664     ac_cs_recheck=: ;;
22665   --version | --vers* | -V )
22666     echo "$ac_cs_version"; exit 0 ;;
22667   --he | --h)
22668     # Conflict between --help and --header
22669     { { echo "$as_me:$LINENO: error: ambiguous option: $1
22670 Try \`$0 --help' for more information." >&5
22671 echo "$as_me: error: ambiguous option: $1
22672 Try \`$0 --help' for more information." >&2;}
22673    { (exit 1); exit 1; }; };;
22674   --help | --hel | -h )
22675     echo "$ac_cs_usage"; exit 0 ;;
22676   --debug | --d* | -d )
22677     debug=: ;;
22678   --file | --fil | --fi | --f )
22679     $ac_shift
22680     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
22681     ac_need_defaults=false;;
22682   --header | --heade | --head | --hea )
22683     $ac_shift
22684     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
22685     ac_need_defaults=false;;
22686   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
22687   | -silent | --silent | --silen | --sile | --sil | --si | --s)
22688     ac_cs_silent=: ;;
22689
22690   # This is an error.
22691   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
22692 Try \`$0 --help' for more information." >&5
22693 echo "$as_me: error: unrecognized option: $1
22694 Try \`$0 --help' for more information." >&2;}
22695    { (exit 1); exit 1; }; } ;;
22696
22697   *) ac_config_targets="$ac_config_targets $1" ;;
22698
22699   esac
22700   shift
22701 done
22702
22703 ac_configure_extra_args=
22704
22705 if $ac_cs_silent; then
22706   exec 6>/dev/null
22707   ac_configure_extra_args="$ac_configure_extra_args --silent"
22708 fi
22709
22710 _ACEOF
22711 cat >>$CONFIG_STATUS <<_ACEOF
22712 if \$ac_cs_recheck; then
22713   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
22714   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
22715 fi
22716
22717 _ACEOF
22718
22719
22720
22721
22722
22723 cat >>$CONFIG_STATUS <<\_ACEOF
22724 for ac_config_target in $ac_config_targets
22725 do
22726   case "$ac_config_target" in
22727   # Handling of arguments.
22728   "GNUmakefile" ) CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
22729   "src/Makefile.global" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
22730   "src/backend/port/tas.s" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
22731   "src/backend/port/dynloader.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
22732   "src/backend/port/pg_sema.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
22733   "src/backend/port/pg_shmem.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
22734   "src/include/dynloader.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
22735   "src/include/pg_config_os.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
22736   "src/Makefile.port" ) CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
22737   "check_win32_symlinks" ) CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
22738   "src/include/pg_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
22739   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
22740 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
22741    { (exit 1); exit 1; }; };;
22742   esac
22743 done
22744
22745 # If the user did not use the arguments to specify the items to instantiate,
22746 # then the envvar interface is used.  Set only those that are not.
22747 # We use the long form for the default assignment because of an extremely
22748 # bizarre bug on SunOS 4.1.3.
22749 if $ac_need_defaults; then
22750   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
22751   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
22752   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
22753   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
22754 fi
22755
22756 # Have a temporary directory for convenience.  Make it in the build tree
22757 # simply because there is no reason to put it here, and in addition,
22758 # creating and moving files from /tmp can sometimes cause problems.
22759 # Create a temporary directory, and hook for its removal unless debugging.
22760 $debug ||
22761 {
22762   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
22763   trap '{ (exit 1); exit 1; }' 1 2 13 15
22764 }
22765
22766 # Create a (secure) tmp directory for tmp files.
22767
22768 {
22769   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
22770   test -n "$tmp" && test -d "$tmp"
22771 }  ||
22772 {
22773   tmp=./confstat$$-$RANDOM
22774   (umask 077 && mkdir $tmp)
22775 } ||
22776 {
22777    echo "$me: cannot create a temporary directory in ." >&2
22778    { (exit 1); exit 1; }
22779 }
22780
22781 _ACEOF
22782
22783 cat >>$CONFIG_STATUS <<_ACEOF
22784
22785 #
22786 # CONFIG_FILES section.
22787 #
22788
22789 # No need to generate the scripts if there are no CONFIG_FILES.
22790 # This happens for instance when ./config.status config.h
22791 if test -n "\$CONFIG_FILES"; then
22792   # Protect against being on the right side of a sed subst in config.status.
22793   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
22794    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
22795 s,@SHELL@,$SHELL,;t t
22796 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
22797 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
22798 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
22799 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
22800 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
22801 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
22802 s,@exec_prefix@,$exec_prefix,;t t
22803 s,@prefix@,$prefix,;t t
22804 s,@program_transform_name@,$program_transform_name,;t t
22805 s,@bindir@,$bindir,;t t
22806 s,@sbindir@,$sbindir,;t t
22807 s,@libexecdir@,$libexecdir,;t t
22808 s,@datadir@,$datadir,;t t
22809 s,@sysconfdir@,$sysconfdir,;t t
22810 s,@sharedstatedir@,$sharedstatedir,;t t
22811 s,@localstatedir@,$localstatedir,;t t
22812 s,@libdir@,$libdir,;t t
22813 s,@includedir@,$includedir,;t t
22814 s,@oldincludedir@,$oldincludedir,;t t
22815 s,@infodir@,$infodir,;t t
22816 s,@mandir@,$mandir,;t t
22817 s,@build_alias@,$build_alias,;t t
22818 s,@host_alias@,$host_alias,;t t
22819 s,@target_alias@,$target_alias,;t t
22820 s,@DEFS@,$DEFS,;t t
22821 s,@ECHO_C@,$ECHO_C,;t t
22822 s,@ECHO_N@,$ECHO_N,;t t
22823 s,@ECHO_T@,$ECHO_T,;t t
22824 s,@LIBS@,$LIBS,;t t
22825 s,@configure_args@,$configure_args,;t t
22826 s,@build@,$build,;t t
22827 s,@build_cpu@,$build_cpu,;t t
22828 s,@build_vendor@,$build_vendor,;t t
22829 s,@build_os@,$build_os,;t t
22830 s,@host@,$host,;t t
22831 s,@host_cpu@,$host_cpu,;t t
22832 s,@host_vendor@,$host_vendor,;t t
22833 s,@host_os@,$host_os,;t t
22834 s,@PORTNAME@,$PORTNAME,;t t
22835 s,@docdir@,$docdir,;t t
22836 s,@enable_nls@,$enable_nls,;t t
22837 s,@WANTED_LANGUAGES@,$WANTED_LANGUAGES,;t t
22838 s,@default_port@,$default_port,;t t
22839 s,@enable_shared@,$enable_shared,;t t
22840 s,@enable_rpath@,$enable_rpath,;t t
22841 s,@enable_debug@,$enable_debug,;t t
22842 s,@CC@,$CC,;t t
22843 s,@CFLAGS@,$CFLAGS,;t t
22844 s,@LDFLAGS@,$LDFLAGS,;t t
22845 s,@CPPFLAGS@,$CPPFLAGS,;t t
22846 s,@ac_ct_CC@,$ac_ct_CC,;t t
22847 s,@EXEEXT@,$EXEEXT,;t t
22848 s,@OBJEXT@,$OBJEXT,;t t
22849 s,@CPP@,$CPP,;t t
22850 s,@GCC@,$GCC,;t t
22851 s,@TAS@,$TAS,;t t
22852 s,@autodepend@,$autodepend,;t t
22853 s,@INCLUDES@,$INCLUDES,;t t
22854 s,@enable_thread_safety@,$enable_thread_safety,;t t
22855 s,@with_tcl@,$with_tcl,;t t
22856 s,@with_perl@,$with_perl,;t t
22857 s,@with_python@,$with_python,;t t
22858 s,@with_krb5@,$with_krb5,;t t
22859 s,@krb_srvtab@,$krb_srvtab,;t t
22860 s,@with_pam@,$with_pam,;t t
22861 s,@with_bonjour@,$with_bonjour,;t t
22862 s,@with_openssl@,$with_openssl,;t t
22863 s,@with_zlib@,$with_zlib,;t t
22864 s,@EGREP@,$EGREP,;t t
22865 s,@ELF_SYS@,$ELF_SYS,;t t
22866 s,@LDFLAGS_SL@,$LDFLAGS_SL,;t t
22867 s,@AWK@,$AWK,;t t
22868 s,@FLEX@,$FLEX,;t t
22869 s,@FLEXFLAGS@,$FLEXFLAGS,;t t
22870 s,@LN_S@,$LN_S,;t t
22871 s,@LD@,$LD,;t t
22872 s,@with_gnu_ld@,$with_gnu_ld,;t t
22873 s,@ld_R_works@,$ld_R_works,;t t
22874 s,@RANLIB@,$RANLIB,;t t
22875 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
22876 s,@LORDER@,$LORDER,;t t
22877 s,@TAR@,$TAR,;t t
22878 s,@STRIP@,$STRIP,;t t
22879 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
22880 s,@STRIP_STATIC_LIB@,$STRIP_STATIC_LIB,;t t
22881 s,@STRIP_SHARED_LIB@,$STRIP_SHARED_LIB,;t t
22882 s,@YACC@,$YACC,;t t
22883 s,@YFLAGS@,$YFLAGS,;t t
22884 s,@PERL@,$PERL,;t t
22885 s,@perl_archlibexp@,$perl_archlibexp,;t t
22886 s,@perl_privlibexp@,$perl_privlibexp,;t t
22887 s,@perl_useshrplib@,$perl_useshrplib,;t t
22888 s,@perl_embed_ldflags@,$perl_embed_ldflags,;t t
22889 s,@PYTHON@,$PYTHON,;t t
22890 s,@python_version@,$python_version,;t t
22891 s,@python_configdir@,$python_configdir,;t t
22892 s,@python_includespec@,$python_includespec,;t t
22893 s,@python_libdir@,$python_libdir,;t t
22894 s,@python_libspec@,$python_libspec,;t t
22895 s,@python_additional_libs@,$python_additional_libs,;t t
22896 s,@HAVE_IPV6@,$HAVE_IPV6,;t t
22897 s,@LIBOBJS@,$LIBOBJS,;t t
22898 s,@acx_pthread_config@,$acx_pthread_config,;t t
22899 s,@PTHREAD_CC@,$PTHREAD_CC,;t t
22900 s,@PTHREAD_LIBS@,$PTHREAD_LIBS,;t t
22901 s,@PTHREAD_CFLAGS@,$PTHREAD_CFLAGS,;t t
22902 s,@HAVE_POSIX_SIGNALS@,$HAVE_POSIX_SIGNALS,;t t
22903 s,@MSGFMT@,$MSGFMT,;t t
22904 s,@MSGMERGE@,$MSGMERGE,;t t
22905 s,@XGETTEXT@,$XGETTEXT,;t t
22906 s,@localedir@,$localedir,;t t
22907 s,@TCLSH@,$TCLSH,;t t
22908 s,@TCL_CONFIG_SH@,$TCL_CONFIG_SH,;t t
22909 s,@TCL_INCLUDE_SPEC@,$TCL_INCLUDE_SPEC,;t t
22910 s,@TCL_LIB_FILE@,$TCL_LIB_FILE,;t t
22911 s,@TCL_LIBS@,$TCL_LIBS,;t t
22912 s,@TCL_LIB_SPEC@,$TCL_LIB_SPEC,;t t
22913 s,@TCL_SHARED_BUILD@,$TCL_SHARED_BUILD,;t t
22914 s,@TCL_SHLIB_LD_LIBS@,$TCL_SHLIB_LD_LIBS,;t t
22915 s,@NSGMLS@,$NSGMLS,;t t
22916 s,@JADE@,$JADE,;t t
22917 s,@have_docbook@,$have_docbook,;t t
22918 s,@DOCBOOKSTYLE@,$DOCBOOKSTYLE,;t t
22919 s,@COLLATEINDEX@,$COLLATEINDEX,;t t
22920 s,@SGMLSPL@,$SGMLSPL,;t t
22921 s,@vpath_build@,$vpath_build,;t t
22922 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
22923 CEOF
22924
22925 _ACEOF
22926
22927   cat >>$CONFIG_STATUS <<\_ACEOF
22928   # Split the substitutions into bite-sized pieces for seds with
22929   # small command number limits, like on Digital OSF/1 and HP-UX.
22930   ac_max_sed_lines=48
22931   ac_sed_frag=1 # Number of current file.
22932   ac_beg=1 # First line for current file.
22933   ac_end=$ac_max_sed_lines # Line after last line for current file.
22934   ac_more_lines=:
22935   ac_sed_cmds=
22936   while $ac_more_lines; do
22937     if test $ac_beg -gt 1; then
22938       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22939     else
22940       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22941     fi
22942     if test ! -s $tmp/subs.frag; then
22943       ac_more_lines=false
22944     else
22945       # The purpose of the label and of the branching condition is to
22946       # speed up the sed processing (if there are no `@' at all, there
22947       # is no need to browse any of the substitutions).
22948       # These are the two extra sed commands mentioned above.
22949       (echo ':t
22950   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
22951       if test -z "$ac_sed_cmds"; then
22952         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
22953       else
22954         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
22955       fi
22956       ac_sed_frag=`expr $ac_sed_frag + 1`
22957       ac_beg=$ac_end
22958       ac_end=`expr $ac_end + $ac_max_sed_lines`
22959     fi
22960   done
22961   if test -z "$ac_sed_cmds"; then
22962     ac_sed_cmds=cat
22963   fi
22964 fi # test -n "$CONFIG_FILES"
22965
22966 _ACEOF
22967 cat >>$CONFIG_STATUS <<\_ACEOF
22968 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
22969   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
22970   case $ac_file in
22971   - | *:- | *:-:* ) # input from stdin
22972         cat >$tmp/stdin
22973         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22974         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
22975   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22976         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
22977   * )   ac_file_in=$ac_file.in ;;
22978   esac
22979
22980   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
22981   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22982 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22983          X"$ac_file" : 'X\(//\)[^/]' \| \
22984          X"$ac_file" : 'X\(//\)$' \| \
22985          X"$ac_file" : 'X\(/\)' \| \
22986          .     : '\(.\)' 2>/dev/null ||
22987 echo X"$ac_file" |
22988     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22989           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22990           /^X\(\/\/\)$/{ s//\1/; q; }
22991           /^X\(\/\).*/{ s//\1/; q; }
22992           s/.*/./; q'`
22993   { if $as_mkdir_p; then
22994     mkdir -p "$ac_dir"
22995   else
22996     as_dir="$ac_dir"
22997     as_dirs=
22998     while test ! -d "$as_dir"; do
22999       as_dirs="$as_dir $as_dirs"
23000       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23001 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23002          X"$as_dir" : 'X\(//\)[^/]' \| \
23003          X"$as_dir" : 'X\(//\)$' \| \
23004          X"$as_dir" : 'X\(/\)' \| \
23005          .     : '\(.\)' 2>/dev/null ||
23006 echo X"$as_dir" |
23007     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23008           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23009           /^X\(\/\/\)$/{ s//\1/; q; }
23010           /^X\(\/\).*/{ s//\1/; q; }
23011           s/.*/./; q'`
23012     done
23013     test ! -n "$as_dirs" || mkdir $as_dirs
23014   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23015 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23016    { (exit 1); exit 1; }; }; }
23017
23018   ac_builddir=.
23019
23020 if test "$ac_dir" != .; then
23021   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
23022   # A "../" for each directory in $ac_dir_suffix.
23023   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23024 else
23025   ac_dir_suffix= ac_top_builddir=
23026 fi
23027
23028 case $srcdir in
23029   .)  # No --srcdir option.  We are building in place.
23030     ac_srcdir=.
23031     if test -z "$ac_top_builddir"; then
23032        ac_top_srcdir=.
23033     else
23034        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23035     fi ;;
23036   [\\/]* | ?:[\\/]* )  # Absolute path.
23037     ac_srcdir=$srcdir$ac_dir_suffix;
23038     ac_top_srcdir=$srcdir ;;
23039   *) # Relative path.
23040     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23041     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23042 esac
23043
23044 # Do not use `cd foo && pwd` to compute absolute paths, because
23045 # the directories may not exist.
23046 case `pwd` in
23047 .) ac_abs_builddir="$ac_dir";;
23048 *)
23049   case "$ac_dir" in
23050   .) ac_abs_builddir=`pwd`;;
23051   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
23052   *) ac_abs_builddir=`pwd`/"$ac_dir";;
23053   esac;;
23054 esac
23055 case $ac_abs_builddir in
23056 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23057 *)
23058   case ${ac_top_builddir}. in
23059   .) ac_abs_top_builddir=$ac_abs_builddir;;
23060   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23061   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23062   esac;;
23063 esac
23064 case $ac_abs_builddir in
23065 .) ac_abs_srcdir=$ac_srcdir;;
23066 *)
23067   case $ac_srcdir in
23068   .) ac_abs_srcdir=$ac_abs_builddir;;
23069   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23070   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23071   esac;;
23072 esac
23073 case $ac_abs_builddir in
23074 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23075 *)
23076   case $ac_top_srcdir in
23077   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23078   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23079   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23080   esac;;
23081 esac
23082
23083
23084
23085   if test x"$ac_file" != x-; then
23086     { echo "$as_me:$LINENO: creating $ac_file" >&5
23087 echo "$as_me: creating $ac_file" >&6;}
23088     rm -f "$ac_file"
23089   fi
23090   # Let's still pretend it is `configure' which instantiates (i.e., don't
23091   # use $as_me), people would be surprised to read:
23092   #    /* config.h.  Generated by config.status.  */
23093   if test x"$ac_file" = x-; then
23094     configure_input=
23095   else
23096     configure_input="$ac_file.  "
23097   fi
23098   configure_input=$configure_input"Generated from `echo $ac_file_in |
23099                                      sed 's,.*/,,'` by configure."
23100
23101   # First look for the input files in the build tree, otherwise in the
23102   # src tree.
23103   ac_file_inputs=`IFS=:
23104     for f in $ac_file_in; do
23105       case $f in
23106       -) echo $tmp/stdin ;;
23107       [\\/$]*)
23108          # Absolute (can't be DOS-style, as IFS=:)
23109          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23110 echo "$as_me: error: cannot find input file: $f" >&2;}
23111    { (exit 1); exit 1; }; }
23112          echo "$f";;
23113       *) # Relative
23114          if test -f "$f"; then
23115            # Build tree
23116            echo "$f"
23117          elif test -f "$srcdir/$f"; then
23118            # Source tree
23119            echo "$srcdir/$f"
23120          else
23121            # /dev/null tree
23122            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23123 echo "$as_me: error: cannot find input file: $f" >&2;}
23124    { (exit 1); exit 1; }; }
23125          fi;;
23126       esac
23127     done` || { (exit 1); exit 1; }
23128 _ACEOF
23129 cat >>$CONFIG_STATUS <<_ACEOF
23130   sed "$ac_vpsub
23131 $extrasub
23132 _ACEOF
23133 cat >>$CONFIG_STATUS <<\_ACEOF
23134 :t
23135 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23136 s,@configure_input@,$configure_input,;t t
23137 s,@srcdir@,$ac_srcdir,;t t
23138 s,@abs_srcdir@,$ac_abs_srcdir,;t t
23139 s,@top_srcdir@,$ac_top_srcdir,;t t
23140 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
23141 s,@builddir@,$ac_builddir,;t t
23142 s,@abs_builddir@,$ac_abs_builddir,;t t
23143 s,@top_builddir@,$ac_top_builddir,;t t
23144 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
23145 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
23146   rm -f $tmp/stdin
23147   if test x"$ac_file" != x-; then
23148     mv $tmp/out $ac_file
23149   else
23150     cat $tmp/out
23151     rm -f $tmp/out
23152   fi
23153
23154 done
23155 _ACEOF
23156 cat >>$CONFIG_STATUS <<\_ACEOF
23157
23158 #
23159 # CONFIG_HEADER section.
23160 #
23161
23162 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
23163 # NAME is the cpp macro being defined and VALUE is the value it is being given.
23164 #
23165 # ac_d sets the value in "#define NAME VALUE" lines.
23166 ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
23167 ac_dB='[         ].*$,\1#\2'
23168 ac_dC=' '
23169 ac_dD=',;t'
23170 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
23171 ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
23172 ac_uB='$,\1#\2define\3'
23173 ac_uC=' '
23174 ac_uD=',;t'
23175
23176 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
23177   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23178   case $ac_file in
23179   - | *:- | *:-:* ) # input from stdin
23180         cat >$tmp/stdin
23181         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23182         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23183   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23184         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23185   * )   ac_file_in=$ac_file.in ;;
23186   esac
23187
23188   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
23189 echo "$as_me: creating $ac_file" >&6;}
23190
23191   # First look for the input files in the build tree, otherwise in the
23192   # src tree.
23193   ac_file_inputs=`IFS=:
23194     for f in $ac_file_in; do
23195       case $f in
23196       -) echo $tmp/stdin ;;
23197       [\\/$]*)
23198          # Absolute (can't be DOS-style, as IFS=:)
23199          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23200 echo "$as_me: error: cannot find input file: $f" >&2;}
23201    { (exit 1); exit 1; }; }
23202          # Do quote $f, to prevent DOS paths from being IFS'd.
23203          echo "$f";;
23204       *) # Relative
23205          if test -f "$f"; then
23206            # Build tree
23207            echo "$f"
23208          elif test -f "$srcdir/$f"; then
23209            # Source tree
23210            echo "$srcdir/$f"
23211          else
23212            # /dev/null tree
23213            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23214 echo "$as_me: error: cannot find input file: $f" >&2;}
23215    { (exit 1); exit 1; }; }
23216          fi;;
23217       esac
23218     done` || { (exit 1); exit 1; }
23219   # Remove the trailing spaces.
23220   sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
23221
23222 _ACEOF
23223
23224 # Transform confdefs.h into two sed scripts, `conftest.defines' and
23225 # `conftest.undefs', that substitutes the proper values into
23226 # config.h.in to produce config.h.  The first handles `#define'
23227 # templates, and the second `#undef' templates.
23228 # And first: Protect against being on the right side of a sed subst in
23229 # config.status.  Protect against being in an unquoted here document
23230 # in config.status.
23231 rm -f conftest.defines conftest.undefs
23232 # Using a here document instead of a string reduces the quoting nightmare.
23233 # Putting comments in sed scripts is not portable.
23234 #
23235 # `end' is used to avoid that the second main sed command (meant for
23236 # 0-ary CPP macros) applies to n-ary macro definitions.
23237 # See the Autoconf documentation for `clear'.
23238 cat >confdef2sed.sed <<\_ACEOF
23239 s/[\\&,]/\\&/g
23240 s,[\\$`],\\&,g
23241 t clear
23242 : clear
23243 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
23244 t end
23245 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
23246 : end
23247 _ACEOF
23248 # If some macros were called several times there might be several times
23249 # the same #defines, which is useless.  Nevertheless, we may not want to
23250 # sort them, since we want the *last* AC-DEFINE to be honored.
23251 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
23252 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
23253 rm -f confdef2sed.sed
23254
23255 # This sed command replaces #undef with comments.  This is necessary, for
23256 # example, in the case of _POSIX_SOURCE, which is predefined and required
23257 # on some systems where configure will not decide to define it.
23258 cat >>conftest.undefs <<\_ACEOF
23259 s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
23260 _ACEOF
23261
23262 # Break up conftest.defines because some shells have a limit on the size
23263 # of here documents, and old seds have small limits too (100 cmds).
23264 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
23265 echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
23266 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
23267 echo '  :' >>$CONFIG_STATUS
23268 rm -f conftest.tail
23269 while grep . conftest.defines >/dev/null
23270 do
23271   # Write a limited-size here document to $tmp/defines.sed.
23272   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
23273   # Speed up: don't consider the non `#define' lines.
23274   echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
23275   # Work around the forget-to-reset-the-flag bug.
23276   echo 't clr' >>$CONFIG_STATUS
23277   echo ': clr' >>$CONFIG_STATUS
23278   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
23279   echo 'CEOF
23280   sed -f $tmp/defines.sed $tmp/in >$tmp/out
23281   rm -f $tmp/in
23282   mv $tmp/out $tmp/in
23283 ' >>$CONFIG_STATUS
23284   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
23285   rm -f conftest.defines
23286   mv conftest.tail conftest.defines
23287 done
23288 rm -f conftest.defines
23289 echo '  fi # grep' >>$CONFIG_STATUS
23290 echo >>$CONFIG_STATUS
23291
23292 # Break up conftest.undefs because some shells have a limit on the size
23293 # of here documents, and old seds have small limits too (100 cmds).
23294 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
23295 rm -f conftest.tail
23296 while grep . conftest.undefs >/dev/null
23297 do
23298   # Write a limited-size here document to $tmp/undefs.sed.
23299   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
23300   # Speed up: don't consider the non `#undef'
23301   echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
23302   # Work around the forget-to-reset-the-flag bug.
23303   echo 't clr' >>$CONFIG_STATUS
23304   echo ': clr' >>$CONFIG_STATUS
23305   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
23306   echo 'CEOF
23307   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
23308   rm -f $tmp/in
23309   mv $tmp/out $tmp/in
23310 ' >>$CONFIG_STATUS
23311   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
23312   rm -f conftest.undefs
23313   mv conftest.tail conftest.undefs
23314 done
23315 rm -f conftest.undefs
23316
23317 cat >>$CONFIG_STATUS <<\_ACEOF
23318   # Let's still pretend it is `configure' which instantiates (i.e., don't
23319   # use $as_me), people would be surprised to read:
23320   #    /* config.h.  Generated by config.status.  */
23321   if test x"$ac_file" = x-; then
23322     echo "/* Generated by configure.  */" >$tmp/config.h
23323   else
23324     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
23325   fi
23326   cat $tmp/in >>$tmp/config.h
23327   rm -f $tmp/in
23328   if test x"$ac_file" != x-; then
23329     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
23330       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
23331 echo "$as_me: $ac_file is unchanged" >&6;}
23332     else
23333       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
23334 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23335          X"$ac_file" : 'X\(//\)[^/]' \| \
23336          X"$ac_file" : 'X\(//\)$' \| \
23337          X"$ac_file" : 'X\(/\)' \| \
23338          .     : '\(.\)' 2>/dev/null ||
23339 echo X"$ac_file" |
23340     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23341           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23342           /^X\(\/\/\)$/{ s//\1/; q; }
23343           /^X\(\/\).*/{ s//\1/; q; }
23344           s/.*/./; q'`
23345       { if $as_mkdir_p; then
23346     mkdir -p "$ac_dir"
23347   else
23348     as_dir="$ac_dir"
23349     as_dirs=
23350     while test ! -d "$as_dir"; do
23351       as_dirs="$as_dir $as_dirs"
23352       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23353 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23354          X"$as_dir" : 'X\(//\)[^/]' \| \
23355          X"$as_dir" : 'X\(//\)$' \| \
23356          X"$as_dir" : 'X\(/\)' \| \
23357          .     : '\(.\)' 2>/dev/null ||
23358 echo X"$as_dir" |
23359     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23360           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23361           /^X\(\/\/\)$/{ s//\1/; q; }
23362           /^X\(\/\).*/{ s//\1/; q; }
23363           s/.*/./; q'`
23364     done
23365     test ! -n "$as_dirs" || mkdir $as_dirs
23366   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23367 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23368    { (exit 1); exit 1; }; }; }
23369
23370       rm -f $ac_file
23371       mv $tmp/config.h $ac_file
23372     fi
23373   else
23374     cat $tmp/config.h
23375     rm -f $tmp/config.h
23376   fi
23377   # Run the commands associated with the file.
23378   case $ac_file in
23379     src/include/pg_config.h )
23380 # Update timestamp for pg_config.h (see Makefile.global)
23381 echo >src/include/stamp-h
23382  ;;
23383   esac
23384 done
23385 _ACEOF
23386 cat >>$CONFIG_STATUS <<\_ACEOF
23387
23388 #
23389 # CONFIG_LINKS section.
23390 #
23391
23392 for ac_file in : $CONFIG_LINKS; do test "x$ac_file" = x: && continue
23393   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
23394   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
23395
23396   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_dest" >&5
23397 echo "$as_me: linking $srcdir/$ac_source to $ac_dest" >&6;}
23398
23399   if test ! -r $srcdir/$ac_source; then
23400     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
23401 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
23402    { (exit 1); exit 1; }; }
23403   fi
23404   rm -f $ac_dest
23405
23406   # Make relative symlinks.
23407   ac_dest_dir=`(dirname "$ac_dest") 2>/dev/null ||
23408 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23409          X"$ac_dest" : 'X\(//\)[^/]' \| \
23410          X"$ac_dest" : 'X\(//\)$' \| \
23411          X"$ac_dest" : 'X\(/\)' \| \
23412          .     : '\(.\)' 2>/dev/null ||
23413 echo X"$ac_dest" |
23414     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23415           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23416           /^X\(\/\/\)$/{ s//\1/; q; }
23417           /^X\(\/\).*/{ s//\1/; q; }
23418           s/.*/./; q'`
23419   { if $as_mkdir_p; then
23420     mkdir -p "$ac_dest_dir"
23421   else
23422     as_dir="$ac_dest_dir"
23423     as_dirs=
23424     while test ! -d "$as_dir"; do
23425       as_dirs="$as_dir $as_dirs"
23426       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23427 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23428          X"$as_dir" : 'X\(//\)[^/]' \| \
23429          X"$as_dir" : 'X\(//\)$' \| \
23430          X"$as_dir" : 'X\(/\)' \| \
23431          .     : '\(.\)' 2>/dev/null ||
23432 echo X"$as_dir" |
23433     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23434           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23435           /^X\(\/\/\)$/{ s//\1/; q; }
23436           /^X\(\/\).*/{ s//\1/; q; }
23437           s/.*/./; q'`
23438     done
23439     test ! -n "$as_dirs" || mkdir $as_dirs
23440   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dest_dir\"" >&5
23441 echo "$as_me: error: cannot create directory \"$ac_dest_dir\"" >&2;}
23442    { (exit 1); exit 1; }; }; }
23443
23444   ac_builddir=.
23445
23446 if test "$ac_dest_dir" != .; then
23447   ac_dir_suffix=/`echo "$ac_dest_dir" | sed 's,^\.[\\/],,'`
23448   # A "../" for each directory in $ac_dir_suffix.
23449   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23450 else
23451   ac_dir_suffix= ac_top_builddir=
23452 fi
23453
23454 case $srcdir in
23455   .)  # No --srcdir option.  We are building in place.
23456     ac_srcdir=.
23457     if test -z "$ac_top_builddir"; then
23458        ac_top_srcdir=.
23459     else
23460        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23461     fi ;;
23462   [\\/]* | ?:[\\/]* )  # Absolute path.
23463     ac_srcdir=$srcdir$ac_dir_suffix;
23464     ac_top_srcdir=$srcdir ;;
23465   *) # Relative path.
23466     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23467     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23468 esac
23469
23470 # Do not use `cd foo && pwd` to compute absolute paths, because
23471 # the directories may not exist.
23472 case `pwd` in
23473 .) ac_abs_builddir="$ac_dest_dir";;
23474 *)
23475   case "$ac_dest_dir" in
23476   .) ac_abs_builddir=`pwd`;;
23477   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dest_dir";;
23478   *) ac_abs_builddir=`pwd`/"$ac_dest_dir";;
23479   esac;;
23480 esac
23481 case $ac_abs_builddir in
23482 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23483 *)
23484   case ${ac_top_builddir}. in
23485   .) ac_abs_top_builddir=$ac_abs_builddir;;
23486   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23487   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23488   esac;;
23489 esac
23490 case $ac_abs_builddir in
23491 .) ac_abs_srcdir=$ac_srcdir;;
23492 *)
23493   case $ac_srcdir in
23494   .) ac_abs_srcdir=$ac_abs_builddir;;
23495   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23496   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23497   esac;;
23498 esac
23499 case $ac_abs_builddir in
23500 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23501 *)
23502   case $ac_top_srcdir in
23503   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23504   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23505   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23506   esac;;
23507 esac
23508
23509
23510   case $srcdir in
23511   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
23512       *) ac_rel_source=$ac_top_builddir$srcdir/$ac_source ;;
23513   esac
23514
23515   # Try a symlink, then a hard link, then a copy.
23516   ln -s $ac_rel_source $ac_dest 2>/dev/null ||
23517     ln $srcdir/$ac_source $ac_dest 2>/dev/null ||
23518     cp -p $srcdir/$ac_source $ac_dest ||
23519     { { echo "$as_me:$LINENO: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&5
23520 echo "$as_me: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&2;}
23521    { (exit 1); exit 1; }; }
23522 done
23523 _ACEOF
23524 cat >>$CONFIG_STATUS <<\_ACEOF
23525
23526 #
23527 # CONFIG_COMMANDS section.
23528 #
23529 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
23530   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
23531   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
23532   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
23533 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23534          X"$ac_dest" : 'X\(//\)[^/]' \| \
23535          X"$ac_dest" : 'X\(//\)$' \| \
23536          X"$ac_dest" : 'X\(/\)' \| \
23537          .     : '\(.\)' 2>/dev/null ||
23538 echo X"$ac_dest" |
23539     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23540           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23541           /^X\(\/\/\)$/{ s//\1/; q; }
23542           /^X\(\/\).*/{ s//\1/; q; }
23543           s/.*/./; q'`
23544   { if $as_mkdir_p; then
23545     mkdir -p "$ac_dir"
23546   else
23547     as_dir="$ac_dir"
23548     as_dirs=
23549     while test ! -d "$as_dir"; do
23550       as_dirs="$as_dir $as_dirs"
23551       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23552 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23553          X"$as_dir" : 'X\(//\)[^/]' \| \
23554          X"$as_dir" : 'X\(//\)$' \| \
23555          X"$as_dir" : 'X\(/\)' \| \
23556          .     : '\(.\)' 2>/dev/null ||
23557 echo X"$as_dir" |
23558     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23559           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23560           /^X\(\/\/\)$/{ s//\1/; q; }
23561           /^X\(\/\).*/{ s//\1/; q; }
23562           s/.*/./; q'`
23563     done
23564     test ! -n "$as_dirs" || mkdir $as_dirs
23565   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23566 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23567    { (exit 1); exit 1; }; }; }
23568
23569   ac_builddir=.
23570
23571 if test "$ac_dir" != .; then
23572   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
23573   # A "../" for each directory in $ac_dir_suffix.
23574   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23575 else
23576   ac_dir_suffix= ac_top_builddir=
23577 fi
23578
23579 case $srcdir in
23580   .)  # No --srcdir option.  We are building in place.
23581     ac_srcdir=.
23582     if test -z "$ac_top_builddir"; then
23583        ac_top_srcdir=.
23584     else
23585        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23586     fi ;;
23587   [\\/]* | ?:[\\/]* )  # Absolute path.
23588     ac_srcdir=$srcdir$ac_dir_suffix;
23589     ac_top_srcdir=$srcdir ;;
23590   *) # Relative path.
23591     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23592     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23593 esac
23594
23595 # Do not use `cd foo && pwd` to compute absolute paths, because
23596 # the directories may not exist.
23597 case `pwd` in
23598 .) ac_abs_builddir="$ac_dir";;
23599 *)
23600   case "$ac_dir" in
23601   .) ac_abs_builddir=`pwd`;;
23602   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
23603   *) ac_abs_builddir=`pwd`/"$ac_dir";;
23604   esac;;
23605 esac
23606 case $ac_abs_builddir in
23607 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23608 *)
23609   case ${ac_top_builddir}. in
23610   .) ac_abs_top_builddir=$ac_abs_builddir;;
23611   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23612   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23613   esac;;
23614 esac
23615 case $ac_abs_builddir in
23616 .) ac_abs_srcdir=$ac_srcdir;;
23617 *)
23618   case $ac_srcdir in
23619   .) ac_abs_srcdir=$ac_abs_builddir;;
23620   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23621   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23622   esac;;
23623 esac
23624 case $ac_abs_builddir in
23625 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23626 *)
23627   case $ac_top_srcdir in
23628   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23629   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23630   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23631   esac;;
23632 esac
23633
23634
23635   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
23636 echo "$as_me: executing $ac_dest commands" >&6;}
23637   case $ac_dest in
23638     check_win32_symlinks )
23639 # Links sometimes fail undetected on Mingw -
23640 # so here we detect it and warn the user
23641 for FILE in $CONFIG_LINKS
23642  do
23643         # test -e works for symlinks in the MinGW console
23644         test -e `expr "$FILE" : '\([^:]*\)'` || { echo "$as_me:$LINENO: WARNING: *** link for $FILE - please fix by hand" >&5
23645 echo "$as_me: WARNING: *** link for $FILE - please fix by hand" >&2;}
23646  done
23647  ;;
23648   esac
23649 done
23650 _ACEOF
23651
23652 cat >>$CONFIG_STATUS <<\_ACEOF
23653
23654 { (exit 0); exit 0; }
23655 _ACEOF
23656 chmod +x $CONFIG_STATUS
23657 ac_clean_files=$ac_clean_files_save
23658
23659
23660 # configure is writing to config.log, and then calls config.status.
23661 # config.status does its own redirection, appending to config.log.
23662 # Unfortunately, on DOS this fails, as config.log is still kept open
23663 # by configure, so config.status won't be able to write to it; its
23664 # output is simply discarded.  So we exec the FD to /dev/null,
23665 # effectively closing config.log, so it can be properly (re)opened and
23666 # appended to by config.status.  When coming back to configure, we
23667 # need to make the FD available again.
23668 if test "$no_create" != yes; then
23669   ac_cs_success=:
23670   ac_config_status_args=
23671   test "$silent" = yes &&
23672     ac_config_status_args="$ac_config_status_args --quiet"
23673   exec 5>/dev/null
23674   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
23675   exec 5>>config.log
23676   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
23677   # would make configure fail if this is the last instruction.
23678   $ac_cs_success || { (exit 1); exit 1; }
23679 fi
23680
23681