]> granicus.if.org Git - postgresql/blob - configure
Add:
[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 echo "$as_me:$LINENO: checking for library containing ldopen" >&5
5381 echo $ECHO_N "checking for library containing ldopen... $ECHO_C" >&6
5382 if test "${ac_cv_search_ldopen+set}" = set; then
5383   echo $ECHO_N "(cached) $ECHO_C" >&6
5384 else
5385   ac_func_search_save_LIBS=$LIBS
5386 ac_cv_search_ldopen=no
5387 cat >conftest.$ac_ext <<_ACEOF
5388 /* confdefs.h.  */
5389 _ACEOF
5390 cat confdefs.h >>conftest.$ac_ext
5391 cat >>conftest.$ac_ext <<_ACEOF
5392 /* end confdefs.h.  */
5393
5394 /* Override any gcc2 internal prototype to avoid an error.  */
5395 #ifdef __cplusplus
5396 extern "C"
5397 #endif
5398 /* We use char because int might match the return type of a gcc2
5399    builtin and then its argument prototype would still apply.  */
5400 char ldopen ();
5401 int
5402 main ()
5403 {
5404 ldopen ();
5405   ;
5406   return 0;
5407 }
5408 _ACEOF
5409 rm -f conftest.$ac_objext conftest$ac_exeext
5410 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5411   (eval $ac_link) 2>conftest.er1
5412   ac_status=$?
5413   grep -v '^ *+' conftest.er1 >conftest.err
5414   rm -f conftest.er1
5415   cat conftest.err >&5
5416   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5417   (exit $ac_status); } &&
5418          { ac_try='test -z "$ac_c_werror_flag"
5419                          || test ! -s conftest.err'
5420   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5421   (eval $ac_try) 2>&5
5422   ac_status=$?
5423   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5424   (exit $ac_status); }; } &&
5425          { ac_try='test -s conftest$ac_exeext'
5426   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5427   (eval $ac_try) 2>&5
5428   ac_status=$?
5429   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5430   (exit $ac_status); }; }; then
5431   ac_cv_search_ldopen="none required"
5432 else
5433   echo "$as_me: failed program was:" >&5
5434 sed 's/^/| /' conftest.$ac_ext >&5
5435
5436 fi
5437 rm -f conftest.err conftest.$ac_objext \
5438       conftest$ac_exeext conftest.$ac_ext
5439 if test "$ac_cv_search_ldopen" = no; then
5440   for ac_lib in ld; do
5441     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5442     cat >conftest.$ac_ext <<_ACEOF
5443 /* confdefs.h.  */
5444 _ACEOF
5445 cat confdefs.h >>conftest.$ac_ext
5446 cat >>conftest.$ac_ext <<_ACEOF
5447 /* end confdefs.h.  */
5448
5449 /* Override any gcc2 internal prototype to avoid an error.  */
5450 #ifdef __cplusplus
5451 extern "C"
5452 #endif
5453 /* We use char because int might match the return type of a gcc2
5454    builtin and then its argument prototype would still apply.  */
5455 char ldopen ();
5456 int
5457 main ()
5458 {
5459 ldopen ();
5460   ;
5461   return 0;
5462 }
5463 _ACEOF
5464 rm -f conftest.$ac_objext conftest$ac_exeext
5465 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5466   (eval $ac_link) 2>conftest.er1
5467   ac_status=$?
5468   grep -v '^ *+' conftest.er1 >conftest.err
5469   rm -f conftest.er1
5470   cat conftest.err >&5
5471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5472   (exit $ac_status); } &&
5473          { ac_try='test -z "$ac_c_werror_flag"
5474                          || test ! -s conftest.err'
5475   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5476   (eval $ac_try) 2>&5
5477   ac_status=$?
5478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5479   (exit $ac_status); }; } &&
5480          { ac_try='test -s conftest$ac_exeext'
5481   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5482   (eval $ac_try) 2>&5
5483   ac_status=$?
5484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5485   (exit $ac_status); }; }; then
5486   ac_cv_search_ldopen="-l$ac_lib"
5487 break
5488 else
5489   echo "$as_me: failed program was:" >&5
5490 sed 's/^/| /' conftest.$ac_ext >&5
5491
5492 fi
5493 rm -f conftest.err conftest.$ac_objext \
5494       conftest$ac_exeext conftest.$ac_ext
5495   done
5496 fi
5497 LIBS=$ac_func_search_save_LIBS
5498 fi
5499 echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
5500 echo "${ECHO_T}$ac_cv_search_ldopen" >&6
5501 if test "$ac_cv_search_ldopen" != no; then
5502   test "$ac_cv_search_ldopen" = "none required" || LIBS="$ac_cv_search_ldopen $LIBS"
5503
5504 fi
5505
5506 echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
5507 echo $ECHO_N "checking for library containing getopt_long... $ECHO_C" >&6
5508 if test "${ac_cv_search_getopt_long+set}" = set; then
5509   echo $ECHO_N "(cached) $ECHO_C" >&6
5510 else
5511   ac_func_search_save_LIBS=$LIBS
5512 ac_cv_search_getopt_long=no
5513 cat >conftest.$ac_ext <<_ACEOF
5514 /* confdefs.h.  */
5515 _ACEOF
5516 cat confdefs.h >>conftest.$ac_ext
5517 cat >>conftest.$ac_ext <<_ACEOF
5518 /* end confdefs.h.  */
5519
5520 /* Override any gcc2 internal prototype to avoid an error.  */
5521 #ifdef __cplusplus
5522 extern "C"
5523 #endif
5524 /* We use char because int might match the return type of a gcc2
5525    builtin and then its argument prototype would still apply.  */
5526 char getopt_long ();
5527 int
5528 main ()
5529 {
5530 getopt_long ();
5531   ;
5532   return 0;
5533 }
5534 _ACEOF
5535 rm -f conftest.$ac_objext conftest$ac_exeext
5536 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5537   (eval $ac_link) 2>conftest.er1
5538   ac_status=$?
5539   grep -v '^ *+' conftest.er1 >conftest.err
5540   rm -f conftest.er1
5541   cat conftest.err >&5
5542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5543   (exit $ac_status); } &&
5544          { ac_try='test -z "$ac_c_werror_flag"
5545                          || test ! -s conftest.err'
5546   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5547   (eval $ac_try) 2>&5
5548   ac_status=$?
5549   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5550   (exit $ac_status); }; } &&
5551          { ac_try='test -s conftest$ac_exeext'
5552   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5553   (eval $ac_try) 2>&5
5554   ac_status=$?
5555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5556   (exit $ac_status); }; }; then
5557   ac_cv_search_getopt_long="none required"
5558 else
5559   echo "$as_me: failed program was:" >&5
5560 sed 's/^/| /' conftest.$ac_ext >&5
5561
5562 fi
5563 rm -f conftest.err conftest.$ac_objext \
5564       conftest$ac_exeext conftest.$ac_ext
5565 if test "$ac_cv_search_getopt_long" = no; then
5566   for ac_lib in getopt gnugetopt; do
5567     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5568     cat >conftest.$ac_ext <<_ACEOF
5569 /* confdefs.h.  */
5570 _ACEOF
5571 cat confdefs.h >>conftest.$ac_ext
5572 cat >>conftest.$ac_ext <<_ACEOF
5573 /* end confdefs.h.  */
5574
5575 /* Override any gcc2 internal prototype to avoid an error.  */
5576 #ifdef __cplusplus
5577 extern "C"
5578 #endif
5579 /* We use char because int might match the return type of a gcc2
5580    builtin and then its argument prototype would still apply.  */
5581 char getopt_long ();
5582 int
5583 main ()
5584 {
5585 getopt_long ();
5586   ;
5587   return 0;
5588 }
5589 _ACEOF
5590 rm -f conftest.$ac_objext conftest$ac_exeext
5591 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5592   (eval $ac_link) 2>conftest.er1
5593   ac_status=$?
5594   grep -v '^ *+' conftest.er1 >conftest.err
5595   rm -f conftest.er1
5596   cat conftest.err >&5
5597   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5598   (exit $ac_status); } &&
5599          { ac_try='test -z "$ac_c_werror_flag"
5600                          || test ! -s conftest.err'
5601   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5602   (eval $ac_try) 2>&5
5603   ac_status=$?
5604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5605   (exit $ac_status); }; } &&
5606          { ac_try='test -s conftest$ac_exeext'
5607   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5608   (eval $ac_try) 2>&5
5609   ac_status=$?
5610   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5611   (exit $ac_status); }; }; then
5612   ac_cv_search_getopt_long="-l$ac_lib"
5613 break
5614 else
5615   echo "$as_me: failed program was:" >&5
5616 sed 's/^/| /' conftest.$ac_ext >&5
5617
5618 fi
5619 rm -f conftest.err conftest.$ac_objext \
5620       conftest$ac_exeext conftest.$ac_ext
5621   done
5622 fi
5623 LIBS=$ac_func_search_save_LIBS
5624 fi
5625 echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
5626 echo "${ECHO_T}$ac_cv_search_getopt_long" >&6
5627 if test "$ac_cv_search_getopt_long" != no; then
5628   test "$ac_cv_search_getopt_long" = "none required" || LIBS="$ac_cv_search_getopt_long $LIBS"
5629
5630 fi
5631
5632 echo "$as_me:$LINENO: checking for library containing crypt" >&5
5633 echo $ECHO_N "checking for library containing crypt... $ECHO_C" >&6
5634 if test "${ac_cv_search_crypt+set}" = set; then
5635   echo $ECHO_N "(cached) $ECHO_C" >&6
5636 else
5637   ac_func_search_save_LIBS=$LIBS
5638 ac_cv_search_crypt=no
5639 cat >conftest.$ac_ext <<_ACEOF
5640 /* confdefs.h.  */
5641 _ACEOF
5642 cat confdefs.h >>conftest.$ac_ext
5643 cat >>conftest.$ac_ext <<_ACEOF
5644 /* end confdefs.h.  */
5645
5646 /* Override any gcc2 internal prototype to avoid an error.  */
5647 #ifdef __cplusplus
5648 extern "C"
5649 #endif
5650 /* We use char because int might match the return type of a gcc2
5651    builtin and then its argument prototype would still apply.  */
5652 char crypt ();
5653 int
5654 main ()
5655 {
5656 crypt ();
5657   ;
5658   return 0;
5659 }
5660 _ACEOF
5661 rm -f conftest.$ac_objext conftest$ac_exeext
5662 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5663   (eval $ac_link) 2>conftest.er1
5664   ac_status=$?
5665   grep -v '^ *+' conftest.er1 >conftest.err
5666   rm -f conftest.er1
5667   cat conftest.err >&5
5668   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5669   (exit $ac_status); } &&
5670          { ac_try='test -z "$ac_c_werror_flag"
5671                          || test ! -s conftest.err'
5672   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5673   (eval $ac_try) 2>&5
5674   ac_status=$?
5675   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5676   (exit $ac_status); }; } &&
5677          { ac_try='test -s conftest$ac_exeext'
5678   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5679   (eval $ac_try) 2>&5
5680   ac_status=$?
5681   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5682   (exit $ac_status); }; }; then
5683   ac_cv_search_crypt="none required"
5684 else
5685   echo "$as_me: failed program was:" >&5
5686 sed 's/^/| /' conftest.$ac_ext >&5
5687
5688 fi
5689 rm -f conftest.err conftest.$ac_objext \
5690       conftest$ac_exeext conftest.$ac_ext
5691 if test "$ac_cv_search_crypt" = no; then
5692   for ac_lib in crypt; do
5693     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5694     cat >conftest.$ac_ext <<_ACEOF
5695 /* confdefs.h.  */
5696 _ACEOF
5697 cat confdefs.h >>conftest.$ac_ext
5698 cat >>conftest.$ac_ext <<_ACEOF
5699 /* end confdefs.h.  */
5700
5701 /* Override any gcc2 internal prototype to avoid an error.  */
5702 #ifdef __cplusplus
5703 extern "C"
5704 #endif
5705 /* We use char because int might match the return type of a gcc2
5706    builtin and then its argument prototype would still apply.  */
5707 char crypt ();
5708 int
5709 main ()
5710 {
5711 crypt ();
5712   ;
5713   return 0;
5714 }
5715 _ACEOF
5716 rm -f conftest.$ac_objext conftest$ac_exeext
5717 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5718   (eval $ac_link) 2>conftest.er1
5719   ac_status=$?
5720   grep -v '^ *+' conftest.er1 >conftest.err
5721   rm -f conftest.er1
5722   cat conftest.err >&5
5723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5724   (exit $ac_status); } &&
5725          { ac_try='test -z "$ac_c_werror_flag"
5726                          || test ! -s conftest.err'
5727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5728   (eval $ac_try) 2>&5
5729   ac_status=$?
5730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5731   (exit $ac_status); }; } &&
5732          { ac_try='test -s conftest$ac_exeext'
5733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5734   (eval $ac_try) 2>&5
5735   ac_status=$?
5736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5737   (exit $ac_status); }; }; then
5738   ac_cv_search_crypt="-l$ac_lib"
5739 break
5740 else
5741   echo "$as_me: failed program was:" >&5
5742 sed 's/^/| /' conftest.$ac_ext >&5
5743
5744 fi
5745 rm -f conftest.err conftest.$ac_objext \
5746       conftest$ac_exeext conftest.$ac_ext
5747   done
5748 fi
5749 LIBS=$ac_func_search_save_LIBS
5750 fi
5751 echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
5752 echo "${ECHO_T}$ac_cv_search_crypt" >&6
5753 if test "$ac_cv_search_crypt" != no; then
5754   test "$ac_cv_search_crypt" = "none required" || LIBS="$ac_cv_search_crypt $LIBS"
5755
5756 fi
5757
5758 # Solaris:
5759 echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
5760 echo $ECHO_N "checking for library containing fdatasync... $ECHO_C" >&6
5761 if test "${ac_cv_search_fdatasync+set}" = set; then
5762   echo $ECHO_N "(cached) $ECHO_C" >&6
5763 else
5764   ac_func_search_save_LIBS=$LIBS
5765 ac_cv_search_fdatasync=no
5766 cat >conftest.$ac_ext <<_ACEOF
5767 /* confdefs.h.  */
5768 _ACEOF
5769 cat confdefs.h >>conftest.$ac_ext
5770 cat >>conftest.$ac_ext <<_ACEOF
5771 /* end confdefs.h.  */
5772
5773 /* Override any gcc2 internal prototype to avoid an error.  */
5774 #ifdef __cplusplus
5775 extern "C"
5776 #endif
5777 /* We use char because int might match the return type of a gcc2
5778    builtin and then its argument prototype would still apply.  */
5779 char fdatasync ();
5780 int
5781 main ()
5782 {
5783 fdatasync ();
5784   ;
5785   return 0;
5786 }
5787 _ACEOF
5788 rm -f conftest.$ac_objext conftest$ac_exeext
5789 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5790   (eval $ac_link) 2>conftest.er1
5791   ac_status=$?
5792   grep -v '^ *+' conftest.er1 >conftest.err
5793   rm -f conftest.er1
5794   cat conftest.err >&5
5795   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5796   (exit $ac_status); } &&
5797          { ac_try='test -z "$ac_c_werror_flag"
5798                          || test ! -s conftest.err'
5799   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5800   (eval $ac_try) 2>&5
5801   ac_status=$?
5802   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5803   (exit $ac_status); }; } &&
5804          { ac_try='test -s conftest$ac_exeext'
5805   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5806   (eval $ac_try) 2>&5
5807   ac_status=$?
5808   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5809   (exit $ac_status); }; }; then
5810   ac_cv_search_fdatasync="none required"
5811 else
5812   echo "$as_me: failed program was:" >&5
5813 sed 's/^/| /' conftest.$ac_ext >&5
5814
5815 fi
5816 rm -f conftest.err conftest.$ac_objext \
5817       conftest$ac_exeext conftest.$ac_ext
5818 if test "$ac_cv_search_fdatasync" = no; then
5819   for ac_lib in rt posix4; do
5820     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5821     cat >conftest.$ac_ext <<_ACEOF
5822 /* confdefs.h.  */
5823 _ACEOF
5824 cat confdefs.h >>conftest.$ac_ext
5825 cat >>conftest.$ac_ext <<_ACEOF
5826 /* end confdefs.h.  */
5827
5828 /* Override any gcc2 internal prototype to avoid an error.  */
5829 #ifdef __cplusplus
5830 extern "C"
5831 #endif
5832 /* We use char because int might match the return type of a gcc2
5833    builtin and then its argument prototype would still apply.  */
5834 char fdatasync ();
5835 int
5836 main ()
5837 {
5838 fdatasync ();
5839   ;
5840   return 0;
5841 }
5842 _ACEOF
5843 rm -f conftest.$ac_objext conftest$ac_exeext
5844 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5845   (eval $ac_link) 2>conftest.er1
5846   ac_status=$?
5847   grep -v '^ *+' conftest.er1 >conftest.err
5848   rm -f conftest.er1
5849   cat conftest.err >&5
5850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5851   (exit $ac_status); } &&
5852          { ac_try='test -z "$ac_c_werror_flag"
5853                          || test ! -s conftest.err'
5854   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5855   (eval $ac_try) 2>&5
5856   ac_status=$?
5857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5858   (exit $ac_status); }; } &&
5859          { ac_try='test -s conftest$ac_exeext'
5860   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5861   (eval $ac_try) 2>&5
5862   ac_status=$?
5863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5864   (exit $ac_status); }; }; then
5865   ac_cv_search_fdatasync="-l$ac_lib"
5866 break
5867 else
5868   echo "$as_me: failed program was:" >&5
5869 sed 's/^/| /' conftest.$ac_ext >&5
5870
5871 fi
5872 rm -f conftest.err conftest.$ac_objext \
5873       conftest$ac_exeext conftest.$ac_ext
5874   done
5875 fi
5876 LIBS=$ac_func_search_save_LIBS
5877 fi
5878 echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
5879 echo "${ECHO_T}$ac_cv_search_fdatasync" >&6
5880 if test "$ac_cv_search_fdatasync" != no; then
5881   test "$ac_cv_search_fdatasync" = "none required" || LIBS="$ac_cv_search_fdatasync $LIBS"
5882
5883 fi
5884
5885 # Cygwin:
5886 echo "$as_me:$LINENO: checking for library containing shmget" >&5
5887 echo $ECHO_N "checking for library containing shmget... $ECHO_C" >&6
5888 if test "${ac_cv_search_shmget+set}" = set; then
5889   echo $ECHO_N "(cached) $ECHO_C" >&6
5890 else
5891   ac_func_search_save_LIBS=$LIBS
5892 ac_cv_search_shmget=no
5893 cat >conftest.$ac_ext <<_ACEOF
5894 /* confdefs.h.  */
5895 _ACEOF
5896 cat confdefs.h >>conftest.$ac_ext
5897 cat >>conftest.$ac_ext <<_ACEOF
5898 /* end confdefs.h.  */
5899
5900 /* Override any gcc2 internal prototype to avoid an error.  */
5901 #ifdef __cplusplus
5902 extern "C"
5903 #endif
5904 /* We use char because int might match the return type of a gcc2
5905    builtin and then its argument prototype would still apply.  */
5906 char shmget ();
5907 int
5908 main ()
5909 {
5910 shmget ();
5911   ;
5912   return 0;
5913 }
5914 _ACEOF
5915 rm -f conftest.$ac_objext conftest$ac_exeext
5916 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5917   (eval $ac_link) 2>conftest.er1
5918   ac_status=$?
5919   grep -v '^ *+' conftest.er1 >conftest.err
5920   rm -f conftest.er1
5921   cat conftest.err >&5
5922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5923   (exit $ac_status); } &&
5924          { ac_try='test -z "$ac_c_werror_flag"
5925                          || test ! -s conftest.err'
5926   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5927   (eval $ac_try) 2>&5
5928   ac_status=$?
5929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5930   (exit $ac_status); }; } &&
5931          { ac_try='test -s conftest$ac_exeext'
5932   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5933   (eval $ac_try) 2>&5
5934   ac_status=$?
5935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5936   (exit $ac_status); }; }; then
5937   ac_cv_search_shmget="none required"
5938 else
5939   echo "$as_me: failed program was:" >&5
5940 sed 's/^/| /' conftest.$ac_ext >&5
5941
5942 fi
5943 rm -f conftest.err conftest.$ac_objext \
5944       conftest$ac_exeext conftest.$ac_ext
5945 if test "$ac_cv_search_shmget" = no; then
5946   for ac_lib in cygipc; do
5947     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5948     cat >conftest.$ac_ext <<_ACEOF
5949 /* confdefs.h.  */
5950 _ACEOF
5951 cat confdefs.h >>conftest.$ac_ext
5952 cat >>conftest.$ac_ext <<_ACEOF
5953 /* end confdefs.h.  */
5954
5955 /* Override any gcc2 internal prototype to avoid an error.  */
5956 #ifdef __cplusplus
5957 extern "C"
5958 #endif
5959 /* We use char because int might match the return type of a gcc2
5960    builtin and then its argument prototype would still apply.  */
5961 char shmget ();
5962 int
5963 main ()
5964 {
5965 shmget ();
5966   ;
5967   return 0;
5968 }
5969 _ACEOF
5970 rm -f conftest.$ac_objext conftest$ac_exeext
5971 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5972   (eval $ac_link) 2>conftest.er1
5973   ac_status=$?
5974   grep -v '^ *+' conftest.er1 >conftest.err
5975   rm -f conftest.er1
5976   cat conftest.err >&5
5977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5978   (exit $ac_status); } &&
5979          { ac_try='test -z "$ac_c_werror_flag"
5980                          || test ! -s conftest.err'
5981   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5982   (eval $ac_try) 2>&5
5983   ac_status=$?
5984   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5985   (exit $ac_status); }; } &&
5986          { ac_try='test -s conftest$ac_exeext'
5987   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5988   (eval $ac_try) 2>&5
5989   ac_status=$?
5990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5991   (exit $ac_status); }; }; then
5992   ac_cv_search_shmget="-l$ac_lib"
5993 break
5994 else
5995   echo "$as_me: failed program was:" >&5
5996 sed 's/^/| /' conftest.$ac_ext >&5
5997
5998 fi
5999 rm -f conftest.err conftest.$ac_objext \
6000       conftest$ac_exeext conftest.$ac_ext
6001   done
6002 fi
6003 LIBS=$ac_func_search_save_LIBS
6004 fi
6005 echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
6006 echo "${ECHO_T}$ac_cv_search_shmget" >&6
6007 if test "$ac_cv_search_shmget" != no; then
6008   test "$ac_cv_search_shmget" = "none required" || LIBS="$ac_cv_search_shmget $LIBS"
6009
6010 fi
6011
6012
6013 if test "$with_readline" = yes; then
6014
6015
6016 if test "${pgac_cv_check_readline+set}" = set; then
6017   echo $ECHO_N "(cached) $ECHO_C" >&6
6018 else
6019   pgac_cv_check_readline=no
6020 pgac_save_LIBS=$LIBS
6021 if test x"$with_libedit_preferred" != x"yes"
6022 then    READLINE_ORDER="-lreadline -ledit"
6023 else    READLINE_ORDER="-ledit -lreadline"
6024 fi
6025 for pgac_rllib in $READLINE_ORDER ; do
6026   echo "$as_me:$LINENO: checking for ${pgac_rllib}" >&5
6027 echo $ECHO_N "checking for ${pgac_rllib}... $ECHO_C" >&6
6028   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
6029     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
6030     cat >conftest.$ac_ext <<_ACEOF
6031 /* confdefs.h.  */
6032 _ACEOF
6033 cat confdefs.h >>conftest.$ac_ext
6034 cat >>conftest.$ac_ext <<_ACEOF
6035 /* end confdefs.h.  */
6036
6037 /* Override any gcc2 internal prototype to avoid an error.  */
6038 #ifdef __cplusplus
6039 extern "C"
6040 #endif
6041 /* We use char because int might match the return type of a gcc2
6042    builtin and then its argument prototype would still apply.  */
6043 char readline ();
6044 int
6045 main ()
6046 {
6047 readline ();
6048   ;
6049   return 0;
6050 }
6051 _ACEOF
6052 rm -f conftest.$ac_objext conftest$ac_exeext
6053 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6054   (eval $ac_link) 2>conftest.er1
6055   ac_status=$?
6056   grep -v '^ *+' conftest.er1 >conftest.err
6057   rm -f conftest.er1
6058   cat conftest.err >&5
6059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6060   (exit $ac_status); } &&
6061          { ac_try='test -z "$ac_c_werror_flag"
6062                          || test ! -s conftest.err'
6063   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6064   (eval $ac_try) 2>&5
6065   ac_status=$?
6066   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6067   (exit $ac_status); }; } &&
6068          { ac_try='test -s conftest$ac_exeext'
6069   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6070   (eval $ac_try) 2>&5
6071   ac_status=$?
6072   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6073   (exit $ac_status); }; }; then
6074
6075       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
6076       # recognize dependent libraries; assume curses is needed if we didn't
6077       # find any dependency.
6078       case $host_os in
6079         netbsd* | openbsd* | irix*)
6080           if test x"$pgac_lib" = x"" ; then
6081             pgac_lib=" -lcurses"
6082           fi ;;
6083       esac
6084
6085       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
6086       break
6087
6088 else
6089   echo "$as_me: failed program was:" >&5
6090 sed 's/^/| /' conftest.$ac_ext >&5
6091
6092 fi
6093 rm -f conftest.err conftest.$ac_objext \
6094       conftest$ac_exeext conftest.$ac_ext
6095   done
6096   if test "$pgac_cv_check_readline" != no ; then
6097     echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
6098 echo "${ECHO_T}yes ($pgac_cv_check_readline)" >&6
6099     break
6100   else
6101     echo "$as_me:$LINENO: result: no" >&5
6102 echo "${ECHO_T}no" >&6
6103   fi
6104 done
6105 LIBS=$pgac_save_LIBS
6106
6107 fi
6108
6109 if test "$pgac_cv_check_readline" != no ; then
6110   LIBS="$pgac_cv_check_readline $LIBS"
6111
6112 cat >>confdefs.h <<\_ACEOF
6113 #define HAVE_LIBREADLINE 1
6114 _ACEOF
6115
6116 fi
6117
6118
6119   if test x"$pgac_cv_check_readline" = x"no"; then
6120     { { echo "$as_me:$LINENO: error: readline library not found
6121 If you have readline already installed, see config.log for details on the
6122 failure.  It is possible the compiler isn't looking in the proper directory.
6123 Use --without-readline to disable readline support." >&5
6124 echo "$as_me: error: readline library not found
6125 If you have readline already installed, see config.log for details on the
6126 failure.  It is possible the compiler isn't looking in the proper directory.
6127 Use --without-readline to disable readline support." >&2;}
6128    { (exit 1); exit 1; }; }
6129   fi
6130 fi
6131
6132 if test "$with_zlib" = yes; then
6133
6134 echo "$as_me:$LINENO: checking for inflate in -lz" >&5
6135 echo $ECHO_N "checking for inflate in -lz... $ECHO_C" >&6
6136 if test "${ac_cv_lib_z_inflate+set}" = set; then
6137   echo $ECHO_N "(cached) $ECHO_C" >&6
6138 else
6139   ac_check_lib_save_LIBS=$LIBS
6140 LIBS="-lz  $LIBS"
6141 cat >conftest.$ac_ext <<_ACEOF
6142 /* confdefs.h.  */
6143 _ACEOF
6144 cat confdefs.h >>conftest.$ac_ext
6145 cat >>conftest.$ac_ext <<_ACEOF
6146 /* end confdefs.h.  */
6147
6148 /* Override any gcc2 internal prototype to avoid an error.  */
6149 #ifdef __cplusplus
6150 extern "C"
6151 #endif
6152 /* We use char because int might match the return type of a gcc2
6153    builtin and then its argument prototype would still apply.  */
6154 char inflate ();
6155 int
6156 main ()
6157 {
6158 inflate ();
6159   ;
6160   return 0;
6161 }
6162 _ACEOF
6163 rm -f conftest.$ac_objext conftest$ac_exeext
6164 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6165   (eval $ac_link) 2>conftest.er1
6166   ac_status=$?
6167   grep -v '^ *+' conftest.er1 >conftest.err
6168   rm -f conftest.er1
6169   cat conftest.err >&5
6170   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6171   (exit $ac_status); } &&
6172          { ac_try='test -z "$ac_c_werror_flag"
6173                          || test ! -s conftest.err'
6174   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6175   (eval $ac_try) 2>&5
6176   ac_status=$?
6177   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6178   (exit $ac_status); }; } &&
6179          { ac_try='test -s conftest$ac_exeext'
6180   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6181   (eval $ac_try) 2>&5
6182   ac_status=$?
6183   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6184   (exit $ac_status); }; }; then
6185   ac_cv_lib_z_inflate=yes
6186 else
6187   echo "$as_me: failed program was:" >&5
6188 sed 's/^/| /' conftest.$ac_ext >&5
6189
6190 ac_cv_lib_z_inflate=no
6191 fi
6192 rm -f conftest.err conftest.$ac_objext \
6193       conftest$ac_exeext conftest.$ac_ext
6194 LIBS=$ac_check_lib_save_LIBS
6195 fi
6196 echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
6197 echo "${ECHO_T}$ac_cv_lib_z_inflate" >&6
6198 if test $ac_cv_lib_z_inflate = yes; then
6199   cat >>confdefs.h <<_ACEOF
6200 #define HAVE_LIBZ 1
6201 _ACEOF
6202
6203   LIBS="-lz $LIBS"
6204
6205 else
6206   { { echo "$as_me:$LINENO: error: zlib library not found
6207 If you have zlib already installed, see config.log for details on the
6208 failure.  It is possible the compiler isn't looking in the proper directory.
6209 Use --without-zlib to disable zlib support." >&5
6210 echo "$as_me: error: zlib library not found
6211 If you have zlib already installed, see config.log for details on the
6212 failure.  It is possible the compiler isn't looking in the proper directory.
6213 Use --without-zlib to disable zlib support." >&2;}
6214    { (exit 1); exit 1; }; }
6215 fi
6216
6217 fi
6218
6219 if test "$enable_spinlocks" = yes; then
6220
6221 cat >>confdefs.h <<\_ACEOF
6222 #define HAVE_SPINLOCKS 1
6223 _ACEOF
6224
6225 else
6226   { echo "$as_me:$LINENO: WARNING:
6227 *** Not using spinlocks will cause poor performance." >&5
6228 echo "$as_me: WARNING:
6229 *** Not using spinlocks will cause poor performance." >&2;}
6230 fi
6231
6232 if test "$with_krb5" = yes ; then
6233   if test "$PORTNAME" != "win32"; then
6234      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6235 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6236 if test "${ac_cv_search_com_err+set}" = set; then
6237   echo $ECHO_N "(cached) $ECHO_C" >&6
6238 else
6239   ac_func_search_save_LIBS=$LIBS
6240 ac_cv_search_com_err=no
6241 cat >conftest.$ac_ext <<_ACEOF
6242 /* confdefs.h.  */
6243 _ACEOF
6244 cat confdefs.h >>conftest.$ac_ext
6245 cat >>conftest.$ac_ext <<_ACEOF
6246 /* end confdefs.h.  */
6247
6248 /* Override any gcc2 internal prototype to avoid an error.  */
6249 #ifdef __cplusplus
6250 extern "C"
6251 #endif
6252 /* We use char because int might match the return type of a gcc2
6253    builtin and then its argument prototype would still apply.  */
6254 char com_err ();
6255 int
6256 main ()
6257 {
6258 com_err ();
6259   ;
6260   return 0;
6261 }
6262 _ACEOF
6263 rm -f conftest.$ac_objext conftest$ac_exeext
6264 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6265   (eval $ac_link) 2>conftest.er1
6266   ac_status=$?
6267   grep -v '^ *+' conftest.er1 >conftest.err
6268   rm -f conftest.er1
6269   cat conftest.err >&5
6270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6271   (exit $ac_status); } &&
6272          { ac_try='test -z "$ac_c_werror_flag"
6273                          || test ! -s conftest.err'
6274   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6275   (eval $ac_try) 2>&5
6276   ac_status=$?
6277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6278   (exit $ac_status); }; } &&
6279          { ac_try='test -s conftest$ac_exeext'
6280   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6281   (eval $ac_try) 2>&5
6282   ac_status=$?
6283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6284   (exit $ac_status); }; }; then
6285   ac_cv_search_com_err="none required"
6286 else
6287   echo "$as_me: failed program was:" >&5
6288 sed 's/^/| /' conftest.$ac_ext >&5
6289
6290 fi
6291 rm -f conftest.err conftest.$ac_objext \
6292       conftest$ac_exeext conftest.$ac_ext
6293 if test "$ac_cv_search_com_err" = no; then
6294   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' com_err; do
6295     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6296     cat >conftest.$ac_ext <<_ACEOF
6297 /* confdefs.h.  */
6298 _ACEOF
6299 cat confdefs.h >>conftest.$ac_ext
6300 cat >>conftest.$ac_ext <<_ACEOF
6301 /* end confdefs.h.  */
6302
6303 /* Override any gcc2 internal prototype to avoid an error.  */
6304 #ifdef __cplusplus
6305 extern "C"
6306 #endif
6307 /* We use char because int might match the return type of a gcc2
6308    builtin and then its argument prototype would still apply.  */
6309 char com_err ();
6310 int
6311 main ()
6312 {
6313 com_err ();
6314   ;
6315   return 0;
6316 }
6317 _ACEOF
6318 rm -f conftest.$ac_objext conftest$ac_exeext
6319 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6320   (eval $ac_link) 2>conftest.er1
6321   ac_status=$?
6322   grep -v '^ *+' conftest.er1 >conftest.err
6323   rm -f conftest.er1
6324   cat conftest.err >&5
6325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6326   (exit $ac_status); } &&
6327          { ac_try='test -z "$ac_c_werror_flag"
6328                          || test ! -s conftest.err'
6329   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6330   (eval $ac_try) 2>&5
6331   ac_status=$?
6332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6333   (exit $ac_status); }; } &&
6334          { ac_try='test -s conftest$ac_exeext'
6335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6336   (eval $ac_try) 2>&5
6337   ac_status=$?
6338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6339   (exit $ac_status); }; }; then
6340   ac_cv_search_com_err="-l$ac_lib"
6341 break
6342 else
6343   echo "$as_me: failed program was:" >&5
6344 sed 's/^/| /' conftest.$ac_ext >&5
6345
6346 fi
6347 rm -f conftest.err conftest.$ac_objext \
6348       conftest$ac_exeext conftest.$ac_ext
6349   done
6350 fi
6351 LIBS=$ac_func_search_save_LIBS
6352 fi
6353 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6354 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6355 if test "$ac_cv_search_com_err" != no; then
6356   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6357
6358 else
6359   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6360 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6361    { (exit 1); exit 1; }; }
6362 fi
6363
6364      echo "$as_me:$LINENO: checking for library containing krb5_encrypt" >&5
6365 echo $ECHO_N "checking for library containing krb5_encrypt... $ECHO_C" >&6
6366 if test "${ac_cv_search_krb5_encrypt+set}" = set; then
6367   echo $ECHO_N "(cached) $ECHO_C" >&6
6368 else
6369   ac_func_search_save_LIBS=$LIBS
6370 ac_cv_search_krb5_encrypt=no
6371 cat >conftest.$ac_ext <<_ACEOF
6372 /* confdefs.h.  */
6373 _ACEOF
6374 cat confdefs.h >>conftest.$ac_ext
6375 cat >>conftest.$ac_ext <<_ACEOF
6376 /* end confdefs.h.  */
6377
6378 /* Override any gcc2 internal prototype to avoid an error.  */
6379 #ifdef __cplusplus
6380 extern "C"
6381 #endif
6382 /* We use char because int might match the return type of a gcc2
6383    builtin and then its argument prototype would still apply.  */
6384 char krb5_encrypt ();
6385 int
6386 main ()
6387 {
6388 krb5_encrypt ();
6389   ;
6390   return 0;
6391 }
6392 _ACEOF
6393 rm -f conftest.$ac_objext conftest$ac_exeext
6394 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6395   (eval $ac_link) 2>conftest.er1
6396   ac_status=$?
6397   grep -v '^ *+' conftest.er1 >conftest.err
6398   rm -f conftest.er1
6399   cat conftest.err >&5
6400   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6401   (exit $ac_status); } &&
6402          { ac_try='test -z "$ac_c_werror_flag"
6403                          || test ! -s conftest.err'
6404   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6405   (eval $ac_try) 2>&5
6406   ac_status=$?
6407   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6408   (exit $ac_status); }; } &&
6409          { ac_try='test -s conftest$ac_exeext'
6410   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6411   (eval $ac_try) 2>&5
6412   ac_status=$?
6413   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6414   (exit $ac_status); }; }; then
6415   ac_cv_search_krb5_encrypt="none required"
6416 else
6417   echo "$as_me: failed program was:" >&5
6418 sed 's/^/| /' conftest.$ac_ext >&5
6419
6420 fi
6421 rm -f conftest.err conftest.$ac_objext \
6422       conftest$ac_exeext conftest.$ac_ext
6423 if test "$ac_cv_search_krb5_encrypt" = no; then
6424   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' crypto k5crypto; do
6425     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6426     cat >conftest.$ac_ext <<_ACEOF
6427 /* confdefs.h.  */
6428 _ACEOF
6429 cat confdefs.h >>conftest.$ac_ext
6430 cat >>conftest.$ac_ext <<_ACEOF
6431 /* end confdefs.h.  */
6432
6433 /* Override any gcc2 internal prototype to avoid an error.  */
6434 #ifdef __cplusplus
6435 extern "C"
6436 #endif
6437 /* We use char because int might match the return type of a gcc2
6438    builtin and then its argument prototype would still apply.  */
6439 char krb5_encrypt ();
6440 int
6441 main ()
6442 {
6443 krb5_encrypt ();
6444   ;
6445   return 0;
6446 }
6447 _ACEOF
6448 rm -f conftest.$ac_objext conftest$ac_exeext
6449 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6450   (eval $ac_link) 2>conftest.er1
6451   ac_status=$?
6452   grep -v '^ *+' conftest.er1 >conftest.err
6453   rm -f conftest.er1
6454   cat conftest.err >&5
6455   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6456   (exit $ac_status); } &&
6457          { ac_try='test -z "$ac_c_werror_flag"
6458                          || test ! -s conftest.err'
6459   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6460   (eval $ac_try) 2>&5
6461   ac_status=$?
6462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6463   (exit $ac_status); }; } &&
6464          { ac_try='test -s conftest$ac_exeext'
6465   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6466   (eval $ac_try) 2>&5
6467   ac_status=$?
6468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6469   (exit $ac_status); }; }; then
6470   ac_cv_search_krb5_encrypt="-l$ac_lib"
6471 break
6472 else
6473   echo "$as_me: failed program was:" >&5
6474 sed 's/^/| /' conftest.$ac_ext >&5
6475
6476 fi
6477 rm -f conftest.err conftest.$ac_objext \
6478       conftest$ac_exeext conftest.$ac_ext
6479   done
6480 fi
6481 LIBS=$ac_func_search_save_LIBS
6482 fi
6483 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_encrypt" >&5
6484 echo "${ECHO_T}$ac_cv_search_krb5_encrypt" >&6
6485 if test "$ac_cv_search_krb5_encrypt" != no; then
6486   test "$ac_cv_search_krb5_encrypt" = "none required" || LIBS="$ac_cv_search_krb5_encrypt $LIBS"
6487
6488 else
6489   { { echo "$as_me:$LINENO: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&5
6490 echo "$as_me: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&2;}
6491    { (exit 1); exit 1; }; }
6492 fi
6493
6494      echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
6495 echo $ECHO_N "checking for library containing krb5_sendauth... $ECHO_C" >&6
6496 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
6497   echo $ECHO_N "(cached) $ECHO_C" >&6
6498 else
6499   ac_func_search_save_LIBS=$LIBS
6500 ac_cv_search_krb5_sendauth=no
6501 cat >conftest.$ac_ext <<_ACEOF
6502 /* confdefs.h.  */
6503 _ACEOF
6504 cat confdefs.h >>conftest.$ac_ext
6505 cat >>conftest.$ac_ext <<_ACEOF
6506 /* end confdefs.h.  */
6507
6508 /* Override any gcc2 internal prototype to avoid an error.  */
6509 #ifdef __cplusplus
6510 extern "C"
6511 #endif
6512 /* We use char because int might match the return type of a gcc2
6513    builtin and then its argument prototype would still apply.  */
6514 char krb5_sendauth ();
6515 int
6516 main ()
6517 {
6518 krb5_sendauth ();
6519   ;
6520   return 0;
6521 }
6522 _ACEOF
6523 rm -f conftest.$ac_objext conftest$ac_exeext
6524 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6525   (eval $ac_link) 2>conftest.er1
6526   ac_status=$?
6527   grep -v '^ *+' conftest.er1 >conftest.err
6528   rm -f conftest.er1
6529   cat conftest.err >&5
6530   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6531   (exit $ac_status); } &&
6532          { ac_try='test -z "$ac_c_werror_flag"
6533                          || test ! -s conftest.err'
6534   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6535   (eval $ac_try) 2>&5
6536   ac_status=$?
6537   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6538   (exit $ac_status); }; } &&
6539          { ac_try='test -s conftest$ac_exeext'
6540   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6541   (eval $ac_try) 2>&5
6542   ac_status=$?
6543   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6544   (exit $ac_status); }; }; then
6545   ac_cv_search_krb5_sendauth="none required"
6546 else
6547   echo "$as_me: failed program was:" >&5
6548 sed 's/^/| /' conftest.$ac_ext >&5
6549
6550 fi
6551 rm -f conftest.err conftest.$ac_objext \
6552       conftest$ac_exeext conftest.$ac_ext
6553 if test "$ac_cv_search_krb5_sendauth" = no; then
6554   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken'; do
6555     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6556     cat >conftest.$ac_ext <<_ACEOF
6557 /* confdefs.h.  */
6558 _ACEOF
6559 cat confdefs.h >>conftest.$ac_ext
6560 cat >>conftest.$ac_ext <<_ACEOF
6561 /* end confdefs.h.  */
6562
6563 /* Override any gcc2 internal prototype to avoid an error.  */
6564 #ifdef __cplusplus
6565 extern "C"
6566 #endif
6567 /* We use char because int might match the return type of a gcc2
6568    builtin and then its argument prototype would still apply.  */
6569 char krb5_sendauth ();
6570 int
6571 main ()
6572 {
6573 krb5_sendauth ();
6574   ;
6575   return 0;
6576 }
6577 _ACEOF
6578 rm -f conftest.$ac_objext conftest$ac_exeext
6579 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6580   (eval $ac_link) 2>conftest.er1
6581   ac_status=$?
6582   grep -v '^ *+' conftest.er1 >conftest.err
6583   rm -f conftest.er1
6584   cat conftest.err >&5
6585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6586   (exit $ac_status); } &&
6587          { ac_try='test -z "$ac_c_werror_flag"
6588                          || test ! -s conftest.err'
6589   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6590   (eval $ac_try) 2>&5
6591   ac_status=$?
6592   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6593   (exit $ac_status); }; } &&
6594          { ac_try='test -s conftest$ac_exeext'
6595   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6596   (eval $ac_try) 2>&5
6597   ac_status=$?
6598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6599   (exit $ac_status); }; }; then
6600   ac_cv_search_krb5_sendauth="-l$ac_lib"
6601 break
6602 else
6603   echo "$as_me: failed program was:" >&5
6604 sed 's/^/| /' conftest.$ac_ext >&5
6605
6606 fi
6607 rm -f conftest.err conftest.$ac_objext \
6608       conftest$ac_exeext conftest.$ac_ext
6609   done
6610 fi
6611 LIBS=$ac_func_search_save_LIBS
6612 fi
6613 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
6614 echo "${ECHO_T}$ac_cv_search_krb5_sendauth" >&6
6615 if test "$ac_cv_search_krb5_sendauth" != no; then
6616   test "$ac_cv_search_krb5_sendauth" = "none required" || LIBS="$ac_cv_search_krb5_sendauth $LIBS"
6617
6618 else
6619   { { echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
6620 echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
6621    { (exit 1); exit 1; }; }
6622 fi
6623
6624   else
6625      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6626 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6627 if test "${ac_cv_search_com_err+set}" = set; then
6628   echo $ECHO_N "(cached) $ECHO_C" >&6
6629 else
6630   ac_func_search_save_LIBS=$LIBS
6631 ac_cv_search_com_err=no
6632 cat >conftest.$ac_ext <<_ACEOF
6633 /* confdefs.h.  */
6634 _ACEOF
6635 cat confdefs.h >>conftest.$ac_ext
6636 cat >>conftest.$ac_ext <<_ACEOF
6637 /* end confdefs.h.  */
6638
6639 /* Override any gcc2 internal prototype to avoid an error.  */
6640 #ifdef __cplusplus
6641 extern "C"
6642 #endif
6643 /* We use char because int might match the return type of a gcc2
6644    builtin and then its argument prototype would still apply.  */
6645 char com_err ();
6646 int
6647 main ()
6648 {
6649 com_err ();
6650   ;
6651   return 0;
6652 }
6653 _ACEOF
6654 rm -f conftest.$ac_objext conftest$ac_exeext
6655 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6656   (eval $ac_link) 2>conftest.er1
6657   ac_status=$?
6658   grep -v '^ *+' conftest.er1 >conftest.err
6659   rm -f conftest.er1
6660   cat conftest.err >&5
6661   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6662   (exit $ac_status); } &&
6663          { ac_try='test -z "$ac_c_werror_flag"
6664                          || test ! -s conftest.err'
6665   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6666   (eval $ac_try) 2>&5
6667   ac_status=$?
6668   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6669   (exit $ac_status); }; } &&
6670          { ac_try='test -s conftest$ac_exeext'
6671   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6672   (eval $ac_try) 2>&5
6673   ac_status=$?
6674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6675   (exit $ac_status); }; }; then
6676   ac_cv_search_com_err="none required"
6677 else
6678   echo "$as_me: failed program was:" >&5
6679 sed 's/^/| /' conftest.$ac_ext >&5
6680
6681 fi
6682 rm -f conftest.err conftest.$ac_objext \
6683       conftest$ac_exeext conftest.$ac_ext
6684 if test "$ac_cv_search_com_err" = no; then
6685   for ac_lib in 'comerr32 -lkrb5_32'; do
6686     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6687     cat >conftest.$ac_ext <<_ACEOF
6688 /* confdefs.h.  */
6689 _ACEOF
6690 cat confdefs.h >>conftest.$ac_ext
6691 cat >>conftest.$ac_ext <<_ACEOF
6692 /* end confdefs.h.  */
6693
6694 /* Override any gcc2 internal prototype to avoid an error.  */
6695 #ifdef __cplusplus
6696 extern "C"
6697 #endif
6698 /* We use char because int might match the return type of a gcc2
6699    builtin and then its argument prototype would still apply.  */
6700 char com_err ();
6701 int
6702 main ()
6703 {
6704 com_err ();
6705   ;
6706   return 0;
6707 }
6708 _ACEOF
6709 rm -f conftest.$ac_objext conftest$ac_exeext
6710 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6711   (eval $ac_link) 2>conftest.er1
6712   ac_status=$?
6713   grep -v '^ *+' conftest.er1 >conftest.err
6714   rm -f conftest.er1
6715   cat conftest.err >&5
6716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6717   (exit $ac_status); } &&
6718          { ac_try='test -z "$ac_c_werror_flag"
6719                          || test ! -s conftest.err'
6720   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6721   (eval $ac_try) 2>&5
6722   ac_status=$?
6723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6724   (exit $ac_status); }; } &&
6725          { ac_try='test -s conftest$ac_exeext'
6726   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6727   (eval $ac_try) 2>&5
6728   ac_status=$?
6729   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6730   (exit $ac_status); }; }; then
6731   ac_cv_search_com_err="-l$ac_lib"
6732 break
6733 else
6734   echo "$as_me: failed program was:" >&5
6735 sed 's/^/| /' conftest.$ac_ext >&5
6736
6737 fi
6738 rm -f conftest.err conftest.$ac_objext \
6739       conftest$ac_exeext conftest.$ac_ext
6740   done
6741 fi
6742 LIBS=$ac_func_search_save_LIBS
6743 fi
6744 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6745 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6746 if test "$ac_cv_search_com_err" != no; then
6747   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6748
6749 else
6750   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6751 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6752    { (exit 1); exit 1; }; }
6753 fi
6754
6755   fi
6756 fi
6757
6758 if test "$with_openssl" = yes ; then
6759     if test "$PORTNAME" != "win32"; then
6760
6761 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
6762 echo $ECHO_N "checking for CRYPTO_new_ex_data in -lcrypto... $ECHO_C" >&6
6763 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
6764   echo $ECHO_N "(cached) $ECHO_C" >&6
6765 else
6766   ac_check_lib_save_LIBS=$LIBS
6767 LIBS="-lcrypto  $LIBS"
6768 cat >conftest.$ac_ext <<_ACEOF
6769 /* confdefs.h.  */
6770 _ACEOF
6771 cat confdefs.h >>conftest.$ac_ext
6772 cat >>conftest.$ac_ext <<_ACEOF
6773 /* end confdefs.h.  */
6774
6775 /* Override any gcc2 internal prototype to avoid an error.  */
6776 #ifdef __cplusplus
6777 extern "C"
6778 #endif
6779 /* We use char because int might match the return type of a gcc2
6780    builtin and then its argument prototype would still apply.  */
6781 char CRYPTO_new_ex_data ();
6782 int
6783 main ()
6784 {
6785 CRYPTO_new_ex_data ();
6786   ;
6787   return 0;
6788 }
6789 _ACEOF
6790 rm -f conftest.$ac_objext conftest$ac_exeext
6791 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6792   (eval $ac_link) 2>conftest.er1
6793   ac_status=$?
6794   grep -v '^ *+' conftest.er1 >conftest.err
6795   rm -f conftest.er1
6796   cat conftest.err >&5
6797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6798   (exit $ac_status); } &&
6799          { ac_try='test -z "$ac_c_werror_flag"
6800                          || test ! -s conftest.err'
6801   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6802   (eval $ac_try) 2>&5
6803   ac_status=$?
6804   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6805   (exit $ac_status); }; } &&
6806          { ac_try='test -s conftest$ac_exeext'
6807   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6808   (eval $ac_try) 2>&5
6809   ac_status=$?
6810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6811   (exit $ac_status); }; }; then
6812   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
6813 else
6814   echo "$as_me: failed program was:" >&5
6815 sed 's/^/| /' conftest.$ac_ext >&5
6816
6817 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
6818 fi
6819 rm -f conftest.err conftest.$ac_objext \
6820       conftest$ac_exeext conftest.$ac_ext
6821 LIBS=$ac_check_lib_save_LIBS
6822 fi
6823 echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
6824 echo "${ECHO_T}$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6
6825 if test $ac_cv_lib_crypto_CRYPTO_new_ex_data = yes; then
6826   cat >>confdefs.h <<_ACEOF
6827 #define HAVE_LIBCRYPTO 1
6828 _ACEOF
6829
6830   LIBS="-lcrypto $LIBS"
6831
6832 else
6833   { { echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
6834 echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
6835    { (exit 1); exit 1; }; }
6836 fi
6837
6838
6839 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
6840 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
6841 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
6842   echo $ECHO_N "(cached) $ECHO_C" >&6
6843 else
6844   ac_check_lib_save_LIBS=$LIBS
6845 LIBS="-lssl  $LIBS"
6846 cat >conftest.$ac_ext <<_ACEOF
6847 /* confdefs.h.  */
6848 _ACEOF
6849 cat confdefs.h >>conftest.$ac_ext
6850 cat >>conftest.$ac_ext <<_ACEOF
6851 /* end confdefs.h.  */
6852
6853 /* Override any gcc2 internal prototype to avoid an error.  */
6854 #ifdef __cplusplus
6855 extern "C"
6856 #endif
6857 /* We use char because int might match the return type of a gcc2
6858    builtin and then its argument prototype would still apply.  */
6859 char SSL_library_init ();
6860 int
6861 main ()
6862 {
6863 SSL_library_init ();
6864   ;
6865   return 0;
6866 }
6867 _ACEOF
6868 rm -f conftest.$ac_objext conftest$ac_exeext
6869 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6870   (eval $ac_link) 2>conftest.er1
6871   ac_status=$?
6872   grep -v '^ *+' conftest.er1 >conftest.err
6873   rm -f conftest.er1
6874   cat conftest.err >&5
6875   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6876   (exit $ac_status); } &&
6877          { ac_try='test -z "$ac_c_werror_flag"
6878                          || test ! -s conftest.err'
6879   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6880   (eval $ac_try) 2>&5
6881   ac_status=$?
6882   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6883   (exit $ac_status); }; } &&
6884          { ac_try='test -s conftest$ac_exeext'
6885   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6886   (eval $ac_try) 2>&5
6887   ac_status=$?
6888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6889   (exit $ac_status); }; }; then
6890   ac_cv_lib_ssl_SSL_library_init=yes
6891 else
6892   echo "$as_me: failed program was:" >&5
6893 sed 's/^/| /' conftest.$ac_ext >&5
6894
6895 ac_cv_lib_ssl_SSL_library_init=no
6896 fi
6897 rm -f conftest.err conftest.$ac_objext \
6898       conftest$ac_exeext conftest.$ac_ext
6899 LIBS=$ac_check_lib_save_LIBS
6900 fi
6901 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
6902 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
6903 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
6904   cat >>confdefs.h <<_ACEOF
6905 #define HAVE_LIBSSL 1
6906 _ACEOF
6907
6908   LIBS="-lssl $LIBS"
6909
6910 else
6911   { { echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
6912 echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
6913    { (exit 1); exit 1; }; }
6914 fi
6915
6916   else
6917
6918 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
6919 echo $ECHO_N "checking for CRYPTO_new_ex_data in -leay32... $ECHO_C" >&6
6920 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
6921   echo $ECHO_N "(cached) $ECHO_C" >&6
6922 else
6923   ac_check_lib_save_LIBS=$LIBS
6924 LIBS="-leay32  $LIBS"
6925 cat >conftest.$ac_ext <<_ACEOF
6926 /* confdefs.h.  */
6927 _ACEOF
6928 cat confdefs.h >>conftest.$ac_ext
6929 cat >>conftest.$ac_ext <<_ACEOF
6930 /* end confdefs.h.  */
6931
6932 /* Override any gcc2 internal prototype to avoid an error.  */
6933 #ifdef __cplusplus
6934 extern "C"
6935 #endif
6936 /* We use char because int might match the return type of a gcc2
6937    builtin and then its argument prototype would still apply.  */
6938 char CRYPTO_new_ex_data ();
6939 int
6940 main ()
6941 {
6942 CRYPTO_new_ex_data ();
6943   ;
6944   return 0;
6945 }
6946 _ACEOF
6947 rm -f conftest.$ac_objext conftest$ac_exeext
6948 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6949   (eval $ac_link) 2>conftest.er1
6950   ac_status=$?
6951   grep -v '^ *+' conftest.er1 >conftest.err
6952   rm -f conftest.er1
6953   cat conftest.err >&5
6954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6955   (exit $ac_status); } &&
6956          { ac_try='test -z "$ac_c_werror_flag"
6957                          || test ! -s conftest.err'
6958   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6959   (eval $ac_try) 2>&5
6960   ac_status=$?
6961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6962   (exit $ac_status); }; } &&
6963          { ac_try='test -s conftest$ac_exeext'
6964   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6965   (eval $ac_try) 2>&5
6966   ac_status=$?
6967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6968   (exit $ac_status); }; }; then
6969   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
6970 else
6971   echo "$as_me: failed program was:" >&5
6972 sed 's/^/| /' conftest.$ac_ext >&5
6973
6974 ac_cv_lib_eay32_CRYPTO_new_ex_data=no
6975 fi
6976 rm -f conftest.err conftest.$ac_objext \
6977       conftest$ac_exeext conftest.$ac_ext
6978 LIBS=$ac_check_lib_save_LIBS
6979 fi
6980 echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
6981 echo "${ECHO_T}$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6
6982 if test $ac_cv_lib_eay32_CRYPTO_new_ex_data = yes; then
6983   cat >>confdefs.h <<_ACEOF
6984 #define HAVE_LIBEAY32 1
6985 _ACEOF
6986
6987   LIBS="-leay32 $LIBS"
6988
6989 else
6990   { { echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
6991 echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
6992    { (exit 1); exit 1; }; }
6993 fi
6994
6995
6996 echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
6997 echo $ECHO_N "checking for SSL_library_init in -lssleay32... $ECHO_C" >&6
6998 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
6999   echo $ECHO_N "(cached) $ECHO_C" >&6
7000 else
7001   ac_check_lib_save_LIBS=$LIBS
7002 LIBS="-lssleay32  $LIBS"
7003 cat >conftest.$ac_ext <<_ACEOF
7004 /* confdefs.h.  */
7005 _ACEOF
7006 cat confdefs.h >>conftest.$ac_ext
7007 cat >>conftest.$ac_ext <<_ACEOF
7008 /* end confdefs.h.  */
7009
7010 /* Override any gcc2 internal prototype to avoid an error.  */
7011 #ifdef __cplusplus
7012 extern "C"
7013 #endif
7014 /* We use char because int might match the return type of a gcc2
7015    builtin and then its argument prototype would still apply.  */
7016 char SSL_library_init ();
7017 int
7018 main ()
7019 {
7020 SSL_library_init ();
7021   ;
7022   return 0;
7023 }
7024 _ACEOF
7025 rm -f conftest.$ac_objext conftest$ac_exeext
7026 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7027   (eval $ac_link) 2>conftest.er1
7028   ac_status=$?
7029   grep -v '^ *+' conftest.er1 >conftest.err
7030   rm -f conftest.er1
7031   cat conftest.err >&5
7032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7033   (exit $ac_status); } &&
7034          { ac_try='test -z "$ac_c_werror_flag"
7035                          || test ! -s conftest.err'
7036   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7037   (eval $ac_try) 2>&5
7038   ac_status=$?
7039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7040   (exit $ac_status); }; } &&
7041          { ac_try='test -s conftest$ac_exeext'
7042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7043   (eval $ac_try) 2>&5
7044   ac_status=$?
7045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7046   (exit $ac_status); }; }; then
7047   ac_cv_lib_ssleay32_SSL_library_init=yes
7048 else
7049   echo "$as_me: failed program was:" >&5
7050 sed 's/^/| /' conftest.$ac_ext >&5
7051
7052 ac_cv_lib_ssleay32_SSL_library_init=no
7053 fi
7054 rm -f conftest.err conftest.$ac_objext \
7055       conftest$ac_exeext conftest.$ac_ext
7056 LIBS=$ac_check_lib_save_LIBS
7057 fi
7058 echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
7059 echo "${ECHO_T}$ac_cv_lib_ssleay32_SSL_library_init" >&6
7060 if test $ac_cv_lib_ssleay32_SSL_library_init = yes; then
7061   cat >>confdefs.h <<_ACEOF
7062 #define HAVE_LIBSSLEAY32 1
7063 _ACEOF
7064
7065   LIBS="-lssleay32 $LIBS"
7066
7067 else
7068   { { echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
7069 echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
7070    { (exit 1); exit 1; }; }
7071 fi
7072
7073   fi
7074 fi
7075
7076 if test "$with_pam" = yes ; then
7077
7078 echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
7079 echo $ECHO_N "checking for pam_start in -lpam... $ECHO_C" >&6
7080 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
7081   echo $ECHO_N "(cached) $ECHO_C" >&6
7082 else
7083   ac_check_lib_save_LIBS=$LIBS
7084 LIBS="-lpam  $LIBS"
7085 cat >conftest.$ac_ext <<_ACEOF
7086 /* confdefs.h.  */
7087 _ACEOF
7088 cat confdefs.h >>conftest.$ac_ext
7089 cat >>conftest.$ac_ext <<_ACEOF
7090 /* end confdefs.h.  */
7091
7092 /* Override any gcc2 internal prototype to avoid an error.  */
7093 #ifdef __cplusplus
7094 extern "C"
7095 #endif
7096 /* We use char because int might match the return type of a gcc2
7097    builtin and then its argument prototype would still apply.  */
7098 char pam_start ();
7099 int
7100 main ()
7101 {
7102 pam_start ();
7103   ;
7104   return 0;
7105 }
7106 _ACEOF
7107 rm -f conftest.$ac_objext conftest$ac_exeext
7108 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7109   (eval $ac_link) 2>conftest.er1
7110   ac_status=$?
7111   grep -v '^ *+' conftest.er1 >conftest.err
7112   rm -f conftest.er1
7113   cat conftest.err >&5
7114   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7115   (exit $ac_status); } &&
7116          { ac_try='test -z "$ac_c_werror_flag"
7117                          || test ! -s conftest.err'
7118   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7119   (eval $ac_try) 2>&5
7120   ac_status=$?
7121   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7122   (exit $ac_status); }; } &&
7123          { ac_try='test -s conftest$ac_exeext'
7124   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7125   (eval $ac_try) 2>&5
7126   ac_status=$?
7127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7128   (exit $ac_status); }; }; then
7129   ac_cv_lib_pam_pam_start=yes
7130 else
7131   echo "$as_me: failed program was:" >&5
7132 sed 's/^/| /' conftest.$ac_ext >&5
7133
7134 ac_cv_lib_pam_pam_start=no
7135 fi
7136 rm -f conftest.err conftest.$ac_objext \
7137       conftest$ac_exeext conftest.$ac_ext
7138 LIBS=$ac_check_lib_save_LIBS
7139 fi
7140 echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
7141 echo "${ECHO_T}$ac_cv_lib_pam_pam_start" >&6
7142 if test $ac_cv_lib_pam_pam_start = yes; then
7143   cat >>confdefs.h <<_ACEOF
7144 #define HAVE_LIBPAM 1
7145 _ACEOF
7146
7147   LIBS="-lpam $LIBS"
7148
7149 else
7150   { { echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
7151 echo "$as_me: error: library 'pam' is required for PAM" >&2;}
7152    { (exit 1); exit 1; }; }
7153 fi
7154
7155 fi
7156
7157
7158 ##
7159 ## Header files
7160 ##
7161
7162 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
7163 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
7164 if test "${ac_cv_header_stdc+set}" = set; then
7165   echo $ECHO_N "(cached) $ECHO_C" >&6
7166 else
7167   cat >conftest.$ac_ext <<_ACEOF
7168 /* confdefs.h.  */
7169 _ACEOF
7170 cat confdefs.h >>conftest.$ac_ext
7171 cat >>conftest.$ac_ext <<_ACEOF
7172 /* end confdefs.h.  */
7173 #include <stdlib.h>
7174 #include <stdarg.h>
7175 #include <string.h>
7176 #include <float.h>
7177
7178 int
7179 main ()
7180 {
7181
7182   ;
7183   return 0;
7184 }
7185 _ACEOF
7186 rm -f conftest.$ac_objext
7187 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7188   (eval $ac_compile) 2>conftest.er1
7189   ac_status=$?
7190   grep -v '^ *+' conftest.er1 >conftest.err
7191   rm -f conftest.er1
7192   cat conftest.err >&5
7193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7194   (exit $ac_status); } &&
7195          { ac_try='test -z "$ac_c_werror_flag"
7196                          || test ! -s conftest.err'
7197   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7198   (eval $ac_try) 2>&5
7199   ac_status=$?
7200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7201   (exit $ac_status); }; } &&
7202          { ac_try='test -s conftest.$ac_objext'
7203   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7204   (eval $ac_try) 2>&5
7205   ac_status=$?
7206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7207   (exit $ac_status); }; }; then
7208   ac_cv_header_stdc=yes
7209 else
7210   echo "$as_me: failed program was:" >&5
7211 sed 's/^/| /' conftest.$ac_ext >&5
7212
7213 ac_cv_header_stdc=no
7214 fi
7215 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7216
7217 if test $ac_cv_header_stdc = yes; then
7218   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7219   cat >conftest.$ac_ext <<_ACEOF
7220 /* confdefs.h.  */
7221 _ACEOF
7222 cat confdefs.h >>conftest.$ac_ext
7223 cat >>conftest.$ac_ext <<_ACEOF
7224 /* end confdefs.h.  */
7225 #include <string.h>
7226
7227 _ACEOF
7228 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7229   $EGREP "memchr" >/dev/null 2>&1; then
7230   :
7231 else
7232   ac_cv_header_stdc=no
7233 fi
7234 rm -f conftest*
7235
7236 fi
7237
7238 if test $ac_cv_header_stdc = yes; then
7239   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7240   cat >conftest.$ac_ext <<_ACEOF
7241 /* confdefs.h.  */
7242 _ACEOF
7243 cat confdefs.h >>conftest.$ac_ext
7244 cat >>conftest.$ac_ext <<_ACEOF
7245 /* end confdefs.h.  */
7246 #include <stdlib.h>
7247
7248 _ACEOF
7249 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7250   $EGREP "free" >/dev/null 2>&1; then
7251   :
7252 else
7253   ac_cv_header_stdc=no
7254 fi
7255 rm -f conftest*
7256
7257 fi
7258
7259 if test $ac_cv_header_stdc = yes; then
7260   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7261   if test "$cross_compiling" = yes; then
7262   :
7263 else
7264   cat >conftest.$ac_ext <<_ACEOF
7265 /* confdefs.h.  */
7266 _ACEOF
7267 cat confdefs.h >>conftest.$ac_ext
7268 cat >>conftest.$ac_ext <<_ACEOF
7269 /* end confdefs.h.  */
7270 #include <ctype.h>
7271 #if ((' ' & 0x0FF) == 0x020)
7272 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7273 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7274 #else
7275 # define ISLOWER(c) \
7276                    (('a' <= (c) && (c) <= 'i') \
7277                      || ('j' <= (c) && (c) <= 'r') \
7278                      || ('s' <= (c) && (c) <= 'z'))
7279 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7280 #endif
7281
7282 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7283 int
7284 main ()
7285 {
7286   int i;
7287   for (i = 0; i < 256; i++)
7288     if (XOR (islower (i), ISLOWER (i))
7289         || toupper (i) != TOUPPER (i))
7290       exit(2);
7291   exit (0);
7292 }
7293 _ACEOF
7294 rm -f conftest$ac_exeext
7295 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7296   (eval $ac_link) 2>&5
7297   ac_status=$?
7298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7299   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7300   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7301   (eval $ac_try) 2>&5
7302   ac_status=$?
7303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7304   (exit $ac_status); }; }; then
7305   :
7306 else
7307   echo "$as_me: program exited with status $ac_status" >&5
7308 echo "$as_me: failed program was:" >&5
7309 sed 's/^/| /' conftest.$ac_ext >&5
7310
7311 ( exit $ac_status )
7312 ac_cv_header_stdc=no
7313 fi
7314 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7315 fi
7316 fi
7317 fi
7318 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
7319 echo "${ECHO_T}$ac_cv_header_stdc" >&6
7320 if test $ac_cv_header_stdc = yes; then
7321
7322 cat >>confdefs.h <<\_ACEOF
7323 #define STDC_HEADERS 1
7324 _ACEOF
7325
7326 fi
7327
7328 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
7329
7330
7331
7332
7333
7334
7335
7336
7337
7338 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7339                   inttypes.h stdint.h unistd.h
7340 do
7341 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7342 echo "$as_me:$LINENO: checking for $ac_header" >&5
7343 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7344 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7345   echo $ECHO_N "(cached) $ECHO_C" >&6
7346 else
7347   cat >conftest.$ac_ext <<_ACEOF
7348 /* confdefs.h.  */
7349 _ACEOF
7350 cat confdefs.h >>conftest.$ac_ext
7351 cat >>conftest.$ac_ext <<_ACEOF
7352 /* end confdefs.h.  */
7353 $ac_includes_default
7354
7355 #include <$ac_header>
7356 _ACEOF
7357 rm -f conftest.$ac_objext
7358 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7359   (eval $ac_compile) 2>conftest.er1
7360   ac_status=$?
7361   grep -v '^ *+' conftest.er1 >conftest.err
7362   rm -f conftest.er1
7363   cat conftest.err >&5
7364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7365   (exit $ac_status); } &&
7366          { ac_try='test -z "$ac_c_werror_flag"
7367                          || test ! -s conftest.err'
7368   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7369   (eval $ac_try) 2>&5
7370   ac_status=$?
7371   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7372   (exit $ac_status); }; } &&
7373          { ac_try='test -s conftest.$ac_objext'
7374   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7375   (eval $ac_try) 2>&5
7376   ac_status=$?
7377   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7378   (exit $ac_status); }; }; then
7379   eval "$as_ac_Header=yes"
7380 else
7381   echo "$as_me: failed program was:" >&5
7382 sed 's/^/| /' conftest.$ac_ext >&5
7383
7384 eval "$as_ac_Header=no"
7385 fi
7386 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7387 fi
7388 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7389 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7390 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7391   cat >>confdefs.h <<_ACEOF
7392 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7393 _ACEOF
7394
7395 fi
7396
7397 done
7398
7399
7400
7401
7402
7403
7404
7405
7406
7407
7408
7409
7410
7411
7412
7413
7414
7415
7416
7417
7418
7419
7420
7421
7422
7423
7424
7425 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
7426 do
7427 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7428 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7429   echo "$as_me:$LINENO: checking for $ac_header" >&5
7430 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7431 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7432   echo $ECHO_N "(cached) $ECHO_C" >&6
7433 fi
7434 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7435 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7436 else
7437   # Is the header compilable?
7438 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7439 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7440 cat >conftest.$ac_ext <<_ACEOF
7441 /* confdefs.h.  */
7442 _ACEOF
7443 cat confdefs.h >>conftest.$ac_ext
7444 cat >>conftest.$ac_ext <<_ACEOF
7445 /* end confdefs.h.  */
7446 $ac_includes_default
7447 #include <$ac_header>
7448 _ACEOF
7449 rm -f conftest.$ac_objext
7450 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7451   (eval $ac_compile) 2>conftest.er1
7452   ac_status=$?
7453   grep -v '^ *+' conftest.er1 >conftest.err
7454   rm -f conftest.er1
7455   cat conftest.err >&5
7456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7457   (exit $ac_status); } &&
7458          { ac_try='test -z "$ac_c_werror_flag"
7459                          || test ! -s conftest.err'
7460   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7461   (eval $ac_try) 2>&5
7462   ac_status=$?
7463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7464   (exit $ac_status); }; } &&
7465          { ac_try='test -s conftest.$ac_objext'
7466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7467   (eval $ac_try) 2>&5
7468   ac_status=$?
7469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7470   (exit $ac_status); }; }; then
7471   ac_header_compiler=yes
7472 else
7473   echo "$as_me: failed program was:" >&5
7474 sed 's/^/| /' conftest.$ac_ext >&5
7475
7476 ac_header_compiler=no
7477 fi
7478 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7479 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7480 echo "${ECHO_T}$ac_header_compiler" >&6
7481
7482 # Is the header present?
7483 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7484 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7485 cat >conftest.$ac_ext <<_ACEOF
7486 /* confdefs.h.  */
7487 _ACEOF
7488 cat confdefs.h >>conftest.$ac_ext
7489 cat >>conftest.$ac_ext <<_ACEOF
7490 /* end confdefs.h.  */
7491 #include <$ac_header>
7492 _ACEOF
7493 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7494   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7495   ac_status=$?
7496   grep -v '^ *+' conftest.er1 >conftest.err
7497   rm -f conftest.er1
7498   cat conftest.err >&5
7499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7500   (exit $ac_status); } >/dev/null; then
7501   if test -s conftest.err; then
7502     ac_cpp_err=$ac_c_preproc_warn_flag
7503     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7504   else
7505     ac_cpp_err=
7506   fi
7507 else
7508   ac_cpp_err=yes
7509 fi
7510 if test -z "$ac_cpp_err"; then
7511   ac_header_preproc=yes
7512 else
7513   echo "$as_me: failed program was:" >&5
7514 sed 's/^/| /' conftest.$ac_ext >&5
7515
7516   ac_header_preproc=no
7517 fi
7518 rm -f conftest.err conftest.$ac_ext
7519 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7520 echo "${ECHO_T}$ac_header_preproc" >&6
7521
7522 # So?  What about this header?
7523 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7524   yes:no: )
7525     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7526 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7527     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7528 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7529     ac_header_preproc=yes
7530     ;;
7531   no:yes:* )
7532     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7533 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7534     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7535 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7536     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7537 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7538     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7539 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7540     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7541 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7542     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7543 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7544     (
7545       cat <<\_ASBOX
7546 ## ---------------------------------------- ##
7547 ## Report this to pgsql-bugs@postgresql.org ##
7548 ## ---------------------------------------- ##
7549 _ASBOX
7550     ) |
7551       sed "s/^/$as_me: WARNING:     /" >&2
7552     ;;
7553 esac
7554 echo "$as_me:$LINENO: checking for $ac_header" >&5
7555 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7556 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7557   echo $ECHO_N "(cached) $ECHO_C" >&6
7558 else
7559   eval "$as_ac_Header=\$ac_header_preproc"
7560 fi
7561 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7562 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7563
7564 fi
7565 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7566   cat >>confdefs.h <<_ACEOF
7567 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7568 _ACEOF
7569
7570 fi
7571
7572 done
7573
7574
7575 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
7576 # netinet/in.h is included first.
7577
7578 for ac_header in netinet/in.h
7579 do
7580 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7581 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7582   echo "$as_me:$LINENO: checking for $ac_header" >&5
7583 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7584 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7585   echo $ECHO_N "(cached) $ECHO_C" >&6
7586 fi
7587 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7588 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7589 else
7590   # Is the header compilable?
7591 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7592 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7593 cat >conftest.$ac_ext <<_ACEOF
7594 /* confdefs.h.  */
7595 _ACEOF
7596 cat confdefs.h >>conftest.$ac_ext
7597 cat >>conftest.$ac_ext <<_ACEOF
7598 /* end confdefs.h.  */
7599 $ac_includes_default
7600 #include <$ac_header>
7601 _ACEOF
7602 rm -f conftest.$ac_objext
7603 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7604   (eval $ac_compile) 2>conftest.er1
7605   ac_status=$?
7606   grep -v '^ *+' conftest.er1 >conftest.err
7607   rm -f conftest.er1
7608   cat conftest.err >&5
7609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7610   (exit $ac_status); } &&
7611          { ac_try='test -z "$ac_c_werror_flag"
7612                          || test ! -s conftest.err'
7613   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7614   (eval $ac_try) 2>&5
7615   ac_status=$?
7616   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7617   (exit $ac_status); }; } &&
7618          { ac_try='test -s conftest.$ac_objext'
7619   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7620   (eval $ac_try) 2>&5
7621   ac_status=$?
7622   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7623   (exit $ac_status); }; }; then
7624   ac_header_compiler=yes
7625 else
7626   echo "$as_me: failed program was:" >&5
7627 sed 's/^/| /' conftest.$ac_ext >&5
7628
7629 ac_header_compiler=no
7630 fi
7631 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7632 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7633 echo "${ECHO_T}$ac_header_compiler" >&6
7634
7635 # Is the header present?
7636 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7637 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7638 cat >conftest.$ac_ext <<_ACEOF
7639 /* confdefs.h.  */
7640 _ACEOF
7641 cat confdefs.h >>conftest.$ac_ext
7642 cat >>conftest.$ac_ext <<_ACEOF
7643 /* end confdefs.h.  */
7644 #include <$ac_header>
7645 _ACEOF
7646 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7647   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7648   ac_status=$?
7649   grep -v '^ *+' conftest.er1 >conftest.err
7650   rm -f conftest.er1
7651   cat conftest.err >&5
7652   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7653   (exit $ac_status); } >/dev/null; then
7654   if test -s conftest.err; then
7655     ac_cpp_err=$ac_c_preproc_warn_flag
7656     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7657   else
7658     ac_cpp_err=
7659   fi
7660 else
7661   ac_cpp_err=yes
7662 fi
7663 if test -z "$ac_cpp_err"; then
7664   ac_header_preproc=yes
7665 else
7666   echo "$as_me: failed program was:" >&5
7667 sed 's/^/| /' conftest.$ac_ext >&5
7668
7669   ac_header_preproc=no
7670 fi
7671 rm -f conftest.err conftest.$ac_ext
7672 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7673 echo "${ECHO_T}$ac_header_preproc" >&6
7674
7675 # So?  What about this header?
7676 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7677   yes:no: )
7678     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7679 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7680     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7681 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7682     ac_header_preproc=yes
7683     ;;
7684   no:yes:* )
7685     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7686 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7687     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7688 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7689     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7690 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7691     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7692 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7693     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7694 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7695     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7696 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7697     (
7698       cat <<\_ASBOX
7699 ## ---------------------------------------- ##
7700 ## Report this to pgsql-bugs@postgresql.org ##
7701 ## ---------------------------------------- ##
7702 _ASBOX
7703     ) |
7704       sed "s/^/$as_me: WARNING:     /" >&2
7705     ;;
7706 esac
7707 echo "$as_me:$LINENO: checking for $ac_header" >&5
7708 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7709 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7710   echo $ECHO_N "(cached) $ECHO_C" >&6
7711 else
7712   eval "$as_ac_Header=\$ac_header_preproc"
7713 fi
7714 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7715 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7716
7717 fi
7718 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7719   cat >>confdefs.h <<_ACEOF
7720 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7721 _ACEOF
7722
7723 fi
7724
7725 done
7726
7727
7728 for ac_header in netinet/tcp.h
7729 do
7730 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7731 echo "$as_me:$LINENO: checking for $ac_header" >&5
7732 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7733 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7734   echo $ECHO_N "(cached) $ECHO_C" >&6
7735 else
7736   cat >conftest.$ac_ext <<_ACEOF
7737 /* confdefs.h.  */
7738 _ACEOF
7739 cat confdefs.h >>conftest.$ac_ext
7740 cat >>conftest.$ac_ext <<_ACEOF
7741 /* end confdefs.h.  */
7742 $ac_includes_default
7743 #ifdef HAVE_NETINET_IN_H
7744 #include <netinet/in.h>
7745 #endif
7746
7747
7748 #include <$ac_header>
7749 _ACEOF
7750 rm -f conftest.$ac_objext
7751 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7752   (eval $ac_compile) 2>conftest.er1
7753   ac_status=$?
7754   grep -v '^ *+' conftest.er1 >conftest.err
7755   rm -f conftest.er1
7756   cat conftest.err >&5
7757   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7758   (exit $ac_status); } &&
7759          { ac_try='test -z "$ac_c_werror_flag"
7760                          || test ! -s conftest.err'
7761   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7762   (eval $ac_try) 2>&5
7763   ac_status=$?
7764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7765   (exit $ac_status); }; } &&
7766          { ac_try='test -s conftest.$ac_objext'
7767   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7768   (eval $ac_try) 2>&5
7769   ac_status=$?
7770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7771   (exit $ac_status); }; }; then
7772   eval "$as_ac_Header=yes"
7773 else
7774   echo "$as_me: failed program was:" >&5
7775 sed 's/^/| /' conftest.$ac_ext >&5
7776
7777 eval "$as_ac_Header=no"
7778 fi
7779 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7780 fi
7781 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7782 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7783 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7784   cat >>confdefs.h <<_ACEOF
7785 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7786 _ACEOF
7787
7788 fi
7789
7790 done
7791
7792
7793 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
7794
7795 for ac_header in readline/readline.h
7796 do
7797 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7798 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7799   echo "$as_me:$LINENO: checking for $ac_header" >&5
7800 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7801 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7802   echo $ECHO_N "(cached) $ECHO_C" >&6
7803 fi
7804 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7805 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7806 else
7807   # Is the header compilable?
7808 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7809 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7810 cat >conftest.$ac_ext <<_ACEOF
7811 /* confdefs.h.  */
7812 _ACEOF
7813 cat confdefs.h >>conftest.$ac_ext
7814 cat >>conftest.$ac_ext <<_ACEOF
7815 /* end confdefs.h.  */
7816 $ac_includes_default
7817 #include <$ac_header>
7818 _ACEOF
7819 rm -f conftest.$ac_objext
7820 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7821   (eval $ac_compile) 2>conftest.er1
7822   ac_status=$?
7823   grep -v '^ *+' conftest.er1 >conftest.err
7824   rm -f conftest.er1
7825   cat conftest.err >&5
7826   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7827   (exit $ac_status); } &&
7828          { ac_try='test -z "$ac_c_werror_flag"
7829                          || test ! -s conftest.err'
7830   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7831   (eval $ac_try) 2>&5
7832   ac_status=$?
7833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7834   (exit $ac_status); }; } &&
7835          { ac_try='test -s conftest.$ac_objext'
7836   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7837   (eval $ac_try) 2>&5
7838   ac_status=$?
7839   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7840   (exit $ac_status); }; }; then
7841   ac_header_compiler=yes
7842 else
7843   echo "$as_me: failed program was:" >&5
7844 sed 's/^/| /' conftest.$ac_ext >&5
7845
7846 ac_header_compiler=no
7847 fi
7848 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7849 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7850 echo "${ECHO_T}$ac_header_compiler" >&6
7851
7852 # Is the header present?
7853 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7854 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7855 cat >conftest.$ac_ext <<_ACEOF
7856 /* confdefs.h.  */
7857 _ACEOF
7858 cat confdefs.h >>conftest.$ac_ext
7859 cat >>conftest.$ac_ext <<_ACEOF
7860 /* end confdefs.h.  */
7861 #include <$ac_header>
7862 _ACEOF
7863 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7864   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7865   ac_status=$?
7866   grep -v '^ *+' conftest.er1 >conftest.err
7867   rm -f conftest.er1
7868   cat conftest.err >&5
7869   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7870   (exit $ac_status); } >/dev/null; then
7871   if test -s conftest.err; then
7872     ac_cpp_err=$ac_c_preproc_warn_flag
7873     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7874   else
7875     ac_cpp_err=
7876   fi
7877 else
7878   ac_cpp_err=yes
7879 fi
7880 if test -z "$ac_cpp_err"; then
7881   ac_header_preproc=yes
7882 else
7883   echo "$as_me: failed program was:" >&5
7884 sed 's/^/| /' conftest.$ac_ext >&5
7885
7886   ac_header_preproc=no
7887 fi
7888 rm -f conftest.err conftest.$ac_ext
7889 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7890 echo "${ECHO_T}$ac_header_preproc" >&6
7891
7892 # So?  What about this header?
7893 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7894   yes:no: )
7895     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7896 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7897     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7898 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7899     ac_header_preproc=yes
7900     ;;
7901   no:yes:* )
7902     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7903 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7904     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7905 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7906     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7907 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7908     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7909 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7910     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7911 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7912     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7913 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7914     (
7915       cat <<\_ASBOX
7916 ## ---------------------------------------- ##
7917 ## Report this to pgsql-bugs@postgresql.org ##
7918 ## ---------------------------------------- ##
7919 _ASBOX
7920     ) |
7921       sed "s/^/$as_me: WARNING:     /" >&2
7922     ;;
7923 esac
7924 echo "$as_me:$LINENO: checking for $ac_header" >&5
7925 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7926 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7927   echo $ECHO_N "(cached) $ECHO_C" >&6
7928 else
7929   eval "$as_ac_Header=\$ac_header_preproc"
7930 fi
7931 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7932 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7933
7934 fi
7935 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7936   cat >>confdefs.h <<_ACEOF
7937 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7938 _ACEOF
7939
7940 else
7941
7942 for ac_header in readline.h
7943 do
7944 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7945 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7946   echo "$as_me:$LINENO: checking for $ac_header" >&5
7947 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7948 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7949   echo $ECHO_N "(cached) $ECHO_C" >&6
7950 fi
7951 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7952 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7953 else
7954   # Is the header compilable?
7955 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7956 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7957 cat >conftest.$ac_ext <<_ACEOF
7958 /* confdefs.h.  */
7959 _ACEOF
7960 cat confdefs.h >>conftest.$ac_ext
7961 cat >>conftest.$ac_ext <<_ACEOF
7962 /* end confdefs.h.  */
7963 $ac_includes_default
7964 #include <$ac_header>
7965 _ACEOF
7966 rm -f conftest.$ac_objext
7967 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7968   (eval $ac_compile) 2>conftest.er1
7969   ac_status=$?
7970   grep -v '^ *+' conftest.er1 >conftest.err
7971   rm -f conftest.er1
7972   cat conftest.err >&5
7973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7974   (exit $ac_status); } &&
7975          { ac_try='test -z "$ac_c_werror_flag"
7976                          || test ! -s conftest.err'
7977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7978   (eval $ac_try) 2>&5
7979   ac_status=$?
7980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7981   (exit $ac_status); }; } &&
7982          { ac_try='test -s conftest.$ac_objext'
7983   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7984   (eval $ac_try) 2>&5
7985   ac_status=$?
7986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7987   (exit $ac_status); }; }; then
7988   ac_header_compiler=yes
7989 else
7990   echo "$as_me: failed program was:" >&5
7991 sed 's/^/| /' conftest.$ac_ext >&5
7992
7993 ac_header_compiler=no
7994 fi
7995 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7996 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7997 echo "${ECHO_T}$ac_header_compiler" >&6
7998
7999 # Is the header present?
8000 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8001 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8002 cat >conftest.$ac_ext <<_ACEOF
8003 /* confdefs.h.  */
8004 _ACEOF
8005 cat confdefs.h >>conftest.$ac_ext
8006 cat >>conftest.$ac_ext <<_ACEOF
8007 /* end confdefs.h.  */
8008 #include <$ac_header>
8009 _ACEOF
8010 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8011   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8012   ac_status=$?
8013   grep -v '^ *+' conftest.er1 >conftest.err
8014   rm -f conftest.er1
8015   cat conftest.err >&5
8016   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8017   (exit $ac_status); } >/dev/null; then
8018   if test -s conftest.err; then
8019     ac_cpp_err=$ac_c_preproc_warn_flag
8020     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8021   else
8022     ac_cpp_err=
8023   fi
8024 else
8025   ac_cpp_err=yes
8026 fi
8027 if test -z "$ac_cpp_err"; then
8028   ac_header_preproc=yes
8029 else
8030   echo "$as_me: failed program was:" >&5
8031 sed 's/^/| /' conftest.$ac_ext >&5
8032
8033   ac_header_preproc=no
8034 fi
8035 rm -f conftest.err conftest.$ac_ext
8036 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8037 echo "${ECHO_T}$ac_header_preproc" >&6
8038
8039 # So?  What about this header?
8040 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8041   yes:no: )
8042     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8043 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8044     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8045 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8046     ac_header_preproc=yes
8047     ;;
8048   no:yes:* )
8049     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8050 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8051     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8052 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8053     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8054 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8055     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8056 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8057     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8058 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8059     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8060 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8061     (
8062       cat <<\_ASBOX
8063 ## ---------------------------------------- ##
8064 ## Report this to pgsql-bugs@postgresql.org ##
8065 ## ---------------------------------------- ##
8066 _ASBOX
8067     ) |
8068       sed "s/^/$as_me: WARNING:     /" >&2
8069     ;;
8070 esac
8071 echo "$as_me:$LINENO: checking for $ac_header" >&5
8072 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8073 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8074   echo $ECHO_N "(cached) $ECHO_C" >&6
8075 else
8076   eval "$as_ac_Header=\$ac_header_preproc"
8077 fi
8078 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8079 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8080
8081 fi
8082 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8083   cat >>confdefs.h <<_ACEOF
8084 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8085 _ACEOF
8086
8087 else
8088   { { echo "$as_me:$LINENO: error: readline header not found
8089 If you have readline already installed, see config.log for details on the
8090 failure.  It is possible the compiler isn't looking in the proper directory.
8091 Use --without-readline to disable readline support." >&5
8092 echo "$as_me: error: readline header not found
8093 If you have readline already installed, see config.log for details on the
8094 failure.  It is possible the compiler isn't looking in the proper directory.
8095 Use --without-readline to disable readline support." >&2;}
8096    { (exit 1); exit 1; }; }
8097 fi
8098
8099 done
8100
8101 fi
8102
8103 done
8104
8105
8106 for ac_header in readline/history.h
8107 do
8108 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8109 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8110   echo "$as_me:$LINENO: checking for $ac_header" >&5
8111 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8112 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8113   echo $ECHO_N "(cached) $ECHO_C" >&6
8114 fi
8115 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8116 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8117 else
8118   # Is the header compilable?
8119 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8120 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8121 cat >conftest.$ac_ext <<_ACEOF
8122 /* confdefs.h.  */
8123 _ACEOF
8124 cat confdefs.h >>conftest.$ac_ext
8125 cat >>conftest.$ac_ext <<_ACEOF
8126 /* end confdefs.h.  */
8127 $ac_includes_default
8128 #include <$ac_header>
8129 _ACEOF
8130 rm -f conftest.$ac_objext
8131 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8132   (eval $ac_compile) 2>conftest.er1
8133   ac_status=$?
8134   grep -v '^ *+' conftest.er1 >conftest.err
8135   rm -f conftest.er1
8136   cat conftest.err >&5
8137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8138   (exit $ac_status); } &&
8139          { ac_try='test -z "$ac_c_werror_flag"
8140                          || test ! -s conftest.err'
8141   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8142   (eval $ac_try) 2>&5
8143   ac_status=$?
8144   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8145   (exit $ac_status); }; } &&
8146          { ac_try='test -s conftest.$ac_objext'
8147   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8148   (eval $ac_try) 2>&5
8149   ac_status=$?
8150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8151   (exit $ac_status); }; }; then
8152   ac_header_compiler=yes
8153 else
8154   echo "$as_me: failed program was:" >&5
8155 sed 's/^/| /' conftest.$ac_ext >&5
8156
8157 ac_header_compiler=no
8158 fi
8159 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8160 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8161 echo "${ECHO_T}$ac_header_compiler" >&6
8162
8163 # Is the header present?
8164 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8165 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8166 cat >conftest.$ac_ext <<_ACEOF
8167 /* confdefs.h.  */
8168 _ACEOF
8169 cat confdefs.h >>conftest.$ac_ext
8170 cat >>conftest.$ac_ext <<_ACEOF
8171 /* end confdefs.h.  */
8172 #include <$ac_header>
8173 _ACEOF
8174 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8175   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8176   ac_status=$?
8177   grep -v '^ *+' conftest.er1 >conftest.err
8178   rm -f conftest.er1
8179   cat conftest.err >&5
8180   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8181   (exit $ac_status); } >/dev/null; then
8182   if test -s conftest.err; then
8183     ac_cpp_err=$ac_c_preproc_warn_flag
8184     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8185   else
8186     ac_cpp_err=
8187   fi
8188 else
8189   ac_cpp_err=yes
8190 fi
8191 if test -z "$ac_cpp_err"; then
8192   ac_header_preproc=yes
8193 else
8194   echo "$as_me: failed program was:" >&5
8195 sed 's/^/| /' conftest.$ac_ext >&5
8196
8197   ac_header_preproc=no
8198 fi
8199 rm -f conftest.err conftest.$ac_ext
8200 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8201 echo "${ECHO_T}$ac_header_preproc" >&6
8202
8203 # So?  What about this header?
8204 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8205   yes:no: )
8206     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8207 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8208     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8209 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8210     ac_header_preproc=yes
8211     ;;
8212   no:yes:* )
8213     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8214 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8215     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8216 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8217     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8218 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8219     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8220 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8221     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8222 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8223     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8224 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8225     (
8226       cat <<\_ASBOX
8227 ## ---------------------------------------- ##
8228 ## Report this to pgsql-bugs@postgresql.org ##
8229 ## ---------------------------------------- ##
8230 _ASBOX
8231     ) |
8232       sed "s/^/$as_me: WARNING:     /" >&2
8233     ;;
8234 esac
8235 echo "$as_me:$LINENO: checking for $ac_header" >&5
8236 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8237 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8238   echo $ECHO_N "(cached) $ECHO_C" >&6
8239 else
8240   eval "$as_ac_Header=\$ac_header_preproc"
8241 fi
8242 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8243 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8244
8245 fi
8246 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8247   cat >>confdefs.h <<_ACEOF
8248 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8249 _ACEOF
8250
8251 else
8252
8253 for ac_header in history.h
8254 do
8255 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8256 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8257   echo "$as_me:$LINENO: checking for $ac_header" >&5
8258 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8259 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8260   echo $ECHO_N "(cached) $ECHO_C" >&6
8261 fi
8262 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8263 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8264 else
8265   # Is the header compilable?
8266 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8267 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8268 cat >conftest.$ac_ext <<_ACEOF
8269 /* confdefs.h.  */
8270 _ACEOF
8271 cat confdefs.h >>conftest.$ac_ext
8272 cat >>conftest.$ac_ext <<_ACEOF
8273 /* end confdefs.h.  */
8274 $ac_includes_default
8275 #include <$ac_header>
8276 _ACEOF
8277 rm -f conftest.$ac_objext
8278 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8279   (eval $ac_compile) 2>conftest.er1
8280   ac_status=$?
8281   grep -v '^ *+' conftest.er1 >conftest.err
8282   rm -f conftest.er1
8283   cat conftest.err >&5
8284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8285   (exit $ac_status); } &&
8286          { ac_try='test -z "$ac_c_werror_flag"
8287                          || test ! -s conftest.err'
8288   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8289   (eval $ac_try) 2>&5
8290   ac_status=$?
8291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8292   (exit $ac_status); }; } &&
8293          { ac_try='test -s conftest.$ac_objext'
8294   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8295   (eval $ac_try) 2>&5
8296   ac_status=$?
8297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8298   (exit $ac_status); }; }; then
8299   ac_header_compiler=yes
8300 else
8301   echo "$as_me: failed program was:" >&5
8302 sed 's/^/| /' conftest.$ac_ext >&5
8303
8304 ac_header_compiler=no
8305 fi
8306 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8307 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8308 echo "${ECHO_T}$ac_header_compiler" >&6
8309
8310 # Is the header present?
8311 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8312 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8313 cat >conftest.$ac_ext <<_ACEOF
8314 /* confdefs.h.  */
8315 _ACEOF
8316 cat confdefs.h >>conftest.$ac_ext
8317 cat >>conftest.$ac_ext <<_ACEOF
8318 /* end confdefs.h.  */
8319 #include <$ac_header>
8320 _ACEOF
8321 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8322   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8323   ac_status=$?
8324   grep -v '^ *+' conftest.er1 >conftest.err
8325   rm -f conftest.er1
8326   cat conftest.err >&5
8327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8328   (exit $ac_status); } >/dev/null; then
8329   if test -s conftest.err; then
8330     ac_cpp_err=$ac_c_preproc_warn_flag
8331     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8332   else
8333     ac_cpp_err=
8334   fi
8335 else
8336   ac_cpp_err=yes
8337 fi
8338 if test -z "$ac_cpp_err"; then
8339   ac_header_preproc=yes
8340 else
8341   echo "$as_me: failed program was:" >&5
8342 sed 's/^/| /' conftest.$ac_ext >&5
8343
8344   ac_header_preproc=no
8345 fi
8346 rm -f conftest.err conftest.$ac_ext
8347 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8348 echo "${ECHO_T}$ac_header_preproc" >&6
8349
8350 # So?  What about this header?
8351 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8352   yes:no: )
8353     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8354 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8355     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8356 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8357     ac_header_preproc=yes
8358     ;;
8359   no:yes:* )
8360     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8361 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8362     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8363 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8364     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8365 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8366     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8367 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8368     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8369 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8370     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8371 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8372     (
8373       cat <<\_ASBOX
8374 ## ---------------------------------------- ##
8375 ## Report this to pgsql-bugs@postgresql.org ##
8376 ## ---------------------------------------- ##
8377 _ASBOX
8378     ) |
8379       sed "s/^/$as_me: WARNING:     /" >&2
8380     ;;
8381 esac
8382 echo "$as_me:$LINENO: checking for $ac_header" >&5
8383 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8384 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8385   echo $ECHO_N "(cached) $ECHO_C" >&6
8386 else
8387   eval "$as_ac_Header=\$ac_header_preproc"
8388 fi
8389 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8390 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8391
8392 fi
8393 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8394   cat >>confdefs.h <<_ACEOF
8395 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8396 _ACEOF
8397
8398 else
8399   { { echo "$as_me:$LINENO: error: history header not found
8400 If you have readline already installed, see config.log for details on the
8401 failure.  It is possible the compiler isn't looking in the proper directory.
8402 Use --without-readline to disable readline support." >&5
8403 echo "$as_me: error: history header not found
8404 If you have readline already installed, see config.log for details on the
8405 failure.  It is possible the compiler isn't looking in the proper directory.
8406 Use --without-readline to disable readline support." >&2;}
8407    { (exit 1); exit 1; }; }
8408 fi
8409
8410 done
8411
8412 fi
8413
8414 done
8415
8416 fi
8417
8418 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
8419 # Some installations of libedit usurp /usr/include/readline/, which seems
8420 # bad practice, since in combined installations readline will have its headers
8421 # there.  We might have to resort to AC_EGREP checks to make sure we found
8422 # the proper header...
8423
8424 for ac_header in editline/readline.h
8425 do
8426 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8427 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8428   echo "$as_me:$LINENO: checking for $ac_header" >&5
8429 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8430 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8431   echo $ECHO_N "(cached) $ECHO_C" >&6
8432 fi
8433 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8434 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8435 else
8436   # Is the header compilable?
8437 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8438 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8439 cat >conftest.$ac_ext <<_ACEOF
8440 /* confdefs.h.  */
8441 _ACEOF
8442 cat confdefs.h >>conftest.$ac_ext
8443 cat >>conftest.$ac_ext <<_ACEOF
8444 /* end confdefs.h.  */
8445 $ac_includes_default
8446 #include <$ac_header>
8447 _ACEOF
8448 rm -f conftest.$ac_objext
8449 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8450   (eval $ac_compile) 2>conftest.er1
8451   ac_status=$?
8452   grep -v '^ *+' conftest.er1 >conftest.err
8453   rm -f conftest.er1
8454   cat conftest.err >&5
8455   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8456   (exit $ac_status); } &&
8457          { ac_try='test -z "$ac_c_werror_flag"
8458                          || test ! -s conftest.err'
8459   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8460   (eval $ac_try) 2>&5
8461   ac_status=$?
8462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8463   (exit $ac_status); }; } &&
8464          { ac_try='test -s conftest.$ac_objext'
8465   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8466   (eval $ac_try) 2>&5
8467   ac_status=$?
8468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8469   (exit $ac_status); }; }; then
8470   ac_header_compiler=yes
8471 else
8472   echo "$as_me: failed program was:" >&5
8473 sed 's/^/| /' conftest.$ac_ext >&5
8474
8475 ac_header_compiler=no
8476 fi
8477 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8478 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8479 echo "${ECHO_T}$ac_header_compiler" >&6
8480
8481 # Is the header present?
8482 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8483 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8484 cat >conftest.$ac_ext <<_ACEOF
8485 /* confdefs.h.  */
8486 _ACEOF
8487 cat confdefs.h >>conftest.$ac_ext
8488 cat >>conftest.$ac_ext <<_ACEOF
8489 /* end confdefs.h.  */
8490 #include <$ac_header>
8491 _ACEOF
8492 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8493   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8494   ac_status=$?
8495   grep -v '^ *+' conftest.er1 >conftest.err
8496   rm -f conftest.er1
8497   cat conftest.err >&5
8498   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8499   (exit $ac_status); } >/dev/null; then
8500   if test -s conftest.err; then
8501     ac_cpp_err=$ac_c_preproc_warn_flag
8502     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8503   else
8504     ac_cpp_err=
8505   fi
8506 else
8507   ac_cpp_err=yes
8508 fi
8509 if test -z "$ac_cpp_err"; then
8510   ac_header_preproc=yes
8511 else
8512   echo "$as_me: failed program was:" >&5
8513 sed 's/^/| /' conftest.$ac_ext >&5
8514
8515   ac_header_preproc=no
8516 fi
8517 rm -f conftest.err conftest.$ac_ext
8518 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8519 echo "${ECHO_T}$ac_header_preproc" >&6
8520
8521 # So?  What about this header?
8522 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8523   yes:no: )
8524     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8525 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8526     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8527 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8528     ac_header_preproc=yes
8529     ;;
8530   no:yes:* )
8531     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8532 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8533     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8534 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8535     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8536 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8537     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8538 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8539     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8540 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8541     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8542 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8543     (
8544       cat <<\_ASBOX
8545 ## ---------------------------------------- ##
8546 ## Report this to pgsql-bugs@postgresql.org ##
8547 ## ---------------------------------------- ##
8548 _ASBOX
8549     ) |
8550       sed "s/^/$as_me: WARNING:     /" >&2
8551     ;;
8552 esac
8553 echo "$as_me:$LINENO: checking for $ac_header" >&5
8554 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8555 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8556   echo $ECHO_N "(cached) $ECHO_C" >&6
8557 else
8558   eval "$as_ac_Header=\$ac_header_preproc"
8559 fi
8560 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8561 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8562
8563 fi
8564 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8565   cat >>confdefs.h <<_ACEOF
8566 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8567 _ACEOF
8568
8569 else
8570
8571 for ac_header in readline.h
8572 do
8573 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8574 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8575   echo "$as_me:$LINENO: checking for $ac_header" >&5
8576 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8577 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8578   echo $ECHO_N "(cached) $ECHO_C" >&6
8579 fi
8580 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8581 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8582 else
8583   # Is the header compilable?
8584 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8585 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8586 cat >conftest.$ac_ext <<_ACEOF
8587 /* confdefs.h.  */
8588 _ACEOF
8589 cat confdefs.h >>conftest.$ac_ext
8590 cat >>conftest.$ac_ext <<_ACEOF
8591 /* end confdefs.h.  */
8592 $ac_includes_default
8593 #include <$ac_header>
8594 _ACEOF
8595 rm -f conftest.$ac_objext
8596 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8597   (eval $ac_compile) 2>conftest.er1
8598   ac_status=$?
8599   grep -v '^ *+' conftest.er1 >conftest.err
8600   rm -f conftest.er1
8601   cat conftest.err >&5
8602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8603   (exit $ac_status); } &&
8604          { ac_try='test -z "$ac_c_werror_flag"
8605                          || test ! -s conftest.err'
8606   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8607   (eval $ac_try) 2>&5
8608   ac_status=$?
8609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8610   (exit $ac_status); }; } &&
8611          { ac_try='test -s conftest.$ac_objext'
8612   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8613   (eval $ac_try) 2>&5
8614   ac_status=$?
8615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8616   (exit $ac_status); }; }; then
8617   ac_header_compiler=yes
8618 else
8619   echo "$as_me: failed program was:" >&5
8620 sed 's/^/| /' conftest.$ac_ext >&5
8621
8622 ac_header_compiler=no
8623 fi
8624 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8625 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8626 echo "${ECHO_T}$ac_header_compiler" >&6
8627
8628 # Is the header present?
8629 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8630 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8631 cat >conftest.$ac_ext <<_ACEOF
8632 /* confdefs.h.  */
8633 _ACEOF
8634 cat confdefs.h >>conftest.$ac_ext
8635 cat >>conftest.$ac_ext <<_ACEOF
8636 /* end confdefs.h.  */
8637 #include <$ac_header>
8638 _ACEOF
8639 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8640   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8641   ac_status=$?
8642   grep -v '^ *+' conftest.er1 >conftest.err
8643   rm -f conftest.er1
8644   cat conftest.err >&5
8645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8646   (exit $ac_status); } >/dev/null; then
8647   if test -s conftest.err; then
8648     ac_cpp_err=$ac_c_preproc_warn_flag
8649     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8650   else
8651     ac_cpp_err=
8652   fi
8653 else
8654   ac_cpp_err=yes
8655 fi
8656 if test -z "$ac_cpp_err"; then
8657   ac_header_preproc=yes
8658 else
8659   echo "$as_me: failed program was:" >&5
8660 sed 's/^/| /' conftest.$ac_ext >&5
8661
8662   ac_header_preproc=no
8663 fi
8664 rm -f conftest.err conftest.$ac_ext
8665 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8666 echo "${ECHO_T}$ac_header_preproc" >&6
8667
8668 # So?  What about this header?
8669 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8670   yes:no: )
8671     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8672 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8673     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8674 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8675     ac_header_preproc=yes
8676     ;;
8677   no:yes:* )
8678     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8679 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8680     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8681 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8682     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8683 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8684     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8685 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8686     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8687 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8688     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8689 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8690     (
8691       cat <<\_ASBOX
8692 ## ---------------------------------------- ##
8693 ## Report this to pgsql-bugs@postgresql.org ##
8694 ## ---------------------------------------- ##
8695 _ASBOX
8696     ) |
8697       sed "s/^/$as_me: WARNING:     /" >&2
8698     ;;
8699 esac
8700 echo "$as_me:$LINENO: checking for $ac_header" >&5
8701 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8702 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8703   echo $ECHO_N "(cached) $ECHO_C" >&6
8704 else
8705   eval "$as_ac_Header=\$ac_header_preproc"
8706 fi
8707 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8708 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8709
8710 fi
8711 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8712   cat >>confdefs.h <<_ACEOF
8713 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8714 _ACEOF
8715
8716 else
8717
8718 for ac_header in readline/readline.h
8719 do
8720 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8721 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8722   echo "$as_me:$LINENO: checking for $ac_header" >&5
8723 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8724 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8725   echo $ECHO_N "(cached) $ECHO_C" >&6
8726 fi
8727 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8728 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8729 else
8730   # Is the header compilable?
8731 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8732 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8733 cat >conftest.$ac_ext <<_ACEOF
8734 /* confdefs.h.  */
8735 _ACEOF
8736 cat confdefs.h >>conftest.$ac_ext
8737 cat >>conftest.$ac_ext <<_ACEOF
8738 /* end confdefs.h.  */
8739 $ac_includes_default
8740 #include <$ac_header>
8741 _ACEOF
8742 rm -f conftest.$ac_objext
8743 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8744   (eval $ac_compile) 2>conftest.er1
8745   ac_status=$?
8746   grep -v '^ *+' conftest.er1 >conftest.err
8747   rm -f conftest.er1
8748   cat conftest.err >&5
8749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8750   (exit $ac_status); } &&
8751          { ac_try='test -z "$ac_c_werror_flag"
8752                          || test ! -s conftest.err'
8753   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8754   (eval $ac_try) 2>&5
8755   ac_status=$?
8756   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8757   (exit $ac_status); }; } &&
8758          { ac_try='test -s conftest.$ac_objext'
8759   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8760   (eval $ac_try) 2>&5
8761   ac_status=$?
8762   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8763   (exit $ac_status); }; }; then
8764   ac_header_compiler=yes
8765 else
8766   echo "$as_me: failed program was:" >&5
8767 sed 's/^/| /' conftest.$ac_ext >&5
8768
8769 ac_header_compiler=no
8770 fi
8771 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8772 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8773 echo "${ECHO_T}$ac_header_compiler" >&6
8774
8775 # Is the header present?
8776 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8777 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8778 cat >conftest.$ac_ext <<_ACEOF
8779 /* confdefs.h.  */
8780 _ACEOF
8781 cat confdefs.h >>conftest.$ac_ext
8782 cat >>conftest.$ac_ext <<_ACEOF
8783 /* end confdefs.h.  */
8784 #include <$ac_header>
8785 _ACEOF
8786 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8787   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8788   ac_status=$?
8789   grep -v '^ *+' conftest.er1 >conftest.err
8790   rm -f conftest.er1
8791   cat conftest.err >&5
8792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8793   (exit $ac_status); } >/dev/null; then
8794   if test -s conftest.err; then
8795     ac_cpp_err=$ac_c_preproc_warn_flag
8796     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8797   else
8798     ac_cpp_err=
8799   fi
8800 else
8801   ac_cpp_err=yes
8802 fi
8803 if test -z "$ac_cpp_err"; then
8804   ac_header_preproc=yes
8805 else
8806   echo "$as_me: failed program was:" >&5
8807 sed 's/^/| /' conftest.$ac_ext >&5
8808
8809   ac_header_preproc=no
8810 fi
8811 rm -f conftest.err conftest.$ac_ext
8812 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8813 echo "${ECHO_T}$ac_header_preproc" >&6
8814
8815 # So?  What about this header?
8816 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8817   yes:no: )
8818     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8819 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8820     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8821 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8822     ac_header_preproc=yes
8823     ;;
8824   no:yes:* )
8825     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8826 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8827     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8828 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8829     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8830 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8831     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8832 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8833     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8834 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8835     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8836 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8837     (
8838       cat <<\_ASBOX
8839 ## ---------------------------------------- ##
8840 ## Report this to pgsql-bugs@postgresql.org ##
8841 ## ---------------------------------------- ##
8842 _ASBOX
8843     ) |
8844       sed "s/^/$as_me: WARNING:     /" >&2
8845     ;;
8846 esac
8847 echo "$as_me:$LINENO: checking for $ac_header" >&5
8848 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8849 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8850   echo $ECHO_N "(cached) $ECHO_C" >&6
8851 else
8852   eval "$as_ac_Header=\$ac_header_preproc"
8853 fi
8854 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8855 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8856
8857 fi
8858 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8859   cat >>confdefs.h <<_ACEOF
8860 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8861 _ACEOF
8862
8863 else
8864   { { echo "$as_me:$LINENO: error: readline header not found
8865 If you have libedit already installed, see config.log for details on the
8866 failure.  It is possible the compiler isn't looking in the proper directory.
8867 Use --without-readline to disable libedit support." >&5
8868 echo "$as_me: error: readline header not found
8869 If you have libedit already installed, see config.log for details on the
8870 failure.  It is possible the compiler isn't looking in the proper directory.
8871 Use --without-readline to disable libedit support." >&2;}
8872    { (exit 1); exit 1; }; }
8873 fi
8874
8875 done
8876
8877 fi
8878
8879 done
8880
8881 fi
8882
8883 done
8884
8885
8886 for ac_header in editline/history.h
8887 do
8888 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8889 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8890   echo "$as_me:$LINENO: checking for $ac_header" >&5
8891 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8892 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8893   echo $ECHO_N "(cached) $ECHO_C" >&6
8894 fi
8895 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8896 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8897 else
8898   # Is the header compilable?
8899 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8900 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8901 cat >conftest.$ac_ext <<_ACEOF
8902 /* confdefs.h.  */
8903 _ACEOF
8904 cat confdefs.h >>conftest.$ac_ext
8905 cat >>conftest.$ac_ext <<_ACEOF
8906 /* end confdefs.h.  */
8907 $ac_includes_default
8908 #include <$ac_header>
8909 _ACEOF
8910 rm -f conftest.$ac_objext
8911 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8912   (eval $ac_compile) 2>conftest.er1
8913   ac_status=$?
8914   grep -v '^ *+' conftest.er1 >conftest.err
8915   rm -f conftest.er1
8916   cat conftest.err >&5
8917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8918   (exit $ac_status); } &&
8919          { ac_try='test -z "$ac_c_werror_flag"
8920                          || test ! -s conftest.err'
8921   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8922   (eval $ac_try) 2>&5
8923   ac_status=$?
8924   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8925   (exit $ac_status); }; } &&
8926          { ac_try='test -s conftest.$ac_objext'
8927   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8928   (eval $ac_try) 2>&5
8929   ac_status=$?
8930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8931   (exit $ac_status); }; }; then
8932   ac_header_compiler=yes
8933 else
8934   echo "$as_me: failed program was:" >&5
8935 sed 's/^/| /' conftest.$ac_ext >&5
8936
8937 ac_header_compiler=no
8938 fi
8939 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8940 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8941 echo "${ECHO_T}$ac_header_compiler" >&6
8942
8943 # Is the header present?
8944 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8945 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8946 cat >conftest.$ac_ext <<_ACEOF
8947 /* confdefs.h.  */
8948 _ACEOF
8949 cat confdefs.h >>conftest.$ac_ext
8950 cat >>conftest.$ac_ext <<_ACEOF
8951 /* end confdefs.h.  */
8952 #include <$ac_header>
8953 _ACEOF
8954 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8955   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8956   ac_status=$?
8957   grep -v '^ *+' conftest.er1 >conftest.err
8958   rm -f conftest.er1
8959   cat conftest.err >&5
8960   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8961   (exit $ac_status); } >/dev/null; then
8962   if test -s conftest.err; then
8963     ac_cpp_err=$ac_c_preproc_warn_flag
8964     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8965   else
8966     ac_cpp_err=
8967   fi
8968 else
8969   ac_cpp_err=yes
8970 fi
8971 if test -z "$ac_cpp_err"; then
8972   ac_header_preproc=yes
8973 else
8974   echo "$as_me: failed program was:" >&5
8975 sed 's/^/| /' conftest.$ac_ext >&5
8976
8977   ac_header_preproc=no
8978 fi
8979 rm -f conftest.err conftest.$ac_ext
8980 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8981 echo "${ECHO_T}$ac_header_preproc" >&6
8982
8983 # So?  What about this header?
8984 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8985   yes:no: )
8986     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8987 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8988     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8989 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8990     ac_header_preproc=yes
8991     ;;
8992   no:yes:* )
8993     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8994 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8995     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8996 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8997     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8998 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8999     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9000 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9001     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9002 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9003     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9004 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9005     (
9006       cat <<\_ASBOX
9007 ## ---------------------------------------- ##
9008 ## Report this to pgsql-bugs@postgresql.org ##
9009 ## ---------------------------------------- ##
9010 _ASBOX
9011     ) |
9012       sed "s/^/$as_me: WARNING:     /" >&2
9013     ;;
9014 esac
9015 echo "$as_me:$LINENO: checking for $ac_header" >&5
9016 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9017 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9018   echo $ECHO_N "(cached) $ECHO_C" >&6
9019 else
9020   eval "$as_ac_Header=\$ac_header_preproc"
9021 fi
9022 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9023 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9024
9025 fi
9026 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9027   cat >>confdefs.h <<_ACEOF
9028 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9029 _ACEOF
9030
9031 else
9032
9033 for ac_header in history.h
9034 do
9035 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9036 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9037   echo "$as_me:$LINENO: checking for $ac_header" >&5
9038 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9039 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9040   echo $ECHO_N "(cached) $ECHO_C" >&6
9041 fi
9042 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9043 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9044 else
9045   # Is the header compilable?
9046 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9047 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9048 cat >conftest.$ac_ext <<_ACEOF
9049 /* confdefs.h.  */
9050 _ACEOF
9051 cat confdefs.h >>conftest.$ac_ext
9052 cat >>conftest.$ac_ext <<_ACEOF
9053 /* end confdefs.h.  */
9054 $ac_includes_default
9055 #include <$ac_header>
9056 _ACEOF
9057 rm -f conftest.$ac_objext
9058 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9059   (eval $ac_compile) 2>conftest.er1
9060   ac_status=$?
9061   grep -v '^ *+' conftest.er1 >conftest.err
9062   rm -f conftest.er1
9063   cat conftest.err >&5
9064   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9065   (exit $ac_status); } &&
9066          { ac_try='test -z "$ac_c_werror_flag"
9067                          || test ! -s conftest.err'
9068   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9069   (eval $ac_try) 2>&5
9070   ac_status=$?
9071   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9072   (exit $ac_status); }; } &&
9073          { ac_try='test -s conftest.$ac_objext'
9074   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9075   (eval $ac_try) 2>&5
9076   ac_status=$?
9077   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9078   (exit $ac_status); }; }; then
9079   ac_header_compiler=yes
9080 else
9081   echo "$as_me: failed program was:" >&5
9082 sed 's/^/| /' conftest.$ac_ext >&5
9083
9084 ac_header_compiler=no
9085 fi
9086 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9087 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9088 echo "${ECHO_T}$ac_header_compiler" >&6
9089
9090 # Is the header present?
9091 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9092 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9093 cat >conftest.$ac_ext <<_ACEOF
9094 /* confdefs.h.  */
9095 _ACEOF
9096 cat confdefs.h >>conftest.$ac_ext
9097 cat >>conftest.$ac_ext <<_ACEOF
9098 /* end confdefs.h.  */
9099 #include <$ac_header>
9100 _ACEOF
9101 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9102   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9103   ac_status=$?
9104   grep -v '^ *+' conftest.er1 >conftest.err
9105   rm -f conftest.er1
9106   cat conftest.err >&5
9107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9108   (exit $ac_status); } >/dev/null; then
9109   if test -s conftest.err; then
9110     ac_cpp_err=$ac_c_preproc_warn_flag
9111     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9112   else
9113     ac_cpp_err=
9114   fi
9115 else
9116   ac_cpp_err=yes
9117 fi
9118 if test -z "$ac_cpp_err"; then
9119   ac_header_preproc=yes
9120 else
9121   echo "$as_me: failed program was:" >&5
9122 sed 's/^/| /' conftest.$ac_ext >&5
9123
9124   ac_header_preproc=no
9125 fi
9126 rm -f conftest.err conftest.$ac_ext
9127 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9128 echo "${ECHO_T}$ac_header_preproc" >&6
9129
9130 # So?  What about this header?
9131 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9132   yes:no: )
9133     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9134 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9135     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9136 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9137     ac_header_preproc=yes
9138     ;;
9139   no:yes:* )
9140     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9141 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9142     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9143 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9144     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9145 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9146     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9147 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9148     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9149 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9150     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9151 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9152     (
9153       cat <<\_ASBOX
9154 ## ---------------------------------------- ##
9155 ## Report this to pgsql-bugs@postgresql.org ##
9156 ## ---------------------------------------- ##
9157 _ASBOX
9158     ) |
9159       sed "s/^/$as_me: WARNING:     /" >&2
9160     ;;
9161 esac
9162 echo "$as_me:$LINENO: checking for $ac_header" >&5
9163 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9164 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9165   echo $ECHO_N "(cached) $ECHO_C" >&6
9166 else
9167   eval "$as_ac_Header=\$ac_header_preproc"
9168 fi
9169 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9170 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9171
9172 fi
9173 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9174   cat >>confdefs.h <<_ACEOF
9175 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9176 _ACEOF
9177
9178 else
9179
9180 for ac_header in readline/history.h
9181 do
9182 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9183 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9184   echo "$as_me:$LINENO: checking for $ac_header" >&5
9185 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9186 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9187   echo $ECHO_N "(cached) $ECHO_C" >&6
9188 fi
9189 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9190 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9191 else
9192   # Is the header compilable?
9193 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9194 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9195 cat >conftest.$ac_ext <<_ACEOF
9196 /* confdefs.h.  */
9197 _ACEOF
9198 cat confdefs.h >>conftest.$ac_ext
9199 cat >>conftest.$ac_ext <<_ACEOF
9200 /* end confdefs.h.  */
9201 $ac_includes_default
9202 #include <$ac_header>
9203 _ACEOF
9204 rm -f conftest.$ac_objext
9205 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9206   (eval $ac_compile) 2>conftest.er1
9207   ac_status=$?
9208   grep -v '^ *+' conftest.er1 >conftest.err
9209   rm -f conftest.er1
9210   cat conftest.err >&5
9211   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9212   (exit $ac_status); } &&
9213          { ac_try='test -z "$ac_c_werror_flag"
9214                          || test ! -s conftest.err'
9215   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9216   (eval $ac_try) 2>&5
9217   ac_status=$?
9218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9219   (exit $ac_status); }; } &&
9220          { ac_try='test -s conftest.$ac_objext'
9221   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9222   (eval $ac_try) 2>&5
9223   ac_status=$?
9224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9225   (exit $ac_status); }; }; then
9226   ac_header_compiler=yes
9227 else
9228   echo "$as_me: failed program was:" >&5
9229 sed 's/^/| /' conftest.$ac_ext >&5
9230
9231 ac_header_compiler=no
9232 fi
9233 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9234 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9235 echo "${ECHO_T}$ac_header_compiler" >&6
9236
9237 # Is the header present?
9238 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9239 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9240 cat >conftest.$ac_ext <<_ACEOF
9241 /* confdefs.h.  */
9242 _ACEOF
9243 cat confdefs.h >>conftest.$ac_ext
9244 cat >>conftest.$ac_ext <<_ACEOF
9245 /* end confdefs.h.  */
9246 #include <$ac_header>
9247 _ACEOF
9248 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9249   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9250   ac_status=$?
9251   grep -v '^ *+' conftest.er1 >conftest.err
9252   rm -f conftest.er1
9253   cat conftest.err >&5
9254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9255   (exit $ac_status); } >/dev/null; then
9256   if test -s conftest.err; then
9257     ac_cpp_err=$ac_c_preproc_warn_flag
9258     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9259   else
9260     ac_cpp_err=
9261   fi
9262 else
9263   ac_cpp_err=yes
9264 fi
9265 if test -z "$ac_cpp_err"; then
9266   ac_header_preproc=yes
9267 else
9268   echo "$as_me: failed program was:" >&5
9269 sed 's/^/| /' conftest.$ac_ext >&5
9270
9271   ac_header_preproc=no
9272 fi
9273 rm -f conftest.err conftest.$ac_ext
9274 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9275 echo "${ECHO_T}$ac_header_preproc" >&6
9276
9277 # So?  What about this header?
9278 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9279   yes:no: )
9280     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9281 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9282     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9283 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9284     ac_header_preproc=yes
9285     ;;
9286   no:yes:* )
9287     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9288 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9289     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9290 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9291     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9292 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9293     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9294 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9295     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9296 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9297     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9298 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9299     (
9300       cat <<\_ASBOX
9301 ## ---------------------------------------- ##
9302 ## Report this to pgsql-bugs@postgresql.org ##
9303 ## ---------------------------------------- ##
9304 _ASBOX
9305     ) |
9306       sed "s/^/$as_me: WARNING:     /" >&2
9307     ;;
9308 esac
9309 echo "$as_me:$LINENO: checking for $ac_header" >&5
9310 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9311 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9312   echo $ECHO_N "(cached) $ECHO_C" >&6
9313 else
9314   eval "$as_ac_Header=\$ac_header_preproc"
9315 fi
9316 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9317 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9318
9319 fi
9320 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9321   cat >>confdefs.h <<_ACEOF
9322 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9323 _ACEOF
9324
9325 else
9326   { { echo "$as_me:$LINENO: error: history header not found
9327 If you have libedit already installed, see config.log for details on the
9328 failure.  It is possible the compiler isn't looking in the proper directory.
9329 Use --without-readline to disable libedit support." >&5
9330 echo "$as_me: error: history header not found
9331 If you have libedit already installed, see config.log for details on the
9332 failure.  It is possible the compiler isn't looking in the proper directory.
9333 Use --without-readline to disable libedit support." >&2;}
9334    { (exit 1); exit 1; }; }
9335 fi
9336
9337 done
9338
9339 fi
9340
9341 done
9342
9343 fi
9344
9345 done
9346
9347 fi
9348
9349 if test "$with_zlib" = yes; then
9350   if test "${ac_cv_header_zlib_h+set}" = set; then
9351   echo "$as_me:$LINENO: checking for zlib.h" >&5
9352 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
9353 if test "${ac_cv_header_zlib_h+set}" = set; then
9354   echo $ECHO_N "(cached) $ECHO_C" >&6
9355 fi
9356 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
9357 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
9358 else
9359   # Is the header compilable?
9360 echo "$as_me:$LINENO: checking zlib.h usability" >&5
9361 echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6
9362 cat >conftest.$ac_ext <<_ACEOF
9363 /* confdefs.h.  */
9364 _ACEOF
9365 cat confdefs.h >>conftest.$ac_ext
9366 cat >>conftest.$ac_ext <<_ACEOF
9367 /* end confdefs.h.  */
9368 $ac_includes_default
9369 #include <zlib.h>
9370 _ACEOF
9371 rm -f conftest.$ac_objext
9372 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9373   (eval $ac_compile) 2>conftest.er1
9374   ac_status=$?
9375   grep -v '^ *+' conftest.er1 >conftest.err
9376   rm -f conftest.er1
9377   cat conftest.err >&5
9378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9379   (exit $ac_status); } &&
9380          { ac_try='test -z "$ac_c_werror_flag"
9381                          || test ! -s conftest.err'
9382   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9383   (eval $ac_try) 2>&5
9384   ac_status=$?
9385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9386   (exit $ac_status); }; } &&
9387          { ac_try='test -s conftest.$ac_objext'
9388   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9389   (eval $ac_try) 2>&5
9390   ac_status=$?
9391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9392   (exit $ac_status); }; }; then
9393   ac_header_compiler=yes
9394 else
9395   echo "$as_me: failed program was:" >&5
9396 sed 's/^/| /' conftest.$ac_ext >&5
9397
9398 ac_header_compiler=no
9399 fi
9400 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9401 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9402 echo "${ECHO_T}$ac_header_compiler" >&6
9403
9404 # Is the header present?
9405 echo "$as_me:$LINENO: checking zlib.h presence" >&5
9406 echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6
9407 cat >conftest.$ac_ext <<_ACEOF
9408 /* confdefs.h.  */
9409 _ACEOF
9410 cat confdefs.h >>conftest.$ac_ext
9411 cat >>conftest.$ac_ext <<_ACEOF
9412 /* end confdefs.h.  */
9413 #include <zlib.h>
9414 _ACEOF
9415 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9416   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9417   ac_status=$?
9418   grep -v '^ *+' conftest.er1 >conftest.err
9419   rm -f conftest.er1
9420   cat conftest.err >&5
9421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9422   (exit $ac_status); } >/dev/null; then
9423   if test -s conftest.err; then
9424     ac_cpp_err=$ac_c_preproc_warn_flag
9425     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9426   else
9427     ac_cpp_err=
9428   fi
9429 else
9430   ac_cpp_err=yes
9431 fi
9432 if test -z "$ac_cpp_err"; then
9433   ac_header_preproc=yes
9434 else
9435   echo "$as_me: failed program was:" >&5
9436 sed 's/^/| /' conftest.$ac_ext >&5
9437
9438   ac_header_preproc=no
9439 fi
9440 rm -f conftest.err conftest.$ac_ext
9441 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9442 echo "${ECHO_T}$ac_header_preproc" >&6
9443
9444 # So?  What about this header?
9445 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9446   yes:no: )
9447     { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
9448 echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9449     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
9450 echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
9451     ac_header_preproc=yes
9452     ;;
9453   no:yes:* )
9454     { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
9455 echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
9456     { echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
9457 echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
9458     { echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
9459 echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
9460     { echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
9461 echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9462     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
9463 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
9464     { echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
9465 echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
9466     (
9467       cat <<\_ASBOX
9468 ## ---------------------------------------- ##
9469 ## Report this to pgsql-bugs@postgresql.org ##
9470 ## ---------------------------------------- ##
9471 _ASBOX
9472     ) |
9473       sed "s/^/$as_me: WARNING:     /" >&2
9474     ;;
9475 esac
9476 echo "$as_me:$LINENO: checking for zlib.h" >&5
9477 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
9478 if test "${ac_cv_header_zlib_h+set}" = set; then
9479   echo $ECHO_N "(cached) $ECHO_C" >&6
9480 else
9481   ac_cv_header_zlib_h=$ac_header_preproc
9482 fi
9483 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
9484 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
9485
9486 fi
9487 if test $ac_cv_header_zlib_h = yes; then
9488   :
9489 else
9490   { { echo "$as_me:$LINENO: error: zlib header not found
9491 If you have zlib already installed, see config.log for details on the
9492 failure.  It is possible the compiler isn't looking in the proper directory.
9493 Use --without-zlib to disable zlib support." >&5
9494 echo "$as_me: error: zlib header not found
9495 If you have zlib already installed, see config.log for details on the
9496 failure.  It is possible the compiler isn't looking in the proper directory.
9497 Use --without-zlib to disable zlib support." >&2;}
9498    { (exit 1); exit 1; }; }
9499 fi
9500
9501
9502 fi
9503
9504 if test "$with_krb5" = yes ; then
9505   if test "${ac_cv_header_krb5_h+set}" = set; then
9506   echo "$as_me:$LINENO: checking for krb5.h" >&5
9507 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9508 if test "${ac_cv_header_krb5_h+set}" = set; then
9509   echo $ECHO_N "(cached) $ECHO_C" >&6
9510 fi
9511 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9512 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9513 else
9514   # Is the header compilable?
9515 echo "$as_me:$LINENO: checking krb5.h usability" >&5
9516 echo $ECHO_N "checking krb5.h usability... $ECHO_C" >&6
9517 cat >conftest.$ac_ext <<_ACEOF
9518 /* confdefs.h.  */
9519 _ACEOF
9520 cat confdefs.h >>conftest.$ac_ext
9521 cat >>conftest.$ac_ext <<_ACEOF
9522 /* end confdefs.h.  */
9523 $ac_includes_default
9524 #include <krb5.h>
9525 _ACEOF
9526 rm -f conftest.$ac_objext
9527 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9528   (eval $ac_compile) 2>conftest.er1
9529   ac_status=$?
9530   grep -v '^ *+' conftest.er1 >conftest.err
9531   rm -f conftest.er1
9532   cat conftest.err >&5
9533   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9534   (exit $ac_status); } &&
9535          { ac_try='test -z "$ac_c_werror_flag"
9536                          || test ! -s conftest.err'
9537   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9538   (eval $ac_try) 2>&5
9539   ac_status=$?
9540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9541   (exit $ac_status); }; } &&
9542          { ac_try='test -s conftest.$ac_objext'
9543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9544   (eval $ac_try) 2>&5
9545   ac_status=$?
9546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9547   (exit $ac_status); }; }; then
9548   ac_header_compiler=yes
9549 else
9550   echo "$as_me: failed program was:" >&5
9551 sed 's/^/| /' conftest.$ac_ext >&5
9552
9553 ac_header_compiler=no
9554 fi
9555 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9556 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9557 echo "${ECHO_T}$ac_header_compiler" >&6
9558
9559 # Is the header present?
9560 echo "$as_me:$LINENO: checking krb5.h presence" >&5
9561 echo $ECHO_N "checking krb5.h presence... $ECHO_C" >&6
9562 cat >conftest.$ac_ext <<_ACEOF
9563 /* confdefs.h.  */
9564 _ACEOF
9565 cat confdefs.h >>conftest.$ac_ext
9566 cat >>conftest.$ac_ext <<_ACEOF
9567 /* end confdefs.h.  */
9568 #include <krb5.h>
9569 _ACEOF
9570 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9571   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9572   ac_status=$?
9573   grep -v '^ *+' conftest.er1 >conftest.err
9574   rm -f conftest.er1
9575   cat conftest.err >&5
9576   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9577   (exit $ac_status); } >/dev/null; then
9578   if test -s conftest.err; then
9579     ac_cpp_err=$ac_c_preproc_warn_flag
9580     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9581   else
9582     ac_cpp_err=
9583   fi
9584 else
9585   ac_cpp_err=yes
9586 fi
9587 if test -z "$ac_cpp_err"; then
9588   ac_header_preproc=yes
9589 else
9590   echo "$as_me: failed program was:" >&5
9591 sed 's/^/| /' conftest.$ac_ext >&5
9592
9593   ac_header_preproc=no
9594 fi
9595 rm -f conftest.err conftest.$ac_ext
9596 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9597 echo "${ECHO_T}$ac_header_preproc" >&6
9598
9599 # So?  What about this header?
9600 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9601   yes:no: )
9602     { echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
9603 echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9604     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
9605 echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
9606     ac_header_preproc=yes
9607     ;;
9608   no:yes:* )
9609     { echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
9610 echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
9611     { echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
9612 echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
9613     { echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
9614 echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
9615     { echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
9616 echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9617     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
9618 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
9619     { echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
9620 echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
9621     (
9622       cat <<\_ASBOX
9623 ## ---------------------------------------- ##
9624 ## Report this to pgsql-bugs@postgresql.org ##
9625 ## ---------------------------------------- ##
9626 _ASBOX
9627     ) |
9628       sed "s/^/$as_me: WARNING:     /" >&2
9629     ;;
9630 esac
9631 echo "$as_me:$LINENO: checking for krb5.h" >&5
9632 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9633 if test "${ac_cv_header_krb5_h+set}" = set; then
9634   echo $ECHO_N "(cached) $ECHO_C" >&6
9635 else
9636   ac_cv_header_krb5_h=$ac_header_preproc
9637 fi
9638 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9639 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9640
9641 fi
9642 if test $ac_cv_header_krb5_h = yes; then
9643   :
9644 else
9645   { { echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
9646 echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
9647    { (exit 1); exit 1; }; }
9648 fi
9649
9650
9651 fi
9652
9653 if test "$with_openssl" = yes ; then
9654   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9655   echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9656 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9657 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9658   echo $ECHO_N "(cached) $ECHO_C" >&6
9659 fi
9660 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9661 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9662 else
9663   # Is the header compilable?
9664 echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
9665 echo $ECHO_N "checking openssl/ssl.h usability... $ECHO_C" >&6
9666 cat >conftest.$ac_ext <<_ACEOF
9667 /* confdefs.h.  */
9668 _ACEOF
9669 cat confdefs.h >>conftest.$ac_ext
9670 cat >>conftest.$ac_ext <<_ACEOF
9671 /* end confdefs.h.  */
9672 $ac_includes_default
9673 #include <openssl/ssl.h>
9674 _ACEOF
9675 rm -f conftest.$ac_objext
9676 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9677   (eval $ac_compile) 2>conftest.er1
9678   ac_status=$?
9679   grep -v '^ *+' conftest.er1 >conftest.err
9680   rm -f conftest.er1
9681   cat conftest.err >&5
9682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9683   (exit $ac_status); } &&
9684          { ac_try='test -z "$ac_c_werror_flag"
9685                          || test ! -s conftest.err'
9686   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9687   (eval $ac_try) 2>&5
9688   ac_status=$?
9689   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9690   (exit $ac_status); }; } &&
9691          { ac_try='test -s conftest.$ac_objext'
9692   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9693   (eval $ac_try) 2>&5
9694   ac_status=$?
9695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9696   (exit $ac_status); }; }; then
9697   ac_header_compiler=yes
9698 else
9699   echo "$as_me: failed program was:" >&5
9700 sed 's/^/| /' conftest.$ac_ext >&5
9701
9702 ac_header_compiler=no
9703 fi
9704 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9705 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9706 echo "${ECHO_T}$ac_header_compiler" >&6
9707
9708 # Is the header present?
9709 echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
9710 echo $ECHO_N "checking openssl/ssl.h presence... $ECHO_C" >&6
9711 cat >conftest.$ac_ext <<_ACEOF
9712 /* confdefs.h.  */
9713 _ACEOF
9714 cat confdefs.h >>conftest.$ac_ext
9715 cat >>conftest.$ac_ext <<_ACEOF
9716 /* end confdefs.h.  */
9717 #include <openssl/ssl.h>
9718 _ACEOF
9719 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9720   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9721   ac_status=$?
9722   grep -v '^ *+' conftest.er1 >conftest.err
9723   rm -f conftest.er1
9724   cat conftest.err >&5
9725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9726   (exit $ac_status); } >/dev/null; then
9727   if test -s conftest.err; then
9728     ac_cpp_err=$ac_c_preproc_warn_flag
9729     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9730   else
9731     ac_cpp_err=
9732   fi
9733 else
9734   ac_cpp_err=yes
9735 fi
9736 if test -z "$ac_cpp_err"; then
9737   ac_header_preproc=yes
9738 else
9739   echo "$as_me: failed program was:" >&5
9740 sed 's/^/| /' conftest.$ac_ext >&5
9741
9742   ac_header_preproc=no
9743 fi
9744 rm -f conftest.err conftest.$ac_ext
9745 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9746 echo "${ECHO_T}$ac_header_preproc" >&6
9747
9748 # So?  What about this header?
9749 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9750   yes:no: )
9751     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
9752 echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9753     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
9754 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
9755     ac_header_preproc=yes
9756     ;;
9757   no:yes:* )
9758     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
9759 echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
9760     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
9761 echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
9762     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
9763 echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
9764     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
9765 echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9766     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
9767 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
9768     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
9769 echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
9770     (
9771       cat <<\_ASBOX
9772 ## ---------------------------------------- ##
9773 ## Report this to pgsql-bugs@postgresql.org ##
9774 ## ---------------------------------------- ##
9775 _ASBOX
9776     ) |
9777       sed "s/^/$as_me: WARNING:     /" >&2
9778     ;;
9779 esac
9780 echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9781 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9782 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9783   echo $ECHO_N "(cached) $ECHO_C" >&6
9784 else
9785   ac_cv_header_openssl_ssl_h=$ac_header_preproc
9786 fi
9787 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9788 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9789
9790 fi
9791 if test $ac_cv_header_openssl_ssl_h = yes; then
9792   :
9793 else
9794   { { echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
9795 echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
9796    { (exit 1); exit 1; }; }
9797 fi
9798
9799
9800   if test "${ac_cv_header_openssl_err_h+set}" = set; then
9801   echo "$as_me:$LINENO: checking for openssl/err.h" >&5
9802 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
9803 if test "${ac_cv_header_openssl_err_h+set}" = set; then
9804   echo $ECHO_N "(cached) $ECHO_C" >&6
9805 fi
9806 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
9807 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
9808 else
9809   # Is the header compilable?
9810 echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
9811 echo $ECHO_N "checking openssl/err.h usability... $ECHO_C" >&6
9812 cat >conftest.$ac_ext <<_ACEOF
9813 /* confdefs.h.  */
9814 _ACEOF
9815 cat confdefs.h >>conftest.$ac_ext
9816 cat >>conftest.$ac_ext <<_ACEOF
9817 /* end confdefs.h.  */
9818 $ac_includes_default
9819 #include <openssl/err.h>
9820 _ACEOF
9821 rm -f conftest.$ac_objext
9822 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9823   (eval $ac_compile) 2>conftest.er1
9824   ac_status=$?
9825   grep -v '^ *+' conftest.er1 >conftest.err
9826   rm -f conftest.er1
9827   cat conftest.err >&5
9828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9829   (exit $ac_status); } &&
9830          { ac_try='test -z "$ac_c_werror_flag"
9831                          || test ! -s conftest.err'
9832   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9833   (eval $ac_try) 2>&5
9834   ac_status=$?
9835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9836   (exit $ac_status); }; } &&
9837          { ac_try='test -s conftest.$ac_objext'
9838   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9839   (eval $ac_try) 2>&5
9840   ac_status=$?
9841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9842   (exit $ac_status); }; }; then
9843   ac_header_compiler=yes
9844 else
9845   echo "$as_me: failed program was:" >&5
9846 sed 's/^/| /' conftest.$ac_ext >&5
9847
9848 ac_header_compiler=no
9849 fi
9850 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9851 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9852 echo "${ECHO_T}$ac_header_compiler" >&6
9853
9854 # Is the header present?
9855 echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
9856 echo $ECHO_N "checking openssl/err.h presence... $ECHO_C" >&6
9857 cat >conftest.$ac_ext <<_ACEOF
9858 /* confdefs.h.  */
9859 _ACEOF
9860 cat confdefs.h >>conftest.$ac_ext
9861 cat >>conftest.$ac_ext <<_ACEOF
9862 /* end confdefs.h.  */
9863 #include <openssl/err.h>
9864 _ACEOF
9865 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9866   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9867   ac_status=$?
9868   grep -v '^ *+' conftest.er1 >conftest.err
9869   rm -f conftest.er1
9870   cat conftest.err >&5
9871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9872   (exit $ac_status); } >/dev/null; then
9873   if test -s conftest.err; then
9874     ac_cpp_err=$ac_c_preproc_warn_flag
9875     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9876   else
9877     ac_cpp_err=
9878   fi
9879 else
9880   ac_cpp_err=yes
9881 fi
9882 if test -z "$ac_cpp_err"; then
9883   ac_header_preproc=yes
9884 else
9885   echo "$as_me: failed program was:" >&5
9886 sed 's/^/| /' conftest.$ac_ext >&5
9887
9888   ac_header_preproc=no
9889 fi
9890 rm -f conftest.err conftest.$ac_ext
9891 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9892 echo "${ECHO_T}$ac_header_preproc" >&6
9893
9894 # So?  What about this header?
9895 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9896   yes:no: )
9897     { echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
9898 echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9899     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
9900 echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
9901     ac_header_preproc=yes
9902     ;;
9903   no:yes:* )
9904     { echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
9905 echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
9906     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
9907 echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
9908     { echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
9909 echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
9910     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
9911 echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9912     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
9913 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
9914     { echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
9915 echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
9916     (
9917       cat <<\_ASBOX
9918 ## ---------------------------------------- ##
9919 ## Report this to pgsql-bugs@postgresql.org ##
9920 ## ---------------------------------------- ##
9921 _ASBOX
9922     ) |
9923       sed "s/^/$as_me: WARNING:     /" >&2
9924     ;;
9925 esac
9926 echo "$as_me:$LINENO: checking for openssl/err.h" >&5
9927 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
9928 if test "${ac_cv_header_openssl_err_h+set}" = set; then
9929   echo $ECHO_N "(cached) $ECHO_C" >&6
9930 else
9931   ac_cv_header_openssl_err_h=$ac_header_preproc
9932 fi
9933 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
9934 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
9935
9936 fi
9937 if test $ac_cv_header_openssl_err_h = yes; then
9938   :
9939 else
9940   { { echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
9941 echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
9942    { (exit 1); exit 1; }; }
9943 fi
9944
9945
9946 fi
9947
9948 if test "$with_pam" = yes ; then
9949
9950 for ac_header in security/pam_appl.h
9951 do
9952 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9953 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9954   echo "$as_me:$LINENO: checking for $ac_header" >&5
9955 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9956 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9957   echo $ECHO_N "(cached) $ECHO_C" >&6
9958 fi
9959 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9960 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9961 else
9962   # Is the header compilable?
9963 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9964 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9965 cat >conftest.$ac_ext <<_ACEOF
9966 /* confdefs.h.  */
9967 _ACEOF
9968 cat confdefs.h >>conftest.$ac_ext
9969 cat >>conftest.$ac_ext <<_ACEOF
9970 /* end confdefs.h.  */
9971 $ac_includes_default
9972 #include <$ac_header>
9973 _ACEOF
9974 rm -f conftest.$ac_objext
9975 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9976   (eval $ac_compile) 2>conftest.er1
9977   ac_status=$?
9978   grep -v '^ *+' conftest.er1 >conftest.err
9979   rm -f conftest.er1
9980   cat conftest.err >&5
9981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9982   (exit $ac_status); } &&
9983          { ac_try='test -z "$ac_c_werror_flag"
9984                          || test ! -s conftest.err'
9985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9986   (eval $ac_try) 2>&5
9987   ac_status=$?
9988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9989   (exit $ac_status); }; } &&
9990          { ac_try='test -s conftest.$ac_objext'
9991   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9992   (eval $ac_try) 2>&5
9993   ac_status=$?
9994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9995   (exit $ac_status); }; }; then
9996   ac_header_compiler=yes
9997 else
9998   echo "$as_me: failed program was:" >&5
9999 sed 's/^/| /' conftest.$ac_ext >&5
10000
10001 ac_header_compiler=no
10002 fi
10003 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10004 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10005 echo "${ECHO_T}$ac_header_compiler" >&6
10006
10007 # Is the header present?
10008 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10009 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10010 cat >conftest.$ac_ext <<_ACEOF
10011 /* confdefs.h.  */
10012 _ACEOF
10013 cat confdefs.h >>conftest.$ac_ext
10014 cat >>conftest.$ac_ext <<_ACEOF
10015 /* end confdefs.h.  */
10016 #include <$ac_header>
10017 _ACEOF
10018 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10019   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10020   ac_status=$?
10021   grep -v '^ *+' conftest.er1 >conftest.err
10022   rm -f conftest.er1
10023   cat conftest.err >&5
10024   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10025   (exit $ac_status); } >/dev/null; then
10026   if test -s conftest.err; then
10027     ac_cpp_err=$ac_c_preproc_warn_flag
10028     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10029   else
10030     ac_cpp_err=
10031   fi
10032 else
10033   ac_cpp_err=yes
10034 fi
10035 if test -z "$ac_cpp_err"; then
10036   ac_header_preproc=yes
10037 else
10038   echo "$as_me: failed program was:" >&5
10039 sed 's/^/| /' conftest.$ac_ext >&5
10040
10041   ac_header_preproc=no
10042 fi
10043 rm -f conftest.err conftest.$ac_ext
10044 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10045 echo "${ECHO_T}$ac_header_preproc" >&6
10046
10047 # So?  What about this header?
10048 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10049   yes:no: )
10050     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10051 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10052     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10053 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10054     ac_header_preproc=yes
10055     ;;
10056   no:yes:* )
10057     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10058 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10059     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10060 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10061     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10062 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10063     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10064 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10065     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10066 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10067     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10068 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10069     (
10070       cat <<\_ASBOX
10071 ## ---------------------------------------- ##
10072 ## Report this to pgsql-bugs@postgresql.org ##
10073 ## ---------------------------------------- ##
10074 _ASBOX
10075     ) |
10076       sed "s/^/$as_me: WARNING:     /" >&2
10077     ;;
10078 esac
10079 echo "$as_me:$LINENO: checking for $ac_header" >&5
10080 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10081 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10082   echo $ECHO_N "(cached) $ECHO_C" >&6
10083 else
10084   eval "$as_ac_Header=\$ac_header_preproc"
10085 fi
10086 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10087 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10088
10089 fi
10090 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10091   cat >>confdefs.h <<_ACEOF
10092 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10093 _ACEOF
10094
10095 else
10096
10097 for ac_header in pam/pam_appl.h
10098 do
10099 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10100 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10101   echo "$as_me:$LINENO: checking for $ac_header" >&5
10102 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10103 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10104   echo $ECHO_N "(cached) $ECHO_C" >&6
10105 fi
10106 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10107 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10108 else
10109   # Is the header compilable?
10110 echo "$as_me:$LINENO: checking $ac_header usability" >&5
10111 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10112 cat >conftest.$ac_ext <<_ACEOF
10113 /* confdefs.h.  */
10114 _ACEOF
10115 cat confdefs.h >>conftest.$ac_ext
10116 cat >>conftest.$ac_ext <<_ACEOF
10117 /* end confdefs.h.  */
10118 $ac_includes_default
10119 #include <$ac_header>
10120 _ACEOF
10121 rm -f conftest.$ac_objext
10122 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10123   (eval $ac_compile) 2>conftest.er1
10124   ac_status=$?
10125   grep -v '^ *+' conftest.er1 >conftest.err
10126   rm -f conftest.er1
10127   cat conftest.err >&5
10128   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10129   (exit $ac_status); } &&
10130          { ac_try='test -z "$ac_c_werror_flag"
10131                          || test ! -s conftest.err'
10132   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10133   (eval $ac_try) 2>&5
10134   ac_status=$?
10135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10136   (exit $ac_status); }; } &&
10137          { ac_try='test -s conftest.$ac_objext'
10138   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10139   (eval $ac_try) 2>&5
10140   ac_status=$?
10141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10142   (exit $ac_status); }; }; then
10143   ac_header_compiler=yes
10144 else
10145   echo "$as_me: failed program was:" >&5
10146 sed 's/^/| /' conftest.$ac_ext >&5
10147
10148 ac_header_compiler=no
10149 fi
10150 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10151 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10152 echo "${ECHO_T}$ac_header_compiler" >&6
10153
10154 # Is the header present?
10155 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10156 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10157 cat >conftest.$ac_ext <<_ACEOF
10158 /* confdefs.h.  */
10159 _ACEOF
10160 cat confdefs.h >>conftest.$ac_ext
10161 cat >>conftest.$ac_ext <<_ACEOF
10162 /* end confdefs.h.  */
10163 #include <$ac_header>
10164 _ACEOF
10165 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10166   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10167   ac_status=$?
10168   grep -v '^ *+' conftest.er1 >conftest.err
10169   rm -f conftest.er1
10170   cat conftest.err >&5
10171   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10172   (exit $ac_status); } >/dev/null; then
10173   if test -s conftest.err; then
10174     ac_cpp_err=$ac_c_preproc_warn_flag
10175     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10176   else
10177     ac_cpp_err=
10178   fi
10179 else
10180   ac_cpp_err=yes
10181 fi
10182 if test -z "$ac_cpp_err"; then
10183   ac_header_preproc=yes
10184 else
10185   echo "$as_me: failed program was:" >&5
10186 sed 's/^/| /' conftest.$ac_ext >&5
10187
10188   ac_header_preproc=no
10189 fi
10190 rm -f conftest.err conftest.$ac_ext
10191 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10192 echo "${ECHO_T}$ac_header_preproc" >&6
10193
10194 # So?  What about this header?
10195 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10196   yes:no: )
10197     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10198 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10199     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10200 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10201     ac_header_preproc=yes
10202     ;;
10203   no:yes:* )
10204     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10205 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10206     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10207 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10208     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10209 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10210     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10211 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10212     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10213 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10214     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10215 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10216     (
10217       cat <<\_ASBOX
10218 ## ---------------------------------------- ##
10219 ## Report this to pgsql-bugs@postgresql.org ##
10220 ## ---------------------------------------- ##
10221 _ASBOX
10222     ) |
10223       sed "s/^/$as_me: WARNING:     /" >&2
10224     ;;
10225 esac
10226 echo "$as_me:$LINENO: checking for $ac_header" >&5
10227 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10228 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10229   echo $ECHO_N "(cached) $ECHO_C" >&6
10230 else
10231   eval "$as_ac_Header=\$ac_header_preproc"
10232 fi
10233 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10234 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10235
10236 fi
10237 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10238   cat >>confdefs.h <<_ACEOF
10239 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10240 _ACEOF
10241
10242 else
10243   { { echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
10244 echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
10245    { (exit 1); exit 1; }; }
10246 fi
10247
10248 done
10249
10250 fi
10251
10252 done
10253
10254 fi
10255
10256 if test "$with_bonjour" = yes ; then
10257   if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10258   echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
10259 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
10260 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10261   echo $ECHO_N "(cached) $ECHO_C" >&6
10262 fi
10263 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
10264 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
10265 else
10266   # Is the header compilable?
10267 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h usability" >&5
10268 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h usability... $ECHO_C" >&6
10269 cat >conftest.$ac_ext <<_ACEOF
10270 /* confdefs.h.  */
10271 _ACEOF
10272 cat confdefs.h >>conftest.$ac_ext
10273 cat >>conftest.$ac_ext <<_ACEOF
10274 /* end confdefs.h.  */
10275 $ac_includes_default
10276 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
10277 _ACEOF
10278 rm -f conftest.$ac_objext
10279 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10280   (eval $ac_compile) 2>conftest.er1
10281   ac_status=$?
10282   grep -v '^ *+' conftest.er1 >conftest.err
10283   rm -f conftest.er1
10284   cat conftest.err >&5
10285   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10286   (exit $ac_status); } &&
10287          { ac_try='test -z "$ac_c_werror_flag"
10288                          || test ! -s conftest.err'
10289   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10290   (eval $ac_try) 2>&5
10291   ac_status=$?
10292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10293   (exit $ac_status); }; } &&
10294          { ac_try='test -s conftest.$ac_objext'
10295   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10296   (eval $ac_try) 2>&5
10297   ac_status=$?
10298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10299   (exit $ac_status); }; }; then
10300   ac_header_compiler=yes
10301 else
10302   echo "$as_me: failed program was:" >&5
10303 sed 's/^/| /' conftest.$ac_ext >&5
10304
10305 ac_header_compiler=no
10306 fi
10307 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10308 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10309 echo "${ECHO_T}$ac_header_compiler" >&6
10310
10311 # Is the header present?
10312 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h presence" >&5
10313 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h presence... $ECHO_C" >&6
10314 cat >conftest.$ac_ext <<_ACEOF
10315 /* confdefs.h.  */
10316 _ACEOF
10317 cat confdefs.h >>conftest.$ac_ext
10318 cat >>conftest.$ac_ext <<_ACEOF
10319 /* end confdefs.h.  */
10320 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
10321 _ACEOF
10322 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10323   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10324   ac_status=$?
10325   grep -v '^ *+' conftest.er1 >conftest.err
10326   rm -f conftest.er1
10327   cat conftest.err >&5
10328   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10329   (exit $ac_status); } >/dev/null; then
10330   if test -s conftest.err; then
10331     ac_cpp_err=$ac_c_preproc_warn_flag
10332     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10333   else
10334     ac_cpp_err=
10335   fi
10336 else
10337   ac_cpp_err=yes
10338 fi
10339 if test -z "$ac_cpp_err"; then
10340   ac_header_preproc=yes
10341 else
10342   echo "$as_me: failed program was:" >&5
10343 sed 's/^/| /' conftest.$ac_ext >&5
10344
10345   ac_header_preproc=no
10346 fi
10347 rm -f conftest.err conftest.$ac_ext
10348 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10349 echo "${ECHO_T}$ac_header_preproc" >&6
10350
10351 # So?  What about this header?
10352 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10353   yes:no: )
10354     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&5
10355 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10356     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&5
10357 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&2;}
10358     ac_header_preproc=yes
10359     ;;
10360   no:yes:* )
10361     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&5
10362 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&2;}
10363     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&5
10364 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&2;}
10365     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&5
10366 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&2;}
10367     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&5
10368 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10369     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
10370 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;}
10371     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&5
10372 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&2;}
10373     (
10374       cat <<\_ASBOX
10375 ## ---------------------------------------- ##
10376 ## Report this to pgsql-bugs@postgresql.org ##
10377 ## ---------------------------------------- ##
10378 _ASBOX
10379     ) |
10380       sed "s/^/$as_me: WARNING:     /" >&2
10381     ;;
10382 esac
10383 echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
10384 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
10385 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10386   echo $ECHO_N "(cached) $ECHO_C" >&6
10387 else
10388   ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h=$ac_header_preproc
10389 fi
10390 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
10391 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
10392
10393 fi
10394 if test $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h = yes; then
10395   :
10396 else
10397   { { echo "$as_me:$LINENO: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&5
10398 echo "$as_me: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&2;}
10399    { (exit 1); exit 1; }; }
10400 fi
10401
10402
10403 fi
10404
10405
10406 ##
10407 ## Types, structures, compiler characteristics
10408 ##
10409
10410  echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
10411 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
10412 if test "${ac_cv_c_const+set}" = set; then
10413   echo $ECHO_N "(cached) $ECHO_C" >&6
10414 else
10415   cat >conftest.$ac_ext <<_ACEOF
10416 /* confdefs.h.  */
10417 _ACEOF
10418 cat confdefs.h >>conftest.$ac_ext
10419 cat >>conftest.$ac_ext <<_ACEOF
10420 /* end confdefs.h.  */
10421
10422 int
10423 main ()
10424 {
10425 /* FIXME: Include the comments suggested by Paul. */
10426 #ifndef __cplusplus
10427   /* Ultrix mips cc rejects this.  */
10428   typedef int charset[2];
10429   const charset x;
10430   /* SunOS 4.1.1 cc rejects this.  */
10431   char const *const *ccp;
10432   char **p;
10433   /* NEC SVR4.0.2 mips cc rejects this.  */
10434   struct point {int x, y;};
10435   static struct point const zero = {0,0};
10436   /* AIX XL C 1.02.0.0 rejects this.
10437      It does not let you subtract one const X* pointer from another in
10438      an arm of an if-expression whose if-part is not a constant
10439      expression */
10440   const char *g = "string";
10441   ccp = &g + (g ? g-g : 0);
10442   /* HPUX 7.0 cc rejects these. */
10443   ++ccp;
10444   p = (char**) ccp;
10445   ccp = (char const *const *) p;
10446   { /* SCO 3.2v4 cc rejects this.  */
10447     char *t;
10448     char const *s = 0 ? (char *) 0 : (char const *) 0;
10449
10450     *t++ = 0;
10451   }
10452   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
10453     int x[] = {25, 17};
10454     const int *foo = &x[0];
10455     ++foo;
10456   }
10457   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
10458     typedef const int *iptr;
10459     iptr p = 0;
10460     ++p;
10461   }
10462   { /* AIX XL C 1.02.0.0 rejects this saying
10463        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
10464     struct s { int j; const int *ap[3]; };
10465     struct s *b; b->j = 5;
10466   }
10467   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
10468     const int foo = 10;
10469   }
10470 #endif
10471
10472   ;
10473   return 0;
10474 }
10475 _ACEOF
10476 rm -f conftest.$ac_objext
10477 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10478   (eval $ac_compile) 2>conftest.er1
10479   ac_status=$?
10480   grep -v '^ *+' conftest.er1 >conftest.err
10481   rm -f conftest.er1
10482   cat conftest.err >&5
10483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10484   (exit $ac_status); } &&
10485          { ac_try='test -z "$ac_c_werror_flag"
10486                          || test ! -s conftest.err'
10487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10488   (eval $ac_try) 2>&5
10489   ac_status=$?
10490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10491   (exit $ac_status); }; } &&
10492          { ac_try='test -s conftest.$ac_objext'
10493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10494   (eval $ac_try) 2>&5
10495   ac_status=$?
10496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10497   (exit $ac_status); }; }; then
10498   ac_cv_c_const=yes
10499 else
10500   echo "$as_me: failed program was:" >&5
10501 sed 's/^/| /' conftest.$ac_ext >&5
10502
10503 ac_cv_c_const=no
10504 fi
10505 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10506 fi
10507 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
10508 echo "${ECHO_T}$ac_cv_c_const" >&6
10509 if test $ac_cv_c_const = no; then
10510
10511 cat >>confdefs.h <<\_ACEOF
10512 #define const
10513 _ACEOF
10514
10515 fi
10516
10517
10518 echo "$as_me:$LINENO: checking for inline" >&5
10519 echo $ECHO_N "checking for inline... $ECHO_C" >&6
10520 if test "${ac_cv_c_inline+set}" = set; then
10521   echo $ECHO_N "(cached) $ECHO_C" >&6
10522 else
10523   ac_cv_c_inline=no
10524 for ac_kw in inline __inline__ __inline; do
10525   cat >conftest.$ac_ext <<_ACEOF
10526 /* confdefs.h.  */
10527 _ACEOF
10528 cat confdefs.h >>conftest.$ac_ext
10529 cat >>conftest.$ac_ext <<_ACEOF
10530 /* end confdefs.h.  */
10531 #ifndef __cplusplus
10532 typedef int foo_t;
10533 static $ac_kw foo_t static_foo () {return 0; }
10534 $ac_kw int foo () {return 0; }
10535 #endif
10536
10537 _ACEOF
10538 rm -f conftest.$ac_objext
10539 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10540   (eval $ac_compile) 2>conftest.er1
10541   ac_status=$?
10542   grep -v '^ *+' conftest.er1 >conftest.err
10543   rm -f conftest.er1
10544   cat conftest.err >&5
10545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10546   (exit $ac_status); } &&
10547          { ac_try='test -z "$ac_c_werror_flag"
10548                          || test ! -s conftest.err'
10549   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10550   (eval $ac_try) 2>&5
10551   ac_status=$?
10552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10553   (exit $ac_status); }; } &&
10554          { ac_try='test -s conftest.$ac_objext'
10555   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10556   (eval $ac_try) 2>&5
10557   ac_status=$?
10558   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10559   (exit $ac_status); }; }; then
10560   ac_cv_c_inline=$ac_kw; break
10561 else
10562   echo "$as_me: failed program was:" >&5
10563 sed 's/^/| /' conftest.$ac_ext >&5
10564
10565 fi
10566 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10567 done
10568
10569 fi
10570 echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
10571 echo "${ECHO_T}$ac_cv_c_inline" >&6
10572 case $ac_cv_c_inline in
10573   inline | yes) ;;
10574   no)
10575 cat >>confdefs.h <<\_ACEOF
10576 #define inline
10577 _ACEOF
10578  ;;
10579   *)  cat >>confdefs.h <<_ACEOF
10580 #define inline $ac_cv_c_inline
10581 _ACEOF
10582  ;;
10583 esac
10584
10585 echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
10586 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6
10587 if test "${ac_cv_c_stringize+set}" = set; then
10588   echo $ECHO_N "(cached) $ECHO_C" >&6
10589 else
10590   cat >conftest.$ac_ext <<_ACEOF
10591 /* confdefs.h.  */
10592 _ACEOF
10593 cat confdefs.h >>conftest.$ac_ext
10594 cat >>conftest.$ac_ext <<_ACEOF
10595 /* end confdefs.h.  */
10596 #define x(y) #y
10597
10598 char *s = x(teststring);
10599 _ACEOF
10600 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10601   $EGREP "#teststring" >/dev/null 2>&1; then
10602   ac_cv_c_stringize=no
10603 else
10604   ac_cv_c_stringize=yes
10605 fi
10606 rm -f conftest*
10607
10608 fi
10609 echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
10610 echo "${ECHO_T}$ac_cv_c_stringize" >&6
10611 if test $ac_cv_c_stringize = yes; then
10612
10613 cat >>confdefs.h <<\_ACEOF
10614 #define HAVE_STRINGIZE 1
10615 _ACEOF
10616
10617 fi
10618
10619 echo "$as_me:$LINENO: checking for signed types" >&5
10620 echo $ECHO_N "checking for signed types... $ECHO_C" >&6
10621 if test "${pgac_cv_c_signed+set}" = set; then
10622   echo $ECHO_N "(cached) $ECHO_C" >&6
10623 else
10624   cat >conftest.$ac_ext <<_ACEOF
10625 /* confdefs.h.  */
10626 _ACEOF
10627 cat confdefs.h >>conftest.$ac_ext
10628 cat >>conftest.$ac_ext <<_ACEOF
10629 /* end confdefs.h.  */
10630
10631 int
10632 main ()
10633 {
10634 signed char c; signed short s; signed int i;
10635   ;
10636   return 0;
10637 }
10638 _ACEOF
10639 rm -f conftest.$ac_objext
10640 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10641   (eval $ac_compile) 2>conftest.er1
10642   ac_status=$?
10643   grep -v '^ *+' conftest.er1 >conftest.err
10644   rm -f conftest.er1
10645   cat conftest.err >&5
10646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10647   (exit $ac_status); } &&
10648          { ac_try='test -z "$ac_c_werror_flag"
10649                          || test ! -s conftest.err'
10650   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10651   (eval $ac_try) 2>&5
10652   ac_status=$?
10653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10654   (exit $ac_status); }; } &&
10655          { ac_try='test -s conftest.$ac_objext'
10656   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10657   (eval $ac_try) 2>&5
10658   ac_status=$?
10659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10660   (exit $ac_status); }; }; then
10661   pgac_cv_c_signed=yes
10662 else
10663   echo "$as_me: failed program was:" >&5
10664 sed 's/^/| /' conftest.$ac_ext >&5
10665
10666 pgac_cv_c_signed=no
10667 fi
10668 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10669 fi
10670 echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
10671 echo "${ECHO_T}$pgac_cv_c_signed" >&6
10672 if test x"$pgac_cv_c_signed" = xno ; then
10673
10674 cat >>confdefs.h <<\_ACEOF
10675 #define signed
10676 _ACEOF
10677
10678 fi
10679 echo "$as_me:$LINENO: checking for working volatile" >&5
10680 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
10681 if test "${ac_cv_c_volatile+set}" = set; then
10682   echo $ECHO_N "(cached) $ECHO_C" >&6
10683 else
10684   cat >conftest.$ac_ext <<_ACEOF
10685 /* confdefs.h.  */
10686 _ACEOF
10687 cat confdefs.h >>conftest.$ac_ext
10688 cat >>conftest.$ac_ext <<_ACEOF
10689 /* end confdefs.h.  */
10690
10691 int
10692 main ()
10693 {
10694
10695 volatile int x;
10696 int * volatile y;
10697   ;
10698   return 0;
10699 }
10700 _ACEOF
10701 rm -f conftest.$ac_objext
10702 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10703   (eval $ac_compile) 2>conftest.er1
10704   ac_status=$?
10705   grep -v '^ *+' conftest.er1 >conftest.err
10706   rm -f conftest.er1
10707   cat conftest.err >&5
10708   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10709   (exit $ac_status); } &&
10710          { ac_try='test -z "$ac_c_werror_flag"
10711                          || test ! -s conftest.err'
10712   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10713   (eval $ac_try) 2>&5
10714   ac_status=$?
10715   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10716   (exit $ac_status); }; } &&
10717          { ac_try='test -s conftest.$ac_objext'
10718   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10719   (eval $ac_try) 2>&5
10720   ac_status=$?
10721   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10722   (exit $ac_status); }; }; then
10723   ac_cv_c_volatile=yes
10724 else
10725   echo "$as_me: failed program was:" >&5
10726 sed 's/^/| /' conftest.$ac_ext >&5
10727
10728 ac_cv_c_volatile=no
10729 fi
10730 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10731 fi
10732 echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
10733 echo "${ECHO_T}$ac_cv_c_volatile" >&6
10734 if test $ac_cv_c_volatile = no; then
10735
10736 cat >>confdefs.h <<\_ACEOF
10737 #define volatile
10738 _ACEOF
10739
10740 fi
10741
10742 echo "$as_me:$LINENO: checking for __func__" >&5
10743 echo $ECHO_N "checking for __func__... $ECHO_C" >&6
10744 if test "${pgac_cv_funcname_func_support+set}" = set; then
10745   echo $ECHO_N "(cached) $ECHO_C" >&6
10746 else
10747   cat >conftest.$ac_ext <<_ACEOF
10748 /* confdefs.h.  */
10749 _ACEOF
10750 cat confdefs.h >>conftest.$ac_ext
10751 cat >>conftest.$ac_ext <<_ACEOF
10752 /* end confdefs.h.  */
10753 #include <stdio.h>
10754 int
10755 main ()
10756 {
10757 printf("%s\n", __func__);
10758   ;
10759   return 0;
10760 }
10761 _ACEOF
10762 rm -f conftest.$ac_objext
10763 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10764   (eval $ac_compile) 2>conftest.er1
10765   ac_status=$?
10766   grep -v '^ *+' conftest.er1 >conftest.err
10767   rm -f conftest.er1
10768   cat conftest.err >&5
10769   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10770   (exit $ac_status); } &&
10771          { ac_try='test -z "$ac_c_werror_flag"
10772                          || test ! -s conftest.err'
10773   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10774   (eval $ac_try) 2>&5
10775   ac_status=$?
10776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10777   (exit $ac_status); }; } &&
10778          { ac_try='test -s conftest.$ac_objext'
10779   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10780   (eval $ac_try) 2>&5
10781   ac_status=$?
10782   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10783   (exit $ac_status); }; }; then
10784   pgac_cv_funcname_func_support=yes
10785 else
10786   echo "$as_me: failed program was:" >&5
10787 sed 's/^/| /' conftest.$ac_ext >&5
10788
10789 pgac_cv_funcname_func_support=no
10790 fi
10791 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10792 fi
10793 echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
10794 echo "${ECHO_T}$pgac_cv_funcname_func_support" >&6
10795 if test x"$pgac_cv_funcname_func_support" = xyes ; then
10796
10797 cat >>confdefs.h <<\_ACEOF
10798 #define HAVE_FUNCNAME__FUNC 1
10799 _ACEOF
10800
10801 else
10802 echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
10803 echo $ECHO_N "checking for __FUNCTION__... $ECHO_C" >&6
10804 if test "${pgac_cv_funcname_function_support+set}" = set; then
10805   echo $ECHO_N "(cached) $ECHO_C" >&6
10806 else
10807   cat >conftest.$ac_ext <<_ACEOF
10808 /* confdefs.h.  */
10809 _ACEOF
10810 cat confdefs.h >>conftest.$ac_ext
10811 cat >>conftest.$ac_ext <<_ACEOF
10812 /* end confdefs.h.  */
10813 #include <stdio.h>
10814 int
10815 main ()
10816 {
10817 printf("%s\n", __FUNCTION__);
10818   ;
10819   return 0;
10820 }
10821 _ACEOF
10822 rm -f conftest.$ac_objext
10823 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10824   (eval $ac_compile) 2>conftest.er1
10825   ac_status=$?
10826   grep -v '^ *+' conftest.er1 >conftest.err
10827   rm -f conftest.er1
10828   cat conftest.err >&5
10829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10830   (exit $ac_status); } &&
10831          { ac_try='test -z "$ac_c_werror_flag"
10832                          || test ! -s conftest.err'
10833   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10834   (eval $ac_try) 2>&5
10835   ac_status=$?
10836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10837   (exit $ac_status); }; } &&
10838          { ac_try='test -s conftest.$ac_objext'
10839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10840   (eval $ac_try) 2>&5
10841   ac_status=$?
10842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10843   (exit $ac_status); }; }; then
10844   pgac_cv_funcname_function_support=yes
10845 else
10846   echo "$as_me: failed program was:" >&5
10847 sed 's/^/| /' conftest.$ac_ext >&5
10848
10849 pgac_cv_funcname_function_support=no
10850 fi
10851 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10852 fi
10853 echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
10854 echo "${ECHO_T}$pgac_cv_funcname_function_support" >&6
10855 if test x"$pgac_cv_funcname_function_support" = xyes ; then
10856
10857 cat >>confdefs.h <<\_ACEOF
10858 #define HAVE_FUNCNAME__FUNCTION 1
10859 _ACEOF
10860
10861 fi
10862 fi
10863 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
10864 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
10865 if test "${ac_cv_struct_tm+set}" = set; then
10866   echo $ECHO_N "(cached) $ECHO_C" >&6
10867 else
10868   cat >conftest.$ac_ext <<_ACEOF
10869 /* confdefs.h.  */
10870 _ACEOF
10871 cat confdefs.h >>conftest.$ac_ext
10872 cat >>conftest.$ac_ext <<_ACEOF
10873 /* end confdefs.h.  */
10874 #include <sys/types.h>
10875 #include <time.h>
10876
10877 int
10878 main ()
10879 {
10880 struct tm *tp; tp->tm_sec;
10881   ;
10882   return 0;
10883 }
10884 _ACEOF
10885 rm -f conftest.$ac_objext
10886 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10887   (eval $ac_compile) 2>conftest.er1
10888   ac_status=$?
10889   grep -v '^ *+' conftest.er1 >conftest.err
10890   rm -f conftest.er1
10891   cat conftest.err >&5
10892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10893   (exit $ac_status); } &&
10894          { ac_try='test -z "$ac_c_werror_flag"
10895                          || test ! -s conftest.err'
10896   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10897   (eval $ac_try) 2>&5
10898   ac_status=$?
10899   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10900   (exit $ac_status); }; } &&
10901          { ac_try='test -s conftest.$ac_objext'
10902   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10903   (eval $ac_try) 2>&5
10904   ac_status=$?
10905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10906   (exit $ac_status); }; }; then
10907   ac_cv_struct_tm=time.h
10908 else
10909   echo "$as_me: failed program was:" >&5
10910 sed 's/^/| /' conftest.$ac_ext >&5
10911
10912 ac_cv_struct_tm=sys/time.h
10913 fi
10914 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10915 fi
10916 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
10917 echo "${ECHO_T}$ac_cv_struct_tm" >&6
10918 if test $ac_cv_struct_tm = sys/time.h; then
10919
10920 cat >>confdefs.h <<\_ACEOF
10921 #define TM_IN_SYS_TIME 1
10922 _ACEOF
10923
10924 fi
10925
10926 echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
10927 echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
10928 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
10929   echo $ECHO_N "(cached) $ECHO_C" >&6
10930 else
10931   cat >conftest.$ac_ext <<_ACEOF
10932 /* confdefs.h.  */
10933 _ACEOF
10934 cat confdefs.h >>conftest.$ac_ext
10935 cat >>conftest.$ac_ext <<_ACEOF
10936 /* end confdefs.h.  */
10937 #include <sys/types.h>
10938 #include <$ac_cv_struct_tm>
10939
10940
10941 int
10942 main ()
10943 {
10944 static struct tm ac_aggr;
10945 if (ac_aggr.tm_zone)
10946 return 0;
10947   ;
10948   return 0;
10949 }
10950 _ACEOF
10951 rm -f conftest.$ac_objext
10952 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10953   (eval $ac_compile) 2>conftest.er1
10954   ac_status=$?
10955   grep -v '^ *+' conftest.er1 >conftest.err
10956   rm -f conftest.er1
10957   cat conftest.err >&5
10958   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10959   (exit $ac_status); } &&
10960          { ac_try='test -z "$ac_c_werror_flag"
10961                          || test ! -s conftest.err'
10962   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10963   (eval $ac_try) 2>&5
10964   ac_status=$?
10965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10966   (exit $ac_status); }; } &&
10967          { ac_try='test -s conftest.$ac_objext'
10968   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10969   (eval $ac_try) 2>&5
10970   ac_status=$?
10971   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10972   (exit $ac_status); }; }; then
10973   ac_cv_member_struct_tm_tm_zone=yes
10974 else
10975   echo "$as_me: failed program was:" >&5
10976 sed 's/^/| /' conftest.$ac_ext >&5
10977
10978 cat >conftest.$ac_ext <<_ACEOF
10979 /* confdefs.h.  */
10980 _ACEOF
10981 cat confdefs.h >>conftest.$ac_ext
10982 cat >>conftest.$ac_ext <<_ACEOF
10983 /* end confdefs.h.  */
10984 #include <sys/types.h>
10985 #include <$ac_cv_struct_tm>
10986
10987
10988 int
10989 main ()
10990 {
10991 static struct tm ac_aggr;
10992 if (sizeof ac_aggr.tm_zone)
10993 return 0;
10994   ;
10995   return 0;
10996 }
10997 _ACEOF
10998 rm -f conftest.$ac_objext
10999 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11000   (eval $ac_compile) 2>conftest.er1
11001   ac_status=$?
11002   grep -v '^ *+' conftest.er1 >conftest.err
11003   rm -f conftest.er1
11004   cat conftest.err >&5
11005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11006   (exit $ac_status); } &&
11007          { ac_try='test -z "$ac_c_werror_flag"
11008                          || test ! -s conftest.err'
11009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11010   (eval $ac_try) 2>&5
11011   ac_status=$?
11012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11013   (exit $ac_status); }; } &&
11014          { ac_try='test -s conftest.$ac_objext'
11015   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11016   (eval $ac_try) 2>&5
11017   ac_status=$?
11018   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11019   (exit $ac_status); }; }; then
11020   ac_cv_member_struct_tm_tm_zone=yes
11021 else
11022   echo "$as_me: failed program was:" >&5
11023 sed 's/^/| /' conftest.$ac_ext >&5
11024
11025 ac_cv_member_struct_tm_tm_zone=no
11026 fi
11027 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11028 fi
11029 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11030 fi
11031 echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
11032 echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
11033 if test $ac_cv_member_struct_tm_tm_zone = yes; then
11034
11035 cat >>confdefs.h <<_ACEOF
11036 #define HAVE_STRUCT_TM_TM_ZONE 1
11037 _ACEOF
11038
11039
11040 fi
11041
11042 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
11043
11044 cat >>confdefs.h <<\_ACEOF
11045 #define HAVE_TM_ZONE 1
11046 _ACEOF
11047
11048 fi
11049 echo "$as_me:$LINENO: checking for tzname" >&5
11050 echo $ECHO_N "checking for tzname... $ECHO_C" >&6
11051 if test "${ac_cv_var_tzname+set}" = set; then
11052   echo $ECHO_N "(cached) $ECHO_C" >&6
11053 else
11054   cat >conftest.$ac_ext <<_ACEOF
11055 /* confdefs.h.  */
11056 _ACEOF
11057 cat confdefs.h >>conftest.$ac_ext
11058 cat >>conftest.$ac_ext <<_ACEOF
11059 /* end confdefs.h.  */
11060 #include <time.h>
11061 #ifndef tzname /* For SGI.  */
11062 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
11063 #endif
11064
11065 int
11066 main ()
11067 {
11068 atoi(*tzname);
11069   ;
11070   return 0;
11071 }
11072 _ACEOF
11073 rm -f conftest.$ac_objext conftest$ac_exeext
11074 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11075   (eval $ac_link) 2>conftest.er1
11076   ac_status=$?
11077   grep -v '^ *+' conftest.er1 >conftest.err
11078   rm -f conftest.er1
11079   cat conftest.err >&5
11080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11081   (exit $ac_status); } &&
11082          { ac_try='test -z "$ac_c_werror_flag"
11083                          || test ! -s conftest.err'
11084   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11085   (eval $ac_try) 2>&5
11086   ac_status=$?
11087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11088   (exit $ac_status); }; } &&
11089          { ac_try='test -s conftest$ac_exeext'
11090   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11091   (eval $ac_try) 2>&5
11092   ac_status=$?
11093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11094   (exit $ac_status); }; }; then
11095   ac_cv_var_tzname=yes
11096 else
11097   echo "$as_me: failed program was:" >&5
11098 sed 's/^/| /' conftest.$ac_ext >&5
11099
11100 ac_cv_var_tzname=no
11101 fi
11102 rm -f conftest.err conftest.$ac_objext \
11103       conftest$ac_exeext conftest.$ac_ext
11104 fi
11105 echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
11106 echo "${ECHO_T}$ac_cv_var_tzname" >&6
11107 if test $ac_cv_var_tzname = yes; then
11108
11109 cat >>confdefs.h <<\_ACEOF
11110 #define HAVE_TZNAME 1
11111 _ACEOF
11112
11113 fi
11114
11115 echo "$as_me:$LINENO: checking for union semun" >&5
11116 echo $ECHO_N "checking for union semun... $ECHO_C" >&6
11117 if test "${ac_cv_type_union_semun+set}" = set; then
11118   echo $ECHO_N "(cached) $ECHO_C" >&6
11119 else
11120   cat >conftest.$ac_ext <<_ACEOF
11121 /* confdefs.h.  */
11122 _ACEOF
11123 cat confdefs.h >>conftest.$ac_ext
11124 cat >>conftest.$ac_ext <<_ACEOF
11125 /* end confdefs.h.  */
11126 #include <sys/types.h>
11127 #include <sys/ipc.h>
11128 #include <sys/sem.h>
11129
11130 int
11131 main ()
11132 {
11133 if ((union semun *) 0)
11134   return 0;
11135 if (sizeof (union semun))
11136   return 0;
11137   ;
11138   return 0;
11139 }
11140 _ACEOF
11141 rm -f conftest.$ac_objext
11142 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11143   (eval $ac_compile) 2>conftest.er1
11144   ac_status=$?
11145   grep -v '^ *+' conftest.er1 >conftest.err
11146   rm -f conftest.er1
11147   cat conftest.err >&5
11148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11149   (exit $ac_status); } &&
11150          { ac_try='test -z "$ac_c_werror_flag"
11151                          || test ! -s conftest.err'
11152   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11153   (eval $ac_try) 2>&5
11154   ac_status=$?
11155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11156   (exit $ac_status); }; } &&
11157          { ac_try='test -s conftest.$ac_objext'
11158   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11159   (eval $ac_try) 2>&5
11160   ac_status=$?
11161   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11162   (exit $ac_status); }; }; then
11163   ac_cv_type_union_semun=yes
11164 else
11165   echo "$as_me: failed program was:" >&5
11166 sed 's/^/| /' conftest.$ac_ext >&5
11167
11168 ac_cv_type_union_semun=no
11169 fi
11170 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11171 fi
11172 echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
11173 echo "${ECHO_T}$ac_cv_type_union_semun" >&6
11174 if test $ac_cv_type_union_semun = yes; then
11175
11176 cat >>confdefs.h <<_ACEOF
11177 #define HAVE_UNION_SEMUN 1
11178 _ACEOF
11179
11180
11181 fi
11182
11183 echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
11184 echo $ECHO_N "checking for struct sockaddr_un... $ECHO_C" >&6
11185 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
11186   echo $ECHO_N "(cached) $ECHO_C" >&6
11187 else
11188   cat >conftest.$ac_ext <<_ACEOF
11189 /* confdefs.h.  */
11190 _ACEOF
11191 cat confdefs.h >>conftest.$ac_ext
11192 cat >>conftest.$ac_ext <<_ACEOF
11193 /* end confdefs.h.  */
11194 #include <sys/types.h>
11195 #ifdef HAVE_SYS_UN_H
11196 #include <sys/un.h>
11197 #endif
11198
11199
11200 int
11201 main ()
11202 {
11203 if ((struct sockaddr_un *) 0)
11204   return 0;
11205 if (sizeof (struct sockaddr_un))
11206   return 0;
11207   ;
11208   return 0;
11209 }
11210 _ACEOF
11211 rm -f conftest.$ac_objext
11212 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11213   (eval $ac_compile) 2>conftest.er1
11214   ac_status=$?
11215   grep -v '^ *+' conftest.er1 >conftest.err
11216   rm -f conftest.er1
11217   cat conftest.err >&5
11218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11219   (exit $ac_status); } &&
11220          { ac_try='test -z "$ac_c_werror_flag"
11221                          || test ! -s conftest.err'
11222   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11223   (eval $ac_try) 2>&5
11224   ac_status=$?
11225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11226   (exit $ac_status); }; } &&
11227          { ac_try='test -s conftest.$ac_objext'
11228   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11229   (eval $ac_try) 2>&5
11230   ac_status=$?
11231   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11232   (exit $ac_status); }; }; then
11233   ac_cv_type_struct_sockaddr_un=yes
11234 else
11235   echo "$as_me: failed program was:" >&5
11236 sed 's/^/| /' conftest.$ac_ext >&5
11237
11238 ac_cv_type_struct_sockaddr_un=no
11239 fi
11240 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11241 fi
11242 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
11243 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_un" >&6
11244 if test $ac_cv_type_struct_sockaddr_un = yes; then
11245
11246 cat >>confdefs.h <<_ACEOF
11247 #define HAVE_STRUCT_SOCKADDR_UN 1
11248 _ACEOF
11249
11250
11251 cat >>confdefs.h <<\_ACEOF
11252 #define HAVE_UNIX_SOCKETS 1
11253 _ACEOF
11254
11255 fi
11256
11257 echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
11258 echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6
11259 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
11260   echo $ECHO_N "(cached) $ECHO_C" >&6
11261 else
11262   cat >conftest.$ac_ext <<_ACEOF
11263 /* confdefs.h.  */
11264 _ACEOF
11265 cat confdefs.h >>conftest.$ac_ext
11266 cat >>conftest.$ac_ext <<_ACEOF
11267 /* end confdefs.h.  */
11268 #include <sys/types.h>
11269 #ifdef HAVE_SYS_SOCKET_H
11270 #include <sys/socket.h>
11271 #endif
11272
11273
11274 int
11275 main ()
11276 {
11277 if ((struct sockaddr_storage *) 0)
11278   return 0;
11279 if (sizeof (struct sockaddr_storage))
11280   return 0;
11281   ;
11282   return 0;
11283 }
11284 _ACEOF
11285 rm -f conftest.$ac_objext
11286 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11287   (eval $ac_compile) 2>conftest.er1
11288   ac_status=$?
11289   grep -v '^ *+' conftest.er1 >conftest.err
11290   rm -f conftest.er1
11291   cat conftest.err >&5
11292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11293   (exit $ac_status); } &&
11294          { ac_try='test -z "$ac_c_werror_flag"
11295                          || test ! -s conftest.err'
11296   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11297   (eval $ac_try) 2>&5
11298   ac_status=$?
11299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11300   (exit $ac_status); }; } &&
11301          { ac_try='test -s conftest.$ac_objext'
11302   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11303   (eval $ac_try) 2>&5
11304   ac_status=$?
11305   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11306   (exit $ac_status); }; }; then
11307   ac_cv_type_struct_sockaddr_storage=yes
11308 else
11309   echo "$as_me: failed program was:" >&5
11310 sed 's/^/| /' conftest.$ac_ext >&5
11311
11312 ac_cv_type_struct_sockaddr_storage=no
11313 fi
11314 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11315 fi
11316 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
11317 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_storage" >&6
11318 if test $ac_cv_type_struct_sockaddr_storage = yes; then
11319
11320 cat >>confdefs.h <<_ACEOF
11321 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
11322 _ACEOF
11323
11324
11325 fi
11326
11327 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
11328 echo $ECHO_N "checking for struct sockaddr_storage.ss_family... $ECHO_C" >&6
11329 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
11330   echo $ECHO_N "(cached) $ECHO_C" >&6
11331 else
11332   cat >conftest.$ac_ext <<_ACEOF
11333 /* confdefs.h.  */
11334 _ACEOF
11335 cat confdefs.h >>conftest.$ac_ext
11336 cat >>conftest.$ac_ext <<_ACEOF
11337 /* end confdefs.h.  */
11338 #include <sys/types.h>
11339 #ifdef HAVE_SYS_SOCKET_H
11340 #include <sys/socket.h>
11341 #endif
11342
11343
11344 int
11345 main ()
11346 {
11347 static struct sockaddr_storage ac_aggr;
11348 if (ac_aggr.ss_family)
11349 return 0;
11350   ;
11351   return 0;
11352 }
11353 _ACEOF
11354 rm -f conftest.$ac_objext
11355 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11356   (eval $ac_compile) 2>conftest.er1
11357   ac_status=$?
11358   grep -v '^ *+' conftest.er1 >conftest.err
11359   rm -f conftest.er1
11360   cat conftest.err >&5
11361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11362   (exit $ac_status); } &&
11363          { ac_try='test -z "$ac_c_werror_flag"
11364                          || test ! -s conftest.err'
11365   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11366   (eval $ac_try) 2>&5
11367   ac_status=$?
11368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11369   (exit $ac_status); }; } &&
11370          { ac_try='test -s conftest.$ac_objext'
11371   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11372   (eval $ac_try) 2>&5
11373   ac_status=$?
11374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11375   (exit $ac_status); }; }; then
11376   ac_cv_member_struct_sockaddr_storage_ss_family=yes
11377 else
11378   echo "$as_me: failed program was:" >&5
11379 sed 's/^/| /' conftest.$ac_ext >&5
11380
11381 cat >conftest.$ac_ext <<_ACEOF
11382 /* confdefs.h.  */
11383 _ACEOF
11384 cat confdefs.h >>conftest.$ac_ext
11385 cat >>conftest.$ac_ext <<_ACEOF
11386 /* end confdefs.h.  */
11387 #include <sys/types.h>
11388 #ifdef HAVE_SYS_SOCKET_H
11389 #include <sys/socket.h>
11390 #endif
11391
11392
11393 int
11394 main ()
11395 {
11396 static struct sockaddr_storage ac_aggr;
11397 if (sizeof ac_aggr.ss_family)
11398 return 0;
11399   ;
11400   return 0;
11401 }
11402 _ACEOF
11403 rm -f conftest.$ac_objext
11404 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11405   (eval $ac_compile) 2>conftest.er1
11406   ac_status=$?
11407   grep -v '^ *+' conftest.er1 >conftest.err
11408   rm -f conftest.er1
11409   cat conftest.err >&5
11410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11411   (exit $ac_status); } &&
11412          { ac_try='test -z "$ac_c_werror_flag"
11413                          || test ! -s conftest.err'
11414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11415   (eval $ac_try) 2>&5
11416   ac_status=$?
11417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11418   (exit $ac_status); }; } &&
11419          { ac_try='test -s conftest.$ac_objext'
11420   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11421   (eval $ac_try) 2>&5
11422   ac_status=$?
11423   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11424   (exit $ac_status); }; }; then
11425   ac_cv_member_struct_sockaddr_storage_ss_family=yes
11426 else
11427   echo "$as_me: failed program was:" >&5
11428 sed 's/^/| /' conftest.$ac_ext >&5
11429
11430 ac_cv_member_struct_sockaddr_storage_ss_family=no
11431 fi
11432 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11433 fi
11434 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11435 fi
11436 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
11437 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_family" >&6
11438 if test $ac_cv_member_struct_sockaddr_storage_ss_family = yes; then
11439
11440 cat >>confdefs.h <<_ACEOF
11441 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
11442 _ACEOF
11443
11444
11445 fi
11446 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
11447 echo $ECHO_N "checking for struct sockaddr_storage.__ss_family... $ECHO_C" >&6
11448 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
11449   echo $ECHO_N "(cached) $ECHO_C" >&6
11450 else
11451   cat >conftest.$ac_ext <<_ACEOF
11452 /* confdefs.h.  */
11453 _ACEOF
11454 cat confdefs.h >>conftest.$ac_ext
11455 cat >>conftest.$ac_ext <<_ACEOF
11456 /* end confdefs.h.  */
11457 #include <sys/types.h>
11458 #ifdef HAVE_SYS_SOCKET_H
11459 #include <sys/socket.h>
11460 #endif
11461
11462
11463 int
11464 main ()
11465 {
11466 static struct sockaddr_storage ac_aggr;
11467 if (ac_aggr.__ss_family)
11468 return 0;
11469   ;
11470   return 0;
11471 }
11472 _ACEOF
11473 rm -f conftest.$ac_objext
11474 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11475   (eval $ac_compile) 2>conftest.er1
11476   ac_status=$?
11477   grep -v '^ *+' conftest.er1 >conftest.err
11478   rm -f conftest.er1
11479   cat conftest.err >&5
11480   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11481   (exit $ac_status); } &&
11482          { ac_try='test -z "$ac_c_werror_flag"
11483                          || test ! -s conftest.err'
11484   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11485   (eval $ac_try) 2>&5
11486   ac_status=$?
11487   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11488   (exit $ac_status); }; } &&
11489          { ac_try='test -s conftest.$ac_objext'
11490   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11491   (eval $ac_try) 2>&5
11492   ac_status=$?
11493   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11494   (exit $ac_status); }; }; then
11495   ac_cv_member_struct_sockaddr_storage___ss_family=yes
11496 else
11497   echo "$as_me: failed program was:" >&5
11498 sed 's/^/| /' conftest.$ac_ext >&5
11499
11500 cat >conftest.$ac_ext <<_ACEOF
11501 /* confdefs.h.  */
11502 _ACEOF
11503 cat confdefs.h >>conftest.$ac_ext
11504 cat >>conftest.$ac_ext <<_ACEOF
11505 /* end confdefs.h.  */
11506 #include <sys/types.h>
11507 #ifdef HAVE_SYS_SOCKET_H
11508 #include <sys/socket.h>
11509 #endif
11510
11511
11512 int
11513 main ()
11514 {
11515 static struct sockaddr_storage ac_aggr;
11516 if (sizeof ac_aggr.__ss_family)
11517 return 0;
11518   ;
11519   return 0;
11520 }
11521 _ACEOF
11522 rm -f conftest.$ac_objext
11523 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11524   (eval $ac_compile) 2>conftest.er1
11525   ac_status=$?
11526   grep -v '^ *+' conftest.er1 >conftest.err
11527   rm -f conftest.er1
11528   cat conftest.err >&5
11529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11530   (exit $ac_status); } &&
11531          { ac_try='test -z "$ac_c_werror_flag"
11532                          || test ! -s conftest.err'
11533   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11534   (eval $ac_try) 2>&5
11535   ac_status=$?
11536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11537   (exit $ac_status); }; } &&
11538          { ac_try='test -s conftest.$ac_objext'
11539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11540   (eval $ac_try) 2>&5
11541   ac_status=$?
11542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11543   (exit $ac_status); }; }; then
11544   ac_cv_member_struct_sockaddr_storage___ss_family=yes
11545 else
11546   echo "$as_me: failed program was:" >&5
11547 sed 's/^/| /' conftest.$ac_ext >&5
11548
11549 ac_cv_member_struct_sockaddr_storage___ss_family=no
11550 fi
11551 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11552 fi
11553 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11554 fi
11555 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
11556 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_family" >&6
11557 if test $ac_cv_member_struct_sockaddr_storage___ss_family = yes; then
11558
11559 cat >>confdefs.h <<_ACEOF
11560 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
11561 _ACEOF
11562
11563
11564 fi
11565 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
11566 echo $ECHO_N "checking for struct sockaddr_storage.ss_len... $ECHO_C" >&6
11567 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
11568   echo $ECHO_N "(cached) $ECHO_C" >&6
11569 else
11570   cat >conftest.$ac_ext <<_ACEOF
11571 /* confdefs.h.  */
11572 _ACEOF
11573 cat confdefs.h >>conftest.$ac_ext
11574 cat >>conftest.$ac_ext <<_ACEOF
11575 /* end confdefs.h.  */
11576 #include <sys/types.h>
11577 #ifdef HAVE_SYS_SOCKET_H
11578 #include <sys/socket.h>
11579 #endif
11580
11581
11582 int
11583 main ()
11584 {
11585 static struct sockaddr_storage ac_aggr;
11586 if (ac_aggr.ss_len)
11587 return 0;
11588   ;
11589   return 0;
11590 }
11591 _ACEOF
11592 rm -f conftest.$ac_objext
11593 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11594   (eval $ac_compile) 2>conftest.er1
11595   ac_status=$?
11596   grep -v '^ *+' conftest.er1 >conftest.err
11597   rm -f conftest.er1
11598   cat conftest.err >&5
11599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11600   (exit $ac_status); } &&
11601          { ac_try='test -z "$ac_c_werror_flag"
11602                          || test ! -s conftest.err'
11603   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11604   (eval $ac_try) 2>&5
11605   ac_status=$?
11606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11607   (exit $ac_status); }; } &&
11608          { ac_try='test -s conftest.$ac_objext'
11609   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11610   (eval $ac_try) 2>&5
11611   ac_status=$?
11612   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11613   (exit $ac_status); }; }; then
11614   ac_cv_member_struct_sockaddr_storage_ss_len=yes
11615 else
11616   echo "$as_me: failed program was:" >&5
11617 sed 's/^/| /' conftest.$ac_ext >&5
11618
11619 cat >conftest.$ac_ext <<_ACEOF
11620 /* confdefs.h.  */
11621 _ACEOF
11622 cat confdefs.h >>conftest.$ac_ext
11623 cat >>conftest.$ac_ext <<_ACEOF
11624 /* end confdefs.h.  */
11625 #include <sys/types.h>
11626 #ifdef HAVE_SYS_SOCKET_H
11627 #include <sys/socket.h>
11628 #endif
11629
11630
11631 int
11632 main ()
11633 {
11634 static struct sockaddr_storage ac_aggr;
11635 if (sizeof ac_aggr.ss_len)
11636 return 0;
11637   ;
11638   return 0;
11639 }
11640 _ACEOF
11641 rm -f conftest.$ac_objext
11642 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11643   (eval $ac_compile) 2>conftest.er1
11644   ac_status=$?
11645   grep -v '^ *+' conftest.er1 >conftest.err
11646   rm -f conftest.er1
11647   cat conftest.err >&5
11648   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11649   (exit $ac_status); } &&
11650          { ac_try='test -z "$ac_c_werror_flag"
11651                          || test ! -s conftest.err'
11652   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11653   (eval $ac_try) 2>&5
11654   ac_status=$?
11655   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11656   (exit $ac_status); }; } &&
11657          { ac_try='test -s conftest.$ac_objext'
11658   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11659   (eval $ac_try) 2>&5
11660   ac_status=$?
11661   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11662   (exit $ac_status); }; }; then
11663   ac_cv_member_struct_sockaddr_storage_ss_len=yes
11664 else
11665   echo "$as_me: failed program was:" >&5
11666 sed 's/^/| /' conftest.$ac_ext >&5
11667
11668 ac_cv_member_struct_sockaddr_storage_ss_len=no
11669 fi
11670 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11671 fi
11672 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11673 fi
11674 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
11675 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_len" >&6
11676 if test $ac_cv_member_struct_sockaddr_storage_ss_len = yes; then
11677
11678 cat >>confdefs.h <<_ACEOF
11679 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
11680 _ACEOF
11681
11682
11683 fi
11684 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
11685 echo $ECHO_N "checking for struct sockaddr_storage.__ss_len... $ECHO_C" >&6
11686 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
11687   echo $ECHO_N "(cached) $ECHO_C" >&6
11688 else
11689   cat >conftest.$ac_ext <<_ACEOF
11690 /* confdefs.h.  */
11691 _ACEOF
11692 cat confdefs.h >>conftest.$ac_ext
11693 cat >>conftest.$ac_ext <<_ACEOF
11694 /* end confdefs.h.  */
11695 #include <sys/types.h>
11696 #ifdef HAVE_SYS_SOCKET_H
11697 #include <sys/socket.h>
11698 #endif
11699
11700
11701 int
11702 main ()
11703 {
11704 static struct sockaddr_storage ac_aggr;
11705 if (ac_aggr.__ss_len)
11706 return 0;
11707   ;
11708   return 0;
11709 }
11710 _ACEOF
11711 rm -f conftest.$ac_objext
11712 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11713   (eval $ac_compile) 2>conftest.er1
11714   ac_status=$?
11715   grep -v '^ *+' conftest.er1 >conftest.err
11716   rm -f conftest.er1
11717   cat conftest.err >&5
11718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11719   (exit $ac_status); } &&
11720          { ac_try='test -z "$ac_c_werror_flag"
11721                          || test ! -s conftest.err'
11722   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11723   (eval $ac_try) 2>&5
11724   ac_status=$?
11725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11726   (exit $ac_status); }; } &&
11727          { ac_try='test -s conftest.$ac_objext'
11728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11729   (eval $ac_try) 2>&5
11730   ac_status=$?
11731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11732   (exit $ac_status); }; }; then
11733   ac_cv_member_struct_sockaddr_storage___ss_len=yes
11734 else
11735   echo "$as_me: failed program was:" >&5
11736 sed 's/^/| /' conftest.$ac_ext >&5
11737
11738 cat >conftest.$ac_ext <<_ACEOF
11739 /* confdefs.h.  */
11740 _ACEOF
11741 cat confdefs.h >>conftest.$ac_ext
11742 cat >>conftest.$ac_ext <<_ACEOF
11743 /* end confdefs.h.  */
11744 #include <sys/types.h>
11745 #ifdef HAVE_SYS_SOCKET_H
11746 #include <sys/socket.h>
11747 #endif
11748
11749
11750 int
11751 main ()
11752 {
11753 static struct sockaddr_storage ac_aggr;
11754 if (sizeof ac_aggr.__ss_len)
11755 return 0;
11756   ;
11757   return 0;
11758 }
11759 _ACEOF
11760 rm -f conftest.$ac_objext
11761 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11762   (eval $ac_compile) 2>conftest.er1
11763   ac_status=$?
11764   grep -v '^ *+' conftest.er1 >conftest.err
11765   rm -f conftest.er1
11766   cat conftest.err >&5
11767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11768   (exit $ac_status); } &&
11769          { ac_try='test -z "$ac_c_werror_flag"
11770                          || test ! -s conftest.err'
11771   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11772   (eval $ac_try) 2>&5
11773   ac_status=$?
11774   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11775   (exit $ac_status); }; } &&
11776          { ac_try='test -s conftest.$ac_objext'
11777   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11778   (eval $ac_try) 2>&5
11779   ac_status=$?
11780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11781   (exit $ac_status); }; }; then
11782   ac_cv_member_struct_sockaddr_storage___ss_len=yes
11783 else
11784   echo "$as_me: failed program was:" >&5
11785 sed 's/^/| /' conftest.$ac_ext >&5
11786
11787 ac_cv_member_struct_sockaddr_storage___ss_len=no
11788 fi
11789 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11790 fi
11791 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11792 fi
11793 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
11794 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_len" >&6
11795 if test $ac_cv_member_struct_sockaddr_storage___ss_len = yes; then
11796
11797 cat >>confdefs.h <<_ACEOF
11798 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
11799 _ACEOF
11800
11801
11802 fi
11803 echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
11804 echo $ECHO_N "checking for struct sockaddr.sa_len... $ECHO_C" >&6
11805 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
11806   echo $ECHO_N "(cached) $ECHO_C" >&6
11807 else
11808   cat >conftest.$ac_ext <<_ACEOF
11809 /* confdefs.h.  */
11810 _ACEOF
11811 cat confdefs.h >>conftest.$ac_ext
11812 cat >>conftest.$ac_ext <<_ACEOF
11813 /* end confdefs.h.  */
11814 #include <sys/types.h>
11815 #ifdef HAVE_SYS_SOCKET_H
11816 #include <sys/socket.h>
11817 #endif
11818
11819
11820 int
11821 main ()
11822 {
11823 static struct sockaddr ac_aggr;
11824 if (ac_aggr.sa_len)
11825 return 0;
11826   ;
11827   return 0;
11828 }
11829 _ACEOF
11830 rm -f conftest.$ac_objext
11831 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11832   (eval $ac_compile) 2>conftest.er1
11833   ac_status=$?
11834   grep -v '^ *+' conftest.er1 >conftest.err
11835   rm -f conftest.er1
11836   cat conftest.err >&5
11837   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11838   (exit $ac_status); } &&
11839          { ac_try='test -z "$ac_c_werror_flag"
11840                          || test ! -s conftest.err'
11841   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11842   (eval $ac_try) 2>&5
11843   ac_status=$?
11844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11845   (exit $ac_status); }; } &&
11846          { ac_try='test -s conftest.$ac_objext'
11847   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11848   (eval $ac_try) 2>&5
11849   ac_status=$?
11850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11851   (exit $ac_status); }; }; then
11852   ac_cv_member_struct_sockaddr_sa_len=yes
11853 else
11854   echo "$as_me: failed program was:" >&5
11855 sed 's/^/| /' conftest.$ac_ext >&5
11856
11857 cat >conftest.$ac_ext <<_ACEOF
11858 /* confdefs.h.  */
11859 _ACEOF
11860 cat confdefs.h >>conftest.$ac_ext
11861 cat >>conftest.$ac_ext <<_ACEOF
11862 /* end confdefs.h.  */
11863 #include <sys/types.h>
11864 #ifdef HAVE_SYS_SOCKET_H
11865 #include <sys/socket.h>
11866 #endif
11867
11868
11869 int
11870 main ()
11871 {
11872 static struct sockaddr ac_aggr;
11873 if (sizeof ac_aggr.sa_len)
11874 return 0;
11875   ;
11876   return 0;
11877 }
11878 _ACEOF
11879 rm -f conftest.$ac_objext
11880 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11881   (eval $ac_compile) 2>conftest.er1
11882   ac_status=$?
11883   grep -v '^ *+' conftest.er1 >conftest.err
11884   rm -f conftest.er1
11885   cat conftest.err >&5
11886   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11887   (exit $ac_status); } &&
11888          { ac_try='test -z "$ac_c_werror_flag"
11889                          || test ! -s conftest.err'
11890   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11891   (eval $ac_try) 2>&5
11892   ac_status=$?
11893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11894   (exit $ac_status); }; } &&
11895          { ac_try='test -s conftest.$ac_objext'
11896   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11897   (eval $ac_try) 2>&5
11898   ac_status=$?
11899   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11900   (exit $ac_status); }; }; then
11901   ac_cv_member_struct_sockaddr_sa_len=yes
11902 else
11903   echo "$as_me: failed program was:" >&5
11904 sed 's/^/| /' conftest.$ac_ext >&5
11905
11906 ac_cv_member_struct_sockaddr_sa_len=no
11907 fi
11908 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11909 fi
11910 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11911 fi
11912 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
11913 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_sa_len" >&6
11914 if test $ac_cv_member_struct_sockaddr_sa_len = yes; then
11915
11916 cat >>confdefs.h <<_ACEOF
11917 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
11918 _ACEOF
11919
11920
11921 fi
11922
11923 echo "$as_me:$LINENO: checking for struct addrinfo" >&5
11924 echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6
11925 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
11926   echo $ECHO_N "(cached) $ECHO_C" >&6
11927 else
11928   cat >conftest.$ac_ext <<_ACEOF
11929 /* confdefs.h.  */
11930 _ACEOF
11931 cat confdefs.h >>conftest.$ac_ext
11932 cat >>conftest.$ac_ext <<_ACEOF
11933 /* end confdefs.h.  */
11934 #include <sys/types.h>
11935 #include <sys/socket.h>
11936 #include <netdb.h>
11937
11938
11939 int
11940 main ()
11941 {
11942 if ((struct addrinfo *) 0)
11943   return 0;
11944 if (sizeof (struct addrinfo))
11945   return 0;
11946   ;
11947   return 0;
11948 }
11949 _ACEOF
11950 rm -f conftest.$ac_objext
11951 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11952   (eval $ac_compile) 2>conftest.er1
11953   ac_status=$?
11954   grep -v '^ *+' conftest.er1 >conftest.err
11955   rm -f conftest.er1
11956   cat conftest.err >&5
11957   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11958   (exit $ac_status); } &&
11959          { ac_try='test -z "$ac_c_werror_flag"
11960                          || test ! -s conftest.err'
11961   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11962   (eval $ac_try) 2>&5
11963   ac_status=$?
11964   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11965   (exit $ac_status); }; } &&
11966          { ac_try='test -s conftest.$ac_objext'
11967   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11968   (eval $ac_try) 2>&5
11969   ac_status=$?
11970   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11971   (exit $ac_status); }; }; then
11972   ac_cv_type_struct_addrinfo=yes
11973 else
11974   echo "$as_me: failed program was:" >&5
11975 sed 's/^/| /' conftest.$ac_ext >&5
11976
11977 ac_cv_type_struct_addrinfo=no
11978 fi
11979 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11980 fi
11981 echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
11982 echo "${ECHO_T}$ac_cv_type_struct_addrinfo" >&6
11983 if test $ac_cv_type_struct_addrinfo = yes; then
11984
11985 cat >>confdefs.h <<_ACEOF
11986 #define HAVE_STRUCT_ADDRINFO 1
11987 _ACEOF
11988
11989
11990 fi
11991
11992
11993 echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
11994 echo $ECHO_N "checking for struct cmsgcred... $ECHO_C" >&6
11995 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
11996   echo $ECHO_N "(cached) $ECHO_C" >&6
11997 else
11998   cat >conftest.$ac_ext <<_ACEOF
11999 /* confdefs.h.  */
12000 _ACEOF
12001 cat confdefs.h >>conftest.$ac_ext
12002 cat >>conftest.$ac_ext <<_ACEOF
12003 /* end confdefs.h.  */
12004 #include <sys/param.h>
12005 #include <sys/types.h>
12006 #include <sys/socket.h>
12007 #include <sys/ucred.h>
12008
12009 int
12010 main ()
12011 {
12012 if ((struct cmsgcred *) 0)
12013   return 0;
12014 if (sizeof (struct cmsgcred))
12015   return 0;
12016   ;
12017   return 0;
12018 }
12019 _ACEOF
12020 rm -f conftest.$ac_objext
12021 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12022   (eval $ac_compile) 2>conftest.er1
12023   ac_status=$?
12024   grep -v '^ *+' conftest.er1 >conftest.err
12025   rm -f conftest.er1
12026   cat conftest.err >&5
12027   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12028   (exit $ac_status); } &&
12029          { ac_try='test -z "$ac_c_werror_flag"
12030                          || test ! -s conftest.err'
12031   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12032   (eval $ac_try) 2>&5
12033   ac_status=$?
12034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12035   (exit $ac_status); }; } &&
12036          { ac_try='test -s conftest.$ac_objext'
12037   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12038   (eval $ac_try) 2>&5
12039   ac_status=$?
12040   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12041   (exit $ac_status); }; }; then
12042   ac_cv_type_struct_cmsgcred=yes
12043 else
12044   echo "$as_me: failed program was:" >&5
12045 sed 's/^/| /' conftest.$ac_ext >&5
12046
12047 ac_cv_type_struct_cmsgcred=no
12048 fi
12049 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12050 fi
12051 echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
12052 echo "${ECHO_T}$ac_cv_type_struct_cmsgcred" >&6
12053 if test $ac_cv_type_struct_cmsgcred = yes; then
12054
12055 cat >>confdefs.h <<_ACEOF
12056 #define HAVE_STRUCT_CMSGCRED 1
12057 _ACEOF
12058
12059
12060 fi
12061 echo "$as_me:$LINENO: checking for struct fcred" >&5
12062 echo $ECHO_N "checking for struct fcred... $ECHO_C" >&6
12063 if test "${ac_cv_type_struct_fcred+set}" = set; then
12064   echo $ECHO_N "(cached) $ECHO_C" >&6
12065 else
12066   cat >conftest.$ac_ext <<_ACEOF
12067 /* confdefs.h.  */
12068 _ACEOF
12069 cat confdefs.h >>conftest.$ac_ext
12070 cat >>conftest.$ac_ext <<_ACEOF
12071 /* end confdefs.h.  */
12072 #include <sys/param.h>
12073 #include <sys/types.h>
12074 #include <sys/socket.h>
12075 #include <sys/ucred.h>
12076
12077 int
12078 main ()
12079 {
12080 if ((struct fcred *) 0)
12081   return 0;
12082 if (sizeof (struct fcred))
12083   return 0;
12084   ;
12085   return 0;
12086 }
12087 _ACEOF
12088 rm -f conftest.$ac_objext
12089 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12090   (eval $ac_compile) 2>conftest.er1
12091   ac_status=$?
12092   grep -v '^ *+' conftest.er1 >conftest.err
12093   rm -f conftest.er1
12094   cat conftest.err >&5
12095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12096   (exit $ac_status); } &&
12097          { ac_try='test -z "$ac_c_werror_flag"
12098                          || test ! -s conftest.err'
12099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12100   (eval $ac_try) 2>&5
12101   ac_status=$?
12102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12103   (exit $ac_status); }; } &&
12104          { ac_try='test -s conftest.$ac_objext'
12105   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12106   (eval $ac_try) 2>&5
12107   ac_status=$?
12108   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12109   (exit $ac_status); }; }; then
12110   ac_cv_type_struct_fcred=yes
12111 else
12112   echo "$as_me: failed program was:" >&5
12113 sed 's/^/| /' conftest.$ac_ext >&5
12114
12115 ac_cv_type_struct_fcred=no
12116 fi
12117 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12118 fi
12119 echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
12120 echo "${ECHO_T}$ac_cv_type_struct_fcred" >&6
12121 if test $ac_cv_type_struct_fcred = yes; then
12122
12123 cat >>confdefs.h <<_ACEOF
12124 #define HAVE_STRUCT_FCRED 1
12125 _ACEOF
12126
12127
12128 fi
12129 echo "$as_me:$LINENO: checking for struct sockcred" >&5
12130 echo $ECHO_N "checking for struct sockcred... $ECHO_C" >&6
12131 if test "${ac_cv_type_struct_sockcred+set}" = set; then
12132   echo $ECHO_N "(cached) $ECHO_C" >&6
12133 else
12134   cat >conftest.$ac_ext <<_ACEOF
12135 /* confdefs.h.  */
12136 _ACEOF
12137 cat confdefs.h >>conftest.$ac_ext
12138 cat >>conftest.$ac_ext <<_ACEOF
12139 /* end confdefs.h.  */
12140 #include <sys/param.h>
12141 #include <sys/types.h>
12142 #include <sys/socket.h>
12143 #include <sys/ucred.h>
12144
12145 int
12146 main ()
12147 {
12148 if ((struct sockcred *) 0)
12149   return 0;
12150 if (sizeof (struct sockcred))
12151   return 0;
12152   ;
12153   return 0;
12154 }
12155 _ACEOF
12156 rm -f conftest.$ac_objext
12157 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12158   (eval $ac_compile) 2>conftest.er1
12159   ac_status=$?
12160   grep -v '^ *+' conftest.er1 >conftest.err
12161   rm -f conftest.er1
12162   cat conftest.err >&5
12163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12164   (exit $ac_status); } &&
12165          { ac_try='test -z "$ac_c_werror_flag"
12166                          || test ! -s conftest.err'
12167   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12168   (eval $ac_try) 2>&5
12169   ac_status=$?
12170   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12171   (exit $ac_status); }; } &&
12172          { ac_try='test -s conftest.$ac_objext'
12173   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12174   (eval $ac_try) 2>&5
12175   ac_status=$?
12176   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12177   (exit $ac_status); }; }; then
12178   ac_cv_type_struct_sockcred=yes
12179 else
12180   echo "$as_me: failed program was:" >&5
12181 sed 's/^/| /' conftest.$ac_ext >&5
12182
12183 ac_cv_type_struct_sockcred=no
12184 fi
12185 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12186 fi
12187 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
12188 echo "${ECHO_T}$ac_cv_type_struct_sockcred" >&6
12189 if test $ac_cv_type_struct_sockcred = yes; then
12190
12191 cat >>confdefs.h <<_ACEOF
12192 #define HAVE_STRUCT_SOCKCRED 1
12193 _ACEOF
12194
12195
12196 fi
12197
12198
12199 echo "$as_me:$LINENO: checking for struct option" >&5
12200 echo $ECHO_N "checking for struct option... $ECHO_C" >&6
12201 if test "${ac_cv_type_struct_option+set}" = set; then
12202   echo $ECHO_N "(cached) $ECHO_C" >&6
12203 else
12204   cat >conftest.$ac_ext <<_ACEOF
12205 /* confdefs.h.  */
12206 _ACEOF
12207 cat confdefs.h >>conftest.$ac_ext
12208 cat >>conftest.$ac_ext <<_ACEOF
12209 /* end confdefs.h.  */
12210 #ifdef HAVE_GETOPT_H
12211 #include <getopt.h>
12212 #endif
12213
12214 int
12215 main ()
12216 {
12217 if ((struct option *) 0)
12218   return 0;
12219 if (sizeof (struct option))
12220   return 0;
12221   ;
12222   return 0;
12223 }
12224 _ACEOF
12225 rm -f conftest.$ac_objext
12226 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12227   (eval $ac_compile) 2>conftest.er1
12228   ac_status=$?
12229   grep -v '^ *+' conftest.er1 >conftest.err
12230   rm -f conftest.er1
12231   cat conftest.err >&5
12232   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12233   (exit $ac_status); } &&
12234          { ac_try='test -z "$ac_c_werror_flag"
12235                          || test ! -s conftest.err'
12236   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12237   (eval $ac_try) 2>&5
12238   ac_status=$?
12239   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12240   (exit $ac_status); }; } &&
12241          { ac_try='test -s conftest.$ac_objext'
12242   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12243   (eval $ac_try) 2>&5
12244   ac_status=$?
12245   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12246   (exit $ac_status); }; }; then
12247   ac_cv_type_struct_option=yes
12248 else
12249   echo "$as_me: failed program was:" >&5
12250 sed 's/^/| /' conftest.$ac_ext >&5
12251
12252 ac_cv_type_struct_option=no
12253 fi
12254 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12255 fi
12256 echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
12257 echo "${ECHO_T}$ac_cv_type_struct_option" >&6
12258 if test $ac_cv_type_struct_option = yes; then
12259
12260 cat >>confdefs.h <<_ACEOF
12261 #define HAVE_STRUCT_OPTION 1
12262 _ACEOF
12263
12264
12265 fi
12266
12267
12268 if test "$with_zlib" = yes; then
12269   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
12270   # did not).  While we could work around the lack of z_streamp, it
12271   # seems unwise to encourage people to use such old zlib versions...
12272   echo "$as_me:$LINENO: checking for z_streamp" >&5
12273 echo $ECHO_N "checking for z_streamp... $ECHO_C" >&6
12274 if test "${ac_cv_type_z_streamp+set}" = set; then
12275   echo $ECHO_N "(cached) $ECHO_C" >&6
12276 else
12277   cat >conftest.$ac_ext <<_ACEOF
12278 /* confdefs.h.  */
12279 _ACEOF
12280 cat confdefs.h >>conftest.$ac_ext
12281 cat >>conftest.$ac_ext <<_ACEOF
12282 /* end confdefs.h.  */
12283 #include <zlib.h>
12284
12285 int
12286 main ()
12287 {
12288 if ((z_streamp *) 0)
12289   return 0;
12290 if (sizeof (z_streamp))
12291   return 0;
12292   ;
12293   return 0;
12294 }
12295 _ACEOF
12296 rm -f conftest.$ac_objext
12297 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12298   (eval $ac_compile) 2>conftest.er1
12299   ac_status=$?
12300   grep -v '^ *+' conftest.er1 >conftest.err
12301   rm -f conftest.er1
12302   cat conftest.err >&5
12303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12304   (exit $ac_status); } &&
12305          { ac_try='test -z "$ac_c_werror_flag"
12306                          || test ! -s conftest.err'
12307   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12308   (eval $ac_try) 2>&5
12309   ac_status=$?
12310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12311   (exit $ac_status); }; } &&
12312          { ac_try='test -s conftest.$ac_objext'
12313   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12314   (eval $ac_try) 2>&5
12315   ac_status=$?
12316   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12317   (exit $ac_status); }; }; then
12318   ac_cv_type_z_streamp=yes
12319 else
12320   echo "$as_me: failed program was:" >&5
12321 sed 's/^/| /' conftest.$ac_ext >&5
12322
12323 ac_cv_type_z_streamp=no
12324 fi
12325 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12326 fi
12327 echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
12328 echo "${ECHO_T}$ac_cv_type_z_streamp" >&6
12329 if test $ac_cv_type_z_streamp = yes; then
12330   :
12331 else
12332   { { echo "$as_me:$LINENO: error: zlib version is too old
12333 Use --without-zlib to disable zlib support." >&5
12334 echo "$as_me: error: zlib version is too old
12335 Use --without-zlib to disable zlib support." >&2;}
12336    { (exit 1); exit 1; }; }
12337 fi
12338
12339 fi
12340
12341 if test "$with_krb5" = yes; then
12342 # Check for differences between MIT and Heimdal (KTH) releases
12343   echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
12344 echo $ECHO_N "checking for krb5_ticket.enc_part2... $ECHO_C" >&6
12345 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
12346   echo $ECHO_N "(cached) $ECHO_C" >&6
12347 else
12348   cat >conftest.$ac_ext <<_ACEOF
12349 /* confdefs.h.  */
12350 _ACEOF
12351 cat confdefs.h >>conftest.$ac_ext
12352 cat >>conftest.$ac_ext <<_ACEOF
12353 /* end confdefs.h.  */
12354 #include <krb5.h>
12355
12356 int
12357 main ()
12358 {
12359 static krb5_ticket ac_aggr;
12360 if (ac_aggr.enc_part2)
12361 return 0;
12362   ;
12363   return 0;
12364 }
12365 _ACEOF
12366 rm -f conftest.$ac_objext
12367 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12368   (eval $ac_compile) 2>conftest.er1
12369   ac_status=$?
12370   grep -v '^ *+' conftest.er1 >conftest.err
12371   rm -f conftest.er1
12372   cat conftest.err >&5
12373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12374   (exit $ac_status); } &&
12375          { ac_try='test -z "$ac_c_werror_flag"
12376                          || test ! -s conftest.err'
12377   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12378   (eval $ac_try) 2>&5
12379   ac_status=$?
12380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12381   (exit $ac_status); }; } &&
12382          { ac_try='test -s conftest.$ac_objext'
12383   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12384   (eval $ac_try) 2>&5
12385   ac_status=$?
12386   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12387   (exit $ac_status); }; }; then
12388   ac_cv_member_krb5_ticket_enc_part2=yes
12389 else
12390   echo "$as_me: failed program was:" >&5
12391 sed 's/^/| /' conftest.$ac_ext >&5
12392
12393 cat >conftest.$ac_ext <<_ACEOF
12394 /* confdefs.h.  */
12395 _ACEOF
12396 cat confdefs.h >>conftest.$ac_ext
12397 cat >>conftest.$ac_ext <<_ACEOF
12398 /* end confdefs.h.  */
12399 #include <krb5.h>
12400
12401 int
12402 main ()
12403 {
12404 static krb5_ticket ac_aggr;
12405 if (sizeof ac_aggr.enc_part2)
12406 return 0;
12407   ;
12408   return 0;
12409 }
12410 _ACEOF
12411 rm -f conftest.$ac_objext
12412 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12413   (eval $ac_compile) 2>conftest.er1
12414   ac_status=$?
12415   grep -v '^ *+' conftest.er1 >conftest.err
12416   rm -f conftest.er1
12417   cat conftest.err >&5
12418   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12419   (exit $ac_status); } &&
12420          { ac_try='test -z "$ac_c_werror_flag"
12421                          || test ! -s conftest.err'
12422   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12423   (eval $ac_try) 2>&5
12424   ac_status=$?
12425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12426   (exit $ac_status); }; } &&
12427          { ac_try='test -s conftest.$ac_objext'
12428   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12429   (eval $ac_try) 2>&5
12430   ac_status=$?
12431   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12432   (exit $ac_status); }; }; then
12433   ac_cv_member_krb5_ticket_enc_part2=yes
12434 else
12435   echo "$as_me: failed program was:" >&5
12436 sed 's/^/| /' conftest.$ac_ext >&5
12437
12438 ac_cv_member_krb5_ticket_enc_part2=no
12439 fi
12440 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12441 fi
12442 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12443 fi
12444 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
12445 echo "${ECHO_T}$ac_cv_member_krb5_ticket_enc_part2" >&6
12446 if test $ac_cv_member_krb5_ticket_enc_part2 = yes; then
12447
12448 cat >>confdefs.h <<_ACEOF
12449 #define HAVE_KRB5_TICKET_ENC_PART2 1
12450 _ACEOF
12451
12452
12453 else
12454   echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
12455 echo $ECHO_N "checking for krb5_ticket.client... $ECHO_C" >&6
12456 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
12457   echo $ECHO_N "(cached) $ECHO_C" >&6
12458 else
12459   cat >conftest.$ac_ext <<_ACEOF
12460 /* confdefs.h.  */
12461 _ACEOF
12462 cat confdefs.h >>conftest.$ac_ext
12463 cat >>conftest.$ac_ext <<_ACEOF
12464 /* end confdefs.h.  */
12465 #include <krb5.h>
12466
12467 int
12468 main ()
12469 {
12470 static krb5_ticket ac_aggr;
12471 if (ac_aggr.client)
12472 return 0;
12473   ;
12474   return 0;
12475 }
12476 _ACEOF
12477 rm -f conftest.$ac_objext
12478 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12479   (eval $ac_compile) 2>conftest.er1
12480   ac_status=$?
12481   grep -v '^ *+' conftest.er1 >conftest.err
12482   rm -f conftest.er1
12483   cat conftest.err >&5
12484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12485   (exit $ac_status); } &&
12486          { ac_try='test -z "$ac_c_werror_flag"
12487                          || test ! -s conftest.err'
12488   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12489   (eval $ac_try) 2>&5
12490   ac_status=$?
12491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12492   (exit $ac_status); }; } &&
12493          { ac_try='test -s conftest.$ac_objext'
12494   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12495   (eval $ac_try) 2>&5
12496   ac_status=$?
12497   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12498   (exit $ac_status); }; }; then
12499   ac_cv_member_krb5_ticket_client=yes
12500 else
12501   echo "$as_me: failed program was:" >&5
12502 sed 's/^/| /' conftest.$ac_ext >&5
12503
12504 cat >conftest.$ac_ext <<_ACEOF
12505 /* confdefs.h.  */
12506 _ACEOF
12507 cat confdefs.h >>conftest.$ac_ext
12508 cat >>conftest.$ac_ext <<_ACEOF
12509 /* end confdefs.h.  */
12510 #include <krb5.h>
12511
12512 int
12513 main ()
12514 {
12515 static krb5_ticket ac_aggr;
12516 if (sizeof ac_aggr.client)
12517 return 0;
12518   ;
12519   return 0;
12520 }
12521 _ACEOF
12522 rm -f conftest.$ac_objext
12523 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12524   (eval $ac_compile) 2>conftest.er1
12525   ac_status=$?
12526   grep -v '^ *+' conftest.er1 >conftest.err
12527   rm -f conftest.er1
12528   cat conftest.err >&5
12529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12530   (exit $ac_status); } &&
12531          { ac_try='test -z "$ac_c_werror_flag"
12532                          || test ! -s conftest.err'
12533   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12534   (eval $ac_try) 2>&5
12535   ac_status=$?
12536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12537   (exit $ac_status); }; } &&
12538          { ac_try='test -s conftest.$ac_objext'
12539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12540   (eval $ac_try) 2>&5
12541   ac_status=$?
12542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12543   (exit $ac_status); }; }; then
12544   ac_cv_member_krb5_ticket_client=yes
12545 else
12546   echo "$as_me: failed program was:" >&5
12547 sed 's/^/| /' conftest.$ac_ext >&5
12548
12549 ac_cv_member_krb5_ticket_client=no
12550 fi
12551 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12552 fi
12553 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12554 fi
12555 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
12556 echo "${ECHO_T}$ac_cv_member_krb5_ticket_client" >&6
12557 if test $ac_cv_member_krb5_ticket_client = yes; then
12558
12559 cat >>confdefs.h <<_ACEOF
12560 #define HAVE_KRB5_TICKET_CLIENT 1
12561 _ACEOF
12562
12563
12564 else
12565   { { echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
12566 echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
12567    { (exit 1); exit 1; }; }
12568 fi
12569
12570 fi
12571
12572   echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
12573 echo $ECHO_N "checking for krb5_error.text.data... $ECHO_C" >&6
12574 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
12575   echo $ECHO_N "(cached) $ECHO_C" >&6
12576 else
12577   cat >conftest.$ac_ext <<_ACEOF
12578 /* confdefs.h.  */
12579 _ACEOF
12580 cat confdefs.h >>conftest.$ac_ext
12581 cat >>conftest.$ac_ext <<_ACEOF
12582 /* end confdefs.h.  */
12583 #include <krb5.h>
12584
12585 int
12586 main ()
12587 {
12588 static krb5_error ac_aggr;
12589 if (ac_aggr.text.data)
12590 return 0;
12591   ;
12592   return 0;
12593 }
12594 _ACEOF
12595 rm -f conftest.$ac_objext
12596 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12597   (eval $ac_compile) 2>conftest.er1
12598   ac_status=$?
12599   grep -v '^ *+' conftest.er1 >conftest.err
12600   rm -f conftest.er1
12601   cat conftest.err >&5
12602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12603   (exit $ac_status); } &&
12604          { ac_try='test -z "$ac_c_werror_flag"
12605                          || test ! -s conftest.err'
12606   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12607   (eval $ac_try) 2>&5
12608   ac_status=$?
12609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12610   (exit $ac_status); }; } &&
12611          { ac_try='test -s conftest.$ac_objext'
12612   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12613   (eval $ac_try) 2>&5
12614   ac_status=$?
12615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12616   (exit $ac_status); }; }; then
12617   ac_cv_member_krb5_error_text_data=yes
12618 else
12619   echo "$as_me: failed program was:" >&5
12620 sed 's/^/| /' conftest.$ac_ext >&5
12621
12622 cat >conftest.$ac_ext <<_ACEOF
12623 /* confdefs.h.  */
12624 _ACEOF
12625 cat confdefs.h >>conftest.$ac_ext
12626 cat >>conftest.$ac_ext <<_ACEOF
12627 /* end confdefs.h.  */
12628 #include <krb5.h>
12629
12630 int
12631 main ()
12632 {
12633 static krb5_error ac_aggr;
12634 if (sizeof ac_aggr.text.data)
12635 return 0;
12636   ;
12637   return 0;
12638 }
12639 _ACEOF
12640 rm -f conftest.$ac_objext
12641 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12642   (eval $ac_compile) 2>conftest.er1
12643   ac_status=$?
12644   grep -v '^ *+' conftest.er1 >conftest.err
12645   rm -f conftest.er1
12646   cat conftest.err >&5
12647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12648   (exit $ac_status); } &&
12649          { ac_try='test -z "$ac_c_werror_flag"
12650                          || test ! -s conftest.err'
12651   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12652   (eval $ac_try) 2>&5
12653   ac_status=$?
12654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12655   (exit $ac_status); }; } &&
12656          { ac_try='test -s conftest.$ac_objext'
12657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12658   (eval $ac_try) 2>&5
12659   ac_status=$?
12660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12661   (exit $ac_status); }; }; then
12662   ac_cv_member_krb5_error_text_data=yes
12663 else
12664   echo "$as_me: failed program was:" >&5
12665 sed 's/^/| /' conftest.$ac_ext >&5
12666
12667 ac_cv_member_krb5_error_text_data=no
12668 fi
12669 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12670 fi
12671 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12672 fi
12673 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
12674 echo "${ECHO_T}$ac_cv_member_krb5_error_text_data" >&6
12675 if test $ac_cv_member_krb5_error_text_data = yes; then
12676
12677 cat >>confdefs.h <<_ACEOF
12678 #define HAVE_KRB5_ERROR_TEXT_DATA 1
12679 _ACEOF
12680
12681
12682 else
12683   echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
12684 echo $ECHO_N "checking for krb5_error.e_data... $ECHO_C" >&6
12685 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
12686   echo $ECHO_N "(cached) $ECHO_C" >&6
12687 else
12688   cat >conftest.$ac_ext <<_ACEOF
12689 /* confdefs.h.  */
12690 _ACEOF
12691 cat confdefs.h >>conftest.$ac_ext
12692 cat >>conftest.$ac_ext <<_ACEOF
12693 /* end confdefs.h.  */
12694 #include <krb5.h>
12695
12696 int
12697 main ()
12698 {
12699 static krb5_error ac_aggr;
12700 if (ac_aggr.e_data)
12701 return 0;
12702   ;
12703   return 0;
12704 }
12705 _ACEOF
12706 rm -f conftest.$ac_objext
12707 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12708   (eval $ac_compile) 2>conftest.er1
12709   ac_status=$?
12710   grep -v '^ *+' conftest.er1 >conftest.err
12711   rm -f conftest.er1
12712   cat conftest.err >&5
12713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12714   (exit $ac_status); } &&
12715          { ac_try='test -z "$ac_c_werror_flag"
12716                          || test ! -s conftest.err'
12717   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12718   (eval $ac_try) 2>&5
12719   ac_status=$?
12720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12721   (exit $ac_status); }; } &&
12722          { ac_try='test -s conftest.$ac_objext'
12723   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12724   (eval $ac_try) 2>&5
12725   ac_status=$?
12726   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12727   (exit $ac_status); }; }; then
12728   ac_cv_member_krb5_error_e_data=yes
12729 else
12730   echo "$as_me: failed program was:" >&5
12731 sed 's/^/| /' conftest.$ac_ext >&5
12732
12733 cat >conftest.$ac_ext <<_ACEOF
12734 /* confdefs.h.  */
12735 _ACEOF
12736 cat confdefs.h >>conftest.$ac_ext
12737 cat >>conftest.$ac_ext <<_ACEOF
12738 /* end confdefs.h.  */
12739 #include <krb5.h>
12740
12741 int
12742 main ()
12743 {
12744 static krb5_error ac_aggr;
12745 if (sizeof ac_aggr.e_data)
12746 return 0;
12747   ;
12748   return 0;
12749 }
12750 _ACEOF
12751 rm -f conftest.$ac_objext
12752 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12753   (eval $ac_compile) 2>conftest.er1
12754   ac_status=$?
12755   grep -v '^ *+' conftest.er1 >conftest.err
12756   rm -f conftest.er1
12757   cat conftest.err >&5
12758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12759   (exit $ac_status); } &&
12760          { ac_try='test -z "$ac_c_werror_flag"
12761                          || test ! -s conftest.err'
12762   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12763   (eval $ac_try) 2>&5
12764   ac_status=$?
12765   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12766   (exit $ac_status); }; } &&
12767          { ac_try='test -s conftest.$ac_objext'
12768   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12769   (eval $ac_try) 2>&5
12770   ac_status=$?
12771   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12772   (exit $ac_status); }; }; then
12773   ac_cv_member_krb5_error_e_data=yes
12774 else
12775   echo "$as_me: failed program was:" >&5
12776 sed 's/^/| /' conftest.$ac_ext >&5
12777
12778 ac_cv_member_krb5_error_e_data=no
12779 fi
12780 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12781 fi
12782 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12783 fi
12784 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
12785 echo "${ECHO_T}$ac_cv_member_krb5_error_e_data" >&6
12786 if test $ac_cv_member_krb5_error_e_data = yes; then
12787
12788 cat >>confdefs.h <<_ACEOF
12789 #define HAVE_KRB5_ERROR_E_DATA 1
12790 _ACEOF
12791
12792
12793 else
12794   { { echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
12795 echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
12796    { (exit 1); exit 1; }; }
12797 fi
12798
12799 fi
12800
12801 fi
12802
12803 # This is probably only present on Darwin, but may as well check always
12804 echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
12805 echo $ECHO_N "checking whether F_FULLFSYNC is declared... $ECHO_C" >&6
12806 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
12807   echo $ECHO_N "(cached) $ECHO_C" >&6
12808 else
12809   cat >conftest.$ac_ext <<_ACEOF
12810 /* confdefs.h.  */
12811 _ACEOF
12812 cat confdefs.h >>conftest.$ac_ext
12813 cat >>conftest.$ac_ext <<_ACEOF
12814 /* end confdefs.h.  */
12815 #include <fcntl.h>
12816
12817 int
12818 main ()
12819 {
12820 #ifndef F_FULLFSYNC
12821   char *p = (char *) F_FULLFSYNC;
12822 #endif
12823
12824   ;
12825   return 0;
12826 }
12827 _ACEOF
12828 rm -f conftest.$ac_objext
12829 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12830   (eval $ac_compile) 2>conftest.er1
12831   ac_status=$?
12832   grep -v '^ *+' conftest.er1 >conftest.err
12833   rm -f conftest.er1
12834   cat conftest.err >&5
12835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12836   (exit $ac_status); } &&
12837          { ac_try='test -z "$ac_c_werror_flag"
12838                          || test ! -s conftest.err'
12839   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12840   (eval $ac_try) 2>&5
12841   ac_status=$?
12842   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12843   (exit $ac_status); }; } &&
12844          { ac_try='test -s conftest.$ac_objext'
12845   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12846   (eval $ac_try) 2>&5
12847   ac_status=$?
12848   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12849   (exit $ac_status); }; }; then
12850   ac_cv_have_decl_F_FULLFSYNC=yes
12851 else
12852   echo "$as_me: failed program was:" >&5
12853 sed 's/^/| /' conftest.$ac_ext >&5
12854
12855 ac_cv_have_decl_F_FULLFSYNC=no
12856 fi
12857 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12858 fi
12859 echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
12860 echo "${ECHO_T}$ac_cv_have_decl_F_FULLFSYNC" >&6
12861 if test $ac_cv_have_decl_F_FULLFSYNC = yes; then
12862
12863 cat >>confdefs.h <<_ACEOF
12864 #define HAVE_DECL_F_FULLFSYNC 1
12865 _ACEOF
12866
12867
12868 else
12869   cat >>confdefs.h <<_ACEOF
12870 #define HAVE_DECL_F_FULLFSYNC 0
12871 _ACEOF
12872
12873
12874 fi
12875
12876
12877
12878 ##
12879 ## Functions, global variables
12880 ##
12881
12882 echo "$as_me:$LINENO: checking for int timezone" >&5
12883 echo $ECHO_N "checking for int timezone... $ECHO_C" >&6
12884 if test "${pgac_cv_var_int_timezone+set}" = set; then
12885   echo $ECHO_N "(cached) $ECHO_C" >&6
12886 else
12887   cat >conftest.$ac_ext <<_ACEOF
12888 /* confdefs.h.  */
12889 _ACEOF
12890 cat confdefs.h >>conftest.$ac_ext
12891 cat >>conftest.$ac_ext <<_ACEOF
12892 /* end confdefs.h.  */
12893 #include <time.h>
12894 int res;
12895 int
12896 main ()
12897 {
12898 #ifndef __CYGWIN__
12899 res = timezone / 60;
12900 #else
12901 res = _timezone / 60;
12902 #endif
12903   ;
12904   return 0;
12905 }
12906 _ACEOF
12907 rm -f conftest.$ac_objext conftest$ac_exeext
12908 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12909   (eval $ac_link) 2>conftest.er1
12910   ac_status=$?
12911   grep -v '^ *+' conftest.er1 >conftest.err
12912   rm -f conftest.er1
12913   cat conftest.err >&5
12914   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12915   (exit $ac_status); } &&
12916          { ac_try='test -z "$ac_c_werror_flag"
12917                          || test ! -s conftest.err'
12918   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12919   (eval $ac_try) 2>&5
12920   ac_status=$?
12921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12922   (exit $ac_status); }; } &&
12923          { ac_try='test -s conftest$ac_exeext'
12924   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12925   (eval $ac_try) 2>&5
12926   ac_status=$?
12927   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12928   (exit $ac_status); }; }; then
12929   pgac_cv_var_int_timezone=yes
12930 else
12931   echo "$as_me: failed program was:" >&5
12932 sed 's/^/| /' conftest.$ac_ext >&5
12933
12934 pgac_cv_var_int_timezone=no
12935 fi
12936 rm -f conftest.err conftest.$ac_objext \
12937       conftest$ac_exeext conftest.$ac_ext
12938 fi
12939 echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
12940 echo "${ECHO_T}$pgac_cv_var_int_timezone" >&6
12941 if test x"$pgac_cv_var_int_timezone" = xyes ; then
12942
12943 cat >>confdefs.h <<\_ACEOF
12944 #define HAVE_INT_TIMEZONE
12945 _ACEOF
12946
12947 fi
12948 echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
12949 echo $ECHO_N "checking types of arguments for accept()... $ECHO_C" >&6
12950  if test "${ac_cv_func_accept_return+set}" = set; then
12951   echo $ECHO_N "(cached) $ECHO_C" >&6
12952 else
12953    if test "${ac_cv_func_accept_arg1+set}" = set; then
12954   echo $ECHO_N "(cached) $ECHO_C" >&6
12955 else
12956     if test "${ac_cv_func_accept_arg2+set}" = set; then
12957   echo $ECHO_N "(cached) $ECHO_C" >&6
12958 else
12959      if test "${ac_cv_func_accept_arg3+set}" = set; then
12960   echo $ECHO_N "(cached) $ECHO_C" >&6
12961 else
12962       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
12963       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
12964        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
12965         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
12966          cat >conftest.$ac_ext <<_ACEOF
12967 /* confdefs.h.  */
12968 _ACEOF
12969 cat confdefs.h >>conftest.$ac_ext
12970 cat >>conftest.$ac_ext <<_ACEOF
12971 /* end confdefs.h.  */
12972 #ifdef HAVE_SYS_TYPES_H
12973 #include <sys/types.h>
12974 #endif
12975 #ifdef HAVE_SYS_SOCKET_H
12976 #include <sys/socket.h>
12977 #endif
12978 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
12979 int
12980 main ()
12981 {
12982
12983   ;
12984   return 0;
12985 }
12986 _ACEOF
12987 rm -f conftest.$ac_objext
12988 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12989   (eval $ac_compile) 2>conftest.er1
12990   ac_status=$?
12991   grep -v '^ *+' conftest.er1 >conftest.err
12992   rm -f conftest.er1
12993   cat conftest.err >&5
12994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12995   (exit $ac_status); } &&
12996          { ac_try='test -z "$ac_c_werror_flag"
12997                          || test ! -s conftest.err'
12998   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12999   (eval $ac_try) 2>&5
13000   ac_status=$?
13001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13002   (exit $ac_status); }; } &&
13003          { ac_try='test -s conftest.$ac_objext'
13004   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13005   (eval $ac_try) 2>&5
13006   ac_status=$?
13007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13008   (exit $ac_status); }; }; then
13009   ac_not_found=no; break 4
13010 else
13011   echo "$as_me: failed program was:" >&5
13012 sed 's/^/| /' conftest.$ac_ext >&5
13013
13014 ac_not_found=yes
13015 fi
13016 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13017        done
13018       done
13019      done
13020     done
13021     if test "$ac_not_found" = yes; then
13022       { { echo "$as_me:$LINENO: error: could not determine argument types" >&5
13023 echo "$as_me: error: could not determine argument types" >&2;}
13024    { (exit 1); exit 1; }; }
13025     fi
13026     if test "$ac_cv_func_accept_arg3" = "void"; then
13027       ac_cv_func_accept_arg3=int
13028     fi
13029
13030 fi
13031
13032 fi
13033
13034 fi
13035
13036 fi
13037  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
13038 echo "${ECHO_T}$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6
13039
13040 cat >>confdefs.h <<_ACEOF
13041 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
13042 _ACEOF
13043
13044
13045 cat >>confdefs.h <<_ACEOF
13046 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
13047 _ACEOF
13048
13049
13050 cat >>confdefs.h <<_ACEOF
13051 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
13052 _ACEOF
13053
13054
13055 cat >>confdefs.h <<_ACEOF
13056 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
13057 _ACEOF
13058
13059
13060 echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
13061 echo $ECHO_N "checking whether gettimeofday takes only one argument... $ECHO_C" >&6
13062 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
13063   echo $ECHO_N "(cached) $ECHO_C" >&6
13064 else
13065   cat >conftest.$ac_ext <<_ACEOF
13066 /* confdefs.h.  */
13067 _ACEOF
13068 cat confdefs.h >>conftest.$ac_ext
13069 cat >>conftest.$ac_ext <<_ACEOF
13070 /* end confdefs.h.  */
13071 #include <sys/time.h>
13072 int
13073 main ()
13074 {
13075 struct timeval *tp;
13076 struct timezone *tzp;
13077 gettimeofday(tp,tzp);
13078   ;
13079   return 0;
13080 }
13081 _ACEOF
13082 rm -f conftest.$ac_objext
13083 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13084   (eval $ac_compile) 2>conftest.er1
13085   ac_status=$?
13086   grep -v '^ *+' conftest.er1 >conftest.err
13087   rm -f conftest.er1
13088   cat conftest.err >&5
13089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13090   (exit $ac_status); } &&
13091          { ac_try='test -z "$ac_c_werror_flag"
13092                          || test ! -s conftest.err'
13093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13094   (eval $ac_try) 2>&5
13095   ac_status=$?
13096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13097   (exit $ac_status); }; } &&
13098          { ac_try='test -s conftest.$ac_objext'
13099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13100   (eval $ac_try) 2>&5
13101   ac_status=$?
13102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13103   (exit $ac_status); }; }; then
13104   pgac_cv_func_gettimeofday_1arg=no
13105 else
13106   echo "$as_me: failed program was:" >&5
13107 sed 's/^/| /' conftest.$ac_ext >&5
13108
13109 pgac_cv_func_gettimeofday_1arg=yes
13110 fi
13111 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13112 fi
13113 echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
13114 echo "${ECHO_T}$pgac_cv_func_gettimeofday_1arg" >&6
13115 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
13116
13117 cat >>confdefs.h <<\_ACEOF
13118 #define GETTIMEOFDAY_1ARG
13119 _ACEOF
13120
13121 fi
13122
13123
13124
13125
13126
13127
13128
13129
13130
13131
13132
13133
13134
13135
13136
13137
13138
13139
13140
13141
13142
13143
13144 for ac_func in cbrt dlopen fcvt fdatasync getpeereid memmove poll pstat readlink setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
13145 do
13146 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13147 echo "$as_me:$LINENO: checking for $ac_func" >&5
13148 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13149 if eval "test \"\${$as_ac_var+set}\" = set"; then
13150   echo $ECHO_N "(cached) $ECHO_C" >&6
13151 else
13152   cat >conftest.$ac_ext <<_ACEOF
13153 /* confdefs.h.  */
13154 _ACEOF
13155 cat confdefs.h >>conftest.$ac_ext
13156 cat >>conftest.$ac_ext <<_ACEOF
13157 /* end confdefs.h.  */
13158 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13159    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13160 #define $ac_func innocuous_$ac_func
13161
13162 /* System header to define __stub macros and hopefully few prototypes,
13163     which can conflict with char $ac_func (); below.
13164     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13165     <limits.h> exists even on freestanding compilers.  */
13166
13167 #ifdef __STDC__
13168 # include <limits.h>
13169 #else
13170 # include <assert.h>
13171 #endif
13172
13173 #undef $ac_func
13174
13175 /* Override any gcc2 internal prototype to avoid an error.  */
13176 #ifdef __cplusplus
13177 extern "C"
13178 {
13179 #endif
13180 /* We use char because int might match the return type of a gcc2
13181    builtin and then its argument prototype would still apply.  */
13182 char $ac_func ();
13183 /* The GNU C library defines this for functions which it implements
13184     to always fail with ENOSYS.  Some functions are actually named
13185     something starting with __ and the normal name is an alias.  */
13186 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13187 choke me
13188 #else
13189 char (*f) () = $ac_func;
13190 #endif
13191 #ifdef __cplusplus
13192 }
13193 #endif
13194
13195 int
13196 main ()
13197 {
13198 return f != $ac_func;
13199   ;
13200   return 0;
13201 }
13202 _ACEOF
13203 rm -f conftest.$ac_objext conftest$ac_exeext
13204 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13205   (eval $ac_link) 2>conftest.er1
13206   ac_status=$?
13207   grep -v '^ *+' conftest.er1 >conftest.err
13208   rm -f conftest.er1
13209   cat conftest.err >&5
13210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13211   (exit $ac_status); } &&
13212          { ac_try='test -z "$ac_c_werror_flag"
13213                          || test ! -s conftest.err'
13214   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13215   (eval $ac_try) 2>&5
13216   ac_status=$?
13217   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13218   (exit $ac_status); }; } &&
13219          { ac_try='test -s conftest$ac_exeext'
13220   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13221   (eval $ac_try) 2>&5
13222   ac_status=$?
13223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13224   (exit $ac_status); }; }; then
13225   eval "$as_ac_var=yes"
13226 else
13227   echo "$as_me: failed program was:" >&5
13228 sed 's/^/| /' conftest.$ac_ext >&5
13229
13230 eval "$as_ac_var=no"
13231 fi
13232 rm -f conftest.err conftest.$ac_objext \
13233       conftest$ac_exeext conftest.$ac_ext
13234 fi
13235 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13236 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13237 if test `eval echo '${'$as_ac_var'}'` = yes; then
13238   cat >>confdefs.h <<_ACEOF
13239 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13240 _ACEOF
13241
13242 fi
13243 done
13244
13245
13246 echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
13247 echo $ECHO_N "checking whether fdatasync is declared... $ECHO_C" >&6
13248 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
13249   echo $ECHO_N "(cached) $ECHO_C" >&6
13250 else
13251   cat >conftest.$ac_ext <<_ACEOF
13252 /* confdefs.h.  */
13253 _ACEOF
13254 cat confdefs.h >>conftest.$ac_ext
13255 cat >>conftest.$ac_ext <<_ACEOF
13256 /* end confdefs.h.  */
13257 #include <unistd.h>
13258
13259 int
13260 main ()
13261 {
13262 #ifndef fdatasync
13263   char *p = (char *) fdatasync;
13264 #endif
13265
13266   ;
13267   return 0;
13268 }
13269 _ACEOF
13270 rm -f conftest.$ac_objext
13271 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13272   (eval $ac_compile) 2>conftest.er1
13273   ac_status=$?
13274   grep -v '^ *+' conftest.er1 >conftest.err
13275   rm -f conftest.er1
13276   cat conftest.err >&5
13277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13278   (exit $ac_status); } &&
13279          { ac_try='test -z "$ac_c_werror_flag"
13280                          || test ! -s conftest.err'
13281   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13282   (eval $ac_try) 2>&5
13283   ac_status=$?
13284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13285   (exit $ac_status); }; } &&
13286          { ac_try='test -s conftest.$ac_objext'
13287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13288   (eval $ac_try) 2>&5
13289   ac_status=$?
13290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13291   (exit $ac_status); }; }; then
13292   ac_cv_have_decl_fdatasync=yes
13293 else
13294   echo "$as_me: failed program was:" >&5
13295 sed 's/^/| /' conftest.$ac_ext >&5
13296
13297 ac_cv_have_decl_fdatasync=no
13298 fi
13299 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13300 fi
13301 echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
13302 echo "${ECHO_T}$ac_cv_have_decl_fdatasync" >&6
13303 if test $ac_cv_have_decl_fdatasync = yes; then
13304
13305 cat >>confdefs.h <<_ACEOF
13306 #define HAVE_DECL_FDATASYNC 1
13307 _ACEOF
13308
13309
13310 else
13311   cat >>confdefs.h <<_ACEOF
13312 #define HAVE_DECL_FDATASYNC 0
13313 _ACEOF
13314
13315
13316 fi
13317
13318
13319
13320 HAVE_IPV6=no
13321 echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
13322 echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6
13323 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
13324   echo $ECHO_N "(cached) $ECHO_C" >&6
13325 else
13326   cat >conftest.$ac_ext <<_ACEOF
13327 /* confdefs.h.  */
13328 _ACEOF
13329 cat confdefs.h >>conftest.$ac_ext
13330 cat >>conftest.$ac_ext <<_ACEOF
13331 /* end confdefs.h.  */
13332 $ac_includes_default
13333 #include <netinet/in.h>
13334
13335 int
13336 main ()
13337 {
13338 if ((struct sockaddr_in6 *) 0)
13339   return 0;
13340 if (sizeof (struct sockaddr_in6))
13341   return 0;
13342   ;
13343   return 0;
13344 }
13345 _ACEOF
13346 rm -f conftest.$ac_objext
13347 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13348   (eval $ac_compile) 2>conftest.er1
13349   ac_status=$?
13350   grep -v '^ *+' conftest.er1 >conftest.err
13351   rm -f conftest.er1
13352   cat conftest.err >&5
13353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13354   (exit $ac_status); } &&
13355          { ac_try='test -z "$ac_c_werror_flag"
13356                          || test ! -s conftest.err'
13357   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13358   (eval $ac_try) 2>&5
13359   ac_status=$?
13360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13361   (exit $ac_status); }; } &&
13362          { ac_try='test -s conftest.$ac_objext'
13363   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13364   (eval $ac_try) 2>&5
13365   ac_status=$?
13366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13367   (exit $ac_status); }; }; then
13368   ac_cv_type_struct_sockaddr_in6=yes
13369 else
13370   echo "$as_me: failed program was:" >&5
13371 sed 's/^/| /' conftest.$ac_ext >&5
13372
13373 ac_cv_type_struct_sockaddr_in6=no
13374 fi
13375 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13376 fi
13377 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
13378 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6
13379 if test $ac_cv_type_struct_sockaddr_in6 = yes; then
13380
13381 cat >>confdefs.h <<\_ACEOF
13382 #define HAVE_IPV6 1
13383 _ACEOF
13384
13385          HAVE_IPV6=yes
13386 fi
13387
13388
13389
13390 echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
13391 echo $ECHO_N "checking for PS_STRINGS... $ECHO_C" >&6
13392 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
13393   echo $ECHO_N "(cached) $ECHO_C" >&6
13394 else
13395   cat >conftest.$ac_ext <<_ACEOF
13396 /* confdefs.h.  */
13397 _ACEOF
13398 cat confdefs.h >>conftest.$ac_ext
13399 cat >>conftest.$ac_ext <<_ACEOF
13400 /* end confdefs.h.  */
13401 #include <machine/vmparam.h>
13402 #include <sys/exec.h>
13403
13404 int
13405 main ()
13406 {
13407 PS_STRINGS->ps_nargvstr = 1;
13408 PS_STRINGS->ps_argvstr = "foo";
13409   ;
13410   return 0;
13411 }
13412 _ACEOF
13413 rm -f conftest.$ac_objext conftest$ac_exeext
13414 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13415   (eval $ac_link) 2>conftest.er1
13416   ac_status=$?
13417   grep -v '^ *+' conftest.er1 >conftest.err
13418   rm -f conftest.er1
13419   cat conftest.err >&5
13420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13421   (exit $ac_status); } &&
13422          { ac_try='test -z "$ac_c_werror_flag"
13423                          || test ! -s conftest.err'
13424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13425   (eval $ac_try) 2>&5
13426   ac_status=$?
13427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13428   (exit $ac_status); }; } &&
13429          { ac_try='test -s conftest$ac_exeext'
13430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13431   (eval $ac_try) 2>&5
13432   ac_status=$?
13433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13434   (exit $ac_status); }; }; then
13435   pgac_cv_var_PS_STRINGS=yes
13436 else
13437   echo "$as_me: failed program was:" >&5
13438 sed 's/^/| /' conftest.$ac_ext >&5
13439
13440 pgac_cv_var_PS_STRINGS=no
13441 fi
13442 rm -f conftest.err conftest.$ac_objext \
13443       conftest$ac_exeext conftest.$ac_ext
13444 fi
13445 echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
13446 echo "${ECHO_T}$pgac_cv_var_PS_STRINGS" >&6
13447 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
13448
13449 cat >>confdefs.h <<\_ACEOF
13450 #define HAVE_PS_STRINGS
13451 _ACEOF
13452
13453 fi
13454
13455
13456 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
13457 # is missing.  Yes, there are machines that have only one.  We may
13458 # also decide to use snprintf.c if snprintf() is present but does not
13459 # have all the features we need --- see below.
13460
13461 if test "$PORTNAME" = "win32"; then
13462   # Win32 gets snprintf.c built unconditionally.
13463   #
13464   # To properly translate all NLS languages strings, we must support the
13465   # *printf() %$ format, which allows *printf() arguments to be selected
13466   # by position in the translated string.
13467   #
13468   # libintl versions < 0.13 use the native *printf() functions, and Win32
13469   # *printf() doesn't understand %$, so we must use our /port versions,
13470   # which do understand %$. libintl versions >= 0.13 include their own
13471   # *printf versions on Win32.  The libintl 0.13 release note text is:
13472   #
13473   #   C format strings with positions, as they arise when a translator
13474   #   needs to reorder a sentence, are now supported on all platforms.
13475   #   On those few platforms (NetBSD and Woe32) for which the native
13476   #   printf()/fprintf()/... functions don't support such format
13477   #   strings, replacements are provided through <libintl.h>.
13478   #
13479   # We could use libintl >= 0.13's *printf() if we were sure that we had
13480   # a litint >= 0.13 at runtime, but seeing that there is no clean way
13481   # to guarantee that, it is best to just use our own, so we are sure to
13482   # get %$ support. In include/port.h we disable the *printf() macros
13483   # that might have been defined by libintl.
13484   #
13485   # We do this unconditionally whether NLS is used or not so we are sure
13486   # that all Win32 libraries and binaries behave the same.
13487   pgac_need_repl_snprintf=yes
13488 else
13489   pgac_need_repl_snprintf=no
13490
13491 for ac_func in snprintf
13492 do
13493 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13494 echo "$as_me:$LINENO: checking for $ac_func" >&5
13495 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13496 if eval "test \"\${$as_ac_var+set}\" = set"; then
13497   echo $ECHO_N "(cached) $ECHO_C" >&6
13498 else
13499   cat >conftest.$ac_ext <<_ACEOF
13500 /* confdefs.h.  */
13501 _ACEOF
13502 cat confdefs.h >>conftest.$ac_ext
13503 cat >>conftest.$ac_ext <<_ACEOF
13504 /* end confdefs.h.  */
13505 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13506    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13507 #define $ac_func innocuous_$ac_func
13508
13509 /* System header to define __stub macros and hopefully few prototypes,
13510     which can conflict with char $ac_func (); below.
13511     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13512     <limits.h> exists even on freestanding compilers.  */
13513
13514 #ifdef __STDC__
13515 # include <limits.h>
13516 #else
13517 # include <assert.h>
13518 #endif
13519
13520 #undef $ac_func
13521
13522 /* Override any gcc2 internal prototype to avoid an error.  */
13523 #ifdef __cplusplus
13524 extern "C"
13525 {
13526 #endif
13527 /* We use char because int might match the return type of a gcc2
13528    builtin and then its argument prototype would still apply.  */
13529 char $ac_func ();
13530 /* The GNU C library defines this for functions which it implements
13531     to always fail with ENOSYS.  Some functions are actually named
13532     something starting with __ and the normal name is an alias.  */
13533 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13534 choke me
13535 #else
13536 char (*f) () = $ac_func;
13537 #endif
13538 #ifdef __cplusplus
13539 }
13540 #endif
13541
13542 int
13543 main ()
13544 {
13545 return f != $ac_func;
13546   ;
13547   return 0;
13548 }
13549 _ACEOF
13550 rm -f conftest.$ac_objext conftest$ac_exeext
13551 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13552   (eval $ac_link) 2>conftest.er1
13553   ac_status=$?
13554   grep -v '^ *+' conftest.er1 >conftest.err
13555   rm -f conftest.er1
13556   cat conftest.err >&5
13557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13558   (exit $ac_status); } &&
13559          { ac_try='test -z "$ac_c_werror_flag"
13560                          || test ! -s conftest.err'
13561   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13562   (eval $ac_try) 2>&5
13563   ac_status=$?
13564   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13565   (exit $ac_status); }; } &&
13566          { ac_try='test -s conftest$ac_exeext'
13567   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13568   (eval $ac_try) 2>&5
13569   ac_status=$?
13570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13571   (exit $ac_status); }; }; then
13572   eval "$as_ac_var=yes"
13573 else
13574   echo "$as_me: failed program was:" >&5
13575 sed 's/^/| /' conftest.$ac_ext >&5
13576
13577 eval "$as_ac_var=no"
13578 fi
13579 rm -f conftest.err conftest.$ac_objext \
13580       conftest$ac_exeext conftest.$ac_ext
13581 fi
13582 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13583 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13584 if test `eval echo '${'$as_ac_var'}'` = yes; then
13585   cat >>confdefs.h <<_ACEOF
13586 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13587 _ACEOF
13588
13589 else
13590   pgac_need_repl_snprintf=yes
13591 fi
13592 done
13593
13594
13595 for ac_func in vsnprintf
13596 do
13597 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13598 echo "$as_me:$LINENO: checking for $ac_func" >&5
13599 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13600 if eval "test \"\${$as_ac_var+set}\" = set"; then
13601   echo $ECHO_N "(cached) $ECHO_C" >&6
13602 else
13603   cat >conftest.$ac_ext <<_ACEOF
13604 /* confdefs.h.  */
13605 _ACEOF
13606 cat confdefs.h >>conftest.$ac_ext
13607 cat >>conftest.$ac_ext <<_ACEOF
13608 /* end confdefs.h.  */
13609 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13610    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13611 #define $ac_func innocuous_$ac_func
13612
13613 /* System header to define __stub macros and hopefully few prototypes,
13614     which can conflict with char $ac_func (); below.
13615     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13616     <limits.h> exists even on freestanding compilers.  */
13617
13618 #ifdef __STDC__
13619 # include <limits.h>
13620 #else
13621 # include <assert.h>
13622 #endif
13623
13624 #undef $ac_func
13625
13626 /* Override any gcc2 internal prototype to avoid an error.  */
13627 #ifdef __cplusplus
13628 extern "C"
13629 {
13630 #endif
13631 /* We use char because int might match the return type of a gcc2
13632    builtin and then its argument prototype would still apply.  */
13633 char $ac_func ();
13634 /* The GNU C library defines this for functions which it implements
13635     to always fail with ENOSYS.  Some functions are actually named
13636     something starting with __ and the normal name is an alias.  */
13637 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13638 choke me
13639 #else
13640 char (*f) () = $ac_func;
13641 #endif
13642 #ifdef __cplusplus
13643 }
13644 #endif
13645
13646 int
13647 main ()
13648 {
13649 return f != $ac_func;
13650   ;
13651   return 0;
13652 }
13653 _ACEOF
13654 rm -f conftest.$ac_objext conftest$ac_exeext
13655 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13656   (eval $ac_link) 2>conftest.er1
13657   ac_status=$?
13658   grep -v '^ *+' conftest.er1 >conftest.err
13659   rm -f conftest.er1
13660   cat conftest.err >&5
13661   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13662   (exit $ac_status); } &&
13663          { ac_try='test -z "$ac_c_werror_flag"
13664                          || test ! -s conftest.err'
13665   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13666   (eval $ac_try) 2>&5
13667   ac_status=$?
13668   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13669   (exit $ac_status); }; } &&
13670          { ac_try='test -s conftest$ac_exeext'
13671   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13672   (eval $ac_try) 2>&5
13673   ac_status=$?
13674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13675   (exit $ac_status); }; }; then
13676   eval "$as_ac_var=yes"
13677 else
13678   echo "$as_me: failed program was:" >&5
13679 sed 's/^/| /' conftest.$ac_ext >&5
13680
13681 eval "$as_ac_var=no"
13682 fi
13683 rm -f conftest.err conftest.$ac_objext \
13684       conftest$ac_exeext conftest.$ac_ext
13685 fi
13686 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13687 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13688 if test `eval echo '${'$as_ac_var'}'` = yes; then
13689   cat >>confdefs.h <<_ACEOF
13690 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13691 _ACEOF
13692
13693 else
13694   pgac_need_repl_snprintf=yes
13695 fi
13696 done
13697
13698 fi
13699
13700
13701 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
13702 # include/c.h will provide declarations.  Note this is a separate test
13703 # from whether the functions exist in the C library --- there are
13704 # systems that have the functions but don't bother to declare them :-(
13705
13706 echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
13707 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6
13708 if test "${ac_cv_have_decl_snprintf+set}" = set; then
13709   echo $ECHO_N "(cached) $ECHO_C" >&6
13710 else
13711   cat >conftest.$ac_ext <<_ACEOF
13712 /* confdefs.h.  */
13713 _ACEOF
13714 cat confdefs.h >>conftest.$ac_ext
13715 cat >>conftest.$ac_ext <<_ACEOF
13716 /* end confdefs.h.  */
13717 $ac_includes_default
13718 int
13719 main ()
13720 {
13721 #ifndef snprintf
13722   char *p = (char *) snprintf;
13723 #endif
13724
13725   ;
13726   return 0;
13727 }
13728 _ACEOF
13729 rm -f conftest.$ac_objext
13730 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13731   (eval $ac_compile) 2>conftest.er1
13732   ac_status=$?
13733   grep -v '^ *+' conftest.er1 >conftest.err
13734   rm -f conftest.er1
13735   cat conftest.err >&5
13736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13737   (exit $ac_status); } &&
13738          { ac_try='test -z "$ac_c_werror_flag"
13739                          || test ! -s conftest.err'
13740   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13741   (eval $ac_try) 2>&5
13742   ac_status=$?
13743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13744   (exit $ac_status); }; } &&
13745          { ac_try='test -s conftest.$ac_objext'
13746   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13747   (eval $ac_try) 2>&5
13748   ac_status=$?
13749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13750   (exit $ac_status); }; }; then
13751   ac_cv_have_decl_snprintf=yes
13752 else
13753   echo "$as_me: failed program was:" >&5
13754 sed 's/^/| /' conftest.$ac_ext >&5
13755
13756 ac_cv_have_decl_snprintf=no
13757 fi
13758 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13759 fi
13760 echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
13761 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6
13762 if test $ac_cv_have_decl_snprintf = yes; then
13763
13764 cat >>confdefs.h <<_ACEOF
13765 #define HAVE_DECL_SNPRINTF 1
13766 _ACEOF
13767
13768
13769 else
13770   cat >>confdefs.h <<_ACEOF
13771 #define HAVE_DECL_SNPRINTF 0
13772 _ACEOF
13773
13774
13775 fi
13776 echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
13777 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6
13778 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
13779   echo $ECHO_N "(cached) $ECHO_C" >&6
13780 else
13781   cat >conftest.$ac_ext <<_ACEOF
13782 /* confdefs.h.  */
13783 _ACEOF
13784 cat confdefs.h >>conftest.$ac_ext
13785 cat >>conftest.$ac_ext <<_ACEOF
13786 /* end confdefs.h.  */
13787 $ac_includes_default
13788 int
13789 main ()
13790 {
13791 #ifndef vsnprintf
13792   char *p = (char *) vsnprintf;
13793 #endif
13794
13795   ;
13796   return 0;
13797 }
13798 _ACEOF
13799 rm -f conftest.$ac_objext
13800 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13801   (eval $ac_compile) 2>conftest.er1
13802   ac_status=$?
13803   grep -v '^ *+' conftest.er1 >conftest.err
13804   rm -f conftest.er1
13805   cat conftest.err >&5
13806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13807   (exit $ac_status); } &&
13808          { ac_try='test -z "$ac_c_werror_flag"
13809                          || test ! -s conftest.err'
13810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13811   (eval $ac_try) 2>&5
13812   ac_status=$?
13813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13814   (exit $ac_status); }; } &&
13815          { ac_try='test -s conftest.$ac_objext'
13816   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13817   (eval $ac_try) 2>&5
13818   ac_status=$?
13819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13820   (exit $ac_status); }; }; then
13821   ac_cv_have_decl_vsnprintf=yes
13822 else
13823   echo "$as_me: failed program was:" >&5
13824 sed 's/^/| /' conftest.$ac_ext >&5
13825
13826 ac_cv_have_decl_vsnprintf=no
13827 fi
13828 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13829 fi
13830 echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
13831 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6
13832 if test $ac_cv_have_decl_vsnprintf = yes; then
13833
13834 cat >>confdefs.h <<_ACEOF
13835 #define HAVE_DECL_VSNPRINTF 1
13836 _ACEOF
13837
13838
13839 else
13840   cat >>confdefs.h <<_ACEOF
13841 #define HAVE_DECL_VSNPRINTF 0
13842 _ACEOF
13843
13844
13845 fi
13846
13847
13848
13849
13850 echo "$as_me:$LINENO: checking for isinf" >&5
13851 echo $ECHO_N "checking for isinf... $ECHO_C" >&6
13852 if test "${ac_cv_func_isinf+set}" = set; then
13853   echo $ECHO_N "(cached) $ECHO_C" >&6
13854 else
13855   cat >conftest.$ac_ext <<_ACEOF
13856 /* confdefs.h.  */
13857 _ACEOF
13858 cat confdefs.h >>conftest.$ac_ext
13859 cat >>conftest.$ac_ext <<_ACEOF
13860 /* end confdefs.h.  */
13861
13862 #include <math.h>
13863 double glob_double;
13864
13865 int
13866 main ()
13867 {
13868 return isinf(glob_double) ? 0 : 1;
13869   ;
13870   return 0;
13871 }
13872 _ACEOF
13873 rm -f conftest.$ac_objext conftest$ac_exeext
13874 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13875   (eval $ac_link) 2>conftest.er1
13876   ac_status=$?
13877   grep -v '^ *+' conftest.er1 >conftest.err
13878   rm -f conftest.er1
13879   cat conftest.err >&5
13880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13881   (exit $ac_status); } &&
13882          { ac_try='test -z "$ac_c_werror_flag"
13883                          || test ! -s conftest.err'
13884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13885   (eval $ac_try) 2>&5
13886   ac_status=$?
13887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13888   (exit $ac_status); }; } &&
13889          { ac_try='test -s conftest$ac_exeext'
13890   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13891   (eval $ac_try) 2>&5
13892   ac_status=$?
13893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13894   (exit $ac_status); }; }; then
13895   ac_cv_func_isinf=yes
13896 else
13897   echo "$as_me: failed program was:" >&5
13898 sed 's/^/| /' conftest.$ac_ext >&5
13899
13900 ac_cv_func_isinf=no
13901 fi
13902 rm -f conftest.err conftest.$ac_objext \
13903       conftest$ac_exeext conftest.$ac_ext
13904 fi
13905 echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
13906 echo "${ECHO_T}$ac_cv_func_isinf" >&6
13907
13908 if test $ac_cv_func_isinf = yes ; then
13909
13910 cat >>confdefs.h <<\_ACEOF
13911 #define HAVE_ISINF 1
13912 _ACEOF
13913
13914 else
13915   case $LIBOBJS in
13916     "isinf.$ac_objext"   | \
13917   *" isinf.$ac_objext"   | \
13918     "isinf.$ac_objext "* | \
13919   *" isinf.$ac_objext "* ) ;;
13920   *) LIBOBJS="$LIBOBJS isinf.$ac_objext" ;;
13921 esac
13922
13923   # Look for a way to implement a substitute for isinf()
13924
13925
13926
13927
13928 for ac_func in fpclass fp_class fp_class_d class
13929 do
13930 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13931 echo "$as_me:$LINENO: checking for $ac_func" >&5
13932 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13933 if eval "test \"\${$as_ac_var+set}\" = set"; then
13934   echo $ECHO_N "(cached) $ECHO_C" >&6
13935 else
13936   cat >conftest.$ac_ext <<_ACEOF
13937 /* confdefs.h.  */
13938 _ACEOF
13939 cat confdefs.h >>conftest.$ac_ext
13940 cat >>conftest.$ac_ext <<_ACEOF
13941 /* end confdefs.h.  */
13942 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13943    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13944 #define $ac_func innocuous_$ac_func
13945
13946 /* System header to define __stub macros and hopefully few prototypes,
13947     which can conflict with char $ac_func (); below.
13948     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13949     <limits.h> exists even on freestanding compilers.  */
13950
13951 #ifdef __STDC__
13952 # include <limits.h>
13953 #else
13954 # include <assert.h>
13955 #endif
13956
13957 #undef $ac_func
13958
13959 /* Override any gcc2 internal prototype to avoid an error.  */
13960 #ifdef __cplusplus
13961 extern "C"
13962 {
13963 #endif
13964 /* We use char because int might match the return type of a gcc2
13965    builtin and then its argument prototype would still apply.  */
13966 char $ac_func ();
13967 /* The GNU C library defines this for functions which it implements
13968     to always fail with ENOSYS.  Some functions are actually named
13969     something starting with __ and the normal name is an alias.  */
13970 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13971 choke me
13972 #else
13973 char (*f) () = $ac_func;
13974 #endif
13975 #ifdef __cplusplus
13976 }
13977 #endif
13978
13979 int
13980 main ()
13981 {
13982 return f != $ac_func;
13983   ;
13984   return 0;
13985 }
13986 _ACEOF
13987 rm -f conftest.$ac_objext conftest$ac_exeext
13988 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13989   (eval $ac_link) 2>conftest.er1
13990   ac_status=$?
13991   grep -v '^ *+' conftest.er1 >conftest.err
13992   rm -f conftest.er1
13993   cat conftest.err >&5
13994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13995   (exit $ac_status); } &&
13996          { ac_try='test -z "$ac_c_werror_flag"
13997                          || test ! -s conftest.err'
13998   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13999   (eval $ac_try) 2>&5
14000   ac_status=$?
14001   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14002   (exit $ac_status); }; } &&
14003          { ac_try='test -s conftest$ac_exeext'
14004   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14005   (eval $ac_try) 2>&5
14006   ac_status=$?
14007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14008   (exit $ac_status); }; }; then
14009   eval "$as_ac_var=yes"
14010 else
14011   echo "$as_me: failed program was:" >&5
14012 sed 's/^/| /' conftest.$ac_ext >&5
14013
14014 eval "$as_ac_var=no"
14015 fi
14016 rm -f conftest.err conftest.$ac_objext \
14017       conftest$ac_exeext conftest.$ac_ext
14018 fi
14019 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14020 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14021 if test `eval echo '${'$as_ac_var'}'` = yes; then
14022   cat >>confdefs.h <<_ACEOF
14023 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14024 _ACEOF
14025  break
14026 fi
14027 done
14028
14029 fi
14030
14031
14032
14033
14034
14035
14036
14037
14038
14039
14040
14041
14042
14043
14044 for ac_func in crypt fseeko getopt getrusage inet_aton random rint srandom strdup strerror strtol strtoul unsetenv
14045 do
14046 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14047 echo "$as_me:$LINENO: checking for $ac_func" >&5
14048 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14049 if eval "test \"\${$as_ac_var+set}\" = set"; then
14050   echo $ECHO_N "(cached) $ECHO_C" >&6
14051 else
14052   cat >conftest.$ac_ext <<_ACEOF
14053 /* confdefs.h.  */
14054 _ACEOF
14055 cat confdefs.h >>conftest.$ac_ext
14056 cat >>conftest.$ac_ext <<_ACEOF
14057 /* end confdefs.h.  */
14058 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14059    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14060 #define $ac_func innocuous_$ac_func
14061
14062 /* System header to define __stub macros and hopefully few prototypes,
14063     which can conflict with char $ac_func (); below.
14064     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14065     <limits.h> exists even on freestanding compilers.  */
14066
14067 #ifdef __STDC__
14068 # include <limits.h>
14069 #else
14070 # include <assert.h>
14071 #endif
14072
14073 #undef $ac_func
14074
14075 /* Override any gcc2 internal prototype to avoid an error.  */
14076 #ifdef __cplusplus
14077 extern "C"
14078 {
14079 #endif
14080 /* We use char because int might match the return type of a gcc2
14081    builtin and then its argument prototype would still apply.  */
14082 char $ac_func ();
14083 /* The GNU C library defines this for functions which it implements
14084     to always fail with ENOSYS.  Some functions are actually named
14085     something starting with __ and the normal name is an alias.  */
14086 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14087 choke me
14088 #else
14089 char (*f) () = $ac_func;
14090 #endif
14091 #ifdef __cplusplus
14092 }
14093 #endif
14094
14095 int
14096 main ()
14097 {
14098 return f != $ac_func;
14099   ;
14100   return 0;
14101 }
14102 _ACEOF
14103 rm -f conftest.$ac_objext conftest$ac_exeext
14104 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14105   (eval $ac_link) 2>conftest.er1
14106   ac_status=$?
14107   grep -v '^ *+' conftest.er1 >conftest.err
14108   rm -f conftest.er1
14109   cat conftest.err >&5
14110   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14111   (exit $ac_status); } &&
14112          { ac_try='test -z "$ac_c_werror_flag"
14113                          || test ! -s conftest.err'
14114   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14115   (eval $ac_try) 2>&5
14116   ac_status=$?
14117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14118   (exit $ac_status); }; } &&
14119          { ac_try='test -s conftest$ac_exeext'
14120   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14121   (eval $ac_try) 2>&5
14122   ac_status=$?
14123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14124   (exit $ac_status); }; }; then
14125   eval "$as_ac_var=yes"
14126 else
14127   echo "$as_me: failed program was:" >&5
14128 sed 's/^/| /' conftest.$ac_ext >&5
14129
14130 eval "$as_ac_var=no"
14131 fi
14132 rm -f conftest.err conftest.$ac_objext \
14133       conftest$ac_exeext conftest.$ac_ext
14134 fi
14135 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14136 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14137 if test `eval echo '${'$as_ac_var'}'` = yes; then
14138   cat >>confdefs.h <<_ACEOF
14139 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14140 _ACEOF
14141
14142 else
14143   case $LIBOBJS in
14144     "$ac_func.$ac_objext"   | \
14145   *" $ac_func.$ac_objext"   | \
14146     "$ac_func.$ac_objext "* | \
14147   *" $ac_func.$ac_objext "* ) ;;
14148   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14149 esac
14150
14151 fi
14152 done
14153
14154
14155
14156 # System's version of getaddrinfo(), if any, may be used only if we found
14157 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
14158 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
14159 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
14160 # because we want to use our own getaddrinfo.c on Windows anyway.)
14161 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
14162
14163 for ac_func in getaddrinfo
14164 do
14165 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14166 echo "$as_me:$LINENO: checking for $ac_func" >&5
14167 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14168 if eval "test \"\${$as_ac_var+set}\" = set"; then
14169   echo $ECHO_N "(cached) $ECHO_C" >&6
14170 else
14171   cat >conftest.$ac_ext <<_ACEOF
14172 /* confdefs.h.  */
14173 _ACEOF
14174 cat confdefs.h >>conftest.$ac_ext
14175 cat >>conftest.$ac_ext <<_ACEOF
14176 /* end confdefs.h.  */
14177 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14178    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14179 #define $ac_func innocuous_$ac_func
14180
14181 /* System header to define __stub macros and hopefully few prototypes,
14182     which can conflict with char $ac_func (); below.
14183     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14184     <limits.h> exists even on freestanding compilers.  */
14185
14186 #ifdef __STDC__
14187 # include <limits.h>
14188 #else
14189 # include <assert.h>
14190 #endif
14191
14192 #undef $ac_func
14193
14194 /* Override any gcc2 internal prototype to avoid an error.  */
14195 #ifdef __cplusplus
14196 extern "C"
14197 {
14198 #endif
14199 /* We use char because int might match the return type of a gcc2
14200    builtin and then its argument prototype would still apply.  */
14201 char $ac_func ();
14202 /* The GNU C library defines this for functions which it implements
14203     to always fail with ENOSYS.  Some functions are actually named
14204     something starting with __ and the normal name is an alias.  */
14205 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14206 choke me
14207 #else
14208 char (*f) () = $ac_func;
14209 #endif
14210 #ifdef __cplusplus
14211 }
14212 #endif
14213
14214 int
14215 main ()
14216 {
14217 return f != $ac_func;
14218   ;
14219   return 0;
14220 }
14221 _ACEOF
14222 rm -f conftest.$ac_objext conftest$ac_exeext
14223 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14224   (eval $ac_link) 2>conftest.er1
14225   ac_status=$?
14226   grep -v '^ *+' conftest.er1 >conftest.err
14227   rm -f conftest.er1
14228   cat conftest.err >&5
14229   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14230   (exit $ac_status); } &&
14231          { ac_try='test -z "$ac_c_werror_flag"
14232                          || test ! -s conftest.err'
14233   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14234   (eval $ac_try) 2>&5
14235   ac_status=$?
14236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14237   (exit $ac_status); }; } &&
14238          { ac_try='test -s conftest$ac_exeext'
14239   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14240   (eval $ac_try) 2>&5
14241   ac_status=$?
14242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14243   (exit $ac_status); }; }; then
14244   eval "$as_ac_var=yes"
14245 else
14246   echo "$as_me: failed program was:" >&5
14247 sed 's/^/| /' conftest.$ac_ext >&5
14248
14249 eval "$as_ac_var=no"
14250 fi
14251 rm -f conftest.err conftest.$ac_objext \
14252       conftest$ac_exeext conftest.$ac_ext
14253 fi
14254 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14255 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14256 if test `eval echo '${'$as_ac_var'}'` = yes; then
14257   cat >>confdefs.h <<_ACEOF
14258 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14259 _ACEOF
14260
14261 else
14262   case $LIBOBJS in
14263     "$ac_func.$ac_objext"   | \
14264   *" $ac_func.$ac_objext"   | \
14265     "$ac_func.$ac_objext "* | \
14266   *" $ac_func.$ac_objext "* ) ;;
14267   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14268 esac
14269
14270 fi
14271 done
14272
14273
14274 else
14275   case $LIBOBJS in
14276     "getaddrinfo.$ac_objext"   | \
14277   *" getaddrinfo.$ac_objext"   | \
14278     "getaddrinfo.$ac_objext "* | \
14279   *" getaddrinfo.$ac_objext "* ) ;;
14280   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext" ;;
14281 esac
14282
14283 fi
14284
14285 # similarly, use system's getopt_long() only if system provides struct option.
14286 if test x"$ac_cv_type_struct_option" = xyes ; then
14287
14288 for ac_func in getopt_long
14289 do
14290 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14291 echo "$as_me:$LINENO: checking for $ac_func" >&5
14292 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14293 if eval "test \"\${$as_ac_var+set}\" = set"; then
14294   echo $ECHO_N "(cached) $ECHO_C" >&6
14295 else
14296   cat >conftest.$ac_ext <<_ACEOF
14297 /* confdefs.h.  */
14298 _ACEOF
14299 cat confdefs.h >>conftest.$ac_ext
14300 cat >>conftest.$ac_ext <<_ACEOF
14301 /* end confdefs.h.  */
14302 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14303    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14304 #define $ac_func innocuous_$ac_func
14305
14306 /* System header to define __stub macros and hopefully few prototypes,
14307     which can conflict with char $ac_func (); below.
14308     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14309     <limits.h> exists even on freestanding compilers.  */
14310
14311 #ifdef __STDC__
14312 # include <limits.h>
14313 #else
14314 # include <assert.h>
14315 #endif
14316
14317 #undef $ac_func
14318
14319 /* Override any gcc2 internal prototype to avoid an error.  */
14320 #ifdef __cplusplus
14321 extern "C"
14322 {
14323 #endif
14324 /* We use char because int might match the return type of a gcc2
14325    builtin and then its argument prototype would still apply.  */
14326 char $ac_func ();
14327 /* The GNU C library defines this for functions which it implements
14328     to always fail with ENOSYS.  Some functions are actually named
14329     something starting with __ and the normal name is an alias.  */
14330 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14331 choke me
14332 #else
14333 char (*f) () = $ac_func;
14334 #endif
14335 #ifdef __cplusplus
14336 }
14337 #endif
14338
14339 int
14340 main ()
14341 {
14342 return f != $ac_func;
14343   ;
14344   return 0;
14345 }
14346 _ACEOF
14347 rm -f conftest.$ac_objext conftest$ac_exeext
14348 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14349   (eval $ac_link) 2>conftest.er1
14350   ac_status=$?
14351   grep -v '^ *+' conftest.er1 >conftest.err
14352   rm -f conftest.er1
14353   cat conftest.err >&5
14354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14355   (exit $ac_status); } &&
14356          { ac_try='test -z "$ac_c_werror_flag"
14357                          || test ! -s conftest.err'
14358   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14359   (eval $ac_try) 2>&5
14360   ac_status=$?
14361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14362   (exit $ac_status); }; } &&
14363          { ac_try='test -s conftest$ac_exeext'
14364   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14365   (eval $ac_try) 2>&5
14366   ac_status=$?
14367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14368   (exit $ac_status); }; }; then
14369   eval "$as_ac_var=yes"
14370 else
14371   echo "$as_me: failed program was:" >&5
14372 sed 's/^/| /' conftest.$ac_ext >&5
14373
14374 eval "$as_ac_var=no"
14375 fi
14376 rm -f conftest.err conftest.$ac_objext \
14377       conftest$ac_exeext conftest.$ac_ext
14378 fi
14379 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14380 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14381 if test `eval echo '${'$as_ac_var'}'` = yes; then
14382   cat >>confdefs.h <<_ACEOF
14383 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14384 _ACEOF
14385
14386 else
14387   case $LIBOBJS in
14388     "$ac_func.$ac_objext"   | \
14389   *" $ac_func.$ac_objext"   | \
14390     "$ac_func.$ac_objext "* | \
14391   *" $ac_func.$ac_objext "* ) ;;
14392   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14393 esac
14394
14395 fi
14396 done
14397
14398
14399 else
14400   case $LIBOBJS in
14401     "getopt_long.$ac_objext"   | \
14402   *" getopt_long.$ac_objext"   | \
14403     "getopt_long.$ac_objext "* | \
14404   *" getopt_long.$ac_objext "* ) ;;
14405   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext" ;;
14406 esac
14407
14408 fi
14409
14410 # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
14411 # We override the previous test that said fseeko/ftello didn't exist
14412 # OS tests are also done in include/c.h and port/fseeko.c
14413 case $host_os in bsdi*|netbsd*)
14414 ac_cv_func_fseeko=yes
14415 esac
14416
14417 # Solaris has a very slow qsort in certain cases, so we replace it:
14418 #   http://forum.sun.com/thread.jspa?forumID=4&threadID=7231
14419 # Supposedly it is fixed in Solaris, but not sure which version, and
14420 # no confirmed testing.  2005-12-16
14421 if test "$PORTNAME" = "solaris"; then
14422 case $LIBOBJS in
14423     "qsort.$ac_objext"   | \
14424   *" qsort.$ac_objext"   | \
14425     "qsort.$ac_objext "* | \
14426   *" qsort.$ac_objext "* ) ;;
14427   *) LIBOBJS="$LIBOBJS qsort.$ac_objext" ;;
14428 esac
14429
14430 fi
14431
14432 # Win32 support
14433 if test "$PORTNAME" = "win32"; then
14434 case $LIBOBJS in
14435     "gettimeofday.$ac_objext"   | \
14436   *" gettimeofday.$ac_objext"   | \
14437     "gettimeofday.$ac_objext "* | \
14438   *" gettimeofday.$ac_objext "* ) ;;
14439   *) LIBOBJS="$LIBOBJS gettimeofday.$ac_objext" ;;
14440 esac
14441
14442 case $LIBOBJS in
14443     "kill.$ac_objext"   | \
14444   *" kill.$ac_objext"   | \
14445     "kill.$ac_objext "* | \
14446   *" kill.$ac_objext "* ) ;;
14447   *) LIBOBJS="$LIBOBJS kill.$ac_objext" ;;
14448 esac
14449
14450 case $LIBOBJS in
14451     "open.$ac_objext"   | \
14452   *" open.$ac_objext"   | \
14453     "open.$ac_objext "* | \
14454   *" open.$ac_objext "* ) ;;
14455   *) LIBOBJS="$LIBOBJS open.$ac_objext" ;;
14456 esac
14457
14458 case $LIBOBJS in
14459     "rand.$ac_objext"   | \
14460   *" rand.$ac_objext"   | \
14461     "rand.$ac_objext "* | \
14462   *" rand.$ac_objext "* ) ;;
14463   *) LIBOBJS="$LIBOBJS rand.$ac_objext" ;;
14464 esac
14465
14466
14467 cat >>confdefs.h <<\_ACEOF
14468 #define HAVE_SYMLINK 1
14469 _ACEOF
14470
14471 fi
14472
14473 if test "$with_readline" = yes; then
14474   echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
14475 echo $ECHO_N "checking for rl_completion_append_character... $ECHO_C" >&6
14476 cat >conftest.$ac_ext <<_ACEOF
14477 /* confdefs.h.  */
14478 _ACEOF
14479 cat confdefs.h >>conftest.$ac_ext
14480 cat >>conftest.$ac_ext <<_ACEOF
14481 /* end confdefs.h.  */
14482 #include <stdio.h>
14483 #ifdef HAVE_READLINE_READLINE_H
14484 # include <readline/readline.h>
14485 #elif defined(HAVE_READLINE_H)
14486 # include <readline.h>
14487 #endif
14488
14489 int
14490 main ()
14491 {
14492 rl_completion_append_character = 'x';
14493   ;
14494   return 0;
14495 }
14496 _ACEOF
14497 rm -f conftest.$ac_objext conftest$ac_exeext
14498 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14499   (eval $ac_link) 2>conftest.er1
14500   ac_status=$?
14501   grep -v '^ *+' conftest.er1 >conftest.err
14502   rm -f conftest.er1
14503   cat conftest.err >&5
14504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14505   (exit $ac_status); } &&
14506          { ac_try='test -z "$ac_c_werror_flag"
14507                          || test ! -s conftest.err'
14508   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14509   (eval $ac_try) 2>&5
14510   ac_status=$?
14511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14512   (exit $ac_status); }; } &&
14513          { ac_try='test -s conftest$ac_exeext'
14514   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14515   (eval $ac_try) 2>&5
14516   ac_status=$?
14517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14518   (exit $ac_status); }; }; then
14519   echo "$as_me:$LINENO: result: yes" >&5
14520 echo "${ECHO_T}yes" >&6
14521
14522 cat >>confdefs.h <<\_ACEOF
14523 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
14524 _ACEOF
14525
14526 else
14527   echo "$as_me: failed program was:" >&5
14528 sed 's/^/| /' conftest.$ac_ext >&5
14529
14530 echo "$as_me:$LINENO: result: no" >&5
14531 echo "${ECHO_T}no" >&6
14532 fi
14533 rm -f conftest.err conftest.$ac_objext \
14534       conftest$ac_exeext conftest.$ac_ext
14535
14536
14537 for ac_func in rl_completion_matches rl_filename_completion_function
14538 do
14539 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14540 echo "$as_me:$LINENO: checking for $ac_func" >&5
14541 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14542 if eval "test \"\${$as_ac_var+set}\" = set"; then
14543   echo $ECHO_N "(cached) $ECHO_C" >&6
14544 else
14545   cat >conftest.$ac_ext <<_ACEOF
14546 /* confdefs.h.  */
14547 _ACEOF
14548 cat confdefs.h >>conftest.$ac_ext
14549 cat >>conftest.$ac_ext <<_ACEOF
14550 /* end confdefs.h.  */
14551 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14552    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14553 #define $ac_func innocuous_$ac_func
14554
14555 /* System header to define __stub macros and hopefully few prototypes,
14556     which can conflict with char $ac_func (); below.
14557     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14558     <limits.h> exists even on freestanding compilers.  */
14559
14560 #ifdef __STDC__
14561 # include <limits.h>
14562 #else
14563 # include <assert.h>
14564 #endif
14565
14566 #undef $ac_func
14567
14568 /* Override any gcc2 internal prototype to avoid an error.  */
14569 #ifdef __cplusplus
14570 extern "C"
14571 {
14572 #endif
14573 /* We use char because int might match the return type of a gcc2
14574    builtin and then its argument prototype would still apply.  */
14575 char $ac_func ();
14576 /* The GNU C library defines this for functions which it implements
14577     to always fail with ENOSYS.  Some functions are actually named
14578     something starting with __ and the normal name is an alias.  */
14579 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14580 choke me
14581 #else
14582 char (*f) () = $ac_func;
14583 #endif
14584 #ifdef __cplusplus
14585 }
14586 #endif
14587
14588 int
14589 main ()
14590 {
14591 return f != $ac_func;
14592   ;
14593   return 0;
14594 }
14595 _ACEOF
14596 rm -f conftest.$ac_objext conftest$ac_exeext
14597 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14598   (eval $ac_link) 2>conftest.er1
14599   ac_status=$?
14600   grep -v '^ *+' conftest.er1 >conftest.err
14601   rm -f conftest.er1
14602   cat conftest.err >&5
14603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14604   (exit $ac_status); } &&
14605          { ac_try='test -z "$ac_c_werror_flag"
14606                          || test ! -s conftest.err'
14607   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14608   (eval $ac_try) 2>&5
14609   ac_status=$?
14610   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14611   (exit $ac_status); }; } &&
14612          { ac_try='test -s conftest$ac_exeext'
14613   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14614   (eval $ac_try) 2>&5
14615   ac_status=$?
14616   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14617   (exit $ac_status); }; }; then
14618   eval "$as_ac_var=yes"
14619 else
14620   echo "$as_me: failed program was:" >&5
14621 sed 's/^/| /' conftest.$ac_ext >&5
14622
14623 eval "$as_ac_var=no"
14624 fi
14625 rm -f conftest.err conftest.$ac_objext \
14626       conftest$ac_exeext conftest.$ac_ext
14627 fi
14628 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14629 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14630 if test `eval echo '${'$as_ac_var'}'` = yes; then
14631   cat >>confdefs.h <<_ACEOF
14632 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14633 _ACEOF
14634
14635 fi
14636 done
14637
14638
14639 for ac_func in replace_history_entry
14640 do
14641 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14642 echo "$as_me:$LINENO: checking for $ac_func" >&5
14643 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14644 if eval "test \"\${$as_ac_var+set}\" = set"; then
14645   echo $ECHO_N "(cached) $ECHO_C" >&6
14646 else
14647   cat >conftest.$ac_ext <<_ACEOF
14648 /* confdefs.h.  */
14649 _ACEOF
14650 cat confdefs.h >>conftest.$ac_ext
14651 cat >>conftest.$ac_ext <<_ACEOF
14652 /* end confdefs.h.  */
14653 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14654    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14655 #define $ac_func innocuous_$ac_func
14656
14657 /* System header to define __stub macros and hopefully few prototypes,
14658     which can conflict with char $ac_func (); below.
14659     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14660     <limits.h> exists even on freestanding compilers.  */
14661
14662 #ifdef __STDC__
14663 # include <limits.h>
14664 #else
14665 # include <assert.h>
14666 #endif
14667
14668 #undef $ac_func
14669
14670 /* Override any gcc2 internal prototype to avoid an error.  */
14671 #ifdef __cplusplus
14672 extern "C"
14673 {
14674 #endif
14675 /* We use char because int might match the return type of a gcc2
14676    builtin and then its argument prototype would still apply.  */
14677 char $ac_func ();
14678 /* The GNU C library defines this for functions which it implements
14679     to always fail with ENOSYS.  Some functions are actually named
14680     something starting with __ and the normal name is an alias.  */
14681 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14682 choke me
14683 #else
14684 char (*f) () = $ac_func;
14685 #endif
14686 #ifdef __cplusplus
14687 }
14688 #endif
14689
14690 int
14691 main ()
14692 {
14693 return f != $ac_func;
14694   ;
14695   return 0;
14696 }
14697 _ACEOF
14698 rm -f conftest.$ac_objext conftest$ac_exeext
14699 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14700   (eval $ac_link) 2>conftest.er1
14701   ac_status=$?
14702   grep -v '^ *+' conftest.er1 >conftest.err
14703   rm -f conftest.er1
14704   cat conftest.err >&5
14705   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14706   (exit $ac_status); } &&
14707          { ac_try='test -z "$ac_c_werror_flag"
14708                          || test ! -s conftest.err'
14709   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14710   (eval $ac_try) 2>&5
14711   ac_status=$?
14712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14713   (exit $ac_status); }; } &&
14714          { ac_try='test -s conftest$ac_exeext'
14715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14716   (eval $ac_try) 2>&5
14717   ac_status=$?
14718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14719   (exit $ac_status); }; }; then
14720   eval "$as_ac_var=yes"
14721 else
14722   echo "$as_me: failed program was:" >&5
14723 sed 's/^/| /' conftest.$ac_ext >&5
14724
14725 eval "$as_ac_var=no"
14726 fi
14727 rm -f conftest.err conftest.$ac_objext \
14728       conftest$ac_exeext conftest.$ac_ext
14729 fi
14730 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14731 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14732 if test `eval echo '${'$as_ac_var'}'` = yes; then
14733   cat >>confdefs.h <<_ACEOF
14734 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14735 _ACEOF
14736
14737 fi
14738 done
14739
14740 fi
14741
14742
14743 echo "$as_me:$LINENO: checking for finite" >&5
14744 echo $ECHO_N "checking for finite... $ECHO_C" >&6
14745 cat >conftest.$ac_ext <<_ACEOF
14746 /* confdefs.h.  */
14747 _ACEOF
14748 cat confdefs.h >>conftest.$ac_ext
14749 cat >>conftest.$ac_ext <<_ACEOF
14750 /* end confdefs.h.  */
14751
14752 #include <math.h>
14753 double glob_double;
14754
14755 int
14756 main ()
14757 {
14758 return finite(glob_double) ? 0 : 1;
14759   ;
14760   return 0;
14761 }
14762 _ACEOF
14763 rm -f conftest.$ac_objext conftest$ac_exeext
14764 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14765   (eval $ac_link) 2>conftest.er1
14766   ac_status=$?
14767   grep -v '^ *+' conftest.er1 >conftest.err
14768   rm -f conftest.er1
14769   cat conftest.err >&5
14770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14771   (exit $ac_status); } &&
14772          { ac_try='test -z "$ac_c_werror_flag"
14773                          || test ! -s conftest.err'
14774   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14775   (eval $ac_try) 2>&5
14776   ac_status=$?
14777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14778   (exit $ac_status); }; } &&
14779          { ac_try='test -s conftest$ac_exeext'
14780   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14781   (eval $ac_try) 2>&5
14782   ac_status=$?
14783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14784   (exit $ac_status); }; }; then
14785
14786 cat >>confdefs.h <<\_ACEOF
14787 #define HAVE_FINITE 1
14788 _ACEOF
14789
14790 echo "$as_me:$LINENO: result: yes" >&5
14791 echo "${ECHO_T}yes" >&6
14792 else
14793   echo "$as_me: failed program was:" >&5
14794 sed 's/^/| /' conftest.$ac_ext >&5
14795
14796 echo "$as_me:$LINENO: result: no" >&5
14797 echo "${ECHO_T}no" >&6
14798 fi
14799 rm -f conftest.err conftest.$ac_objext \
14800       conftest$ac_exeext conftest.$ac_ext
14801
14802 echo "$as_me:$LINENO: checking for sigsetjmp" >&5
14803 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6
14804 cat >conftest.$ac_ext <<_ACEOF
14805 /* confdefs.h.  */
14806 _ACEOF
14807 cat confdefs.h >>conftest.$ac_ext
14808 cat >>conftest.$ac_ext <<_ACEOF
14809 /* end confdefs.h.  */
14810 #include <setjmp.h>
14811 int
14812 main ()
14813 {
14814 sigjmp_buf x; sigsetjmp(x, 1);
14815   ;
14816   return 0;
14817 }
14818 _ACEOF
14819 rm -f conftest.$ac_objext conftest$ac_exeext
14820 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14821   (eval $ac_link) 2>conftest.er1
14822   ac_status=$?
14823   grep -v '^ *+' conftest.er1 >conftest.err
14824   rm -f conftest.er1
14825   cat conftest.err >&5
14826   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14827   (exit $ac_status); } &&
14828          { ac_try='test -z "$ac_c_werror_flag"
14829                          || test ! -s conftest.err'
14830   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14831   (eval $ac_try) 2>&5
14832   ac_status=$?
14833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14834   (exit $ac_status); }; } &&
14835          { ac_try='test -s conftest$ac_exeext'
14836   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14837   (eval $ac_try) 2>&5
14838   ac_status=$?
14839   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14840   (exit $ac_status); }; }; then
14841
14842 cat >>confdefs.h <<\_ACEOF
14843 #define HAVE_SIGSETJMP 1
14844 _ACEOF
14845
14846 echo "$as_me:$LINENO: result: yes" >&5
14847 echo "${ECHO_T}yes" >&6
14848 else
14849   echo "$as_me: failed program was:" >&5
14850 sed 's/^/| /' conftest.$ac_ext >&5
14851
14852 echo "$as_me:$LINENO: result: no" >&5
14853 echo "${ECHO_T}no" >&6
14854 fi
14855 rm -f conftest.err conftest.$ac_objext \
14856       conftest$ac_exeext conftest.$ac_ext
14857
14858 echo "$as_me:$LINENO: checking for syslog" >&5
14859 echo $ECHO_N "checking for syslog... $ECHO_C" >&6
14860 if test "${ac_cv_func_syslog+set}" = set; then
14861   echo $ECHO_N "(cached) $ECHO_C" >&6
14862 else
14863   cat >conftest.$ac_ext <<_ACEOF
14864 /* confdefs.h.  */
14865 _ACEOF
14866 cat confdefs.h >>conftest.$ac_ext
14867 cat >>conftest.$ac_ext <<_ACEOF
14868 /* end confdefs.h.  */
14869 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
14870    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14871 #define syslog innocuous_syslog
14872
14873 /* System header to define __stub macros and hopefully few prototypes,
14874     which can conflict with char syslog (); below.
14875     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14876     <limits.h> exists even on freestanding compilers.  */
14877
14878 #ifdef __STDC__
14879 # include <limits.h>
14880 #else
14881 # include <assert.h>
14882 #endif
14883
14884 #undef syslog
14885
14886 /* Override any gcc2 internal prototype to avoid an error.  */
14887 #ifdef __cplusplus
14888 extern "C"
14889 {
14890 #endif
14891 /* We use char because int might match the return type of a gcc2
14892    builtin and then its argument prototype would still apply.  */
14893 char syslog ();
14894 /* The GNU C library defines this for functions which it implements
14895     to always fail with ENOSYS.  Some functions are actually named
14896     something starting with __ and the normal name is an alias.  */
14897 #if defined (__stub_syslog) || defined (__stub___syslog)
14898 choke me
14899 #else
14900 char (*f) () = syslog;
14901 #endif
14902 #ifdef __cplusplus
14903 }
14904 #endif
14905
14906 int
14907 main ()
14908 {
14909 return f != syslog;
14910   ;
14911   return 0;
14912 }
14913 _ACEOF
14914 rm -f conftest.$ac_objext conftest$ac_exeext
14915 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14916   (eval $ac_link) 2>conftest.er1
14917   ac_status=$?
14918   grep -v '^ *+' conftest.er1 >conftest.err
14919   rm -f conftest.er1
14920   cat conftest.err >&5
14921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14922   (exit $ac_status); } &&
14923          { ac_try='test -z "$ac_c_werror_flag"
14924                          || test ! -s conftest.err'
14925   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14926   (eval $ac_try) 2>&5
14927   ac_status=$?
14928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14929   (exit $ac_status); }; } &&
14930          { ac_try='test -s conftest$ac_exeext'
14931   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14932   (eval $ac_try) 2>&5
14933   ac_status=$?
14934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14935   (exit $ac_status); }; }; then
14936   ac_cv_func_syslog=yes
14937 else
14938   echo "$as_me: failed program was:" >&5
14939 sed 's/^/| /' conftest.$ac_ext >&5
14940
14941 ac_cv_func_syslog=no
14942 fi
14943 rm -f conftest.err conftest.$ac_objext \
14944       conftest$ac_exeext conftest.$ac_ext
14945 fi
14946 echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
14947 echo "${ECHO_T}$ac_cv_func_syslog" >&6
14948 if test $ac_cv_func_syslog = yes; then
14949   if test "${ac_cv_header_syslog_h+set}" = set; then
14950   echo "$as_me:$LINENO: checking for syslog.h" >&5
14951 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
14952 if test "${ac_cv_header_syslog_h+set}" = set; then
14953   echo $ECHO_N "(cached) $ECHO_C" >&6
14954 fi
14955 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
14956 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
14957 else
14958   # Is the header compilable?
14959 echo "$as_me:$LINENO: checking syslog.h usability" >&5
14960 echo $ECHO_N "checking syslog.h usability... $ECHO_C" >&6
14961 cat >conftest.$ac_ext <<_ACEOF
14962 /* confdefs.h.  */
14963 _ACEOF
14964 cat confdefs.h >>conftest.$ac_ext
14965 cat >>conftest.$ac_ext <<_ACEOF
14966 /* end confdefs.h.  */
14967 $ac_includes_default
14968 #include <syslog.h>
14969 _ACEOF
14970 rm -f conftest.$ac_objext
14971 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14972   (eval $ac_compile) 2>conftest.er1
14973   ac_status=$?
14974   grep -v '^ *+' conftest.er1 >conftest.err
14975   rm -f conftest.er1
14976   cat conftest.err >&5
14977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14978   (exit $ac_status); } &&
14979          { ac_try='test -z "$ac_c_werror_flag"
14980                          || test ! -s conftest.err'
14981   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14982   (eval $ac_try) 2>&5
14983   ac_status=$?
14984   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14985   (exit $ac_status); }; } &&
14986          { ac_try='test -s conftest.$ac_objext'
14987   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14988   (eval $ac_try) 2>&5
14989   ac_status=$?
14990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14991   (exit $ac_status); }; }; then
14992   ac_header_compiler=yes
14993 else
14994   echo "$as_me: failed program was:" >&5
14995 sed 's/^/| /' conftest.$ac_ext >&5
14996
14997 ac_header_compiler=no
14998 fi
14999 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15000 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15001 echo "${ECHO_T}$ac_header_compiler" >&6
15002
15003 # Is the header present?
15004 echo "$as_me:$LINENO: checking syslog.h presence" >&5
15005 echo $ECHO_N "checking syslog.h presence... $ECHO_C" >&6
15006 cat >conftest.$ac_ext <<_ACEOF
15007 /* confdefs.h.  */
15008 _ACEOF
15009 cat confdefs.h >>conftest.$ac_ext
15010 cat >>conftest.$ac_ext <<_ACEOF
15011 /* end confdefs.h.  */
15012 #include <syslog.h>
15013 _ACEOF
15014 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15015   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15016   ac_status=$?
15017   grep -v '^ *+' conftest.er1 >conftest.err
15018   rm -f conftest.er1
15019   cat conftest.err >&5
15020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15021   (exit $ac_status); } >/dev/null; then
15022   if test -s conftest.err; then
15023     ac_cpp_err=$ac_c_preproc_warn_flag
15024     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15025   else
15026     ac_cpp_err=
15027   fi
15028 else
15029   ac_cpp_err=yes
15030 fi
15031 if test -z "$ac_cpp_err"; then
15032   ac_header_preproc=yes
15033 else
15034   echo "$as_me: failed program was:" >&5
15035 sed 's/^/| /' conftest.$ac_ext >&5
15036
15037   ac_header_preproc=no
15038 fi
15039 rm -f conftest.err conftest.$ac_ext
15040 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15041 echo "${ECHO_T}$ac_header_preproc" >&6
15042
15043 # So?  What about this header?
15044 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15045   yes:no: )
15046     { echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
15047 echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15048     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
15049 echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
15050     ac_header_preproc=yes
15051     ;;
15052   no:yes:* )
15053     { echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
15054 echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
15055     { echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
15056 echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
15057     { echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
15058 echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
15059     { echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
15060 echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
15061     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
15062 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
15063     { echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
15064 echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
15065     (
15066       cat <<\_ASBOX
15067 ## ---------------------------------------- ##
15068 ## Report this to pgsql-bugs@postgresql.org ##
15069 ## ---------------------------------------- ##
15070 _ASBOX
15071     ) |
15072       sed "s/^/$as_me: WARNING:     /" >&2
15073     ;;
15074 esac
15075 echo "$as_me:$LINENO: checking for syslog.h" >&5
15076 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
15077 if test "${ac_cv_header_syslog_h+set}" = set; then
15078   echo $ECHO_N "(cached) $ECHO_C" >&6
15079 else
15080   ac_cv_header_syslog_h=$ac_header_preproc
15081 fi
15082 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
15083 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
15084
15085 fi
15086 if test $ac_cv_header_syslog_h = yes; then
15087
15088 cat >>confdefs.h <<\_ACEOF
15089 #define HAVE_SYSLOG 1
15090 _ACEOF
15091
15092 fi
15093
15094
15095 fi
15096
15097
15098 echo "$as_me:$LINENO: checking for optreset" >&5
15099 echo $ECHO_N "checking for optreset... $ECHO_C" >&6
15100 if test "${pgac_cv_var_int_optreset+set}" = set; then
15101   echo $ECHO_N "(cached) $ECHO_C" >&6
15102 else
15103   cat >conftest.$ac_ext <<_ACEOF
15104 /* confdefs.h.  */
15105 _ACEOF
15106 cat confdefs.h >>conftest.$ac_ext
15107 cat >>conftest.$ac_ext <<_ACEOF
15108 /* end confdefs.h.  */
15109 #include <unistd.h>
15110 int
15111 main ()
15112 {
15113 extern int optreset; optreset = 1;
15114   ;
15115   return 0;
15116 }
15117 _ACEOF
15118 rm -f conftest.$ac_objext conftest$ac_exeext
15119 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15120   (eval $ac_link) 2>conftest.er1
15121   ac_status=$?
15122   grep -v '^ *+' conftest.er1 >conftest.err
15123   rm -f conftest.er1
15124   cat conftest.err >&5
15125   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15126   (exit $ac_status); } &&
15127          { ac_try='test -z "$ac_c_werror_flag"
15128                          || test ! -s conftest.err'
15129   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15130   (eval $ac_try) 2>&5
15131   ac_status=$?
15132   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15133   (exit $ac_status); }; } &&
15134          { ac_try='test -s conftest$ac_exeext'
15135   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15136   (eval $ac_try) 2>&5
15137   ac_status=$?
15138   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15139   (exit $ac_status); }; }; then
15140   pgac_cv_var_int_optreset=yes
15141 else
15142   echo "$as_me: failed program was:" >&5
15143 sed 's/^/| /' conftest.$ac_ext >&5
15144
15145 pgac_cv_var_int_optreset=no
15146 fi
15147 rm -f conftest.err conftest.$ac_objext \
15148       conftest$ac_exeext conftest.$ac_ext
15149 fi
15150 echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
15151 echo "${ECHO_T}$pgac_cv_var_int_optreset" >&6
15152 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
15153
15154 cat >>confdefs.h <<\_ACEOF
15155 #define HAVE_INT_OPTRESET 1
15156 _ACEOF
15157
15158 fi
15159
15160
15161
15162 for ac_func in strtoll strtoq
15163 do
15164 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15165 echo "$as_me:$LINENO: checking for $ac_func" >&5
15166 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15167 if eval "test \"\${$as_ac_var+set}\" = set"; then
15168   echo $ECHO_N "(cached) $ECHO_C" >&6
15169 else
15170   cat >conftest.$ac_ext <<_ACEOF
15171 /* confdefs.h.  */
15172 _ACEOF
15173 cat confdefs.h >>conftest.$ac_ext
15174 cat >>conftest.$ac_ext <<_ACEOF
15175 /* end confdefs.h.  */
15176 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15177    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15178 #define $ac_func innocuous_$ac_func
15179
15180 /* System header to define __stub macros and hopefully few prototypes,
15181     which can conflict with char $ac_func (); below.
15182     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15183     <limits.h> exists even on freestanding compilers.  */
15184
15185 #ifdef __STDC__
15186 # include <limits.h>
15187 #else
15188 # include <assert.h>
15189 #endif
15190
15191 #undef $ac_func
15192
15193 /* Override any gcc2 internal prototype to avoid an error.  */
15194 #ifdef __cplusplus
15195 extern "C"
15196 {
15197 #endif
15198 /* We use char because int might match the return type of a gcc2
15199    builtin and then its argument prototype would still apply.  */
15200 char $ac_func ();
15201 /* The GNU C library defines this for functions which it implements
15202     to always fail with ENOSYS.  Some functions are actually named
15203     something starting with __ and the normal name is an alias.  */
15204 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15205 choke me
15206 #else
15207 char (*f) () = $ac_func;
15208 #endif
15209 #ifdef __cplusplus
15210 }
15211 #endif
15212
15213 int
15214 main ()
15215 {
15216 return f != $ac_func;
15217   ;
15218   return 0;
15219 }
15220 _ACEOF
15221 rm -f conftest.$ac_objext conftest$ac_exeext
15222 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15223   (eval $ac_link) 2>conftest.er1
15224   ac_status=$?
15225   grep -v '^ *+' conftest.er1 >conftest.err
15226   rm -f conftest.er1
15227   cat conftest.err >&5
15228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15229   (exit $ac_status); } &&
15230          { ac_try='test -z "$ac_c_werror_flag"
15231                          || test ! -s conftest.err'
15232   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15233   (eval $ac_try) 2>&5
15234   ac_status=$?
15235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15236   (exit $ac_status); }; } &&
15237          { ac_try='test -s conftest$ac_exeext'
15238   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15239   (eval $ac_try) 2>&5
15240   ac_status=$?
15241   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15242   (exit $ac_status); }; }; then
15243   eval "$as_ac_var=yes"
15244 else
15245   echo "$as_me: failed program was:" >&5
15246 sed 's/^/| /' conftest.$ac_ext >&5
15247
15248 eval "$as_ac_var=no"
15249 fi
15250 rm -f conftest.err conftest.$ac_objext \
15251       conftest$ac_exeext conftest.$ac_ext
15252 fi
15253 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15254 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15255 if test `eval echo '${'$as_ac_var'}'` = yes; then
15256   cat >>confdefs.h <<_ACEOF
15257 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15258 _ACEOF
15259  break
15260 fi
15261 done
15262
15263
15264
15265 for ac_func in strtoull strtouq
15266 do
15267 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15268 echo "$as_me:$LINENO: checking for $ac_func" >&5
15269 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15270 if eval "test \"\${$as_ac_var+set}\" = set"; then
15271   echo $ECHO_N "(cached) $ECHO_C" >&6
15272 else
15273   cat >conftest.$ac_ext <<_ACEOF
15274 /* confdefs.h.  */
15275 _ACEOF
15276 cat confdefs.h >>conftest.$ac_ext
15277 cat >>conftest.$ac_ext <<_ACEOF
15278 /* end confdefs.h.  */
15279 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15280    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15281 #define $ac_func innocuous_$ac_func
15282
15283 /* System header to define __stub macros and hopefully few prototypes,
15284     which can conflict with char $ac_func (); below.
15285     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15286     <limits.h> exists even on freestanding compilers.  */
15287
15288 #ifdef __STDC__
15289 # include <limits.h>
15290 #else
15291 # include <assert.h>
15292 #endif
15293
15294 #undef $ac_func
15295
15296 /* Override any gcc2 internal prototype to avoid an error.  */
15297 #ifdef __cplusplus
15298 extern "C"
15299 {
15300 #endif
15301 /* We use char because int might match the return type of a gcc2
15302    builtin and then its argument prototype would still apply.  */
15303 char $ac_func ();
15304 /* The GNU C library defines this for functions which it implements
15305     to always fail with ENOSYS.  Some functions are actually named
15306     something starting with __ and the normal name is an alias.  */
15307 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15308 choke me
15309 #else
15310 char (*f) () = $ac_func;
15311 #endif
15312 #ifdef __cplusplus
15313 }
15314 #endif
15315
15316 int
15317 main ()
15318 {
15319 return f != $ac_func;
15320   ;
15321   return 0;
15322 }
15323 _ACEOF
15324 rm -f conftest.$ac_objext conftest$ac_exeext
15325 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15326   (eval $ac_link) 2>conftest.er1
15327   ac_status=$?
15328   grep -v '^ *+' conftest.er1 >conftest.err
15329   rm -f conftest.er1
15330   cat conftest.err >&5
15331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15332   (exit $ac_status); } &&
15333          { ac_try='test -z "$ac_c_werror_flag"
15334                          || test ! -s conftest.err'
15335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15336   (eval $ac_try) 2>&5
15337   ac_status=$?
15338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15339   (exit $ac_status); }; } &&
15340          { ac_try='test -s conftest$ac_exeext'
15341   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15342   (eval $ac_try) 2>&5
15343   ac_status=$?
15344   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15345   (exit $ac_status); }; }; then
15346   eval "$as_ac_var=yes"
15347 else
15348   echo "$as_me: failed program was:" >&5
15349 sed 's/^/| /' conftest.$ac_ext >&5
15350
15351 eval "$as_ac_var=no"
15352 fi
15353 rm -f conftest.err conftest.$ac_objext \
15354       conftest$ac_exeext conftest.$ac_ext
15355 fi
15356 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15357 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15358 if test `eval echo '${'$as_ac_var'}'` = yes; then
15359   cat >>confdefs.h <<_ACEOF
15360 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15361 _ACEOF
15362  break
15363 fi
15364 done
15365
15366
15367 # Check for one of atexit() or on_exit()
15368
15369 for ac_func in atexit
15370 do
15371 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15372 echo "$as_me:$LINENO: checking for $ac_func" >&5
15373 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15374 if eval "test \"\${$as_ac_var+set}\" = set"; then
15375   echo $ECHO_N "(cached) $ECHO_C" >&6
15376 else
15377   cat >conftest.$ac_ext <<_ACEOF
15378 /* confdefs.h.  */
15379 _ACEOF
15380 cat confdefs.h >>conftest.$ac_ext
15381 cat >>conftest.$ac_ext <<_ACEOF
15382 /* end confdefs.h.  */
15383 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15384    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15385 #define $ac_func innocuous_$ac_func
15386
15387 /* System header to define __stub macros and hopefully few prototypes,
15388     which can conflict with char $ac_func (); below.
15389     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15390     <limits.h> exists even on freestanding compilers.  */
15391
15392 #ifdef __STDC__
15393 # include <limits.h>
15394 #else
15395 # include <assert.h>
15396 #endif
15397
15398 #undef $ac_func
15399
15400 /* Override any gcc2 internal prototype to avoid an error.  */
15401 #ifdef __cplusplus
15402 extern "C"
15403 {
15404 #endif
15405 /* We use char because int might match the return type of a gcc2
15406    builtin and then its argument prototype would still apply.  */
15407 char $ac_func ();
15408 /* The GNU C library defines this for functions which it implements
15409     to always fail with ENOSYS.  Some functions are actually named
15410     something starting with __ and the normal name is an alias.  */
15411 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15412 choke me
15413 #else
15414 char (*f) () = $ac_func;
15415 #endif
15416 #ifdef __cplusplus
15417 }
15418 #endif
15419
15420 int
15421 main ()
15422 {
15423 return f != $ac_func;
15424   ;
15425   return 0;
15426 }
15427 _ACEOF
15428 rm -f conftest.$ac_objext conftest$ac_exeext
15429 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15430   (eval $ac_link) 2>conftest.er1
15431   ac_status=$?
15432   grep -v '^ *+' conftest.er1 >conftest.err
15433   rm -f conftest.er1
15434   cat conftest.err >&5
15435   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15436   (exit $ac_status); } &&
15437          { ac_try='test -z "$ac_c_werror_flag"
15438                          || test ! -s conftest.err'
15439   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15440   (eval $ac_try) 2>&5
15441   ac_status=$?
15442   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15443   (exit $ac_status); }; } &&
15444          { ac_try='test -s conftest$ac_exeext'
15445   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15446   (eval $ac_try) 2>&5
15447   ac_status=$?
15448   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15449   (exit $ac_status); }; }; then
15450   eval "$as_ac_var=yes"
15451 else
15452   echo "$as_me: failed program was:" >&5
15453 sed 's/^/| /' conftest.$ac_ext >&5
15454
15455 eval "$as_ac_var=no"
15456 fi
15457 rm -f conftest.err conftest.$ac_objext \
15458       conftest$ac_exeext conftest.$ac_ext
15459 fi
15460 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15461 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15462 if test `eval echo '${'$as_ac_var'}'` = yes; then
15463   cat >>confdefs.h <<_ACEOF
15464 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15465 _ACEOF
15466
15467 else
15468
15469 for ac_func in on_exit
15470 do
15471 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15472 echo "$as_me:$LINENO: checking for $ac_func" >&5
15473 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15474 if eval "test \"\${$as_ac_var+set}\" = set"; then
15475   echo $ECHO_N "(cached) $ECHO_C" >&6
15476 else
15477   cat >conftest.$ac_ext <<_ACEOF
15478 /* confdefs.h.  */
15479 _ACEOF
15480 cat confdefs.h >>conftest.$ac_ext
15481 cat >>conftest.$ac_ext <<_ACEOF
15482 /* end confdefs.h.  */
15483 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15484    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15485 #define $ac_func innocuous_$ac_func
15486
15487 /* System header to define __stub macros and hopefully few prototypes,
15488     which can conflict with char $ac_func (); below.
15489     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15490     <limits.h> exists even on freestanding compilers.  */
15491
15492 #ifdef __STDC__
15493 # include <limits.h>
15494 #else
15495 # include <assert.h>
15496 #endif
15497
15498 #undef $ac_func
15499
15500 /* Override any gcc2 internal prototype to avoid an error.  */
15501 #ifdef __cplusplus
15502 extern "C"
15503 {
15504 #endif
15505 /* We use char because int might match the return type of a gcc2
15506    builtin and then its argument prototype would still apply.  */
15507 char $ac_func ();
15508 /* The GNU C library defines this for functions which it implements
15509     to always fail with ENOSYS.  Some functions are actually named
15510     something starting with __ and the normal name is an alias.  */
15511 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15512 choke me
15513 #else
15514 char (*f) () = $ac_func;
15515 #endif
15516 #ifdef __cplusplus
15517 }
15518 #endif
15519
15520 int
15521 main ()
15522 {
15523 return f != $ac_func;
15524   ;
15525   return 0;
15526 }
15527 _ACEOF
15528 rm -f conftest.$ac_objext conftest$ac_exeext
15529 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15530   (eval $ac_link) 2>conftest.er1
15531   ac_status=$?
15532   grep -v '^ *+' conftest.er1 >conftest.err
15533   rm -f conftest.er1
15534   cat conftest.err >&5
15535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15536   (exit $ac_status); } &&
15537          { ac_try='test -z "$ac_c_werror_flag"
15538                          || test ! -s conftest.err'
15539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15540   (eval $ac_try) 2>&5
15541   ac_status=$?
15542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15543   (exit $ac_status); }; } &&
15544          { ac_try='test -s conftest$ac_exeext'
15545   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15546   (eval $ac_try) 2>&5
15547   ac_status=$?
15548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15549   (exit $ac_status); }; }; then
15550   eval "$as_ac_var=yes"
15551 else
15552   echo "$as_me: failed program was:" >&5
15553 sed 's/^/| /' conftest.$ac_ext >&5
15554
15555 eval "$as_ac_var=no"
15556 fi
15557 rm -f conftest.err conftest.$ac_objext \
15558       conftest$ac_exeext conftest.$ac_ext
15559 fi
15560 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15561 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15562 if test `eval echo '${'$as_ac_var'}'` = yes; then
15563   cat >>confdefs.h <<_ACEOF
15564 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15565 _ACEOF
15566
15567 else
15568   { { echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
15569 echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
15570    { (exit 1); exit 1; }; }
15571 fi
15572 done
15573
15574 fi
15575 done
15576
15577
15578 echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15579 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
15580 if test "${ac_cv_sys_largefile_source+set}" = set; then
15581   echo $ECHO_N "(cached) $ECHO_C" >&6
15582 else
15583   while :; do
15584   ac_cv_sys_largefile_source=no
15585   cat >conftest.$ac_ext <<_ACEOF
15586 /* confdefs.h.  */
15587 _ACEOF
15588 cat confdefs.h >>conftest.$ac_ext
15589 cat >>conftest.$ac_ext <<_ACEOF
15590 /* end confdefs.h.  */
15591 #include <stdio.h>
15592 int
15593 main ()
15594 {
15595 return !fseeko;
15596   ;
15597   return 0;
15598 }
15599 _ACEOF
15600 rm -f conftest.$ac_objext
15601 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15602   (eval $ac_compile) 2>conftest.er1
15603   ac_status=$?
15604   grep -v '^ *+' conftest.er1 >conftest.err
15605   rm -f conftest.er1
15606   cat conftest.err >&5
15607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15608   (exit $ac_status); } &&
15609          { ac_try='test -z "$ac_c_werror_flag"
15610                          || test ! -s conftest.err'
15611   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15612   (eval $ac_try) 2>&5
15613   ac_status=$?
15614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15615   (exit $ac_status); }; } &&
15616          { ac_try='test -s conftest.$ac_objext'
15617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15618   (eval $ac_try) 2>&5
15619   ac_status=$?
15620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15621   (exit $ac_status); }; }; then
15622   break
15623 else
15624   echo "$as_me: failed program was:" >&5
15625 sed 's/^/| /' conftest.$ac_ext >&5
15626
15627 fi
15628 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15629   cat >conftest.$ac_ext <<_ACEOF
15630 /* confdefs.h.  */
15631 _ACEOF
15632 cat confdefs.h >>conftest.$ac_ext
15633 cat >>conftest.$ac_ext <<_ACEOF
15634 /* end confdefs.h.  */
15635 #define _LARGEFILE_SOURCE 1
15636 #include <stdio.h>
15637 int
15638 main ()
15639 {
15640 return !fseeko;
15641   ;
15642   return 0;
15643 }
15644 _ACEOF
15645 rm -f conftest.$ac_objext
15646 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15647   (eval $ac_compile) 2>conftest.er1
15648   ac_status=$?
15649   grep -v '^ *+' conftest.er1 >conftest.err
15650   rm -f conftest.er1
15651   cat conftest.err >&5
15652   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15653   (exit $ac_status); } &&
15654          { ac_try='test -z "$ac_c_werror_flag"
15655                          || test ! -s conftest.err'
15656   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15657   (eval $ac_try) 2>&5
15658   ac_status=$?
15659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15660   (exit $ac_status); }; } &&
15661          { ac_try='test -s conftest.$ac_objext'
15662   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15663   (eval $ac_try) 2>&5
15664   ac_status=$?
15665   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15666   (exit $ac_status); }; }; then
15667   ac_cv_sys_largefile_source=1; break
15668 else
15669   echo "$as_me: failed program was:" >&5
15670 sed 's/^/| /' conftest.$ac_ext >&5
15671
15672 fi
15673 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15674   break
15675 done
15676 fi
15677 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
15678 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
15679 if test "$ac_cv_sys_largefile_source" != no; then
15680
15681 cat >>confdefs.h <<_ACEOF
15682 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15683 _ACEOF
15684
15685 fi
15686 rm -f conftest*
15687
15688 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15689 # in glibc 2.1.3, but that breaks too many other things.
15690 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15691 echo "$as_me:$LINENO: checking for fseeko" >&5
15692 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
15693 if test "${ac_cv_func_fseeko+set}" = set; then
15694   echo $ECHO_N "(cached) $ECHO_C" >&6
15695 else
15696   cat >conftest.$ac_ext <<_ACEOF
15697 /* confdefs.h.  */
15698 _ACEOF
15699 cat confdefs.h >>conftest.$ac_ext
15700 cat >>conftest.$ac_ext <<_ACEOF
15701 /* end confdefs.h.  */
15702 #include <stdio.h>
15703 int
15704 main ()
15705 {
15706 return fseeko && fseeko (stdin, 0, 0);
15707   ;
15708   return 0;
15709 }
15710 _ACEOF
15711 rm -f conftest.$ac_objext conftest$ac_exeext
15712 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15713   (eval $ac_link) 2>conftest.er1
15714   ac_status=$?
15715   grep -v '^ *+' conftest.er1 >conftest.err
15716   rm -f conftest.er1
15717   cat conftest.err >&5
15718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15719   (exit $ac_status); } &&
15720          { ac_try='test -z "$ac_c_werror_flag"
15721                          || test ! -s conftest.err'
15722   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15723   (eval $ac_try) 2>&5
15724   ac_status=$?
15725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15726   (exit $ac_status); }; } &&
15727          { ac_try='test -s conftest$ac_exeext'
15728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15729   (eval $ac_try) 2>&5
15730   ac_status=$?
15731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15732   (exit $ac_status); }; }; then
15733   ac_cv_func_fseeko=yes
15734 else
15735   echo "$as_me: failed program was:" >&5
15736 sed 's/^/| /' conftest.$ac_ext >&5
15737
15738 ac_cv_func_fseeko=no
15739 fi
15740 rm -f conftest.err conftest.$ac_objext \
15741       conftest$ac_exeext conftest.$ac_ext
15742 fi
15743 echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
15744 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
15745 if test $ac_cv_func_fseeko = yes; then
15746
15747 cat >>confdefs.h <<\_ACEOF
15748 #define HAVE_FSEEKO 1
15749 _ACEOF
15750
15751 fi
15752
15753
15754 #
15755 # Pthreads
15756 #
15757 # For each platform, we need to know about any special compile and link
15758 # libraries, and whether the normal C function names are thread-safe.
15759 # See the comment at the top of src/port/thread.c for more information.
15760 #
15761 if test "$enable_thread_safety" = yes; then
15762
15763
15764
15765
15766 ac_ext=c
15767 ac_cpp='$CPP $CPPFLAGS'
15768 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
15769 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
15770 ac_compiler_gnu=$ac_cv_c_compiler_gnu
15771
15772 acx_pthread_ok=no
15773
15774 # We used to check for pthread.h first, but this fails if pthread.h
15775 # requires special compiler flags (e.g. on True64 or Sequent).
15776 # It gets checked for in the link test anyway.
15777
15778 # First of all, check if the user has set any of the PTHREAD_LIBS,
15779 # etcetera environment variables, and if threads linking works using
15780 # them:
15781 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
15782         save_CFLAGS="$CFLAGS"
15783         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
15784         save_LIBS="$LIBS"
15785         LIBS="$PTHREAD_LIBS $LIBS"
15786         echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
15787 echo $ECHO_N "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... $ECHO_C" >&6
15788         cat >conftest.$ac_ext <<_ACEOF
15789 /* confdefs.h.  */
15790 _ACEOF
15791 cat confdefs.h >>conftest.$ac_ext
15792 cat >>conftest.$ac_ext <<_ACEOF
15793 /* end confdefs.h.  */
15794
15795 /* Override any gcc2 internal prototype to avoid an error.  */
15796 #ifdef __cplusplus
15797 extern "C"
15798 #endif
15799 /* We use char because int might match the return type of a gcc2
15800    builtin and then its argument prototype would still apply.  */
15801 char pthread_join ();
15802 int
15803 main ()
15804 {
15805 pthread_join ();
15806   ;
15807   return 0;
15808 }
15809 _ACEOF
15810 rm -f conftest.$ac_objext conftest$ac_exeext
15811 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15812   (eval $ac_link) 2>conftest.er1
15813   ac_status=$?
15814   grep -v '^ *+' conftest.er1 >conftest.err
15815   rm -f conftest.er1
15816   cat conftest.err >&5
15817   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15818   (exit $ac_status); } &&
15819          { ac_try='test -z "$ac_c_werror_flag"
15820                          || test ! -s conftest.err'
15821   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15822   (eval $ac_try) 2>&5
15823   ac_status=$?
15824   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15825   (exit $ac_status); }; } &&
15826          { ac_try='test -s conftest$ac_exeext'
15827   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15828   (eval $ac_try) 2>&5
15829   ac_status=$?
15830   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15831   (exit $ac_status); }; }; then
15832   acx_pthread_ok=yes
15833 else
15834   echo "$as_me: failed program was:" >&5
15835 sed 's/^/| /' conftest.$ac_ext >&5
15836
15837 fi
15838 rm -f conftest.err conftest.$ac_objext \
15839       conftest$ac_exeext conftest.$ac_ext
15840         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
15841 echo "${ECHO_T}$acx_pthread_ok" >&6
15842         if test x"$acx_pthread_ok" = xno; then
15843                 PTHREAD_LIBS=""
15844                 PTHREAD_CFLAGS=""
15845         fi
15846         LIBS="$save_LIBS"
15847         CFLAGS="$save_CFLAGS"
15848 fi
15849
15850 # We must check for the threads library under a number of different
15851 # names; the ordering is very important because some systems
15852 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
15853 # libraries is broken (non-POSIX).
15854
15855 # Create a list of thread flags to try.  Items starting with a "-" are
15856 # C compiler flags, and other items are library names, except for "none"
15857 # which indicates that we try without any flags at all, and "pthread-config"
15858 # which is a program returning the flags for the Pth emulation library.
15859
15860 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
15861
15862 # The ordering *is* (sometimes) important.  Some notes on the
15863 # individual items follow:
15864
15865 # pthreads: AIX (must check this before -lpthread)
15866 # none: in case threads are in libc; should be tried before -Kthread and
15867 #       other compiler flags to prevent continual compiler warnings
15868 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
15869 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
15870 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
15871 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
15872 # -pthreads: Solaris/gcc
15873 # -mthreads: Mingw32/gcc, Lynx/gcc
15874 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
15875 #      doesn't hurt to check since this sometimes defines pthreads too;
15876 #      also defines -D_REENTRANT)
15877 # pthread: Linux, etcetera
15878 # --thread-safe: KAI C++
15879 # pthread-config: use pthread-config program (for GNU Pth library)
15880
15881 case "${host_cpu}-${host_os}" in
15882         *solaris*)
15883
15884         # On Solaris (at least, for some versions), libc contains stubbed
15885         # (non-functional) versions of the pthreads routines, so link-based
15886         # tests will erroneously succeed.  (We need to link with -pthread or
15887         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
15888         # a function called by this macro, so we could check for that, but
15889         # who knows whether they'll stub that too in a future libc.)  So,
15890         # we'll just look for -pthreads and -lpthread first:
15891
15892         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
15893         ;;
15894 esac
15895
15896 if test x"$acx_pthread_ok" = xno; then
15897 for flag in $acx_pthread_flags; do
15898
15899         tryPTHREAD_CFLAGS=""
15900         tryPTHREAD_LIBS=""
15901         case $flag in
15902                 none)
15903                 echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
15904 echo $ECHO_N "checking whether pthreads work without any flags... $ECHO_C" >&6
15905                 ;;
15906
15907                 -*)
15908                 echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
15909 echo $ECHO_N "checking whether pthreads work with $flag... $ECHO_C" >&6
15910                 tryPTHREAD_CFLAGS="$flag"
15911                 ;;
15912
15913                 pthread-config)
15914                 # skip this if we already have flags defined, for PostgreSQL
15915                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
15916                 # Extract the first word of "pthread-config", so it can be a program name with args.
15917 set dummy pthread-config; ac_word=$2
15918 echo "$as_me:$LINENO: checking for $ac_word" >&5
15919 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
15920 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
15921   echo $ECHO_N "(cached) $ECHO_C" >&6
15922 else
15923   if test -n "$acx_pthread_config"; then
15924   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
15925 else
15926 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15927 for as_dir in $PATH
15928 do
15929   IFS=$as_save_IFS
15930   test -z "$as_dir" && as_dir=.
15931   for ac_exec_ext in '' $ac_executable_extensions; do
15932   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
15933     ac_cv_prog_acx_pthread_config="yes"
15934     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15935     break 2
15936   fi
15937 done
15938 done
15939
15940   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
15941 fi
15942 fi
15943 acx_pthread_config=$ac_cv_prog_acx_pthread_config
15944 if test -n "$acx_pthread_config"; then
15945   echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
15946 echo "${ECHO_T}$acx_pthread_config" >&6
15947 else
15948   echo "$as_me:$LINENO: result: no" >&5
15949 echo "${ECHO_T}no" >&6
15950 fi
15951
15952                 if test x"$acx_pthread_config" = xno; then continue; fi
15953                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
15954                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
15955                 ;;
15956
15957                 *)
15958                 echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
15959 echo $ECHO_N "checking for the pthreads library -l$flag... $ECHO_C" >&6
15960                 tryPTHREAD_LIBS="-l$flag"
15961                 ;;
15962         esac
15963
15964         save_LIBS="$LIBS"
15965         save_CFLAGS="$CFLAGS"
15966         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
15967         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
15968
15969         # Check for various functions.  We must include pthread.h,
15970         # since some functions may be macros.  (On the Sequent, we
15971         # need a special flag -Kthread to make this header compile.)
15972         # We check for pthread_join because it is in -lpthread on IRIX
15973         # while pthread_create is in libc.  We check for pthread_attr_init
15974         # due to DEC craziness with -lpthreads.  We check for
15975         # pthread_cleanup_push because it is one of the few pthread
15976         # functions on Solaris that doesn't have a non-functional libc stub.
15977         # We try pthread_create on general principles.
15978         cat >conftest.$ac_ext <<_ACEOF
15979 /* confdefs.h.  */
15980 _ACEOF
15981 cat confdefs.h >>conftest.$ac_ext
15982 cat >>conftest.$ac_ext <<_ACEOF
15983 /* end confdefs.h.  */
15984 #include <pthread.h>
15985 int
15986 main ()
15987 {
15988 pthread_t th; pthread_join(th, 0);
15989                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
15990                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
15991   ;
15992   return 0;
15993 }
15994 _ACEOF
15995 rm -f conftest.$ac_objext conftest$ac_exeext
15996 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15997   (eval $ac_link) 2>conftest.er1
15998   ac_status=$?
15999   grep -v '^ *+' conftest.er1 >conftest.err
16000   rm -f conftest.er1
16001   cat conftest.err >&5
16002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16003   (exit $ac_status); } &&
16004          { ac_try='test -z "$ac_c_werror_flag"
16005                          || test ! -s conftest.err'
16006   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16007   (eval $ac_try) 2>&5
16008   ac_status=$?
16009   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16010   (exit $ac_status); }; } &&
16011          { ac_try='test -s conftest$ac_exeext'
16012   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16013   (eval $ac_try) 2>&5
16014   ac_status=$?
16015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16016   (exit $ac_status); }; }; then
16017   acx_pthread_ok=yes
16018 else
16019   echo "$as_me: failed program was:" >&5
16020 sed 's/^/| /' conftest.$ac_ext >&5
16021
16022 acx_pthread_ok=no
16023 fi
16024 rm -f conftest.err conftest.$ac_objext \
16025       conftest$ac_exeext conftest.$ac_ext
16026
16027         if test "x$acx_pthread_ok" = xyes; then
16028             # Don't use options that are ignored by the compiler.
16029             # We find them by checking stderror.
16030             cat >conftest.$ac_ext <<_ACEOF
16031 int
16032 main (int argc, char **argv)
16033 {
16034   (void) argc;
16035   (void) argv;
16036   return 0;
16037 }
16038 _ACEOF
16039             rm -f conftest.$ac_objext conftest$ac_exeext
16040             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
16041                 # we continue with more flags because Linux needs -lpthread
16042                 # for libpq builds on PostgreSQL.  The test above only
16043                 # tests for building binaries, not shared libraries.
16044                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
16045                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
16046             else   acx_pthread_ok=no
16047             fi
16048         fi
16049
16050         LIBS="$save_LIBS"
16051         CFLAGS="$save_CFLAGS"
16052
16053         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
16054 echo "${ECHO_T}$acx_pthread_ok" >&6
16055 done
16056 fi
16057
16058 # Various other checks:
16059 if test "x$acx_pthread_ok" = xyes; then
16060         save_LIBS="$LIBS"
16061         LIBS="$PTHREAD_LIBS $LIBS"
16062         save_CFLAGS="$CFLAGS"
16063         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16064
16065         # Detect AIX lossage: threads are created detached by default
16066         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
16067         echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
16068 echo $ECHO_N "checking for joinable pthread attribute... $ECHO_C" >&6
16069         cat >conftest.$ac_ext <<_ACEOF
16070 /* confdefs.h.  */
16071 _ACEOF
16072 cat confdefs.h >>conftest.$ac_ext
16073 cat >>conftest.$ac_ext <<_ACEOF
16074 /* end confdefs.h.  */
16075 #include <pthread.h>
16076 int
16077 main ()
16078 {
16079 int attr=PTHREAD_CREATE_JOINABLE;
16080   ;
16081   return 0;
16082 }
16083 _ACEOF
16084 rm -f conftest.$ac_objext conftest$ac_exeext
16085 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16086   (eval $ac_link) 2>conftest.er1
16087   ac_status=$?
16088   grep -v '^ *+' conftest.er1 >conftest.err
16089   rm -f conftest.er1
16090   cat conftest.err >&5
16091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16092   (exit $ac_status); } &&
16093          { ac_try='test -z "$ac_c_werror_flag"
16094                          || test ! -s conftest.err'
16095   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16096   (eval $ac_try) 2>&5
16097   ac_status=$?
16098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16099   (exit $ac_status); }; } &&
16100          { ac_try='test -s conftest$ac_exeext'
16101   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16102   (eval $ac_try) 2>&5
16103   ac_status=$?
16104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16105   (exit $ac_status); }; }; then
16106   ok=PTHREAD_CREATE_JOINABLE
16107 else
16108   echo "$as_me: failed program was:" >&5
16109 sed 's/^/| /' conftest.$ac_ext >&5
16110
16111 ok=unknown
16112 fi
16113 rm -f conftest.err conftest.$ac_objext \
16114       conftest$ac_exeext conftest.$ac_ext
16115         if test x"$ok" = xunknown; then
16116                 cat >conftest.$ac_ext <<_ACEOF
16117 /* confdefs.h.  */
16118 _ACEOF
16119 cat confdefs.h >>conftest.$ac_ext
16120 cat >>conftest.$ac_ext <<_ACEOF
16121 /* end confdefs.h.  */
16122 #include <pthread.h>
16123 int
16124 main ()
16125 {
16126 int attr=PTHREAD_CREATE_UNDETACHED;
16127   ;
16128   return 0;
16129 }
16130 _ACEOF
16131 rm -f conftest.$ac_objext conftest$ac_exeext
16132 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16133   (eval $ac_link) 2>conftest.er1
16134   ac_status=$?
16135   grep -v '^ *+' conftest.er1 >conftest.err
16136   rm -f conftest.er1
16137   cat conftest.err >&5
16138   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16139   (exit $ac_status); } &&
16140          { ac_try='test -z "$ac_c_werror_flag"
16141                          || test ! -s conftest.err'
16142   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16143   (eval $ac_try) 2>&5
16144   ac_status=$?
16145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16146   (exit $ac_status); }; } &&
16147          { ac_try='test -s conftest$ac_exeext'
16148   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16149   (eval $ac_try) 2>&5
16150   ac_status=$?
16151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16152   (exit $ac_status); }; }; then
16153   ok=PTHREAD_CREATE_UNDETACHED
16154 else
16155   echo "$as_me: failed program was:" >&5
16156 sed 's/^/| /' conftest.$ac_ext >&5
16157
16158 ok=unknown
16159 fi
16160 rm -f conftest.err conftest.$ac_objext \
16161       conftest$ac_exeext conftest.$ac_ext
16162         fi
16163         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
16164
16165 cat >>confdefs.h <<\_ACEOF
16166 #define PTHREAD_CREATE_JOINABLE $ok
16167 _ACEOF
16168
16169         fi
16170         echo "$as_me:$LINENO: result: ${ok}" >&5
16171 echo "${ECHO_T}${ok}" >&6
16172         if test x"$ok" = xunknown; then
16173                 { echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
16174 echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
16175         fi
16176
16177         echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
16178 echo $ECHO_N "checking if more special flags are required for pthreads... $ECHO_C" >&6
16179         flag=no
16180 # We always add these in PostgreSQL
16181 #       case "${host_cpu}-${host_os}" in
16182 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
16183 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
16184 #       esac
16185         echo "$as_me:$LINENO: result: ${flag}" >&5
16186 echo "${ECHO_T}${flag}" >&6
16187         if test "x$flag" != xno; then
16188                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
16189         fi
16190
16191         LIBS="$save_LIBS"
16192         CFLAGS="$save_CFLAGS"
16193
16194 # Supporting cc_r would require a special CC in all places that
16195 # use libpq, and that is ugly, so we don't do it.  Users can still
16196 # define their compiler as cc_r to do thread builds of everything.
16197         # More AIX lossage: must compile with cc_r
16198         # Extract the first word of "cc_r", so it can be a program name with args.
16199 set dummy cc_r; ac_word=$2
16200 echo "$as_me:$LINENO: checking for $ac_word" >&5
16201 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16202 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
16203   echo $ECHO_N "(cached) $ECHO_C" >&6
16204 else
16205   if test -n "$PTHREAD_CC"; then
16206   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
16207 else
16208 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16209 for as_dir in $PATH
16210 do
16211   IFS=$as_save_IFS
16212   test -z "$as_dir" && as_dir=.
16213   for ac_exec_ext in '' $ac_executable_extensions; do
16214   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16215     ac_cv_prog_PTHREAD_CC="cc_r"
16216     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16217     break 2
16218   fi
16219 done
16220 done
16221
16222   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
16223 fi
16224 fi
16225 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
16226 if test -n "$PTHREAD_CC"; then
16227   echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
16228 echo "${ECHO_T}$PTHREAD_CC" >&6
16229 else
16230   echo "$as_me:$LINENO: result: no" >&5
16231 echo "${ECHO_T}no" >&6
16232 fi
16233
16234 else
16235         PTHREAD_CC="$CC"
16236 fi
16237
16238
16239
16240
16241
16242 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
16243 if test x"$acx_pthread_ok" = xyes; then
16244
16245 cat >>confdefs.h <<\_ACEOF
16246 #define HAVE_PTHREAD 1
16247 _ACEOF
16248
16249         :
16250 else
16251         acx_pthread_ok=no
16252
16253 fi
16254 ac_ext=c
16255 ac_cpp='$CPP $CPPFLAGS'
16256 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16257 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16258 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16259
16260         # set thread flags
16261
16262 # Some platforms use these, so just defineed them.  They can't hurt if they
16263 # are not supported.
16264 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
16265
16266
16267 # At this point, we don't want to muck with the compiler name for threading.
16268 # Let's see who fails, perhaps AIX.  2004-04-23
16269 if test "$PTHREAD_CC" != "$CC"; then
16270 { { echo "$as_me:$LINENO: error:
16271 PostgreSQL does not support platforms that require a special
16272 compiler binary for thread-safety.
16273 " >&5
16274 echo "$as_me: error:
16275 PostgreSQL does not support platforms that require a special
16276 compiler binary for thread-safety.
16277 " >&2;}
16278    { (exit 1); exit 1; }; }
16279 fi
16280
16281 if test "$THREAD_SUPPORT" = no; then
16282 { { echo "$as_me:$LINENO: error:
16283 Cannot enable threads on your platform.
16284 Your platform is known to not support thread-safe programs.
16285 For details, compile and run src/bin/pg_thread_test.
16286 " >&5
16287 echo "$as_me: 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 " >&2;}
16292    { (exit 1); exit 1; }; }
16293 fi
16294
16295 # Check for *_r functions
16296 _CFLAGS="$CFLAGS"
16297 _LIBS="$LIBS"
16298 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16299 LIBS="$LIBS $PTHREAD_LIBS"
16300
16301 if test "${ac_cv_header_pthread_h+set}" = set; then
16302   echo "$as_me:$LINENO: checking for pthread.h" >&5
16303 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
16304 if test "${ac_cv_header_pthread_h+set}" = set; then
16305   echo $ECHO_N "(cached) $ECHO_C" >&6
16306 fi
16307 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
16308 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
16309 else
16310   # Is the header compilable?
16311 echo "$as_me:$LINENO: checking pthread.h usability" >&5
16312 echo $ECHO_N "checking pthread.h usability... $ECHO_C" >&6
16313 cat >conftest.$ac_ext <<_ACEOF
16314 /* confdefs.h.  */
16315 _ACEOF
16316 cat confdefs.h >>conftest.$ac_ext
16317 cat >>conftest.$ac_ext <<_ACEOF
16318 /* end confdefs.h.  */
16319 $ac_includes_default
16320 #include <pthread.h>
16321 _ACEOF
16322 rm -f conftest.$ac_objext
16323 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16324   (eval $ac_compile) 2>conftest.er1
16325   ac_status=$?
16326   grep -v '^ *+' conftest.er1 >conftest.err
16327   rm -f conftest.er1
16328   cat conftest.err >&5
16329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16330   (exit $ac_status); } &&
16331          { ac_try='test -z "$ac_c_werror_flag"
16332                          || test ! -s conftest.err'
16333   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16334   (eval $ac_try) 2>&5
16335   ac_status=$?
16336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16337   (exit $ac_status); }; } &&
16338          { ac_try='test -s conftest.$ac_objext'
16339   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16340   (eval $ac_try) 2>&5
16341   ac_status=$?
16342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16343   (exit $ac_status); }; }; then
16344   ac_header_compiler=yes
16345 else
16346   echo "$as_me: failed program was:" >&5
16347 sed 's/^/| /' conftest.$ac_ext >&5
16348
16349 ac_header_compiler=no
16350 fi
16351 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16352 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16353 echo "${ECHO_T}$ac_header_compiler" >&6
16354
16355 # Is the header present?
16356 echo "$as_me:$LINENO: checking pthread.h presence" >&5
16357 echo $ECHO_N "checking pthread.h presence... $ECHO_C" >&6
16358 cat >conftest.$ac_ext <<_ACEOF
16359 /* confdefs.h.  */
16360 _ACEOF
16361 cat confdefs.h >>conftest.$ac_ext
16362 cat >>conftest.$ac_ext <<_ACEOF
16363 /* end confdefs.h.  */
16364 #include <pthread.h>
16365 _ACEOF
16366 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16367   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16368   ac_status=$?
16369   grep -v '^ *+' conftest.er1 >conftest.err
16370   rm -f conftest.er1
16371   cat conftest.err >&5
16372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16373   (exit $ac_status); } >/dev/null; then
16374   if test -s conftest.err; then
16375     ac_cpp_err=$ac_c_preproc_warn_flag
16376     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16377   else
16378     ac_cpp_err=
16379   fi
16380 else
16381   ac_cpp_err=yes
16382 fi
16383 if test -z "$ac_cpp_err"; then
16384   ac_header_preproc=yes
16385 else
16386   echo "$as_me: failed program was:" >&5
16387 sed 's/^/| /' conftest.$ac_ext >&5
16388
16389   ac_header_preproc=no
16390 fi
16391 rm -f conftest.err conftest.$ac_ext
16392 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16393 echo "${ECHO_T}$ac_header_preproc" >&6
16394
16395 # So?  What about this header?
16396 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16397   yes:no: )
16398     { echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
16399 echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
16400     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
16401 echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
16402     ac_header_preproc=yes
16403     ;;
16404   no:yes:* )
16405     { echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
16406 echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
16407     { echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
16408 echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
16409     { echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
16410 echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
16411     { echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
16412 echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
16413     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
16414 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
16415     { echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
16416 echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
16417     (
16418       cat <<\_ASBOX
16419 ## ---------------------------------------- ##
16420 ## Report this to pgsql-bugs@postgresql.org ##
16421 ## ---------------------------------------- ##
16422 _ASBOX
16423     ) |
16424       sed "s/^/$as_me: WARNING:     /" >&2
16425     ;;
16426 esac
16427 echo "$as_me:$LINENO: checking for pthread.h" >&5
16428 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
16429 if test "${ac_cv_header_pthread_h+set}" = set; then
16430   echo $ECHO_N "(cached) $ECHO_C" >&6
16431 else
16432   ac_cv_header_pthread_h=$ac_header_preproc
16433 fi
16434 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
16435 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
16436
16437 fi
16438 if test $ac_cv_header_pthread_h = yes; then
16439   :
16440 else
16441   { { echo "$as_me:$LINENO: error: pthread.h not found, required for --enable-thread-safety" >&5
16442 echo "$as_me: error: pthread.h not found, required for --enable-thread-safety" >&2;}
16443    { (exit 1); exit 1; }; }
16444 fi
16445
16446
16447
16448
16449
16450
16451 for ac_func in strerror_r getpwuid_r gethostbyname_r
16452 do
16453 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16454 echo "$as_me:$LINENO: checking for $ac_func" >&5
16455 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16456 if eval "test \"\${$as_ac_var+set}\" = set"; then
16457   echo $ECHO_N "(cached) $ECHO_C" >&6
16458 else
16459   cat >conftest.$ac_ext <<_ACEOF
16460 /* confdefs.h.  */
16461 _ACEOF
16462 cat confdefs.h >>conftest.$ac_ext
16463 cat >>conftest.$ac_ext <<_ACEOF
16464 /* end confdefs.h.  */
16465 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16466    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16467 #define $ac_func innocuous_$ac_func
16468
16469 /* System header to define __stub macros and hopefully few prototypes,
16470     which can conflict with char $ac_func (); below.
16471     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16472     <limits.h> exists even on freestanding compilers.  */
16473
16474 #ifdef __STDC__
16475 # include <limits.h>
16476 #else
16477 # include <assert.h>
16478 #endif
16479
16480 #undef $ac_func
16481
16482 /* Override any gcc2 internal prototype to avoid an error.  */
16483 #ifdef __cplusplus
16484 extern "C"
16485 {
16486 #endif
16487 /* We use char because int might match the return type of a gcc2
16488    builtin and then its argument prototype would still apply.  */
16489 char $ac_func ();
16490 /* The GNU C library defines this for functions which it implements
16491     to always fail with ENOSYS.  Some functions are actually named
16492     something starting with __ and the normal name is an alias.  */
16493 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16494 choke me
16495 #else
16496 char (*f) () = $ac_func;
16497 #endif
16498 #ifdef __cplusplus
16499 }
16500 #endif
16501
16502 int
16503 main ()
16504 {
16505 return f != $ac_func;
16506   ;
16507   return 0;
16508 }
16509 _ACEOF
16510 rm -f conftest.$ac_objext conftest$ac_exeext
16511 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16512   (eval $ac_link) 2>conftest.er1
16513   ac_status=$?
16514   grep -v '^ *+' conftest.er1 >conftest.err
16515   rm -f conftest.er1
16516   cat conftest.err >&5
16517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16518   (exit $ac_status); } &&
16519          { ac_try='test -z "$ac_c_werror_flag"
16520                          || test ! -s conftest.err'
16521   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16522   (eval $ac_try) 2>&5
16523   ac_status=$?
16524   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16525   (exit $ac_status); }; } &&
16526          { ac_try='test -s conftest$ac_exeext'
16527   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16528   (eval $ac_try) 2>&5
16529   ac_status=$?
16530   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16531   (exit $ac_status); }; }; then
16532   eval "$as_ac_var=yes"
16533 else
16534   echo "$as_me: failed program was:" >&5
16535 sed 's/^/| /' conftest.$ac_ext >&5
16536
16537 eval "$as_ac_var=no"
16538 fi
16539 rm -f conftest.err conftest.$ac_objext \
16540       conftest$ac_exeext conftest.$ac_ext
16541 fi
16542 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16543 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16544 if test `eval echo '${'$as_ac_var'}'` = yes; then
16545   cat >>confdefs.h <<_ACEOF
16546 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16547 _ACEOF
16548
16549 fi
16550 done
16551
16552
16553 # Do test here with the proper thread flags
16554 echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
16555 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6
16556 if test "${pgac_func_getpwuid_r_5arg+set}" = set; then
16557   echo $ECHO_N "(cached) $ECHO_C" >&6
16558 else
16559   cat >conftest.$ac_ext <<_ACEOF
16560 /* confdefs.h.  */
16561 _ACEOF
16562 cat confdefs.h >>conftest.$ac_ext
16563 cat >>conftest.$ac_ext <<_ACEOF
16564 /* end confdefs.h.  */
16565 #include <sys/types.h>
16566 #include <pwd.h>
16567 int
16568 main ()
16569 {
16570 uid_t uid;
16571 struct passwd *space;
16572 char *buf;
16573 size_t bufsize;
16574 struct passwd **result;
16575 getpwuid_r(uid, space, buf, bufsize, result);
16576   ;
16577   return 0;
16578 }
16579 _ACEOF
16580 rm -f conftest.$ac_objext
16581 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16582   (eval $ac_compile) 2>conftest.er1
16583   ac_status=$?
16584   grep -v '^ *+' conftest.er1 >conftest.err
16585   rm -f conftest.er1
16586   cat conftest.err >&5
16587   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16588   (exit $ac_status); } &&
16589          { ac_try='test -z "$ac_c_werror_flag"
16590                          || test ! -s conftest.err'
16591   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16592   (eval $ac_try) 2>&5
16593   ac_status=$?
16594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16595   (exit $ac_status); }; } &&
16596          { ac_try='test -s conftest.$ac_objext'
16597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16598   (eval $ac_try) 2>&5
16599   ac_status=$?
16600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16601   (exit $ac_status); }; }; then
16602   pgac_func_getpwuid_r_5arg=yes
16603 else
16604   echo "$as_me: failed program was:" >&5
16605 sed 's/^/| /' conftest.$ac_ext >&5
16606
16607 pgac_func_getpwuid_r_5arg=no
16608 fi
16609 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16610 fi
16611 echo "$as_me:$LINENO: result: $pgac_func_getpwuid_r_5arg" >&5
16612 echo "${ECHO_T}$pgac_func_getpwuid_r_5arg" >&6
16613 if test x"$pgac_func_getpwuid_r_5arg" = xyes ; then
16614
16615 cat >>confdefs.h <<\_ACEOF
16616 #define GETPWUID_R_5ARG
16617 _ACEOF
16618
16619 fi
16620
16621 echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
16622 echo $ECHO_N "checking whether strerror_r returns int... $ECHO_C" >&6
16623 if test "${pgac_func_strerror_r_int+set}" = set; then
16624   echo $ECHO_N "(cached) $ECHO_C" >&6
16625 else
16626   cat >conftest.$ac_ext <<_ACEOF
16627 /* confdefs.h.  */
16628 _ACEOF
16629 cat confdefs.h >>conftest.$ac_ext
16630 cat >>conftest.$ac_ext <<_ACEOF
16631 /* end confdefs.h.  */
16632 #include <string.h>
16633 int
16634 main ()
16635 {
16636 #ifndef _AIX
16637 int strerror_r(int, char *, size_t);
16638 #else
16639 /* Older AIX has 'int' for the third argument so we don't test the args. */
16640 int strerror_r();
16641 #endif
16642   ;
16643   return 0;
16644 }
16645 _ACEOF
16646 rm -f conftest.$ac_objext
16647 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16648   (eval $ac_compile) 2>conftest.er1
16649   ac_status=$?
16650   grep -v '^ *+' conftest.er1 >conftest.err
16651   rm -f conftest.er1
16652   cat conftest.err >&5
16653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16654   (exit $ac_status); } &&
16655          { ac_try='test -z "$ac_c_werror_flag"
16656                          || test ! -s conftest.err'
16657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16658   (eval $ac_try) 2>&5
16659   ac_status=$?
16660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16661   (exit $ac_status); }; } &&
16662          { ac_try='test -s conftest.$ac_objext'
16663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16664   (eval $ac_try) 2>&5
16665   ac_status=$?
16666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16667   (exit $ac_status); }; }; then
16668   pgac_func_strerror_r_int=yes
16669 else
16670   echo "$as_me: failed program was:" >&5
16671 sed 's/^/| /' conftest.$ac_ext >&5
16672
16673 pgac_func_strerror_r_int=no
16674 fi
16675 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16676 fi
16677 echo "$as_me:$LINENO: result: $pgac_func_strerror_r_int" >&5
16678 echo "${ECHO_T}$pgac_func_strerror_r_int" >&6
16679 if test x"$pgac_func_strerror_r_int" = xyes ; then
16680
16681 cat >>confdefs.h <<\_ACEOF
16682 #define STRERROR_R_INT
16683 _ACEOF
16684
16685 fi
16686
16687
16688 CFLAGS="$_CFLAGS"
16689 LIBS="$_LIBS"
16690
16691 else
16692 # do not use values from template file
16693 PTHREAD_CFLAGS=
16694 PTHREAD_LIBS=
16695 fi
16696
16697
16698
16699
16700
16701 # This test makes sure that run tests work at all.  Sometimes a shared
16702 # library is found by the linker, but the runtime linker can't find it.
16703 # This check should come after all modifications of compiler or linker
16704 # variables, and before any other run tests.
16705 echo "$as_me:$LINENO: checking test program" >&5
16706 echo $ECHO_N "checking test program... $ECHO_C" >&6
16707 if test "$cross_compiling" = yes; then
16708   echo "$as_me:$LINENO: result: cross-compiling" >&5
16709 echo "${ECHO_T}cross-compiling" >&6
16710 else
16711   cat >conftest.$ac_ext <<_ACEOF
16712 /* confdefs.h.  */
16713 _ACEOF
16714 cat confdefs.h >>conftest.$ac_ext
16715 cat >>conftest.$ac_ext <<_ACEOF
16716 /* end confdefs.h.  */
16717 int main() { return 0; }
16718 _ACEOF
16719 rm -f conftest$ac_exeext
16720 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16721   (eval $ac_link) 2>&5
16722   ac_status=$?
16723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16724   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16725   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16726   (eval $ac_try) 2>&5
16727   ac_status=$?
16728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16729   (exit $ac_status); }; }; then
16730   echo "$as_me:$LINENO: result: ok" >&5
16731 echo "${ECHO_T}ok" >&6
16732 else
16733   echo "$as_me: program exited with status $ac_status" >&5
16734 echo "$as_me: failed program was:" >&5
16735 sed 's/^/| /' conftest.$ac_ext >&5
16736
16737 ( exit $ac_status )
16738 echo "$as_me:$LINENO: result: failed" >&5
16739 echo "${ECHO_T}failed" >&6
16740 { { echo "$as_me:$LINENO: error:
16741 *** Could not execute a simple test program.  This may be a problem
16742 *** related to locating shared libraries.  Check the file 'config.log'
16743 *** for the exact reason." >&5
16744 echo "$as_me: error:
16745 *** Could not execute a simple test program.  This may be a problem
16746 *** related to locating shared libraries.  Check the file 'config.log'
16747 *** for the exact reason." >&2;}
16748    { (exit 1); exit 1; }; }
16749 fi
16750 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16751 fi
16752
16753 # --------------------
16754 # Run tests below here
16755 # --------------------
16756
16757 # Force use of our snprintf if system's doesn't do arg control
16758 # See comment above at snprintf test for details.
16759 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
16760   echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
16761 echo $ECHO_N "checking whether printf supports argument control... $ECHO_C" >&6
16762 if test "${pgac_cv_printf_arg_control+set}" = set; then
16763   echo $ECHO_N "(cached) $ECHO_C" >&6
16764 else
16765   if test "$cross_compiling" = yes; then
16766   pgac_cv_printf_arg_control=cross
16767 else
16768   cat >conftest.$ac_ext <<_ACEOF
16769 /* confdefs.h.  */
16770 _ACEOF
16771 cat confdefs.h >>conftest.$ac_ext
16772 cat >>conftest.$ac_ext <<_ACEOF
16773 /* end confdefs.h.  */
16774 #include <stdio.h>
16775 #include <string.h>
16776
16777 int main()
16778 {
16779   char buf[100];
16780
16781   /* can it swap arguments? */
16782   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
16783   if (strcmp(buf, "4 3") != 0)
16784     return 1;
16785   return 0;
16786 }
16787 _ACEOF
16788 rm -f conftest$ac_exeext
16789 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16790   (eval $ac_link) 2>&5
16791   ac_status=$?
16792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16793   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16794   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16795   (eval $ac_try) 2>&5
16796   ac_status=$?
16797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16798   (exit $ac_status); }; }; then
16799   pgac_cv_printf_arg_control=yes
16800 else
16801   echo "$as_me: program exited with status $ac_status" >&5
16802 echo "$as_me: failed program was:" >&5
16803 sed 's/^/| /' conftest.$ac_ext >&5
16804
16805 ( exit $ac_status )
16806 pgac_cv_printf_arg_control=no
16807 fi
16808 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16809 fi
16810
16811 fi
16812 echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
16813 echo "${ECHO_T}$pgac_cv_printf_arg_control" >&6
16814
16815   if test $pgac_cv_printf_arg_control != yes ; then
16816     pgac_need_repl_snprintf=yes
16817   fi
16818 fi
16819
16820
16821
16822 echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
16823 echo $ECHO_N "checking whether long int is 64 bits... $ECHO_C" >&6
16824 if test "${pgac_cv_type_long_int_64+set}" = set; then
16825   echo $ECHO_N "(cached) $ECHO_C" >&6
16826 else
16827   if test "$cross_compiling" = yes; then
16828   # If cross-compiling, check the size reported by the compiler and
16829 # trust that the arithmetic works.
16830 cat >conftest.$ac_ext <<_ACEOF
16831 /* confdefs.h.  */
16832 _ACEOF
16833 cat confdefs.h >>conftest.$ac_ext
16834 cat >>conftest.$ac_ext <<_ACEOF
16835 /* end confdefs.h.  */
16836
16837 int
16838 main ()
16839 {
16840 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
16841 test_array [0] = 0
16842
16843   ;
16844   return 0;
16845 }
16846 _ACEOF
16847 rm -f conftest.$ac_objext
16848 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16849   (eval $ac_compile) 2>conftest.er1
16850   ac_status=$?
16851   grep -v '^ *+' conftest.er1 >conftest.err
16852   rm -f conftest.er1
16853   cat conftest.err >&5
16854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16855   (exit $ac_status); } &&
16856          { ac_try='test -z "$ac_c_werror_flag"
16857                          || test ! -s conftest.err'
16858   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16859   (eval $ac_try) 2>&5
16860   ac_status=$?
16861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16862   (exit $ac_status); }; } &&
16863          { ac_try='test -s conftest.$ac_objext'
16864   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16865   (eval $ac_try) 2>&5
16866   ac_status=$?
16867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16868   (exit $ac_status); }; }; then
16869   pgac_cv_type_long_int_64=yes
16870 else
16871   echo "$as_me: failed program was:" >&5
16872 sed 's/^/| /' conftest.$ac_ext >&5
16873
16874 pgac_cv_type_long_int_64=no
16875 fi
16876 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16877 else
16878   cat >conftest.$ac_ext <<_ACEOF
16879 /* confdefs.h.  */
16880 _ACEOF
16881 cat confdefs.h >>conftest.$ac_ext
16882 cat >>conftest.$ac_ext <<_ACEOF
16883 /* end confdefs.h.  */
16884 typedef long int ac_int64;
16885
16886 /*
16887  * These are globals to discourage the compiler from folding all the
16888  * arithmetic tests down to compile-time constants.
16889  */
16890 ac_int64 a = 20000001;
16891 ac_int64 b = 40000005;
16892
16893 int does_int64_work()
16894 {
16895   ac_int64 c,d;
16896
16897   if (sizeof(ac_int64) != 8)
16898     return 0;                   /* definitely not the right size */
16899
16900   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
16901   c = a * b;
16902   d = (c + b) / b;
16903   if (d != a+1)
16904     return 0;
16905   return 1;
16906 }
16907 main() {
16908   exit(! does_int64_work());
16909 }
16910 _ACEOF
16911 rm -f conftest$ac_exeext
16912 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16913   (eval $ac_link) 2>&5
16914   ac_status=$?
16915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16916   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16917   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16918   (eval $ac_try) 2>&5
16919   ac_status=$?
16920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16921   (exit $ac_status); }; }; then
16922   pgac_cv_type_long_int_64=yes
16923 else
16924   echo "$as_me: program exited with status $ac_status" >&5
16925 echo "$as_me: failed program was:" >&5
16926 sed 's/^/| /' conftest.$ac_ext >&5
16927
16928 ( exit $ac_status )
16929 pgac_cv_type_long_int_64=no
16930 fi
16931 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16932 fi
16933 fi
16934 echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
16935 echo "${ECHO_T}$pgac_cv_type_long_int_64" >&6
16936
16937 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
16938 if test x"$pgac_cv_type_long_int_64" = xyes ; then
16939
16940 cat >>confdefs.h <<\_ACEOF
16941 #define HAVE_LONG_INT_64
16942 _ACEOF
16943
16944 fi
16945
16946
16947 if test x"$HAVE_LONG_INT_64" = x"no" ; then
16948   echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
16949 echo $ECHO_N "checking whether long long int is 64 bits... $ECHO_C" >&6
16950 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
16951   echo $ECHO_N "(cached) $ECHO_C" >&6
16952 else
16953   if test "$cross_compiling" = yes; then
16954   # If cross-compiling, check the size reported by the compiler and
16955 # trust that the arithmetic works.
16956 cat >conftest.$ac_ext <<_ACEOF
16957 /* confdefs.h.  */
16958 _ACEOF
16959 cat confdefs.h >>conftest.$ac_ext
16960 cat >>conftest.$ac_ext <<_ACEOF
16961 /* end confdefs.h.  */
16962
16963 int
16964 main ()
16965 {
16966 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
16967 test_array [0] = 0
16968
16969   ;
16970   return 0;
16971 }
16972 _ACEOF
16973 rm -f conftest.$ac_objext
16974 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16975   (eval $ac_compile) 2>conftest.er1
16976   ac_status=$?
16977   grep -v '^ *+' conftest.er1 >conftest.err
16978   rm -f conftest.er1
16979   cat conftest.err >&5
16980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16981   (exit $ac_status); } &&
16982          { ac_try='test -z "$ac_c_werror_flag"
16983                          || test ! -s conftest.err'
16984   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16985   (eval $ac_try) 2>&5
16986   ac_status=$?
16987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16988   (exit $ac_status); }; } &&
16989          { ac_try='test -s conftest.$ac_objext'
16990   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16991   (eval $ac_try) 2>&5
16992   ac_status=$?
16993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16994   (exit $ac_status); }; }; then
16995   pgac_cv_type_long_long_int_64=yes
16996 else
16997   echo "$as_me: failed program was:" >&5
16998 sed 's/^/| /' conftest.$ac_ext >&5
16999
17000 pgac_cv_type_long_long_int_64=no
17001 fi
17002 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17003 else
17004   cat >conftest.$ac_ext <<_ACEOF
17005 /* confdefs.h.  */
17006 _ACEOF
17007 cat confdefs.h >>conftest.$ac_ext
17008 cat >>conftest.$ac_ext <<_ACEOF
17009 /* end confdefs.h.  */
17010 typedef long long int ac_int64;
17011
17012 /*
17013  * These are globals to discourage the compiler from folding all the
17014  * arithmetic tests down to compile-time constants.
17015  */
17016 ac_int64 a = 20000001;
17017 ac_int64 b = 40000005;
17018
17019 int does_int64_work()
17020 {
17021   ac_int64 c,d;
17022
17023   if (sizeof(ac_int64) != 8)
17024     return 0;                   /* definitely not the right size */
17025
17026   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
17027   c = a * b;
17028   d = (c + b) / b;
17029   if (d != a+1)
17030     return 0;
17031   return 1;
17032 }
17033 main() {
17034   exit(! does_int64_work());
17035 }
17036 _ACEOF
17037 rm -f conftest$ac_exeext
17038 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17039   (eval $ac_link) 2>&5
17040   ac_status=$?
17041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17042   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17043   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17044   (eval $ac_try) 2>&5
17045   ac_status=$?
17046   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17047   (exit $ac_status); }; }; then
17048   pgac_cv_type_long_long_int_64=yes
17049 else
17050   echo "$as_me: program exited with status $ac_status" >&5
17051 echo "$as_me: failed program was:" >&5
17052 sed 's/^/| /' conftest.$ac_ext >&5
17053
17054 ( exit $ac_status )
17055 pgac_cv_type_long_long_int_64=no
17056 fi
17057 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17058 fi
17059 fi
17060 echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
17061 echo "${ECHO_T}$pgac_cv_type_long_long_int_64" >&6
17062
17063 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
17064 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
17065
17066 cat >>confdefs.h <<\_ACEOF
17067 #define HAVE_LONG_LONG_INT_64
17068 _ACEOF
17069
17070 fi
17071
17072 fi
17073
17074
17075
17076 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
17077   cat >conftest.$ac_ext <<_ACEOF
17078 /* confdefs.h.  */
17079 _ACEOF
17080 cat confdefs.h >>conftest.$ac_ext
17081 cat >>conftest.$ac_ext <<_ACEOF
17082 /* end confdefs.h.  */
17083
17084 #define INT64CONST(x)  x##LL
17085 long long int foo = INT64CONST(0x1234567890123456);
17086
17087 int
17088 main ()
17089 {
17090
17091   ;
17092   return 0;
17093 }
17094 _ACEOF
17095 rm -f conftest.$ac_objext
17096 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17097   (eval $ac_compile) 2>conftest.er1
17098   ac_status=$?
17099   grep -v '^ *+' conftest.er1 >conftest.err
17100   rm -f conftest.er1
17101   cat conftest.err >&5
17102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17103   (exit $ac_status); } &&
17104          { ac_try='test -z "$ac_c_werror_flag"
17105                          || test ! -s conftest.err'
17106   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17107   (eval $ac_try) 2>&5
17108   ac_status=$?
17109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17110   (exit $ac_status); }; } &&
17111          { ac_try='test -s conftest.$ac_objext'
17112   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17113   (eval $ac_try) 2>&5
17114   ac_status=$?
17115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17116   (exit $ac_status); }; }; then
17117
17118 cat >>confdefs.h <<\_ACEOF
17119 #define HAVE_LL_CONSTANTS 1
17120 _ACEOF
17121
17122 else
17123   echo "$as_me: failed program was:" >&5
17124 sed 's/^/| /' conftest.$ac_ext >&5
17125
17126 fi
17127 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17128 fi
17129
17130
17131 # If we found "long int" is 64 bits, assume snprintf handles it.  If
17132 # we found we need to use "long long int", better check.  We cope with
17133 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
17134 # work, fall back to our own snprintf emulation (which we know uses %lld).
17135
17136 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
17137   if test $pgac_need_repl_snprintf = no; then
17138     echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
17139 echo $ECHO_N "checking snprintf format for long long int... $ECHO_C" >&6
17140 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
17141   echo $ECHO_N "(cached) $ECHO_C" >&6
17142 else
17143   for pgac_format in '%lld' '%qd' '%I64d'; do
17144 if test "$cross_compiling" = yes; then
17145   pgac_cv_snprintf_long_long_int_format=cross; break
17146 else
17147   cat >conftest.$ac_ext <<_ACEOF
17148 /* confdefs.h.  */
17149 _ACEOF
17150 cat confdefs.h >>conftest.$ac_ext
17151 cat >>conftest.$ac_ext <<_ACEOF
17152 /* end confdefs.h.  */
17153 #include <stdio.h>
17154 typedef long long int ac_int64;
17155 #define INT64_FORMAT "$pgac_format"
17156
17157 ac_int64 a = 20000001;
17158 ac_int64 b = 40000005;
17159
17160 int does_int64_snprintf_work()
17161 {
17162   ac_int64 c;
17163   char buf[100];
17164
17165   if (sizeof(ac_int64) != 8)
17166     return 0;                   /* doesn't look like the right size */
17167
17168   c = a * b;
17169   snprintf(buf, 100, INT64_FORMAT, c);
17170   if (strcmp(buf, "800000140000005") != 0)
17171     return 0;                   /* either multiply or snprintf is busted */
17172   return 1;
17173 }
17174 main() {
17175   exit(! does_int64_snprintf_work());
17176 }
17177 _ACEOF
17178 rm -f conftest$ac_exeext
17179 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17180   (eval $ac_link) 2>&5
17181   ac_status=$?
17182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17183   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17184   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17185   (eval $ac_try) 2>&5
17186   ac_status=$?
17187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17188   (exit $ac_status); }; }; then
17189   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
17190 else
17191   echo "$as_me: program exited with status $ac_status" >&5
17192 echo "$as_me: failed program was:" >&5
17193 sed 's/^/| /' conftest.$ac_ext >&5
17194
17195 fi
17196 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17197 fi
17198 done
17199 fi
17200
17201 LONG_LONG_INT_FORMAT=''
17202
17203 case $pgac_cv_snprintf_long_long_int_format in
17204   cross) echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
17205 echo "${ECHO_T}cannot test (not on host machine)" >&6;;
17206   ?*)    echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
17207 echo "${ECHO_T}$pgac_cv_snprintf_long_long_int_format" >&6
17208          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
17209   *)     echo "$as_me:$LINENO: result: none" >&5
17210 echo "${ECHO_T}none" >&6;;
17211 esac
17212     if test "$LONG_LONG_INT_FORMAT" = ""; then
17213       # Force usage of our own snprintf, since system snprintf is broken
17214       pgac_need_repl_snprintf=yes
17215       LONG_LONG_INT_FORMAT='%lld'
17216     fi
17217   else
17218     # Here if we previously decided we needed to use our own snprintf
17219     LONG_LONG_INT_FORMAT='%lld'
17220   fi
17221   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
17222   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
17223   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
17224 else
17225   # Here if we are not using 'long long int' at all
17226   INT64_FORMAT='"%ld"'
17227   UINT64_FORMAT='"%lu"'
17228 fi
17229
17230
17231 cat >>confdefs.h <<_ACEOF
17232 #define INT64_FORMAT $INT64_FORMAT
17233 _ACEOF
17234
17235
17236
17237 cat >>confdefs.h <<_ACEOF
17238 #define UINT64_FORMAT $UINT64_FORMAT
17239 _ACEOF
17240
17241
17242 # Now we have checked all the reasons to replace snprintf
17243 if test $pgac_need_repl_snprintf = yes; then
17244
17245 cat >>confdefs.h <<\_ACEOF
17246 #define USE_REPL_SNPRINTF 1
17247 _ACEOF
17248
17249   case $LIBOBJS in
17250     "snprintf.$ac_objext"   | \
17251   *" snprintf.$ac_objext"   | \
17252     "snprintf.$ac_objext "* | \
17253   *" snprintf.$ac_objext "* ) ;;
17254   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" ;;
17255 esac
17256
17257 fi
17258
17259 # Need a #define for the size of Datum (unsigned long)
17260 echo "$as_me:$LINENO: checking for unsigned long" >&5
17261 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6
17262 if test "${ac_cv_type_unsigned_long+set}" = set; then
17263   echo $ECHO_N "(cached) $ECHO_C" >&6
17264 else
17265   cat >conftest.$ac_ext <<_ACEOF
17266 /* confdefs.h.  */
17267 _ACEOF
17268 cat confdefs.h >>conftest.$ac_ext
17269 cat >>conftest.$ac_ext <<_ACEOF
17270 /* end confdefs.h.  */
17271 $ac_includes_default
17272 int
17273 main ()
17274 {
17275 if ((unsigned long *) 0)
17276   return 0;
17277 if (sizeof (unsigned long))
17278   return 0;
17279   ;
17280   return 0;
17281 }
17282 _ACEOF
17283 rm -f conftest.$ac_objext
17284 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17285   (eval $ac_compile) 2>conftest.er1
17286   ac_status=$?
17287   grep -v '^ *+' conftest.er1 >conftest.err
17288   rm -f conftest.er1
17289   cat conftest.err >&5
17290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17291   (exit $ac_status); } &&
17292          { ac_try='test -z "$ac_c_werror_flag"
17293                          || test ! -s conftest.err'
17294   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17295   (eval $ac_try) 2>&5
17296   ac_status=$?
17297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17298   (exit $ac_status); }; } &&
17299          { ac_try='test -s conftest.$ac_objext'
17300   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17301   (eval $ac_try) 2>&5
17302   ac_status=$?
17303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17304   (exit $ac_status); }; }; then
17305   ac_cv_type_unsigned_long=yes
17306 else
17307   echo "$as_me: failed program was:" >&5
17308 sed 's/^/| /' conftest.$ac_ext >&5
17309
17310 ac_cv_type_unsigned_long=no
17311 fi
17312 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17313 fi
17314 echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
17315 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6
17316
17317 echo "$as_me:$LINENO: checking size of unsigned long" >&5
17318 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6
17319 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
17320   echo $ECHO_N "(cached) $ECHO_C" >&6
17321 else
17322   if test "$ac_cv_type_unsigned_long" = yes; then
17323   # The cast to unsigned long works around a bug in the HP C Compiler
17324   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17325   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
17326   # This bug is HP SR number 8606223364.
17327   if test "$cross_compiling" = yes; then
17328   # Depending upon the size, compute the lo and hi bounds.
17329 cat >conftest.$ac_ext <<_ACEOF
17330 /* confdefs.h.  */
17331 _ACEOF
17332 cat confdefs.h >>conftest.$ac_ext
17333 cat >>conftest.$ac_ext <<_ACEOF
17334 /* end confdefs.h.  */
17335 $ac_includes_default
17336 int
17337 main ()
17338 {
17339 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= 0)];
17340 test_array [0] = 0
17341
17342   ;
17343   return 0;
17344 }
17345 _ACEOF
17346 rm -f conftest.$ac_objext
17347 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17348   (eval $ac_compile) 2>conftest.er1
17349   ac_status=$?
17350   grep -v '^ *+' conftest.er1 >conftest.err
17351   rm -f conftest.er1
17352   cat conftest.err >&5
17353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17354   (exit $ac_status); } &&
17355          { ac_try='test -z "$ac_c_werror_flag"
17356                          || test ! -s conftest.err'
17357   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17358   (eval $ac_try) 2>&5
17359   ac_status=$?
17360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17361   (exit $ac_status); }; } &&
17362          { ac_try='test -s conftest.$ac_objext'
17363   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17364   (eval $ac_try) 2>&5
17365   ac_status=$?
17366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17367   (exit $ac_status); }; }; then
17368   ac_lo=0 ac_mid=0
17369   while :; do
17370     cat >conftest.$ac_ext <<_ACEOF
17371 /* confdefs.h.  */
17372 _ACEOF
17373 cat confdefs.h >>conftest.$ac_ext
17374 cat >>conftest.$ac_ext <<_ACEOF
17375 /* end confdefs.h.  */
17376 $ac_includes_default
17377 int
17378 main ()
17379 {
17380 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
17381 test_array [0] = 0
17382
17383   ;
17384   return 0;
17385 }
17386 _ACEOF
17387 rm -f conftest.$ac_objext
17388 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17389   (eval $ac_compile) 2>conftest.er1
17390   ac_status=$?
17391   grep -v '^ *+' conftest.er1 >conftest.err
17392   rm -f conftest.er1
17393   cat conftest.err >&5
17394   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17395   (exit $ac_status); } &&
17396          { ac_try='test -z "$ac_c_werror_flag"
17397                          || test ! -s conftest.err'
17398   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17399   (eval $ac_try) 2>&5
17400   ac_status=$?
17401   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17402   (exit $ac_status); }; } &&
17403          { ac_try='test -s conftest.$ac_objext'
17404   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17405   (eval $ac_try) 2>&5
17406   ac_status=$?
17407   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17408   (exit $ac_status); }; }; then
17409   ac_hi=$ac_mid; break
17410 else
17411   echo "$as_me: failed program was:" >&5
17412 sed 's/^/| /' conftest.$ac_ext >&5
17413
17414 ac_lo=`expr $ac_mid + 1`
17415                     if test $ac_lo -le $ac_mid; then
17416                       ac_lo= ac_hi=
17417                       break
17418                     fi
17419                     ac_mid=`expr 2 '*' $ac_mid + 1`
17420 fi
17421 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17422   done
17423 else
17424   echo "$as_me: failed program was:" >&5
17425 sed 's/^/| /' conftest.$ac_ext >&5
17426
17427 cat >conftest.$ac_ext <<_ACEOF
17428 /* confdefs.h.  */
17429 _ACEOF
17430 cat confdefs.h >>conftest.$ac_ext
17431 cat >>conftest.$ac_ext <<_ACEOF
17432 /* end confdefs.h.  */
17433 $ac_includes_default
17434 int
17435 main ()
17436 {
17437 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) < 0)];
17438 test_array [0] = 0
17439
17440   ;
17441   return 0;
17442 }
17443 _ACEOF
17444 rm -f conftest.$ac_objext
17445 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17446   (eval $ac_compile) 2>conftest.er1
17447   ac_status=$?
17448   grep -v '^ *+' conftest.er1 >conftest.err
17449   rm -f conftest.er1
17450   cat conftest.err >&5
17451   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17452   (exit $ac_status); } &&
17453          { ac_try='test -z "$ac_c_werror_flag"
17454                          || test ! -s conftest.err'
17455   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17456   (eval $ac_try) 2>&5
17457   ac_status=$?
17458   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17459   (exit $ac_status); }; } &&
17460          { ac_try='test -s conftest.$ac_objext'
17461   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17462   (eval $ac_try) 2>&5
17463   ac_status=$?
17464   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17465   (exit $ac_status); }; }; then
17466   ac_hi=-1 ac_mid=-1
17467   while :; do
17468     cat >conftest.$ac_ext <<_ACEOF
17469 /* confdefs.h.  */
17470 _ACEOF
17471 cat confdefs.h >>conftest.$ac_ext
17472 cat >>conftest.$ac_ext <<_ACEOF
17473 /* end confdefs.h.  */
17474 $ac_includes_default
17475 int
17476 main ()
17477 {
17478 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= $ac_mid)];
17479 test_array [0] = 0
17480
17481   ;
17482   return 0;
17483 }
17484 _ACEOF
17485 rm -f conftest.$ac_objext
17486 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17487   (eval $ac_compile) 2>conftest.er1
17488   ac_status=$?
17489   grep -v '^ *+' conftest.er1 >conftest.err
17490   rm -f conftest.er1
17491   cat conftest.err >&5
17492   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17493   (exit $ac_status); } &&
17494          { ac_try='test -z "$ac_c_werror_flag"
17495                          || test ! -s conftest.err'
17496   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17497   (eval $ac_try) 2>&5
17498   ac_status=$?
17499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17500   (exit $ac_status); }; } &&
17501          { ac_try='test -s conftest.$ac_objext'
17502   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17503   (eval $ac_try) 2>&5
17504   ac_status=$?
17505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17506   (exit $ac_status); }; }; then
17507   ac_lo=$ac_mid; break
17508 else
17509   echo "$as_me: failed program was:" >&5
17510 sed 's/^/| /' conftest.$ac_ext >&5
17511
17512 ac_hi=`expr '(' $ac_mid ')' - 1`
17513                        if test $ac_mid -le $ac_hi; then
17514                          ac_lo= ac_hi=
17515                          break
17516                        fi
17517                        ac_mid=`expr 2 '*' $ac_mid`
17518 fi
17519 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17520   done
17521 else
17522   echo "$as_me: failed program was:" >&5
17523 sed 's/^/| /' conftest.$ac_ext >&5
17524
17525 ac_lo= ac_hi=
17526 fi
17527 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17528 fi
17529 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17530 # Binary search between lo and hi bounds.
17531 while test "x$ac_lo" != "x$ac_hi"; do
17532   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
17533   cat >conftest.$ac_ext <<_ACEOF
17534 /* confdefs.h.  */
17535 _ACEOF
17536 cat confdefs.h >>conftest.$ac_ext
17537 cat >>conftest.$ac_ext <<_ACEOF
17538 /* end confdefs.h.  */
17539 $ac_includes_default
17540 int
17541 main ()
17542 {
17543 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
17544 test_array [0] = 0
17545
17546   ;
17547   return 0;
17548 }
17549 _ACEOF
17550 rm -f conftest.$ac_objext
17551 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17552   (eval $ac_compile) 2>conftest.er1
17553   ac_status=$?
17554   grep -v '^ *+' conftest.er1 >conftest.err
17555   rm -f conftest.er1
17556   cat conftest.err >&5
17557   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17558   (exit $ac_status); } &&
17559          { ac_try='test -z "$ac_c_werror_flag"
17560                          || test ! -s conftest.err'
17561   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17562   (eval $ac_try) 2>&5
17563   ac_status=$?
17564   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17565   (exit $ac_status); }; } &&
17566          { ac_try='test -s conftest.$ac_objext'
17567   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17568   (eval $ac_try) 2>&5
17569   ac_status=$?
17570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17571   (exit $ac_status); }; }; then
17572   ac_hi=$ac_mid
17573 else
17574   echo "$as_me: failed program was:" >&5
17575 sed 's/^/| /' conftest.$ac_ext >&5
17576
17577 ac_lo=`expr '(' $ac_mid ')' + 1`
17578 fi
17579 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17580 done
17581 case $ac_lo in
17582 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
17583 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77
17584 See \`config.log' for more details." >&5
17585 echo "$as_me: error: cannot compute sizeof (unsigned long), 77
17586 See \`config.log' for more details." >&2;}
17587    { (exit 1); exit 1; }; } ;;
17588 esac
17589 else
17590   if test "$cross_compiling" = yes; then
17591   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
17592 See \`config.log' for more details." >&5
17593 echo "$as_me: error: cannot run test program while cross compiling
17594 See \`config.log' for more details." >&2;}
17595    { (exit 1); exit 1; }; }
17596 else
17597   cat >conftest.$ac_ext <<_ACEOF
17598 /* confdefs.h.  */
17599 _ACEOF
17600 cat confdefs.h >>conftest.$ac_ext
17601 cat >>conftest.$ac_ext <<_ACEOF
17602 /* end confdefs.h.  */
17603 $ac_includes_default
17604 long longval () { return (long) (sizeof (unsigned long)); }
17605 unsigned long ulongval () { return (long) (sizeof (unsigned long)); }
17606 #include <stdio.h>
17607 #include <stdlib.h>
17608 int
17609 main ()
17610 {
17611
17612   FILE *f = fopen ("conftest.val", "w");
17613   if (! f)
17614     exit (1);
17615   if (((long) (sizeof (unsigned long))) < 0)
17616     {
17617       long i = longval ();
17618       if (i != ((long) (sizeof (unsigned long))))
17619         exit (1);
17620       fprintf (f, "%ld\n", i);
17621     }
17622   else
17623     {
17624       unsigned long i = ulongval ();
17625       if (i != ((long) (sizeof (unsigned long))))
17626         exit (1);
17627       fprintf (f, "%lu\n", i);
17628     }
17629   exit (ferror (f) || fclose (f) != 0);
17630
17631   ;
17632   return 0;
17633 }
17634 _ACEOF
17635 rm -f conftest$ac_exeext
17636 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17637   (eval $ac_link) 2>&5
17638   ac_status=$?
17639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17640   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17641   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17642   (eval $ac_try) 2>&5
17643   ac_status=$?
17644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17645   (exit $ac_status); }; }; then
17646   ac_cv_sizeof_unsigned_long=`cat conftest.val`
17647 else
17648   echo "$as_me: program exited with status $ac_status" >&5
17649 echo "$as_me: failed program was:" >&5
17650 sed 's/^/| /' conftest.$ac_ext >&5
17651
17652 ( exit $ac_status )
17653 { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77
17654 See \`config.log' for more details." >&5
17655 echo "$as_me: error: cannot compute sizeof (unsigned long), 77
17656 See \`config.log' for more details." >&2;}
17657    { (exit 1); exit 1; }; }
17658 fi
17659 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17660 fi
17661 fi
17662 rm -f conftest.val
17663 else
17664   ac_cv_sizeof_unsigned_long=0
17665 fi
17666 fi
17667 echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
17668 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6
17669 cat >>confdefs.h <<_ACEOF
17670 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
17671 _ACEOF
17672
17673
17674
17675 # And one for the size of size_t (enables tweaks for > 32bit address space)
17676 echo "$as_me:$LINENO: checking for size_t" >&5
17677 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
17678 if test "${ac_cv_type_size_t+set}" = set; then
17679   echo $ECHO_N "(cached) $ECHO_C" >&6
17680 else
17681   cat >conftest.$ac_ext <<_ACEOF
17682 /* confdefs.h.  */
17683 _ACEOF
17684 cat confdefs.h >>conftest.$ac_ext
17685 cat >>conftest.$ac_ext <<_ACEOF
17686 /* end confdefs.h.  */
17687 $ac_includes_default
17688 int
17689 main ()
17690 {
17691 if ((size_t *) 0)
17692   return 0;
17693 if (sizeof (size_t))
17694   return 0;
17695   ;
17696   return 0;
17697 }
17698 _ACEOF
17699 rm -f conftest.$ac_objext
17700 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17701   (eval $ac_compile) 2>conftest.er1
17702   ac_status=$?
17703   grep -v '^ *+' conftest.er1 >conftest.err
17704   rm -f conftest.er1
17705   cat conftest.err >&5
17706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17707   (exit $ac_status); } &&
17708          { ac_try='test -z "$ac_c_werror_flag"
17709                          || test ! -s conftest.err'
17710   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17711   (eval $ac_try) 2>&5
17712   ac_status=$?
17713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17714   (exit $ac_status); }; } &&
17715          { ac_try='test -s conftest.$ac_objext'
17716   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17717   (eval $ac_try) 2>&5
17718   ac_status=$?
17719   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17720   (exit $ac_status); }; }; then
17721   ac_cv_type_size_t=yes
17722 else
17723   echo "$as_me: failed program was:" >&5
17724 sed 's/^/| /' conftest.$ac_ext >&5
17725
17726 ac_cv_type_size_t=no
17727 fi
17728 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17729 fi
17730 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
17731 echo "${ECHO_T}$ac_cv_type_size_t" >&6
17732
17733 echo "$as_me:$LINENO: checking size of size_t" >&5
17734 echo $ECHO_N "checking size of size_t... $ECHO_C" >&6
17735 if test "${ac_cv_sizeof_size_t+set}" = set; then
17736   echo $ECHO_N "(cached) $ECHO_C" >&6
17737 else
17738   if test "$ac_cv_type_size_t" = yes; then
17739   # The cast to unsigned long works around a bug in the HP C Compiler
17740   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17741   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
17742   # This bug is HP SR number 8606223364.
17743   if test "$cross_compiling" = yes; then
17744   # Depending upon the size, compute the lo and hi bounds.
17745 cat >conftest.$ac_ext <<_ACEOF
17746 /* confdefs.h.  */
17747 _ACEOF
17748 cat confdefs.h >>conftest.$ac_ext
17749 cat >>conftest.$ac_ext <<_ACEOF
17750 /* end confdefs.h.  */
17751 $ac_includes_default
17752 int
17753 main ()
17754 {
17755 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) >= 0)];
17756 test_array [0] = 0
17757
17758   ;
17759   return 0;
17760 }
17761 _ACEOF
17762 rm -f conftest.$ac_objext
17763 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17764   (eval $ac_compile) 2>conftest.er1
17765   ac_status=$?
17766   grep -v '^ *+' conftest.er1 >conftest.err
17767   rm -f conftest.er1
17768   cat conftest.err >&5
17769   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17770   (exit $ac_status); } &&
17771          { ac_try='test -z "$ac_c_werror_flag"
17772                          || test ! -s conftest.err'
17773   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17774   (eval $ac_try) 2>&5
17775   ac_status=$?
17776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17777   (exit $ac_status); }; } &&
17778          { ac_try='test -s conftest.$ac_objext'
17779   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17780   (eval $ac_try) 2>&5
17781   ac_status=$?
17782   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17783   (exit $ac_status); }; }; then
17784   ac_lo=0 ac_mid=0
17785   while :; do
17786     cat >conftest.$ac_ext <<_ACEOF
17787 /* confdefs.h.  */
17788 _ACEOF
17789 cat confdefs.h >>conftest.$ac_ext
17790 cat >>conftest.$ac_ext <<_ACEOF
17791 /* end confdefs.h.  */
17792 $ac_includes_default
17793 int
17794 main ()
17795 {
17796 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) <= $ac_mid)];
17797 test_array [0] = 0
17798
17799   ;
17800   return 0;
17801 }
17802 _ACEOF
17803 rm -f conftest.$ac_objext
17804 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17805   (eval $ac_compile) 2>conftest.er1
17806   ac_status=$?
17807   grep -v '^ *+' conftest.er1 >conftest.err
17808   rm -f conftest.er1
17809   cat conftest.err >&5
17810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17811   (exit $ac_status); } &&
17812          { ac_try='test -z "$ac_c_werror_flag"
17813                          || test ! -s conftest.err'
17814   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17815   (eval $ac_try) 2>&5
17816   ac_status=$?
17817   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17818   (exit $ac_status); }; } &&
17819          { ac_try='test -s conftest.$ac_objext'
17820   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17821   (eval $ac_try) 2>&5
17822   ac_status=$?
17823   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17824   (exit $ac_status); }; }; then
17825   ac_hi=$ac_mid; break
17826 else
17827   echo "$as_me: failed program was:" >&5
17828 sed 's/^/| /' conftest.$ac_ext >&5
17829
17830 ac_lo=`expr $ac_mid + 1`
17831                     if test $ac_lo -le $ac_mid; then
17832                       ac_lo= ac_hi=
17833                       break
17834                     fi
17835                     ac_mid=`expr 2 '*' $ac_mid + 1`
17836 fi
17837 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17838   done
17839 else
17840   echo "$as_me: failed program was:" >&5
17841 sed 's/^/| /' conftest.$ac_ext >&5
17842
17843 cat >conftest.$ac_ext <<_ACEOF
17844 /* confdefs.h.  */
17845 _ACEOF
17846 cat confdefs.h >>conftest.$ac_ext
17847 cat >>conftest.$ac_ext <<_ACEOF
17848 /* end confdefs.h.  */
17849 $ac_includes_default
17850 int
17851 main ()
17852 {
17853 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) < 0)];
17854 test_array [0] = 0
17855
17856   ;
17857   return 0;
17858 }
17859 _ACEOF
17860 rm -f conftest.$ac_objext
17861 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17862   (eval $ac_compile) 2>conftest.er1
17863   ac_status=$?
17864   grep -v '^ *+' conftest.er1 >conftest.err
17865   rm -f conftest.er1
17866   cat conftest.err >&5
17867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17868   (exit $ac_status); } &&
17869          { ac_try='test -z "$ac_c_werror_flag"
17870                          || test ! -s conftest.err'
17871   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17872   (eval $ac_try) 2>&5
17873   ac_status=$?
17874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17875   (exit $ac_status); }; } &&
17876          { ac_try='test -s conftest.$ac_objext'
17877   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17878   (eval $ac_try) 2>&5
17879   ac_status=$?
17880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17881   (exit $ac_status); }; }; then
17882   ac_hi=-1 ac_mid=-1
17883   while :; do
17884     cat >conftest.$ac_ext <<_ACEOF
17885 /* confdefs.h.  */
17886 _ACEOF
17887 cat confdefs.h >>conftest.$ac_ext
17888 cat >>conftest.$ac_ext <<_ACEOF
17889 /* end confdefs.h.  */
17890 $ac_includes_default
17891 int
17892 main ()
17893 {
17894 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) >= $ac_mid)];
17895 test_array [0] = 0
17896
17897   ;
17898   return 0;
17899 }
17900 _ACEOF
17901 rm -f conftest.$ac_objext
17902 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17903   (eval $ac_compile) 2>conftest.er1
17904   ac_status=$?
17905   grep -v '^ *+' conftest.er1 >conftest.err
17906   rm -f conftest.er1
17907   cat conftest.err >&5
17908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17909   (exit $ac_status); } &&
17910          { ac_try='test -z "$ac_c_werror_flag"
17911                          || test ! -s conftest.err'
17912   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17913   (eval $ac_try) 2>&5
17914   ac_status=$?
17915   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17916   (exit $ac_status); }; } &&
17917          { ac_try='test -s conftest.$ac_objext'
17918   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17919   (eval $ac_try) 2>&5
17920   ac_status=$?
17921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17922   (exit $ac_status); }; }; then
17923   ac_lo=$ac_mid; break
17924 else
17925   echo "$as_me: failed program was:" >&5
17926 sed 's/^/| /' conftest.$ac_ext >&5
17927
17928 ac_hi=`expr '(' $ac_mid ')' - 1`
17929                        if test $ac_mid -le $ac_hi; then
17930                          ac_lo= ac_hi=
17931                          break
17932                        fi
17933                        ac_mid=`expr 2 '*' $ac_mid`
17934 fi
17935 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17936   done
17937 else
17938   echo "$as_me: failed program was:" >&5
17939 sed 's/^/| /' conftest.$ac_ext >&5
17940
17941 ac_lo= ac_hi=
17942 fi
17943 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17944 fi
17945 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17946 # Binary search between lo and hi bounds.
17947 while test "x$ac_lo" != "x$ac_hi"; do
17948   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
17949   cat >conftest.$ac_ext <<_ACEOF
17950 /* confdefs.h.  */
17951 _ACEOF
17952 cat confdefs.h >>conftest.$ac_ext
17953 cat >>conftest.$ac_ext <<_ACEOF
17954 /* end confdefs.h.  */
17955 $ac_includes_default
17956 int
17957 main ()
17958 {
17959 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) <= $ac_mid)];
17960 test_array [0] = 0
17961
17962   ;
17963   return 0;
17964 }
17965 _ACEOF
17966 rm -f conftest.$ac_objext
17967 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17968   (eval $ac_compile) 2>conftest.er1
17969   ac_status=$?
17970   grep -v '^ *+' conftest.er1 >conftest.err
17971   rm -f conftest.er1
17972   cat conftest.err >&5
17973   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17974   (exit $ac_status); } &&
17975          { ac_try='test -z "$ac_c_werror_flag"
17976                          || test ! -s conftest.err'
17977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17978   (eval $ac_try) 2>&5
17979   ac_status=$?
17980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17981   (exit $ac_status); }; } &&
17982          { ac_try='test -s conftest.$ac_objext'
17983   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17984   (eval $ac_try) 2>&5
17985   ac_status=$?
17986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17987   (exit $ac_status); }; }; then
17988   ac_hi=$ac_mid
17989 else
17990   echo "$as_me: failed program was:" >&5
17991 sed 's/^/| /' conftest.$ac_ext >&5
17992
17993 ac_lo=`expr '(' $ac_mid ')' + 1`
17994 fi
17995 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17996 done
17997 case $ac_lo in
17998 ?*) ac_cv_sizeof_size_t=$ac_lo;;
17999 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t), 77
18000 See \`config.log' for more details." >&5
18001 echo "$as_me: error: cannot compute sizeof (size_t), 77
18002 See \`config.log' for more details." >&2;}
18003    { (exit 1); exit 1; }; } ;;
18004 esac
18005 else
18006   if test "$cross_compiling" = yes; then
18007   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18008 See \`config.log' for more details." >&5
18009 echo "$as_me: error: cannot run test program while cross compiling
18010 See \`config.log' for more details." >&2;}
18011    { (exit 1); exit 1; }; }
18012 else
18013   cat >conftest.$ac_ext <<_ACEOF
18014 /* confdefs.h.  */
18015 _ACEOF
18016 cat confdefs.h >>conftest.$ac_ext
18017 cat >>conftest.$ac_ext <<_ACEOF
18018 /* end confdefs.h.  */
18019 $ac_includes_default
18020 long longval () { return (long) (sizeof (size_t)); }
18021 unsigned long ulongval () { return (long) (sizeof (size_t)); }
18022 #include <stdio.h>
18023 #include <stdlib.h>
18024 int
18025 main ()
18026 {
18027
18028   FILE *f = fopen ("conftest.val", "w");
18029   if (! f)
18030     exit (1);
18031   if (((long) (sizeof (size_t))) < 0)
18032     {
18033       long i = longval ();
18034       if (i != ((long) (sizeof (size_t))))
18035         exit (1);
18036       fprintf (f, "%ld\n", i);
18037     }
18038   else
18039     {
18040       unsigned long i = ulongval ();
18041       if (i != ((long) (sizeof (size_t))))
18042         exit (1);
18043       fprintf (f, "%lu\n", i);
18044     }
18045   exit (ferror (f) || fclose (f) != 0);
18046
18047   ;
18048   return 0;
18049 }
18050 _ACEOF
18051 rm -f conftest$ac_exeext
18052 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18053   (eval $ac_link) 2>&5
18054   ac_status=$?
18055   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18056   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18057   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18058   (eval $ac_try) 2>&5
18059   ac_status=$?
18060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18061   (exit $ac_status); }; }; then
18062   ac_cv_sizeof_size_t=`cat conftest.val`
18063 else
18064   echo "$as_me: program exited with status $ac_status" >&5
18065 echo "$as_me: failed program was:" >&5
18066 sed 's/^/| /' conftest.$ac_ext >&5
18067
18068 ( exit $ac_status )
18069 { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t), 77
18070 See \`config.log' for more details." >&5
18071 echo "$as_me: error: cannot compute sizeof (size_t), 77
18072 See \`config.log' for more details." >&2;}
18073    { (exit 1); exit 1; }; }
18074 fi
18075 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18076 fi
18077 fi
18078 rm -f conftest.val
18079 else
18080   ac_cv_sizeof_size_t=0
18081 fi
18082 fi
18083 echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
18084 echo "${ECHO_T}$ac_cv_sizeof_size_t" >&6
18085 cat >>confdefs.h <<_ACEOF
18086 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
18087 _ACEOF
18088
18089
18090
18091 # Determine memory alignment requirements for the basic C data types.
18092
18093 echo "$as_me:$LINENO: checking for short" >&5
18094 echo $ECHO_N "checking for short... $ECHO_C" >&6
18095 if test "${ac_cv_type_short+set}" = set; then
18096   echo $ECHO_N "(cached) $ECHO_C" >&6
18097 else
18098   cat >conftest.$ac_ext <<_ACEOF
18099 /* confdefs.h.  */
18100 _ACEOF
18101 cat confdefs.h >>conftest.$ac_ext
18102 cat >>conftest.$ac_ext <<_ACEOF
18103 /* end confdefs.h.  */
18104 $ac_includes_default
18105 int
18106 main ()
18107 {
18108 if ((short *) 0)
18109   return 0;
18110 if (sizeof (short))
18111   return 0;
18112   ;
18113   return 0;
18114 }
18115 _ACEOF
18116 rm -f conftest.$ac_objext
18117 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18118   (eval $ac_compile) 2>conftest.er1
18119   ac_status=$?
18120   grep -v '^ *+' conftest.er1 >conftest.err
18121   rm -f conftest.er1
18122   cat conftest.err >&5
18123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18124   (exit $ac_status); } &&
18125          { ac_try='test -z "$ac_c_werror_flag"
18126                          || test ! -s conftest.err'
18127   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18128   (eval $ac_try) 2>&5
18129   ac_status=$?
18130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18131   (exit $ac_status); }; } &&
18132          { ac_try='test -s conftest.$ac_objext'
18133   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18134   (eval $ac_try) 2>&5
18135   ac_status=$?
18136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18137   (exit $ac_status); }; }; then
18138   ac_cv_type_short=yes
18139 else
18140   echo "$as_me: failed program was:" >&5
18141 sed 's/^/| /' conftest.$ac_ext >&5
18142
18143 ac_cv_type_short=no
18144 fi
18145 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18146 fi
18147 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
18148 echo "${ECHO_T}$ac_cv_type_short" >&6
18149
18150 echo "$as_me:$LINENO: checking alignment of short" >&5
18151 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6
18152 if test "${pgac_cv_alignof_short+set}" = set; then
18153   echo $ECHO_N "(cached) $ECHO_C" >&6
18154 else
18155   if test "$ac_cv_type_short" = yes; then
18156   if test "$cross_compiling" = yes; then
18157   # Depending upon the size, compute the lo and hi bounds.
18158 cat >conftest.$ac_ext <<_ACEOF
18159 /* confdefs.h.  */
18160 _ACEOF
18161 cat confdefs.h >>conftest.$ac_ext
18162 cat >>conftest.$ac_ext <<_ACEOF
18163 /* end confdefs.h.  */
18164 $ac_includes_default
18165 struct { char filler; short field; } pgac_struct;
18166 int
18167 main ()
18168 {
18169 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
18170 test_array [0] = 0
18171
18172   ;
18173   return 0;
18174 }
18175 _ACEOF
18176 rm -f conftest.$ac_objext
18177 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18178   (eval $ac_compile) 2>conftest.er1
18179   ac_status=$?
18180   grep -v '^ *+' conftest.er1 >conftest.err
18181   rm -f conftest.er1
18182   cat conftest.err >&5
18183   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18184   (exit $ac_status); } &&
18185          { ac_try='test -z "$ac_c_werror_flag"
18186                          || test ! -s conftest.err'
18187   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18188   (eval $ac_try) 2>&5
18189   ac_status=$?
18190   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18191   (exit $ac_status); }; } &&
18192          { ac_try='test -s conftest.$ac_objext'
18193   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18194   (eval $ac_try) 2>&5
18195   ac_status=$?
18196   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18197   (exit $ac_status); }; }; then
18198   ac_lo=0 ac_mid=0
18199   while :; do
18200     cat >conftest.$ac_ext <<_ACEOF
18201 /* confdefs.h.  */
18202 _ACEOF
18203 cat confdefs.h >>conftest.$ac_ext
18204 cat >>conftest.$ac_ext <<_ACEOF
18205 /* end confdefs.h.  */
18206 $ac_includes_default
18207 struct { char filler; short field; } pgac_struct;
18208 int
18209 main ()
18210 {
18211 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18212 test_array [0] = 0
18213
18214   ;
18215   return 0;
18216 }
18217 _ACEOF
18218 rm -f conftest.$ac_objext
18219 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18220   (eval $ac_compile) 2>conftest.er1
18221   ac_status=$?
18222   grep -v '^ *+' conftest.er1 >conftest.err
18223   rm -f conftest.er1
18224   cat conftest.err >&5
18225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18226   (exit $ac_status); } &&
18227          { ac_try='test -z "$ac_c_werror_flag"
18228                          || test ! -s conftest.err'
18229   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18230   (eval $ac_try) 2>&5
18231   ac_status=$?
18232   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18233   (exit $ac_status); }; } &&
18234          { ac_try='test -s conftest.$ac_objext'
18235   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18236   (eval $ac_try) 2>&5
18237   ac_status=$?
18238   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18239   (exit $ac_status); }; }; then
18240   ac_hi=$ac_mid; break
18241 else
18242   echo "$as_me: failed program was:" >&5
18243 sed 's/^/| /' conftest.$ac_ext >&5
18244
18245 ac_lo=`expr $ac_mid + 1`
18246                     if test $ac_lo -le $ac_mid; then
18247                       ac_lo= ac_hi=
18248                       break
18249                     fi
18250                     ac_mid=`expr 2 '*' $ac_mid + 1`
18251 fi
18252 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18253   done
18254 else
18255   echo "$as_me: failed program was:" >&5
18256 sed 's/^/| /' conftest.$ac_ext >&5
18257
18258 cat >conftest.$ac_ext <<_ACEOF
18259 /* confdefs.h.  */
18260 _ACEOF
18261 cat confdefs.h >>conftest.$ac_ext
18262 cat >>conftest.$ac_ext <<_ACEOF
18263 /* end confdefs.h.  */
18264 $ac_includes_default
18265 struct { char filler; short field; } pgac_struct;
18266 int
18267 main ()
18268 {
18269 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
18270 test_array [0] = 0
18271
18272   ;
18273   return 0;
18274 }
18275 _ACEOF
18276 rm -f conftest.$ac_objext
18277 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18278   (eval $ac_compile) 2>conftest.er1
18279   ac_status=$?
18280   grep -v '^ *+' conftest.er1 >conftest.err
18281   rm -f conftest.er1
18282   cat conftest.err >&5
18283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18284   (exit $ac_status); } &&
18285          { ac_try='test -z "$ac_c_werror_flag"
18286                          || test ! -s conftest.err'
18287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18288   (eval $ac_try) 2>&5
18289   ac_status=$?
18290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18291   (exit $ac_status); }; } &&
18292          { ac_try='test -s conftest.$ac_objext'
18293   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18294   (eval $ac_try) 2>&5
18295   ac_status=$?
18296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18297   (exit $ac_status); }; }; then
18298   ac_hi=-1 ac_mid=-1
18299   while :; do
18300     cat >conftest.$ac_ext <<_ACEOF
18301 /* confdefs.h.  */
18302 _ACEOF
18303 cat confdefs.h >>conftest.$ac_ext
18304 cat >>conftest.$ac_ext <<_ACEOF
18305 /* end confdefs.h.  */
18306 $ac_includes_default
18307 struct { char filler; short field; } pgac_struct;
18308 int
18309 main ()
18310 {
18311 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
18312 test_array [0] = 0
18313
18314   ;
18315   return 0;
18316 }
18317 _ACEOF
18318 rm -f conftest.$ac_objext
18319 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18320   (eval $ac_compile) 2>conftest.er1
18321   ac_status=$?
18322   grep -v '^ *+' conftest.er1 >conftest.err
18323   rm -f conftest.er1
18324   cat conftest.err >&5
18325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18326   (exit $ac_status); } &&
18327          { ac_try='test -z "$ac_c_werror_flag"
18328                          || test ! -s conftest.err'
18329   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18330   (eval $ac_try) 2>&5
18331   ac_status=$?
18332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18333   (exit $ac_status); }; } &&
18334          { ac_try='test -s conftest.$ac_objext'
18335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18336   (eval $ac_try) 2>&5
18337   ac_status=$?
18338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18339   (exit $ac_status); }; }; then
18340   ac_lo=$ac_mid; break
18341 else
18342   echo "$as_me: failed program was:" >&5
18343 sed 's/^/| /' conftest.$ac_ext >&5
18344
18345 ac_hi=`expr '(' $ac_mid ')' - 1`
18346                        if test $ac_mid -le $ac_hi; then
18347                          ac_lo= ac_hi=
18348                          break
18349                        fi
18350                        ac_mid=`expr 2 '*' $ac_mid`
18351 fi
18352 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18353   done
18354 else
18355   echo "$as_me: failed program was:" >&5
18356 sed 's/^/| /' conftest.$ac_ext >&5
18357
18358 ac_lo= ac_hi=
18359 fi
18360 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18361 fi
18362 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18363 # Binary search between lo and hi bounds.
18364 while test "x$ac_lo" != "x$ac_hi"; do
18365   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18366   cat >conftest.$ac_ext <<_ACEOF
18367 /* confdefs.h.  */
18368 _ACEOF
18369 cat confdefs.h >>conftest.$ac_ext
18370 cat >>conftest.$ac_ext <<_ACEOF
18371 /* end confdefs.h.  */
18372 $ac_includes_default
18373 struct { char filler; short field; } pgac_struct;
18374 int
18375 main ()
18376 {
18377 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18378 test_array [0] = 0
18379
18380   ;
18381   return 0;
18382 }
18383 _ACEOF
18384 rm -f conftest.$ac_objext
18385 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18386   (eval $ac_compile) 2>conftest.er1
18387   ac_status=$?
18388   grep -v '^ *+' conftest.er1 >conftest.err
18389   rm -f conftest.er1
18390   cat conftest.err >&5
18391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18392   (exit $ac_status); } &&
18393          { ac_try='test -z "$ac_c_werror_flag"
18394                          || test ! -s conftest.err'
18395   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18396   (eval $ac_try) 2>&5
18397   ac_status=$?
18398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18399   (exit $ac_status); }; } &&
18400          { ac_try='test -s conftest.$ac_objext'
18401   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18402   (eval $ac_try) 2>&5
18403   ac_status=$?
18404   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18405   (exit $ac_status); }; }; then
18406   ac_hi=$ac_mid
18407 else
18408   echo "$as_me: failed program was:" >&5
18409 sed 's/^/| /' conftest.$ac_ext >&5
18410
18411 ac_lo=`expr '(' $ac_mid ')' + 1`
18412 fi
18413 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18414 done
18415 case $ac_lo in
18416 ?*) pgac_cv_alignof_short=$ac_lo;;
18417 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
18418 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
18419    { (exit 1); exit 1; }; } ;;
18420 esac
18421 else
18422   if test "$cross_compiling" = yes; then
18423   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18424 See \`config.log' for more details." >&5
18425 echo "$as_me: error: cannot run test program while cross compiling
18426 See \`config.log' for more details." >&2;}
18427    { (exit 1); exit 1; }; }
18428 else
18429   cat >conftest.$ac_ext <<_ACEOF
18430 /* confdefs.h.  */
18431 _ACEOF
18432 cat confdefs.h >>conftest.$ac_ext
18433 cat >>conftest.$ac_ext <<_ACEOF
18434 /* end confdefs.h.  */
18435 $ac_includes_default
18436 struct { char filler; short field; } pgac_struct;
18437 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18438 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18439 #include <stdio.h>
18440 #include <stdlib.h>
18441 int
18442 main ()
18443 {
18444
18445   FILE *f = fopen ("conftest.val", "w");
18446   if (! f)
18447     exit (1);
18448   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
18449     {
18450       long i = longval ();
18451       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18452         exit (1);
18453       fprintf (f, "%ld\n", i);
18454     }
18455   else
18456     {
18457       unsigned long i = ulongval ();
18458       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18459         exit (1);
18460       fprintf (f, "%lu\n", i);
18461     }
18462   exit (ferror (f) || fclose (f) != 0);
18463
18464   ;
18465   return 0;
18466 }
18467 _ACEOF
18468 rm -f conftest$ac_exeext
18469 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18470   (eval $ac_link) 2>&5
18471   ac_status=$?
18472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18473   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18474   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18475   (eval $ac_try) 2>&5
18476   ac_status=$?
18477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18478   (exit $ac_status); }; }; then
18479   pgac_cv_alignof_short=`cat conftest.val`
18480 else
18481   echo "$as_me: program exited with status $ac_status" >&5
18482 echo "$as_me: failed program was:" >&5
18483 sed 's/^/| /' conftest.$ac_ext >&5
18484
18485 ( exit $ac_status )
18486 { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
18487 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
18488    { (exit 1); exit 1; }; }
18489 fi
18490 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18491 fi
18492 fi
18493 rm -f conftest.val
18494 else
18495   pgac_cv_alignof_short=0
18496 fi
18497 fi
18498 echo "$as_me:$LINENO: result: $pgac_cv_alignof_short" >&5
18499 echo "${ECHO_T}$pgac_cv_alignof_short" >&6
18500 cat >>confdefs.h <<_ACEOF
18501 #define ALIGNOF_SHORT $pgac_cv_alignof_short
18502 _ACEOF
18503
18504
18505 echo "$as_me:$LINENO: checking for int" >&5
18506 echo $ECHO_N "checking for int... $ECHO_C" >&6
18507 if test "${ac_cv_type_int+set}" = set; then
18508   echo $ECHO_N "(cached) $ECHO_C" >&6
18509 else
18510   cat >conftest.$ac_ext <<_ACEOF
18511 /* confdefs.h.  */
18512 _ACEOF
18513 cat confdefs.h >>conftest.$ac_ext
18514 cat >>conftest.$ac_ext <<_ACEOF
18515 /* end confdefs.h.  */
18516 $ac_includes_default
18517 int
18518 main ()
18519 {
18520 if ((int *) 0)
18521   return 0;
18522 if (sizeof (int))
18523   return 0;
18524   ;
18525   return 0;
18526 }
18527 _ACEOF
18528 rm -f conftest.$ac_objext
18529 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18530   (eval $ac_compile) 2>conftest.er1
18531   ac_status=$?
18532   grep -v '^ *+' conftest.er1 >conftest.err
18533   rm -f conftest.er1
18534   cat conftest.err >&5
18535   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18536   (exit $ac_status); } &&
18537          { ac_try='test -z "$ac_c_werror_flag"
18538                          || test ! -s conftest.err'
18539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18540   (eval $ac_try) 2>&5
18541   ac_status=$?
18542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18543   (exit $ac_status); }; } &&
18544          { ac_try='test -s conftest.$ac_objext'
18545   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18546   (eval $ac_try) 2>&5
18547   ac_status=$?
18548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18549   (exit $ac_status); }; }; then
18550   ac_cv_type_int=yes
18551 else
18552   echo "$as_me: failed program was:" >&5
18553 sed 's/^/| /' conftest.$ac_ext >&5
18554
18555 ac_cv_type_int=no
18556 fi
18557 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18558 fi
18559 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
18560 echo "${ECHO_T}$ac_cv_type_int" >&6
18561
18562 echo "$as_me:$LINENO: checking alignment of int" >&5
18563 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6
18564 if test "${pgac_cv_alignof_int+set}" = set; then
18565   echo $ECHO_N "(cached) $ECHO_C" >&6
18566 else
18567   if test "$ac_cv_type_int" = yes; then
18568   if test "$cross_compiling" = yes; then
18569   # Depending upon the size, compute the lo and hi bounds.
18570 cat >conftest.$ac_ext <<_ACEOF
18571 /* confdefs.h.  */
18572 _ACEOF
18573 cat confdefs.h >>conftest.$ac_ext
18574 cat >>conftest.$ac_ext <<_ACEOF
18575 /* end confdefs.h.  */
18576 $ac_includes_default
18577 struct { char filler; int field; } pgac_struct;
18578 int
18579 main ()
18580 {
18581 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
18582 test_array [0] = 0
18583
18584   ;
18585   return 0;
18586 }
18587 _ACEOF
18588 rm -f conftest.$ac_objext
18589 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18590   (eval $ac_compile) 2>conftest.er1
18591   ac_status=$?
18592   grep -v '^ *+' conftest.er1 >conftest.err
18593   rm -f conftest.er1
18594   cat conftest.err >&5
18595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18596   (exit $ac_status); } &&
18597          { ac_try='test -z "$ac_c_werror_flag"
18598                          || test ! -s conftest.err'
18599   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18600   (eval $ac_try) 2>&5
18601   ac_status=$?
18602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18603   (exit $ac_status); }; } &&
18604          { ac_try='test -s conftest.$ac_objext'
18605   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18606   (eval $ac_try) 2>&5
18607   ac_status=$?
18608   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18609   (exit $ac_status); }; }; then
18610   ac_lo=0 ac_mid=0
18611   while :; do
18612     cat >conftest.$ac_ext <<_ACEOF
18613 /* confdefs.h.  */
18614 _ACEOF
18615 cat confdefs.h >>conftest.$ac_ext
18616 cat >>conftest.$ac_ext <<_ACEOF
18617 /* end confdefs.h.  */
18618 $ac_includes_default
18619 struct { char filler; int field; } pgac_struct;
18620 int
18621 main ()
18622 {
18623 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18624 test_array [0] = 0
18625
18626   ;
18627   return 0;
18628 }
18629 _ACEOF
18630 rm -f conftest.$ac_objext
18631 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18632   (eval $ac_compile) 2>conftest.er1
18633   ac_status=$?
18634   grep -v '^ *+' conftest.er1 >conftest.err
18635   rm -f conftest.er1
18636   cat conftest.err >&5
18637   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18638   (exit $ac_status); } &&
18639          { ac_try='test -z "$ac_c_werror_flag"
18640                          || test ! -s conftest.err'
18641   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18642   (eval $ac_try) 2>&5
18643   ac_status=$?
18644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18645   (exit $ac_status); }; } &&
18646          { ac_try='test -s conftest.$ac_objext'
18647   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18648   (eval $ac_try) 2>&5
18649   ac_status=$?
18650   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18651   (exit $ac_status); }; }; then
18652   ac_hi=$ac_mid; break
18653 else
18654   echo "$as_me: failed program was:" >&5
18655 sed 's/^/| /' conftest.$ac_ext >&5
18656
18657 ac_lo=`expr $ac_mid + 1`
18658                     if test $ac_lo -le $ac_mid; then
18659                       ac_lo= ac_hi=
18660                       break
18661                     fi
18662                     ac_mid=`expr 2 '*' $ac_mid + 1`
18663 fi
18664 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18665   done
18666 else
18667   echo "$as_me: failed program was:" >&5
18668 sed 's/^/| /' conftest.$ac_ext >&5
18669
18670 cat >conftest.$ac_ext <<_ACEOF
18671 /* confdefs.h.  */
18672 _ACEOF
18673 cat confdefs.h >>conftest.$ac_ext
18674 cat >>conftest.$ac_ext <<_ACEOF
18675 /* end confdefs.h.  */
18676 $ac_includes_default
18677 struct { char filler; int field; } pgac_struct;
18678 int
18679 main ()
18680 {
18681 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
18682 test_array [0] = 0
18683
18684   ;
18685   return 0;
18686 }
18687 _ACEOF
18688 rm -f conftest.$ac_objext
18689 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18690   (eval $ac_compile) 2>conftest.er1
18691   ac_status=$?
18692   grep -v '^ *+' conftest.er1 >conftest.err
18693   rm -f conftest.er1
18694   cat conftest.err >&5
18695   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18696   (exit $ac_status); } &&
18697          { ac_try='test -z "$ac_c_werror_flag"
18698                          || test ! -s conftest.err'
18699   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18700   (eval $ac_try) 2>&5
18701   ac_status=$?
18702   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18703   (exit $ac_status); }; } &&
18704          { ac_try='test -s conftest.$ac_objext'
18705   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18706   (eval $ac_try) 2>&5
18707   ac_status=$?
18708   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18709   (exit $ac_status); }; }; then
18710   ac_hi=-1 ac_mid=-1
18711   while :; do
18712     cat >conftest.$ac_ext <<_ACEOF
18713 /* confdefs.h.  */
18714 _ACEOF
18715 cat confdefs.h >>conftest.$ac_ext
18716 cat >>conftest.$ac_ext <<_ACEOF
18717 /* end confdefs.h.  */
18718 $ac_includes_default
18719 struct { char filler; int field; } pgac_struct;
18720 int
18721 main ()
18722 {
18723 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
18724 test_array [0] = 0
18725
18726   ;
18727   return 0;
18728 }
18729 _ACEOF
18730 rm -f conftest.$ac_objext
18731 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18732   (eval $ac_compile) 2>conftest.er1
18733   ac_status=$?
18734   grep -v '^ *+' conftest.er1 >conftest.err
18735   rm -f conftest.er1
18736   cat conftest.err >&5
18737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18738   (exit $ac_status); } &&
18739          { ac_try='test -z "$ac_c_werror_flag"
18740                          || test ! -s conftest.err'
18741   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18742   (eval $ac_try) 2>&5
18743   ac_status=$?
18744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18745   (exit $ac_status); }; } &&
18746          { ac_try='test -s conftest.$ac_objext'
18747   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18748   (eval $ac_try) 2>&5
18749   ac_status=$?
18750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18751   (exit $ac_status); }; }; then
18752   ac_lo=$ac_mid; break
18753 else
18754   echo "$as_me: failed program was:" >&5
18755 sed 's/^/| /' conftest.$ac_ext >&5
18756
18757 ac_hi=`expr '(' $ac_mid ')' - 1`
18758                        if test $ac_mid -le $ac_hi; then
18759                          ac_lo= ac_hi=
18760                          break
18761                        fi
18762                        ac_mid=`expr 2 '*' $ac_mid`
18763 fi
18764 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18765   done
18766 else
18767   echo "$as_me: failed program was:" >&5
18768 sed 's/^/| /' conftest.$ac_ext >&5
18769
18770 ac_lo= ac_hi=
18771 fi
18772 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18773 fi
18774 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18775 # Binary search between lo and hi bounds.
18776 while test "x$ac_lo" != "x$ac_hi"; do
18777   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18778   cat >conftest.$ac_ext <<_ACEOF
18779 /* confdefs.h.  */
18780 _ACEOF
18781 cat confdefs.h >>conftest.$ac_ext
18782 cat >>conftest.$ac_ext <<_ACEOF
18783 /* end confdefs.h.  */
18784 $ac_includes_default
18785 struct { char filler; int field; } pgac_struct;
18786 int
18787 main ()
18788 {
18789 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18790 test_array [0] = 0
18791
18792   ;
18793   return 0;
18794 }
18795 _ACEOF
18796 rm -f conftest.$ac_objext
18797 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18798   (eval $ac_compile) 2>conftest.er1
18799   ac_status=$?
18800   grep -v '^ *+' conftest.er1 >conftest.err
18801   rm -f conftest.er1
18802   cat conftest.err >&5
18803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18804   (exit $ac_status); } &&
18805          { ac_try='test -z "$ac_c_werror_flag"
18806                          || test ! -s conftest.err'
18807   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18808   (eval $ac_try) 2>&5
18809   ac_status=$?
18810   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18811   (exit $ac_status); }; } &&
18812          { ac_try='test -s conftest.$ac_objext'
18813   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18814   (eval $ac_try) 2>&5
18815   ac_status=$?
18816   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18817   (exit $ac_status); }; }; then
18818   ac_hi=$ac_mid
18819 else
18820   echo "$as_me: failed program was:" >&5
18821 sed 's/^/| /' conftest.$ac_ext >&5
18822
18823 ac_lo=`expr '(' $ac_mid ')' + 1`
18824 fi
18825 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18826 done
18827 case $ac_lo in
18828 ?*) pgac_cv_alignof_int=$ac_lo;;
18829 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
18830 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
18831    { (exit 1); exit 1; }; } ;;
18832 esac
18833 else
18834   if test "$cross_compiling" = yes; then
18835   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18836 See \`config.log' for more details." >&5
18837 echo "$as_me: error: cannot run test program while cross compiling
18838 See \`config.log' for more details." >&2;}
18839    { (exit 1); exit 1; }; }
18840 else
18841   cat >conftest.$ac_ext <<_ACEOF
18842 /* confdefs.h.  */
18843 _ACEOF
18844 cat confdefs.h >>conftest.$ac_ext
18845 cat >>conftest.$ac_ext <<_ACEOF
18846 /* end confdefs.h.  */
18847 $ac_includes_default
18848 struct { char filler; int field; } pgac_struct;
18849 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18850 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18851 #include <stdio.h>
18852 #include <stdlib.h>
18853 int
18854 main ()
18855 {
18856
18857   FILE *f = fopen ("conftest.val", "w");
18858   if (! f)
18859     exit (1);
18860   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
18861     {
18862       long i = longval ();
18863       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18864         exit (1);
18865       fprintf (f, "%ld\n", i);
18866     }
18867   else
18868     {
18869       unsigned long i = ulongval ();
18870       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18871         exit (1);
18872       fprintf (f, "%lu\n", i);
18873     }
18874   exit (ferror (f) || fclose (f) != 0);
18875
18876   ;
18877   return 0;
18878 }
18879 _ACEOF
18880 rm -f conftest$ac_exeext
18881 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18882   (eval $ac_link) 2>&5
18883   ac_status=$?
18884   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18885   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18886   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18887   (eval $ac_try) 2>&5
18888   ac_status=$?
18889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18890   (exit $ac_status); }; }; then
18891   pgac_cv_alignof_int=`cat conftest.val`
18892 else
18893   echo "$as_me: program exited with status $ac_status" >&5
18894 echo "$as_me: failed program was:" >&5
18895 sed 's/^/| /' conftest.$ac_ext >&5
18896
18897 ( exit $ac_status )
18898 { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
18899 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
18900    { (exit 1); exit 1; }; }
18901 fi
18902 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18903 fi
18904 fi
18905 rm -f conftest.val
18906 else
18907   pgac_cv_alignof_int=0
18908 fi
18909 fi
18910 echo "$as_me:$LINENO: result: $pgac_cv_alignof_int" >&5
18911 echo "${ECHO_T}$pgac_cv_alignof_int" >&6
18912 cat >>confdefs.h <<_ACEOF
18913 #define ALIGNOF_INT $pgac_cv_alignof_int
18914 _ACEOF
18915
18916
18917 echo "$as_me:$LINENO: checking for long" >&5
18918 echo $ECHO_N "checking for long... $ECHO_C" >&6
18919 if test "${ac_cv_type_long+set}" = set; then
18920   echo $ECHO_N "(cached) $ECHO_C" >&6
18921 else
18922   cat >conftest.$ac_ext <<_ACEOF
18923 /* confdefs.h.  */
18924 _ACEOF
18925 cat confdefs.h >>conftest.$ac_ext
18926 cat >>conftest.$ac_ext <<_ACEOF
18927 /* end confdefs.h.  */
18928 $ac_includes_default
18929 int
18930 main ()
18931 {
18932 if ((long *) 0)
18933   return 0;
18934 if (sizeof (long))
18935   return 0;
18936   ;
18937   return 0;
18938 }
18939 _ACEOF
18940 rm -f conftest.$ac_objext
18941 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18942   (eval $ac_compile) 2>conftest.er1
18943   ac_status=$?
18944   grep -v '^ *+' conftest.er1 >conftest.err
18945   rm -f conftest.er1
18946   cat conftest.err >&5
18947   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18948   (exit $ac_status); } &&
18949          { ac_try='test -z "$ac_c_werror_flag"
18950                          || test ! -s conftest.err'
18951   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18952   (eval $ac_try) 2>&5
18953   ac_status=$?
18954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18955   (exit $ac_status); }; } &&
18956          { ac_try='test -s conftest.$ac_objext'
18957   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18958   (eval $ac_try) 2>&5
18959   ac_status=$?
18960   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18961   (exit $ac_status); }; }; then
18962   ac_cv_type_long=yes
18963 else
18964   echo "$as_me: failed program was:" >&5
18965 sed 's/^/| /' conftest.$ac_ext >&5
18966
18967 ac_cv_type_long=no
18968 fi
18969 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18970 fi
18971 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
18972 echo "${ECHO_T}$ac_cv_type_long" >&6
18973
18974 echo "$as_me:$LINENO: checking alignment of long" >&5
18975 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6
18976 if test "${pgac_cv_alignof_long+set}" = set; then
18977   echo $ECHO_N "(cached) $ECHO_C" >&6
18978 else
18979   if test "$ac_cv_type_long" = yes; then
18980   if test "$cross_compiling" = yes; then
18981   # Depending upon the size, compute the lo and hi bounds.
18982 cat >conftest.$ac_ext <<_ACEOF
18983 /* confdefs.h.  */
18984 _ACEOF
18985 cat confdefs.h >>conftest.$ac_ext
18986 cat >>conftest.$ac_ext <<_ACEOF
18987 /* end confdefs.h.  */
18988 $ac_includes_default
18989 struct { char filler; long field; } pgac_struct;
18990 int
18991 main ()
18992 {
18993 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
18994 test_array [0] = 0
18995
18996   ;
18997   return 0;
18998 }
18999 _ACEOF
19000 rm -f conftest.$ac_objext
19001 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19002   (eval $ac_compile) 2>conftest.er1
19003   ac_status=$?
19004   grep -v '^ *+' conftest.er1 >conftest.err
19005   rm -f conftest.er1
19006   cat conftest.err >&5
19007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19008   (exit $ac_status); } &&
19009          { ac_try='test -z "$ac_c_werror_flag"
19010                          || test ! -s conftest.err'
19011   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19012   (eval $ac_try) 2>&5
19013   ac_status=$?
19014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19015   (exit $ac_status); }; } &&
19016          { ac_try='test -s conftest.$ac_objext'
19017   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19018   (eval $ac_try) 2>&5
19019   ac_status=$?
19020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19021   (exit $ac_status); }; }; then
19022   ac_lo=0 ac_mid=0
19023   while :; do
19024     cat >conftest.$ac_ext <<_ACEOF
19025 /* confdefs.h.  */
19026 _ACEOF
19027 cat confdefs.h >>conftest.$ac_ext
19028 cat >>conftest.$ac_ext <<_ACEOF
19029 /* end confdefs.h.  */
19030 $ac_includes_default
19031 struct { char filler; long field; } pgac_struct;
19032 int
19033 main ()
19034 {
19035 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19036 test_array [0] = 0
19037
19038   ;
19039   return 0;
19040 }
19041 _ACEOF
19042 rm -f conftest.$ac_objext
19043 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19044   (eval $ac_compile) 2>conftest.er1
19045   ac_status=$?
19046   grep -v '^ *+' conftest.er1 >conftest.err
19047   rm -f conftest.er1
19048   cat conftest.err >&5
19049   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19050   (exit $ac_status); } &&
19051          { ac_try='test -z "$ac_c_werror_flag"
19052                          || test ! -s conftest.err'
19053   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19054   (eval $ac_try) 2>&5
19055   ac_status=$?
19056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19057   (exit $ac_status); }; } &&
19058          { ac_try='test -s conftest.$ac_objext'
19059   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19060   (eval $ac_try) 2>&5
19061   ac_status=$?
19062   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19063   (exit $ac_status); }; }; then
19064   ac_hi=$ac_mid; break
19065 else
19066   echo "$as_me: failed program was:" >&5
19067 sed 's/^/| /' conftest.$ac_ext >&5
19068
19069 ac_lo=`expr $ac_mid + 1`
19070                     if test $ac_lo -le $ac_mid; then
19071                       ac_lo= ac_hi=
19072                       break
19073                     fi
19074                     ac_mid=`expr 2 '*' $ac_mid + 1`
19075 fi
19076 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19077   done
19078 else
19079   echo "$as_me: failed program was:" >&5
19080 sed 's/^/| /' conftest.$ac_ext >&5
19081
19082 cat >conftest.$ac_ext <<_ACEOF
19083 /* confdefs.h.  */
19084 _ACEOF
19085 cat confdefs.h >>conftest.$ac_ext
19086 cat >>conftest.$ac_ext <<_ACEOF
19087 /* end confdefs.h.  */
19088 $ac_includes_default
19089 struct { char filler; long field; } pgac_struct;
19090 int
19091 main ()
19092 {
19093 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19094 test_array [0] = 0
19095
19096   ;
19097   return 0;
19098 }
19099 _ACEOF
19100 rm -f conftest.$ac_objext
19101 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19102   (eval $ac_compile) 2>conftest.er1
19103   ac_status=$?
19104   grep -v '^ *+' conftest.er1 >conftest.err
19105   rm -f conftest.er1
19106   cat conftest.err >&5
19107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19108   (exit $ac_status); } &&
19109          { ac_try='test -z "$ac_c_werror_flag"
19110                          || test ! -s conftest.err'
19111   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19112   (eval $ac_try) 2>&5
19113   ac_status=$?
19114   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19115   (exit $ac_status); }; } &&
19116          { ac_try='test -s conftest.$ac_objext'
19117   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19118   (eval $ac_try) 2>&5
19119   ac_status=$?
19120   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19121   (exit $ac_status); }; }; then
19122   ac_hi=-1 ac_mid=-1
19123   while :; do
19124     cat >conftest.$ac_ext <<_ACEOF
19125 /* confdefs.h.  */
19126 _ACEOF
19127 cat confdefs.h >>conftest.$ac_ext
19128 cat >>conftest.$ac_ext <<_ACEOF
19129 /* end confdefs.h.  */
19130 $ac_includes_default
19131 struct { char filler; long field; } pgac_struct;
19132 int
19133 main ()
19134 {
19135 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19136 test_array [0] = 0
19137
19138   ;
19139   return 0;
19140 }
19141 _ACEOF
19142 rm -f conftest.$ac_objext
19143 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19144   (eval $ac_compile) 2>conftest.er1
19145   ac_status=$?
19146   grep -v '^ *+' conftest.er1 >conftest.err
19147   rm -f conftest.er1
19148   cat conftest.err >&5
19149   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19150   (exit $ac_status); } &&
19151          { ac_try='test -z "$ac_c_werror_flag"
19152                          || test ! -s conftest.err'
19153   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19154   (eval $ac_try) 2>&5
19155   ac_status=$?
19156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19157   (exit $ac_status); }; } &&
19158          { ac_try='test -s conftest.$ac_objext'
19159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19160   (eval $ac_try) 2>&5
19161   ac_status=$?
19162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19163   (exit $ac_status); }; }; then
19164   ac_lo=$ac_mid; break
19165 else
19166   echo "$as_me: failed program was:" >&5
19167 sed 's/^/| /' conftest.$ac_ext >&5
19168
19169 ac_hi=`expr '(' $ac_mid ')' - 1`
19170                        if test $ac_mid -le $ac_hi; then
19171                          ac_lo= ac_hi=
19172                          break
19173                        fi
19174                        ac_mid=`expr 2 '*' $ac_mid`
19175 fi
19176 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19177   done
19178 else
19179   echo "$as_me: failed program was:" >&5
19180 sed 's/^/| /' conftest.$ac_ext >&5
19181
19182 ac_lo= ac_hi=
19183 fi
19184 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19185 fi
19186 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19187 # Binary search between lo and hi bounds.
19188 while test "x$ac_lo" != "x$ac_hi"; do
19189   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19190   cat >conftest.$ac_ext <<_ACEOF
19191 /* confdefs.h.  */
19192 _ACEOF
19193 cat confdefs.h >>conftest.$ac_ext
19194 cat >>conftest.$ac_ext <<_ACEOF
19195 /* end confdefs.h.  */
19196 $ac_includes_default
19197 struct { char filler; long field; } pgac_struct;
19198 int
19199 main ()
19200 {
19201 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19202 test_array [0] = 0
19203
19204   ;
19205   return 0;
19206 }
19207 _ACEOF
19208 rm -f conftest.$ac_objext
19209 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19210   (eval $ac_compile) 2>conftest.er1
19211   ac_status=$?
19212   grep -v '^ *+' conftest.er1 >conftest.err
19213   rm -f conftest.er1
19214   cat conftest.err >&5
19215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19216   (exit $ac_status); } &&
19217          { ac_try='test -z "$ac_c_werror_flag"
19218                          || test ! -s conftest.err'
19219   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19220   (eval $ac_try) 2>&5
19221   ac_status=$?
19222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19223   (exit $ac_status); }; } &&
19224          { ac_try='test -s conftest.$ac_objext'
19225   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19226   (eval $ac_try) 2>&5
19227   ac_status=$?
19228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19229   (exit $ac_status); }; }; then
19230   ac_hi=$ac_mid
19231 else
19232   echo "$as_me: failed program was:" >&5
19233 sed 's/^/| /' conftest.$ac_ext >&5
19234
19235 ac_lo=`expr '(' $ac_mid ')' + 1`
19236 fi
19237 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19238 done
19239 case $ac_lo in
19240 ?*) pgac_cv_alignof_long=$ac_lo;;
19241 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
19242 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
19243    { (exit 1); exit 1; }; } ;;
19244 esac
19245 else
19246   if test "$cross_compiling" = yes; then
19247   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19248 See \`config.log' for more details." >&5
19249 echo "$as_me: error: cannot run test program while cross compiling
19250 See \`config.log' for more details." >&2;}
19251    { (exit 1); exit 1; }; }
19252 else
19253   cat >conftest.$ac_ext <<_ACEOF
19254 /* confdefs.h.  */
19255 _ACEOF
19256 cat confdefs.h >>conftest.$ac_ext
19257 cat >>conftest.$ac_ext <<_ACEOF
19258 /* end confdefs.h.  */
19259 $ac_includes_default
19260 struct { char filler; long field; } pgac_struct;
19261 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19262 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19263 #include <stdio.h>
19264 #include <stdlib.h>
19265 int
19266 main ()
19267 {
19268
19269   FILE *f = fopen ("conftest.val", "w");
19270   if (! f)
19271     exit (1);
19272   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
19273     {
19274       long i = longval ();
19275       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19276         exit (1);
19277       fprintf (f, "%ld\n", i);
19278     }
19279   else
19280     {
19281       unsigned long i = ulongval ();
19282       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19283         exit (1);
19284       fprintf (f, "%lu\n", i);
19285     }
19286   exit (ferror (f) || fclose (f) != 0);
19287
19288   ;
19289   return 0;
19290 }
19291 _ACEOF
19292 rm -f conftest$ac_exeext
19293 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19294   (eval $ac_link) 2>&5
19295   ac_status=$?
19296   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19297   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19298   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19299   (eval $ac_try) 2>&5
19300   ac_status=$?
19301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19302   (exit $ac_status); }; }; then
19303   pgac_cv_alignof_long=`cat conftest.val`
19304 else
19305   echo "$as_me: program exited with status $ac_status" >&5
19306 echo "$as_me: failed program was:" >&5
19307 sed 's/^/| /' conftest.$ac_ext >&5
19308
19309 ( exit $ac_status )
19310 { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
19311 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
19312    { (exit 1); exit 1; }; }
19313 fi
19314 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19315 fi
19316 fi
19317 rm -f conftest.val
19318 else
19319   pgac_cv_alignof_long=0
19320 fi
19321 fi
19322 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long" >&5
19323 echo "${ECHO_T}$pgac_cv_alignof_long" >&6
19324 cat >>confdefs.h <<_ACEOF
19325 #define ALIGNOF_LONG $pgac_cv_alignof_long
19326 _ACEOF
19327
19328
19329 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
19330   echo "$as_me:$LINENO: checking for long long int" >&5
19331 echo $ECHO_N "checking for long long int... $ECHO_C" >&6
19332 if test "${ac_cv_type_long_long_int+set}" = set; then
19333   echo $ECHO_N "(cached) $ECHO_C" >&6
19334 else
19335   cat >conftest.$ac_ext <<_ACEOF
19336 /* confdefs.h.  */
19337 _ACEOF
19338 cat confdefs.h >>conftest.$ac_ext
19339 cat >>conftest.$ac_ext <<_ACEOF
19340 /* end confdefs.h.  */
19341 $ac_includes_default
19342 int
19343 main ()
19344 {
19345 if ((long long int *) 0)
19346   return 0;
19347 if (sizeof (long long int))
19348   return 0;
19349   ;
19350   return 0;
19351 }
19352 _ACEOF
19353 rm -f conftest.$ac_objext
19354 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19355   (eval $ac_compile) 2>conftest.er1
19356   ac_status=$?
19357   grep -v '^ *+' conftest.er1 >conftest.err
19358   rm -f conftest.er1
19359   cat conftest.err >&5
19360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19361   (exit $ac_status); } &&
19362          { ac_try='test -z "$ac_c_werror_flag"
19363                          || test ! -s conftest.err'
19364   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19365   (eval $ac_try) 2>&5
19366   ac_status=$?
19367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19368   (exit $ac_status); }; } &&
19369          { ac_try='test -s conftest.$ac_objext'
19370   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19371   (eval $ac_try) 2>&5
19372   ac_status=$?
19373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19374   (exit $ac_status); }; }; then
19375   ac_cv_type_long_long_int=yes
19376 else
19377   echo "$as_me: failed program was:" >&5
19378 sed 's/^/| /' conftest.$ac_ext >&5
19379
19380 ac_cv_type_long_long_int=no
19381 fi
19382 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19383 fi
19384 echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
19385 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6
19386
19387 echo "$as_me:$LINENO: checking alignment of long long int" >&5
19388 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6
19389 if test "${pgac_cv_alignof_long_long_int+set}" = set; then
19390   echo $ECHO_N "(cached) $ECHO_C" >&6
19391 else
19392   if test "$ac_cv_type_long_long_int" = yes; then
19393   if test "$cross_compiling" = yes; then
19394   # Depending upon the size, compute the lo and hi bounds.
19395 cat >conftest.$ac_ext <<_ACEOF
19396 /* confdefs.h.  */
19397 _ACEOF
19398 cat confdefs.h >>conftest.$ac_ext
19399 cat >>conftest.$ac_ext <<_ACEOF
19400 /* end confdefs.h.  */
19401 $ac_includes_default
19402 struct { char filler; long long int field; } pgac_struct;
19403 int
19404 main ()
19405 {
19406 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
19407 test_array [0] = 0
19408
19409   ;
19410   return 0;
19411 }
19412 _ACEOF
19413 rm -f conftest.$ac_objext
19414 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19415   (eval $ac_compile) 2>conftest.er1
19416   ac_status=$?
19417   grep -v '^ *+' conftest.er1 >conftest.err
19418   rm -f conftest.er1
19419   cat conftest.err >&5
19420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19421   (exit $ac_status); } &&
19422          { ac_try='test -z "$ac_c_werror_flag"
19423                          || test ! -s conftest.err'
19424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19425   (eval $ac_try) 2>&5
19426   ac_status=$?
19427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19428   (exit $ac_status); }; } &&
19429          { ac_try='test -s conftest.$ac_objext'
19430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19431   (eval $ac_try) 2>&5
19432   ac_status=$?
19433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19434   (exit $ac_status); }; }; then
19435   ac_lo=0 ac_mid=0
19436   while :; do
19437     cat >conftest.$ac_ext <<_ACEOF
19438 /* confdefs.h.  */
19439 _ACEOF
19440 cat confdefs.h >>conftest.$ac_ext
19441 cat >>conftest.$ac_ext <<_ACEOF
19442 /* end confdefs.h.  */
19443 $ac_includes_default
19444 struct { char filler; long long int field; } pgac_struct;
19445 int
19446 main ()
19447 {
19448 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19449 test_array [0] = 0
19450
19451   ;
19452   return 0;
19453 }
19454 _ACEOF
19455 rm -f conftest.$ac_objext
19456 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19457   (eval $ac_compile) 2>conftest.er1
19458   ac_status=$?
19459   grep -v '^ *+' conftest.er1 >conftest.err
19460   rm -f conftest.er1
19461   cat conftest.err >&5
19462   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19463   (exit $ac_status); } &&
19464          { ac_try='test -z "$ac_c_werror_flag"
19465                          || test ! -s conftest.err'
19466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19467   (eval $ac_try) 2>&5
19468   ac_status=$?
19469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19470   (exit $ac_status); }; } &&
19471          { ac_try='test -s conftest.$ac_objext'
19472   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19473   (eval $ac_try) 2>&5
19474   ac_status=$?
19475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19476   (exit $ac_status); }; }; then
19477   ac_hi=$ac_mid; break
19478 else
19479   echo "$as_me: failed program was:" >&5
19480 sed 's/^/| /' conftest.$ac_ext >&5
19481
19482 ac_lo=`expr $ac_mid + 1`
19483                     if test $ac_lo -le $ac_mid; then
19484                       ac_lo= ac_hi=
19485                       break
19486                     fi
19487                     ac_mid=`expr 2 '*' $ac_mid + 1`
19488 fi
19489 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19490   done
19491 else
19492   echo "$as_me: failed program was:" >&5
19493 sed 's/^/| /' conftest.$ac_ext >&5
19494
19495 cat >conftest.$ac_ext <<_ACEOF
19496 /* confdefs.h.  */
19497 _ACEOF
19498 cat confdefs.h >>conftest.$ac_ext
19499 cat >>conftest.$ac_ext <<_ACEOF
19500 /* end confdefs.h.  */
19501 $ac_includes_default
19502 struct { char filler; long long int field; } pgac_struct;
19503 int
19504 main ()
19505 {
19506 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19507 test_array [0] = 0
19508
19509   ;
19510   return 0;
19511 }
19512 _ACEOF
19513 rm -f conftest.$ac_objext
19514 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19515   (eval $ac_compile) 2>conftest.er1
19516   ac_status=$?
19517   grep -v '^ *+' conftest.er1 >conftest.err
19518   rm -f conftest.er1
19519   cat conftest.err >&5
19520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19521   (exit $ac_status); } &&
19522          { ac_try='test -z "$ac_c_werror_flag"
19523                          || test ! -s conftest.err'
19524   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19525   (eval $ac_try) 2>&5
19526   ac_status=$?
19527   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19528   (exit $ac_status); }; } &&
19529          { ac_try='test -s conftest.$ac_objext'
19530   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19531   (eval $ac_try) 2>&5
19532   ac_status=$?
19533   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19534   (exit $ac_status); }; }; then
19535   ac_hi=-1 ac_mid=-1
19536   while :; do
19537     cat >conftest.$ac_ext <<_ACEOF
19538 /* confdefs.h.  */
19539 _ACEOF
19540 cat confdefs.h >>conftest.$ac_ext
19541 cat >>conftest.$ac_ext <<_ACEOF
19542 /* end confdefs.h.  */
19543 $ac_includes_default
19544 struct { char filler; long long int field; } pgac_struct;
19545 int
19546 main ()
19547 {
19548 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19549 test_array [0] = 0
19550
19551   ;
19552   return 0;
19553 }
19554 _ACEOF
19555 rm -f conftest.$ac_objext
19556 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19557   (eval $ac_compile) 2>conftest.er1
19558   ac_status=$?
19559   grep -v '^ *+' conftest.er1 >conftest.err
19560   rm -f conftest.er1
19561   cat conftest.err >&5
19562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19563   (exit $ac_status); } &&
19564          { ac_try='test -z "$ac_c_werror_flag"
19565                          || test ! -s conftest.err'
19566   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19567   (eval $ac_try) 2>&5
19568   ac_status=$?
19569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19570   (exit $ac_status); }; } &&
19571          { ac_try='test -s conftest.$ac_objext'
19572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19573   (eval $ac_try) 2>&5
19574   ac_status=$?
19575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19576   (exit $ac_status); }; }; then
19577   ac_lo=$ac_mid; break
19578 else
19579   echo "$as_me: failed program was:" >&5
19580 sed 's/^/| /' conftest.$ac_ext >&5
19581
19582 ac_hi=`expr '(' $ac_mid ')' - 1`
19583                        if test $ac_mid -le $ac_hi; then
19584                          ac_lo= ac_hi=
19585                          break
19586                        fi
19587                        ac_mid=`expr 2 '*' $ac_mid`
19588 fi
19589 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19590   done
19591 else
19592   echo "$as_me: failed program was:" >&5
19593 sed 's/^/| /' conftest.$ac_ext >&5
19594
19595 ac_lo= ac_hi=
19596 fi
19597 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19598 fi
19599 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19600 # Binary search between lo and hi bounds.
19601 while test "x$ac_lo" != "x$ac_hi"; do
19602   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19603   cat >conftest.$ac_ext <<_ACEOF
19604 /* confdefs.h.  */
19605 _ACEOF
19606 cat confdefs.h >>conftest.$ac_ext
19607 cat >>conftest.$ac_ext <<_ACEOF
19608 /* end confdefs.h.  */
19609 $ac_includes_default
19610 struct { char filler; long long int field; } pgac_struct;
19611 int
19612 main ()
19613 {
19614 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19615 test_array [0] = 0
19616
19617   ;
19618   return 0;
19619 }
19620 _ACEOF
19621 rm -f conftest.$ac_objext
19622 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19623   (eval $ac_compile) 2>conftest.er1
19624   ac_status=$?
19625   grep -v '^ *+' conftest.er1 >conftest.err
19626   rm -f conftest.er1
19627   cat conftest.err >&5
19628   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19629   (exit $ac_status); } &&
19630          { ac_try='test -z "$ac_c_werror_flag"
19631                          || test ! -s conftest.err'
19632   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19633   (eval $ac_try) 2>&5
19634   ac_status=$?
19635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19636   (exit $ac_status); }; } &&
19637          { ac_try='test -s conftest.$ac_objext'
19638   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19639   (eval $ac_try) 2>&5
19640   ac_status=$?
19641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19642   (exit $ac_status); }; }; then
19643   ac_hi=$ac_mid
19644 else
19645   echo "$as_me: failed program was:" >&5
19646 sed 's/^/| /' conftest.$ac_ext >&5
19647
19648 ac_lo=`expr '(' $ac_mid ')' + 1`
19649 fi
19650 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19651 done
19652 case $ac_lo in
19653 ?*) pgac_cv_alignof_long_long_int=$ac_lo;;
19654 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
19655 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
19656    { (exit 1); exit 1; }; } ;;
19657 esac
19658 else
19659   if test "$cross_compiling" = yes; then
19660   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19661 See \`config.log' for more details." >&5
19662 echo "$as_me: error: cannot run test program while cross compiling
19663 See \`config.log' for more details." >&2;}
19664    { (exit 1); exit 1; }; }
19665 else
19666   cat >conftest.$ac_ext <<_ACEOF
19667 /* confdefs.h.  */
19668 _ACEOF
19669 cat confdefs.h >>conftest.$ac_ext
19670 cat >>conftest.$ac_ext <<_ACEOF
19671 /* end confdefs.h.  */
19672 $ac_includes_default
19673 struct { char filler; long long int field; } pgac_struct;
19674 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19675 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19676 #include <stdio.h>
19677 #include <stdlib.h>
19678 int
19679 main ()
19680 {
19681
19682   FILE *f = fopen ("conftest.val", "w");
19683   if (! f)
19684     exit (1);
19685   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
19686     {
19687       long i = longval ();
19688       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19689         exit (1);
19690       fprintf (f, "%ld\n", i);
19691     }
19692   else
19693     {
19694       unsigned long i = ulongval ();
19695       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19696         exit (1);
19697       fprintf (f, "%lu\n", i);
19698     }
19699   exit (ferror (f) || fclose (f) != 0);
19700
19701   ;
19702   return 0;
19703 }
19704 _ACEOF
19705 rm -f conftest$ac_exeext
19706 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19707   (eval $ac_link) 2>&5
19708   ac_status=$?
19709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19710   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19711   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19712   (eval $ac_try) 2>&5
19713   ac_status=$?
19714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19715   (exit $ac_status); }; }; then
19716   pgac_cv_alignof_long_long_int=`cat conftest.val`
19717 else
19718   echo "$as_me: program exited with status $ac_status" >&5
19719 echo "$as_me: failed program was:" >&5
19720 sed 's/^/| /' conftest.$ac_ext >&5
19721
19722 ( exit $ac_status )
19723 { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
19724 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
19725    { (exit 1); exit 1; }; }
19726 fi
19727 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19728 fi
19729 fi
19730 rm -f conftest.val
19731 else
19732   pgac_cv_alignof_long_long_int=0
19733 fi
19734 fi
19735 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long_long_int" >&5
19736 echo "${ECHO_T}$pgac_cv_alignof_long_long_int" >&6
19737 cat >>confdefs.h <<_ACEOF
19738 #define ALIGNOF_LONG_LONG_INT $pgac_cv_alignof_long_long_int
19739 _ACEOF
19740
19741
19742 fi
19743 echo "$as_me:$LINENO: checking for double" >&5
19744 echo $ECHO_N "checking for double... $ECHO_C" >&6
19745 if test "${ac_cv_type_double+set}" = set; then
19746   echo $ECHO_N "(cached) $ECHO_C" >&6
19747 else
19748   cat >conftest.$ac_ext <<_ACEOF
19749 /* confdefs.h.  */
19750 _ACEOF
19751 cat confdefs.h >>conftest.$ac_ext
19752 cat >>conftest.$ac_ext <<_ACEOF
19753 /* end confdefs.h.  */
19754 $ac_includes_default
19755 int
19756 main ()
19757 {
19758 if ((double *) 0)
19759   return 0;
19760 if (sizeof (double))
19761   return 0;
19762   ;
19763   return 0;
19764 }
19765 _ACEOF
19766 rm -f conftest.$ac_objext
19767 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19768   (eval $ac_compile) 2>conftest.er1
19769   ac_status=$?
19770   grep -v '^ *+' conftest.er1 >conftest.err
19771   rm -f conftest.er1
19772   cat conftest.err >&5
19773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19774   (exit $ac_status); } &&
19775          { ac_try='test -z "$ac_c_werror_flag"
19776                          || test ! -s conftest.err'
19777   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19778   (eval $ac_try) 2>&5
19779   ac_status=$?
19780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19781   (exit $ac_status); }; } &&
19782          { ac_try='test -s conftest.$ac_objext'
19783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19784   (eval $ac_try) 2>&5
19785   ac_status=$?
19786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19787   (exit $ac_status); }; }; then
19788   ac_cv_type_double=yes
19789 else
19790   echo "$as_me: failed program was:" >&5
19791 sed 's/^/| /' conftest.$ac_ext >&5
19792
19793 ac_cv_type_double=no
19794 fi
19795 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19796 fi
19797 echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
19798 echo "${ECHO_T}$ac_cv_type_double" >&6
19799
19800 echo "$as_me:$LINENO: checking alignment of double" >&5
19801 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6
19802 if test "${pgac_cv_alignof_double+set}" = set; then
19803   echo $ECHO_N "(cached) $ECHO_C" >&6
19804 else
19805   if test "$ac_cv_type_double" = yes; then
19806   if test "$cross_compiling" = yes; then
19807   # Depending upon the size, compute the lo and hi bounds.
19808 cat >conftest.$ac_ext <<_ACEOF
19809 /* confdefs.h.  */
19810 _ACEOF
19811 cat confdefs.h >>conftest.$ac_ext
19812 cat >>conftest.$ac_ext <<_ACEOF
19813 /* end confdefs.h.  */
19814 $ac_includes_default
19815 struct { char filler; double field; } pgac_struct;
19816 int
19817 main ()
19818 {
19819 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
19820 test_array [0] = 0
19821
19822   ;
19823   return 0;
19824 }
19825 _ACEOF
19826 rm -f conftest.$ac_objext
19827 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19828   (eval $ac_compile) 2>conftest.er1
19829   ac_status=$?
19830   grep -v '^ *+' conftest.er1 >conftest.err
19831   rm -f conftest.er1
19832   cat conftest.err >&5
19833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19834   (exit $ac_status); } &&
19835          { ac_try='test -z "$ac_c_werror_flag"
19836                          || test ! -s conftest.err'
19837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19838   (eval $ac_try) 2>&5
19839   ac_status=$?
19840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19841   (exit $ac_status); }; } &&
19842          { ac_try='test -s conftest.$ac_objext'
19843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19844   (eval $ac_try) 2>&5
19845   ac_status=$?
19846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19847   (exit $ac_status); }; }; then
19848   ac_lo=0 ac_mid=0
19849   while :; do
19850     cat >conftest.$ac_ext <<_ACEOF
19851 /* confdefs.h.  */
19852 _ACEOF
19853 cat confdefs.h >>conftest.$ac_ext
19854 cat >>conftest.$ac_ext <<_ACEOF
19855 /* end confdefs.h.  */
19856 $ac_includes_default
19857 struct { char filler; double field; } pgac_struct;
19858 int
19859 main ()
19860 {
19861 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19862 test_array [0] = 0
19863
19864   ;
19865   return 0;
19866 }
19867 _ACEOF
19868 rm -f conftest.$ac_objext
19869 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19870   (eval $ac_compile) 2>conftest.er1
19871   ac_status=$?
19872   grep -v '^ *+' conftest.er1 >conftest.err
19873   rm -f conftest.er1
19874   cat conftest.err >&5
19875   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19876   (exit $ac_status); } &&
19877          { ac_try='test -z "$ac_c_werror_flag"
19878                          || test ! -s conftest.err'
19879   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19880   (eval $ac_try) 2>&5
19881   ac_status=$?
19882   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19883   (exit $ac_status); }; } &&
19884          { ac_try='test -s conftest.$ac_objext'
19885   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19886   (eval $ac_try) 2>&5
19887   ac_status=$?
19888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19889   (exit $ac_status); }; }; then
19890   ac_hi=$ac_mid; break
19891 else
19892   echo "$as_me: failed program was:" >&5
19893 sed 's/^/| /' conftest.$ac_ext >&5
19894
19895 ac_lo=`expr $ac_mid + 1`
19896                     if test $ac_lo -le $ac_mid; then
19897                       ac_lo= ac_hi=
19898                       break
19899                     fi
19900                     ac_mid=`expr 2 '*' $ac_mid + 1`
19901 fi
19902 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19903   done
19904 else
19905   echo "$as_me: failed program was:" >&5
19906 sed 's/^/| /' conftest.$ac_ext >&5
19907
19908 cat >conftest.$ac_ext <<_ACEOF
19909 /* confdefs.h.  */
19910 _ACEOF
19911 cat confdefs.h >>conftest.$ac_ext
19912 cat >>conftest.$ac_ext <<_ACEOF
19913 /* end confdefs.h.  */
19914 $ac_includes_default
19915 struct { char filler; double field; } pgac_struct;
19916 int
19917 main ()
19918 {
19919 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19920 test_array [0] = 0
19921
19922   ;
19923   return 0;
19924 }
19925 _ACEOF
19926 rm -f conftest.$ac_objext
19927 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19928   (eval $ac_compile) 2>conftest.er1
19929   ac_status=$?
19930   grep -v '^ *+' conftest.er1 >conftest.err
19931   rm -f conftest.er1
19932   cat conftest.err >&5
19933   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19934   (exit $ac_status); } &&
19935          { ac_try='test -z "$ac_c_werror_flag"
19936                          || test ! -s conftest.err'
19937   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19938   (eval $ac_try) 2>&5
19939   ac_status=$?
19940   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19941   (exit $ac_status); }; } &&
19942          { ac_try='test -s conftest.$ac_objext'
19943   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19944   (eval $ac_try) 2>&5
19945   ac_status=$?
19946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19947   (exit $ac_status); }; }; then
19948   ac_hi=-1 ac_mid=-1
19949   while :; do
19950     cat >conftest.$ac_ext <<_ACEOF
19951 /* confdefs.h.  */
19952 _ACEOF
19953 cat confdefs.h >>conftest.$ac_ext
19954 cat >>conftest.$ac_ext <<_ACEOF
19955 /* end confdefs.h.  */
19956 $ac_includes_default
19957 struct { char filler; double field; } pgac_struct;
19958 int
19959 main ()
19960 {
19961 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19962 test_array [0] = 0
19963
19964   ;
19965   return 0;
19966 }
19967 _ACEOF
19968 rm -f conftest.$ac_objext
19969 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19970   (eval $ac_compile) 2>conftest.er1
19971   ac_status=$?
19972   grep -v '^ *+' conftest.er1 >conftest.err
19973   rm -f conftest.er1
19974   cat conftest.err >&5
19975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19976   (exit $ac_status); } &&
19977          { ac_try='test -z "$ac_c_werror_flag"
19978                          || test ! -s conftest.err'
19979   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19980   (eval $ac_try) 2>&5
19981   ac_status=$?
19982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19983   (exit $ac_status); }; } &&
19984          { ac_try='test -s conftest.$ac_objext'
19985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19986   (eval $ac_try) 2>&5
19987   ac_status=$?
19988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19989   (exit $ac_status); }; }; then
19990   ac_lo=$ac_mid; break
19991 else
19992   echo "$as_me: failed program was:" >&5
19993 sed 's/^/| /' conftest.$ac_ext >&5
19994
19995 ac_hi=`expr '(' $ac_mid ')' - 1`
19996                        if test $ac_mid -le $ac_hi; then
19997                          ac_lo= ac_hi=
19998                          break
19999                        fi
20000                        ac_mid=`expr 2 '*' $ac_mid`
20001 fi
20002 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20003   done
20004 else
20005   echo "$as_me: failed program was:" >&5
20006 sed 's/^/| /' conftest.$ac_ext >&5
20007
20008 ac_lo= ac_hi=
20009 fi
20010 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20011 fi
20012 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20013 # Binary search between lo and hi bounds.
20014 while test "x$ac_lo" != "x$ac_hi"; do
20015   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20016   cat >conftest.$ac_ext <<_ACEOF
20017 /* confdefs.h.  */
20018 _ACEOF
20019 cat confdefs.h >>conftest.$ac_ext
20020 cat >>conftest.$ac_ext <<_ACEOF
20021 /* end confdefs.h.  */
20022 $ac_includes_default
20023 struct { char filler; double field; } pgac_struct;
20024 int
20025 main ()
20026 {
20027 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
20028 test_array [0] = 0
20029
20030   ;
20031   return 0;
20032 }
20033 _ACEOF
20034 rm -f conftest.$ac_objext
20035 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20036   (eval $ac_compile) 2>conftest.er1
20037   ac_status=$?
20038   grep -v '^ *+' conftest.er1 >conftest.err
20039   rm -f conftest.er1
20040   cat conftest.err >&5
20041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20042   (exit $ac_status); } &&
20043          { ac_try='test -z "$ac_c_werror_flag"
20044                          || test ! -s conftest.err'
20045   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20046   (eval $ac_try) 2>&5
20047   ac_status=$?
20048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20049   (exit $ac_status); }; } &&
20050          { ac_try='test -s conftest.$ac_objext'
20051   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20052   (eval $ac_try) 2>&5
20053   ac_status=$?
20054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20055   (exit $ac_status); }; }; then
20056   ac_hi=$ac_mid
20057 else
20058   echo "$as_me: failed program was:" >&5
20059 sed 's/^/| /' conftest.$ac_ext >&5
20060
20061 ac_lo=`expr '(' $ac_mid ')' + 1`
20062 fi
20063 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20064 done
20065 case $ac_lo in
20066 ?*) pgac_cv_alignof_double=$ac_lo;;
20067 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
20068 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
20069    { (exit 1); exit 1; }; } ;;
20070 esac
20071 else
20072   if test "$cross_compiling" = yes; then
20073   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
20074 See \`config.log' for more details." >&5
20075 echo "$as_me: error: cannot run test program while cross compiling
20076 See \`config.log' for more details." >&2;}
20077    { (exit 1); exit 1; }; }
20078 else
20079   cat >conftest.$ac_ext <<_ACEOF
20080 /* confdefs.h.  */
20081 _ACEOF
20082 cat confdefs.h >>conftest.$ac_ext
20083 cat >>conftest.$ac_ext <<_ACEOF
20084 /* end confdefs.h.  */
20085 $ac_includes_default
20086 struct { char filler; double field; } pgac_struct;
20087 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20088 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20089 #include <stdio.h>
20090 #include <stdlib.h>
20091 int
20092 main ()
20093 {
20094
20095   FILE *f = fopen ("conftest.val", "w");
20096   if (! f)
20097     exit (1);
20098   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
20099     {
20100       long i = longval ();
20101       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20102         exit (1);
20103       fprintf (f, "%ld\n", i);
20104     }
20105   else
20106     {
20107       unsigned long i = ulongval ();
20108       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20109         exit (1);
20110       fprintf (f, "%lu\n", i);
20111     }
20112   exit (ferror (f) || fclose (f) != 0);
20113
20114   ;
20115   return 0;
20116 }
20117 _ACEOF
20118 rm -f conftest$ac_exeext
20119 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20120   (eval $ac_link) 2>&5
20121   ac_status=$?
20122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20123   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20124   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20125   (eval $ac_try) 2>&5
20126   ac_status=$?
20127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20128   (exit $ac_status); }; }; then
20129   pgac_cv_alignof_double=`cat conftest.val`
20130 else
20131   echo "$as_me: program exited with status $ac_status" >&5
20132 echo "$as_me: failed program was:" >&5
20133 sed 's/^/| /' conftest.$ac_ext >&5
20134
20135 ( exit $ac_status )
20136 { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
20137 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
20138    { (exit 1); exit 1; }; }
20139 fi
20140 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20141 fi
20142 fi
20143 rm -f conftest.val
20144 else
20145   pgac_cv_alignof_double=0
20146 fi
20147 fi
20148 echo "$as_me:$LINENO: result: $pgac_cv_alignof_double" >&5
20149 echo "${ECHO_T}$pgac_cv_alignof_double" >&6
20150 cat >>confdefs.h <<_ACEOF
20151 #define ALIGNOF_DOUBLE $pgac_cv_alignof_double
20152 _ACEOF
20153
20154
20155
20156 # Compute maximum alignment of any basic type.
20157 # We assume long's alignment is at least as strong as char, short, or int;
20158 # but we must check long long (if it exists) and double.
20159
20160 MAX_ALIGNOF=$pgac_cv_alignof_long
20161 if test $MAX_ALIGNOF -lt $pgac_cv_alignof_double ; then
20162   MAX_ALIGNOF=$pgac_cv_alignof_double
20163 fi
20164 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $pgac_cv_alignof_long_long_int ; then
20165   MAX_ALIGNOF="$pgac_cv_alignof_long_long_int"
20166 fi
20167
20168 cat >>confdefs.h <<_ACEOF
20169 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
20170 _ACEOF
20171
20172
20173
20174 # Some platforms predefine the types int8, int16, etc.  Only check
20175 # a (hopefully) representative subset.
20176 echo "$as_me:$LINENO: checking for int8" >&5
20177 echo $ECHO_N "checking for int8... $ECHO_C" >&6
20178 if test "${ac_cv_type_int8+set}" = set; then
20179   echo $ECHO_N "(cached) $ECHO_C" >&6
20180 else
20181   cat >conftest.$ac_ext <<_ACEOF
20182 /* confdefs.h.  */
20183 _ACEOF
20184 cat confdefs.h >>conftest.$ac_ext
20185 cat >>conftest.$ac_ext <<_ACEOF
20186 /* end confdefs.h.  */
20187 #include <stdio.h>
20188 #ifdef HAVE_SUPPORTDEFS_H
20189 #include <SupportDefs.h>
20190 #endif
20191
20192 int
20193 main ()
20194 {
20195 if ((int8 *) 0)
20196   return 0;
20197 if (sizeof (int8))
20198   return 0;
20199   ;
20200   return 0;
20201 }
20202 _ACEOF
20203 rm -f conftest.$ac_objext
20204 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20205   (eval $ac_compile) 2>conftest.er1
20206   ac_status=$?
20207   grep -v '^ *+' conftest.er1 >conftest.err
20208   rm -f conftest.er1
20209   cat conftest.err >&5
20210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20211   (exit $ac_status); } &&
20212          { ac_try='test -z "$ac_c_werror_flag"
20213                          || test ! -s conftest.err'
20214   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20215   (eval $ac_try) 2>&5
20216   ac_status=$?
20217   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20218   (exit $ac_status); }; } &&
20219          { ac_try='test -s conftest.$ac_objext'
20220   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20221   (eval $ac_try) 2>&5
20222   ac_status=$?
20223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20224   (exit $ac_status); }; }; then
20225   ac_cv_type_int8=yes
20226 else
20227   echo "$as_me: failed program was:" >&5
20228 sed 's/^/| /' conftest.$ac_ext >&5
20229
20230 ac_cv_type_int8=no
20231 fi
20232 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20233 fi
20234 echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
20235 echo "${ECHO_T}$ac_cv_type_int8" >&6
20236 if test $ac_cv_type_int8 = yes; then
20237
20238 cat >>confdefs.h <<_ACEOF
20239 #define HAVE_INT8 1
20240 _ACEOF
20241
20242
20243 fi
20244 echo "$as_me:$LINENO: checking for uint8" >&5
20245 echo $ECHO_N "checking for uint8... $ECHO_C" >&6
20246 if test "${ac_cv_type_uint8+set}" = set; then
20247   echo $ECHO_N "(cached) $ECHO_C" >&6
20248 else
20249   cat >conftest.$ac_ext <<_ACEOF
20250 /* confdefs.h.  */
20251 _ACEOF
20252 cat confdefs.h >>conftest.$ac_ext
20253 cat >>conftest.$ac_ext <<_ACEOF
20254 /* end confdefs.h.  */
20255 #include <stdio.h>
20256 #ifdef HAVE_SUPPORTDEFS_H
20257 #include <SupportDefs.h>
20258 #endif
20259
20260 int
20261 main ()
20262 {
20263 if ((uint8 *) 0)
20264   return 0;
20265 if (sizeof (uint8))
20266   return 0;
20267   ;
20268   return 0;
20269 }
20270 _ACEOF
20271 rm -f conftest.$ac_objext
20272 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20273   (eval $ac_compile) 2>conftest.er1
20274   ac_status=$?
20275   grep -v '^ *+' conftest.er1 >conftest.err
20276   rm -f conftest.er1
20277   cat conftest.err >&5
20278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20279   (exit $ac_status); } &&
20280          { ac_try='test -z "$ac_c_werror_flag"
20281                          || test ! -s conftest.err'
20282   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20283   (eval $ac_try) 2>&5
20284   ac_status=$?
20285   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20286   (exit $ac_status); }; } &&
20287          { ac_try='test -s conftest.$ac_objext'
20288   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20289   (eval $ac_try) 2>&5
20290   ac_status=$?
20291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20292   (exit $ac_status); }; }; then
20293   ac_cv_type_uint8=yes
20294 else
20295   echo "$as_me: failed program was:" >&5
20296 sed 's/^/| /' conftest.$ac_ext >&5
20297
20298 ac_cv_type_uint8=no
20299 fi
20300 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20301 fi
20302 echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
20303 echo "${ECHO_T}$ac_cv_type_uint8" >&6
20304 if test $ac_cv_type_uint8 = yes; then
20305
20306 cat >>confdefs.h <<_ACEOF
20307 #define HAVE_UINT8 1
20308 _ACEOF
20309
20310
20311 fi
20312 echo "$as_me:$LINENO: checking for int64" >&5
20313 echo $ECHO_N "checking for int64... $ECHO_C" >&6
20314 if test "${ac_cv_type_int64+set}" = set; then
20315   echo $ECHO_N "(cached) $ECHO_C" >&6
20316 else
20317   cat >conftest.$ac_ext <<_ACEOF
20318 /* confdefs.h.  */
20319 _ACEOF
20320 cat confdefs.h >>conftest.$ac_ext
20321 cat >>conftest.$ac_ext <<_ACEOF
20322 /* end confdefs.h.  */
20323 #include <stdio.h>
20324 #ifdef HAVE_SUPPORTDEFS_H
20325 #include <SupportDefs.h>
20326 #endif
20327
20328 int
20329 main ()
20330 {
20331 if ((int64 *) 0)
20332   return 0;
20333 if (sizeof (int64))
20334   return 0;
20335   ;
20336   return 0;
20337 }
20338 _ACEOF
20339 rm -f conftest.$ac_objext
20340 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20341   (eval $ac_compile) 2>conftest.er1
20342   ac_status=$?
20343   grep -v '^ *+' conftest.er1 >conftest.err
20344   rm -f conftest.er1
20345   cat conftest.err >&5
20346   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20347   (exit $ac_status); } &&
20348          { ac_try='test -z "$ac_c_werror_flag"
20349                          || test ! -s conftest.err'
20350   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20351   (eval $ac_try) 2>&5
20352   ac_status=$?
20353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20354   (exit $ac_status); }; } &&
20355          { ac_try='test -s conftest.$ac_objext'
20356   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20357   (eval $ac_try) 2>&5
20358   ac_status=$?
20359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20360   (exit $ac_status); }; }; then
20361   ac_cv_type_int64=yes
20362 else
20363   echo "$as_me: failed program was:" >&5
20364 sed 's/^/| /' conftest.$ac_ext >&5
20365
20366 ac_cv_type_int64=no
20367 fi
20368 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20369 fi
20370 echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
20371 echo "${ECHO_T}$ac_cv_type_int64" >&6
20372 if test $ac_cv_type_int64 = yes; then
20373
20374 cat >>confdefs.h <<_ACEOF
20375 #define HAVE_INT64 1
20376 _ACEOF
20377
20378
20379 fi
20380 echo "$as_me:$LINENO: checking for uint64" >&5
20381 echo $ECHO_N "checking for uint64... $ECHO_C" >&6
20382 if test "${ac_cv_type_uint64+set}" = set; then
20383   echo $ECHO_N "(cached) $ECHO_C" >&6
20384 else
20385   cat >conftest.$ac_ext <<_ACEOF
20386 /* confdefs.h.  */
20387 _ACEOF
20388 cat confdefs.h >>conftest.$ac_ext
20389 cat >>conftest.$ac_ext <<_ACEOF
20390 /* end confdefs.h.  */
20391 #include <stdio.h>
20392 #ifdef HAVE_SUPPORTDEFS_H
20393 #include <SupportDefs.h>
20394 #endif
20395
20396 int
20397 main ()
20398 {
20399 if ((uint64 *) 0)
20400   return 0;
20401 if (sizeof (uint64))
20402   return 0;
20403   ;
20404   return 0;
20405 }
20406 _ACEOF
20407 rm -f conftest.$ac_objext
20408 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20409   (eval $ac_compile) 2>conftest.er1
20410   ac_status=$?
20411   grep -v '^ *+' conftest.er1 >conftest.err
20412   rm -f conftest.er1
20413   cat conftest.err >&5
20414   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20415   (exit $ac_status); } &&
20416          { ac_try='test -z "$ac_c_werror_flag"
20417                          || test ! -s conftest.err'
20418   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20419   (eval $ac_try) 2>&5
20420   ac_status=$?
20421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20422   (exit $ac_status); }; } &&
20423          { ac_try='test -s conftest.$ac_objext'
20424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20425   (eval $ac_try) 2>&5
20426   ac_status=$?
20427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20428   (exit $ac_status); }; }; then
20429   ac_cv_type_uint64=yes
20430 else
20431   echo "$as_me: failed program was:" >&5
20432 sed 's/^/| /' conftest.$ac_ext >&5
20433
20434 ac_cv_type_uint64=no
20435 fi
20436 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20437 fi
20438 echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
20439 echo "${ECHO_T}$ac_cv_type_uint64" >&6
20440 if test $ac_cv_type_uint64 = yes; then
20441
20442 cat >>confdefs.h <<_ACEOF
20443 #define HAVE_UINT64 1
20444 _ACEOF
20445
20446
20447 fi
20448
20449
20450 # We also check for sig_atomic_t, which *should* be defined per ANSI
20451 # C, but is missing on some old platforms.
20452 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
20453 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
20454 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
20455   echo $ECHO_N "(cached) $ECHO_C" >&6
20456 else
20457   cat >conftest.$ac_ext <<_ACEOF
20458 /* confdefs.h.  */
20459 _ACEOF
20460 cat confdefs.h >>conftest.$ac_ext
20461 cat >>conftest.$ac_ext <<_ACEOF
20462 /* end confdefs.h.  */
20463 #include <signal.h>
20464
20465 int
20466 main ()
20467 {
20468 if ((sig_atomic_t *) 0)
20469   return 0;
20470 if (sizeof (sig_atomic_t))
20471   return 0;
20472   ;
20473   return 0;
20474 }
20475 _ACEOF
20476 rm -f conftest.$ac_objext
20477 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20478   (eval $ac_compile) 2>conftest.er1
20479   ac_status=$?
20480   grep -v '^ *+' conftest.er1 >conftest.err
20481   rm -f conftest.er1
20482   cat conftest.err >&5
20483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20484   (exit $ac_status); } &&
20485          { ac_try='test -z "$ac_c_werror_flag"
20486                          || test ! -s conftest.err'
20487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20488   (eval $ac_try) 2>&5
20489   ac_status=$?
20490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20491   (exit $ac_status); }; } &&
20492          { ac_try='test -s conftest.$ac_objext'
20493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20494   (eval $ac_try) 2>&5
20495   ac_status=$?
20496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20497   (exit $ac_status); }; }; then
20498   ac_cv_type_sig_atomic_t=yes
20499 else
20500   echo "$as_me: failed program was:" >&5
20501 sed 's/^/| /' conftest.$ac_ext >&5
20502
20503 ac_cv_type_sig_atomic_t=no
20504 fi
20505 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20506 fi
20507 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
20508 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
20509 if test $ac_cv_type_sig_atomic_t = yes; then
20510
20511 cat >>confdefs.h <<_ACEOF
20512 #define HAVE_SIG_ATOMIC_T 1
20513 _ACEOF
20514
20515
20516 fi
20517
20518
20519
20520 if test x"$template" != x"win32"
20521 then
20522 echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
20523 echo $ECHO_N "checking for POSIX signal interface... $ECHO_C" >&6
20524 if test "${pgac_cv_func_posix_signals+set}" = set; then
20525   echo $ECHO_N "(cached) $ECHO_C" >&6
20526 else
20527   cat >conftest.$ac_ext <<_ACEOF
20528 /* confdefs.h.  */
20529 _ACEOF
20530 cat confdefs.h >>conftest.$ac_ext
20531 cat >>conftest.$ac_ext <<_ACEOF
20532 /* end confdefs.h.  */
20533 #include <signal.h>
20534
20535 int
20536 main ()
20537 {
20538 struct sigaction act, oact;
20539 sigemptyset(&act.sa_mask);
20540 act.sa_flags = SA_RESTART;
20541 sigaction(0, &act, &oact);
20542   ;
20543   return 0;
20544 }
20545 _ACEOF
20546 rm -f conftest.$ac_objext conftest$ac_exeext
20547 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20548   (eval $ac_link) 2>conftest.er1
20549   ac_status=$?
20550   grep -v '^ *+' conftest.er1 >conftest.err
20551   rm -f conftest.er1
20552   cat conftest.err >&5
20553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20554   (exit $ac_status); } &&
20555          { ac_try='test -z "$ac_c_werror_flag"
20556                          || test ! -s conftest.err'
20557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20558   (eval $ac_try) 2>&5
20559   ac_status=$?
20560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20561   (exit $ac_status); }; } &&
20562          { ac_try='test -s conftest$ac_exeext'
20563   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20564   (eval $ac_try) 2>&5
20565   ac_status=$?
20566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20567   (exit $ac_status); }; }; then
20568   pgac_cv_func_posix_signals=yes
20569 else
20570   echo "$as_me: failed program was:" >&5
20571 sed 's/^/| /' conftest.$ac_ext >&5
20572
20573 pgac_cv_func_posix_signals=no
20574 fi
20575 rm -f conftest.err conftest.$ac_objext \
20576       conftest$ac_exeext conftest.$ac_ext
20577 fi
20578 echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
20579 echo "${ECHO_T}$pgac_cv_func_posix_signals" >&6
20580 if test x"$pgac_cv_func_posix_signals" = xyes ; then
20581
20582 cat >>confdefs.h <<\_ACEOF
20583 #define HAVE_POSIX_SIGNALS
20584 _ACEOF
20585
20586 fi
20587 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
20588
20589 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
20590   { { echo "$as_me:$LINENO: error:
20591 *** Thread-safety requires POSIX signals, which are not supported by your
20592 *** operating system.
20593 " >&5
20594 echo "$as_me: error:
20595 *** Thread-safety requires POSIX signals, which are not supported by your
20596 *** operating system.
20597 " >&2;}
20598    { (exit 1); exit 1; }; }
20599 fi
20600 fi
20601
20602 if test $ac_cv_func_fseeko = yes; then
20603 # Check whether --enable-largefile or --disable-largefile was given.
20604 if test "${enable_largefile+set}" = set; then
20605   enableval="$enable_largefile"
20606
20607 fi;
20608 if test "$enable_largefile" != no; then
20609
20610   echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
20611 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
20612 if test "${ac_cv_sys_largefile_CC+set}" = set; then
20613   echo $ECHO_N "(cached) $ECHO_C" >&6
20614 else
20615   ac_cv_sys_largefile_CC=no
20616      if test "$GCC" != yes; then
20617        ac_save_CC=$CC
20618        while :; do
20619          # IRIX 6.2 and later do not support large files by default,
20620          # so use the C compiler's -n32 option if that helps.
20621          cat >conftest.$ac_ext <<_ACEOF
20622 /* confdefs.h.  */
20623 _ACEOF
20624 cat confdefs.h >>conftest.$ac_ext
20625 cat >>conftest.$ac_ext <<_ACEOF
20626 /* end confdefs.h.  */
20627 #include <sys/types.h>
20628  /* Check that off_t can represent 2**63 - 1 correctly.
20629     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20630     since some C++ compilers masquerading as C compilers
20631     incorrectly reject 9223372036854775807.  */
20632 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20633   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20634                        && LARGE_OFF_T % 2147483647 == 1)
20635                       ? 1 : -1];
20636 int
20637 main ()
20638 {
20639
20640   ;
20641   return 0;
20642 }
20643 _ACEOF
20644          rm -f conftest.$ac_objext
20645 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20646   (eval $ac_compile) 2>conftest.er1
20647   ac_status=$?
20648   grep -v '^ *+' conftest.er1 >conftest.err
20649   rm -f conftest.er1
20650   cat conftest.err >&5
20651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20652   (exit $ac_status); } &&
20653          { ac_try='test -z "$ac_c_werror_flag"
20654                          || test ! -s conftest.err'
20655   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20656   (eval $ac_try) 2>&5
20657   ac_status=$?
20658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20659   (exit $ac_status); }; } &&
20660          { ac_try='test -s conftest.$ac_objext'
20661   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20662   (eval $ac_try) 2>&5
20663   ac_status=$?
20664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20665   (exit $ac_status); }; }; then
20666   break
20667 else
20668   echo "$as_me: failed program was:" >&5
20669 sed 's/^/| /' conftest.$ac_ext >&5
20670
20671 fi
20672 rm -f conftest.err conftest.$ac_objext
20673          CC="$CC -n32"
20674          rm -f conftest.$ac_objext
20675 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20676   (eval $ac_compile) 2>conftest.er1
20677   ac_status=$?
20678   grep -v '^ *+' conftest.er1 >conftest.err
20679   rm -f conftest.er1
20680   cat conftest.err >&5
20681   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20682   (exit $ac_status); } &&
20683          { ac_try='test -z "$ac_c_werror_flag"
20684                          || test ! -s conftest.err'
20685   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20686   (eval $ac_try) 2>&5
20687   ac_status=$?
20688   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20689   (exit $ac_status); }; } &&
20690          { ac_try='test -s conftest.$ac_objext'
20691   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20692   (eval $ac_try) 2>&5
20693   ac_status=$?
20694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20695   (exit $ac_status); }; }; then
20696   ac_cv_sys_largefile_CC=' -n32'; break
20697 else
20698   echo "$as_me: failed program was:" >&5
20699 sed 's/^/| /' conftest.$ac_ext >&5
20700
20701 fi
20702 rm -f conftest.err conftest.$ac_objext
20703          break
20704        done
20705        CC=$ac_save_CC
20706        rm -f conftest.$ac_ext
20707     fi
20708 fi
20709 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
20710 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
20711   if test "$ac_cv_sys_largefile_CC" != no; then
20712     CC=$CC$ac_cv_sys_largefile_CC
20713   fi
20714
20715   echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
20716 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
20717 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
20718   echo $ECHO_N "(cached) $ECHO_C" >&6
20719 else
20720   while :; do
20721   ac_cv_sys_file_offset_bits=no
20722   cat >conftest.$ac_ext <<_ACEOF
20723 /* confdefs.h.  */
20724 _ACEOF
20725 cat confdefs.h >>conftest.$ac_ext
20726 cat >>conftest.$ac_ext <<_ACEOF
20727 /* end confdefs.h.  */
20728 #include <sys/types.h>
20729  /* Check that off_t can represent 2**63 - 1 correctly.
20730     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20731     since some C++ compilers masquerading as C compilers
20732     incorrectly reject 9223372036854775807.  */
20733 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20734   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20735                        && LARGE_OFF_T % 2147483647 == 1)
20736                       ? 1 : -1];
20737 int
20738 main ()
20739 {
20740
20741   ;
20742   return 0;
20743 }
20744 _ACEOF
20745 rm -f conftest.$ac_objext
20746 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20747   (eval $ac_compile) 2>conftest.er1
20748   ac_status=$?
20749   grep -v '^ *+' conftest.er1 >conftest.err
20750   rm -f conftest.er1
20751   cat conftest.err >&5
20752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20753   (exit $ac_status); } &&
20754          { ac_try='test -z "$ac_c_werror_flag"
20755                          || test ! -s conftest.err'
20756   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20757   (eval $ac_try) 2>&5
20758   ac_status=$?
20759   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20760   (exit $ac_status); }; } &&
20761          { ac_try='test -s conftest.$ac_objext'
20762   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20763   (eval $ac_try) 2>&5
20764   ac_status=$?
20765   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20766   (exit $ac_status); }; }; then
20767   break
20768 else
20769   echo "$as_me: failed program was:" >&5
20770 sed 's/^/| /' conftest.$ac_ext >&5
20771
20772 fi
20773 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20774   cat >conftest.$ac_ext <<_ACEOF
20775 /* confdefs.h.  */
20776 _ACEOF
20777 cat confdefs.h >>conftest.$ac_ext
20778 cat >>conftest.$ac_ext <<_ACEOF
20779 /* end confdefs.h.  */
20780 #define _FILE_OFFSET_BITS 64
20781 #include <sys/types.h>
20782  /* Check that off_t can represent 2**63 - 1 correctly.
20783     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20784     since some C++ compilers masquerading as C compilers
20785     incorrectly reject 9223372036854775807.  */
20786 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20787   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20788                        && LARGE_OFF_T % 2147483647 == 1)
20789                       ? 1 : -1];
20790 int
20791 main ()
20792 {
20793
20794   ;
20795   return 0;
20796 }
20797 _ACEOF
20798 rm -f conftest.$ac_objext
20799 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20800   (eval $ac_compile) 2>conftest.er1
20801   ac_status=$?
20802   grep -v '^ *+' conftest.er1 >conftest.err
20803   rm -f conftest.er1
20804   cat conftest.err >&5
20805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20806   (exit $ac_status); } &&
20807          { ac_try='test -z "$ac_c_werror_flag"
20808                          || test ! -s conftest.err'
20809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20810   (eval $ac_try) 2>&5
20811   ac_status=$?
20812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20813   (exit $ac_status); }; } &&
20814          { ac_try='test -s conftest.$ac_objext'
20815   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20816   (eval $ac_try) 2>&5
20817   ac_status=$?
20818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20819   (exit $ac_status); }; }; then
20820   ac_cv_sys_file_offset_bits=64; break
20821 else
20822   echo "$as_me: failed program was:" >&5
20823 sed 's/^/| /' conftest.$ac_ext >&5
20824
20825 fi
20826 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20827   break
20828 done
20829 fi
20830 echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
20831 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
20832 if test "$ac_cv_sys_file_offset_bits" != no; then
20833
20834 cat >>confdefs.h <<_ACEOF
20835 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
20836 _ACEOF
20837
20838 fi
20839 rm -f conftest*
20840   echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
20841 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
20842 if test "${ac_cv_sys_large_files+set}" = set; then
20843   echo $ECHO_N "(cached) $ECHO_C" >&6
20844 else
20845   while :; do
20846   ac_cv_sys_large_files=no
20847   cat >conftest.$ac_ext <<_ACEOF
20848 /* confdefs.h.  */
20849 _ACEOF
20850 cat confdefs.h >>conftest.$ac_ext
20851 cat >>conftest.$ac_ext <<_ACEOF
20852 /* end confdefs.h.  */
20853 #include <sys/types.h>
20854  /* Check that off_t can represent 2**63 - 1 correctly.
20855     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20856     since some C++ compilers masquerading as C compilers
20857     incorrectly reject 9223372036854775807.  */
20858 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20859   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20860                        && LARGE_OFF_T % 2147483647 == 1)
20861                       ? 1 : -1];
20862 int
20863 main ()
20864 {
20865
20866   ;
20867   return 0;
20868 }
20869 _ACEOF
20870 rm -f conftest.$ac_objext
20871 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20872   (eval $ac_compile) 2>conftest.er1
20873   ac_status=$?
20874   grep -v '^ *+' conftest.er1 >conftest.err
20875   rm -f conftest.er1
20876   cat conftest.err >&5
20877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20878   (exit $ac_status); } &&
20879          { ac_try='test -z "$ac_c_werror_flag"
20880                          || test ! -s conftest.err'
20881   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20882   (eval $ac_try) 2>&5
20883   ac_status=$?
20884   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20885   (exit $ac_status); }; } &&
20886          { ac_try='test -s conftest.$ac_objext'
20887   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20888   (eval $ac_try) 2>&5
20889   ac_status=$?
20890   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20891   (exit $ac_status); }; }; then
20892   break
20893 else
20894   echo "$as_me: failed program was:" >&5
20895 sed 's/^/| /' conftest.$ac_ext >&5
20896
20897 fi
20898 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20899   cat >conftest.$ac_ext <<_ACEOF
20900 /* confdefs.h.  */
20901 _ACEOF
20902 cat confdefs.h >>conftest.$ac_ext
20903 cat >>conftest.$ac_ext <<_ACEOF
20904 /* end confdefs.h.  */
20905 #define _LARGE_FILES 1
20906 #include <sys/types.h>
20907  /* Check that off_t can represent 2**63 - 1 correctly.
20908     We can't simply define LARGE_OFF_T to be 9223372036854775807,
20909     since some C++ compilers masquerading as C compilers
20910     incorrectly reject 9223372036854775807.  */
20911 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
20912   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
20913                        && LARGE_OFF_T % 2147483647 == 1)
20914                       ? 1 : -1];
20915 int
20916 main ()
20917 {
20918
20919   ;
20920   return 0;
20921 }
20922 _ACEOF
20923 rm -f conftest.$ac_objext
20924 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20925   (eval $ac_compile) 2>conftest.er1
20926   ac_status=$?
20927   grep -v '^ *+' conftest.er1 >conftest.err
20928   rm -f conftest.er1
20929   cat conftest.err >&5
20930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20931   (exit $ac_status); } &&
20932          { ac_try='test -z "$ac_c_werror_flag"
20933                          || test ! -s conftest.err'
20934   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20935   (eval $ac_try) 2>&5
20936   ac_status=$?
20937   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20938   (exit $ac_status); }; } &&
20939          { ac_try='test -s conftest.$ac_objext'
20940   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20941   (eval $ac_try) 2>&5
20942   ac_status=$?
20943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20944   (exit $ac_status); }; }; then
20945   ac_cv_sys_large_files=1; break
20946 else
20947   echo "$as_me: failed program was:" >&5
20948 sed 's/^/| /' conftest.$ac_ext >&5
20949
20950 fi
20951 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20952   break
20953 done
20954 fi
20955 echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
20956 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
20957 if test "$ac_cv_sys_large_files" != no; then
20958
20959 cat >>confdefs.h <<_ACEOF
20960 #define _LARGE_FILES $ac_cv_sys_large_files
20961 _ACEOF
20962
20963 fi
20964 rm -f conftest*
20965 fi
20966
20967 fi
20968
20969 # SunOS doesn't handle negative byte comparisons properly with +/- return
20970 echo "$as_me:$LINENO: checking for working memcmp" >&5
20971 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
20972 if test "${ac_cv_func_memcmp_working+set}" = set; then
20973   echo $ECHO_N "(cached) $ECHO_C" >&6
20974 else
20975   if test "$cross_compiling" = yes; then
20976   ac_cv_func_memcmp_working=no
20977 else
20978   cat >conftest.$ac_ext <<_ACEOF
20979 /* confdefs.h.  */
20980 _ACEOF
20981 cat confdefs.h >>conftest.$ac_ext
20982 cat >>conftest.$ac_ext <<_ACEOF
20983 /* end confdefs.h.  */
20984 $ac_includes_default
20985 int
20986 main ()
20987 {
20988
20989   /* Some versions of memcmp are not 8-bit clean.  */
20990   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
20991   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
20992     exit (1);
20993
20994   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
20995      or more and with at least one buffer not starting on a 4-byte boundary.
20996      William Lewis provided this test program.   */
20997   {
20998     char foo[21];
20999     char bar[21];
21000     int i;
21001     for (i = 0; i < 4; i++)
21002       {
21003         char *a = foo + i;
21004         char *b = bar + i;
21005         strcpy (a, "--------01111111");
21006         strcpy (b, "--------10000000");
21007         if (memcmp (a, b, 16) >= 0)
21008           exit (1);
21009       }
21010     exit (0);
21011   }
21012
21013   ;
21014   return 0;
21015 }
21016 _ACEOF
21017 rm -f conftest$ac_exeext
21018 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21019   (eval $ac_link) 2>&5
21020   ac_status=$?
21021   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21022   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21023   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21024   (eval $ac_try) 2>&5
21025   ac_status=$?
21026   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21027   (exit $ac_status); }; }; then
21028   ac_cv_func_memcmp_working=yes
21029 else
21030   echo "$as_me: program exited with status $ac_status" >&5
21031 echo "$as_me: failed program was:" >&5
21032 sed 's/^/| /' conftest.$ac_ext >&5
21033
21034 ( exit $ac_status )
21035 ac_cv_func_memcmp_working=no
21036 fi
21037 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21038 fi
21039 fi
21040 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
21041 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
21042 test $ac_cv_func_memcmp_working = no && case $LIBOBJS in
21043     "memcmp.$ac_objext"   | \
21044   *" memcmp.$ac_objext"   | \
21045     "memcmp.$ac_objext "* | \
21046   *" memcmp.$ac_objext "* ) ;;
21047   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" ;;
21048 esac
21049
21050
21051
21052
21053 # Select semaphore implementation type.
21054 if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
21055
21056 cat >>confdefs.h <<\_ACEOF
21057 #define USE_NAMED_POSIX_SEMAPHORES 1
21058 _ACEOF
21059
21060   SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21061 else
21062   if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
21063
21064 cat >>confdefs.h <<\_ACEOF
21065 #define USE_UNNAMED_POSIX_SEMAPHORES 1
21066 _ACEOF
21067
21068     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21069   else
21070
21071 cat >>confdefs.h <<\_ACEOF
21072 #define USE_SYSV_SEMAPHORES 1
21073 _ACEOF
21074
21075     SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
21076   fi
21077 fi
21078
21079
21080 # Select shared-memory implementation type.
21081
21082 cat >>confdefs.h <<\_ACEOF
21083 #define USE_SYSV_SHARED_MEMORY 1
21084 _ACEOF
21085
21086 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
21087
21088
21089 # If not set in template file, set bytes to use libc memset()
21090 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
21091   MEMSET_LOOP_LIMIT=1024
21092 fi
21093
21094 cat >>confdefs.h <<_ACEOF
21095 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
21096 _ACEOF
21097
21098
21099
21100 if test "$enable_nls" = yes ; then
21101
21102   echo "$as_me:$LINENO: checking for library containing gettext" >&5
21103 echo $ECHO_N "checking for library containing gettext... $ECHO_C" >&6
21104 if test "${ac_cv_search_gettext+set}" = set; then
21105   echo $ECHO_N "(cached) $ECHO_C" >&6
21106 else
21107   ac_func_search_save_LIBS=$LIBS
21108 ac_cv_search_gettext=no
21109 cat >conftest.$ac_ext <<_ACEOF
21110 /* confdefs.h.  */
21111 _ACEOF
21112 cat confdefs.h >>conftest.$ac_ext
21113 cat >>conftest.$ac_ext <<_ACEOF
21114 /* end confdefs.h.  */
21115
21116 /* Override any gcc2 internal prototype to avoid an error.  */
21117 #ifdef __cplusplus
21118 extern "C"
21119 #endif
21120 /* We use char because int might match the return type of a gcc2
21121    builtin and then its argument prototype would still apply.  */
21122 char gettext ();
21123 int
21124 main ()
21125 {
21126 gettext ();
21127   ;
21128   return 0;
21129 }
21130 _ACEOF
21131 rm -f conftest.$ac_objext conftest$ac_exeext
21132 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21133   (eval $ac_link) 2>conftest.er1
21134   ac_status=$?
21135   grep -v '^ *+' conftest.er1 >conftest.err
21136   rm -f conftest.er1
21137   cat conftest.err >&5
21138   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21139   (exit $ac_status); } &&
21140          { ac_try='test -z "$ac_c_werror_flag"
21141                          || test ! -s conftest.err'
21142   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21143   (eval $ac_try) 2>&5
21144   ac_status=$?
21145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21146   (exit $ac_status); }; } &&
21147          { ac_try='test -s conftest$ac_exeext'
21148   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21149   (eval $ac_try) 2>&5
21150   ac_status=$?
21151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21152   (exit $ac_status); }; }; then
21153   ac_cv_search_gettext="none required"
21154 else
21155   echo "$as_me: failed program was:" >&5
21156 sed 's/^/| /' conftest.$ac_ext >&5
21157
21158 fi
21159 rm -f conftest.err conftest.$ac_objext \
21160       conftest$ac_exeext conftest.$ac_ext
21161 if test "$ac_cv_search_gettext" = no; then
21162   for ac_lib in intl; do
21163     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21164     cat >conftest.$ac_ext <<_ACEOF
21165 /* confdefs.h.  */
21166 _ACEOF
21167 cat confdefs.h >>conftest.$ac_ext
21168 cat >>conftest.$ac_ext <<_ACEOF
21169 /* end confdefs.h.  */
21170
21171 /* Override any gcc2 internal prototype to avoid an error.  */
21172 #ifdef __cplusplus
21173 extern "C"
21174 #endif
21175 /* We use char because int might match the return type of a gcc2
21176    builtin and then its argument prototype would still apply.  */
21177 char gettext ();
21178 int
21179 main ()
21180 {
21181 gettext ();
21182   ;
21183   return 0;
21184 }
21185 _ACEOF
21186 rm -f conftest.$ac_objext conftest$ac_exeext
21187 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21188   (eval $ac_link) 2>conftest.er1
21189   ac_status=$?
21190   grep -v '^ *+' conftest.er1 >conftest.err
21191   rm -f conftest.er1
21192   cat conftest.err >&5
21193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21194   (exit $ac_status); } &&
21195          { ac_try='test -z "$ac_c_werror_flag"
21196                          || test ! -s conftest.err'
21197   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21198   (eval $ac_try) 2>&5
21199   ac_status=$?
21200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21201   (exit $ac_status); }; } &&
21202          { ac_try='test -s conftest$ac_exeext'
21203   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21204   (eval $ac_try) 2>&5
21205   ac_status=$?
21206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21207   (exit $ac_status); }; }; then
21208   ac_cv_search_gettext="-l$ac_lib"
21209 break
21210 else
21211   echo "$as_me: failed program was:" >&5
21212 sed 's/^/| /' conftest.$ac_ext >&5
21213
21214 fi
21215 rm -f conftest.err conftest.$ac_objext \
21216       conftest$ac_exeext conftest.$ac_ext
21217   done
21218 fi
21219 LIBS=$ac_func_search_save_LIBS
21220 fi
21221 echo "$as_me:$LINENO: result: $ac_cv_search_gettext" >&5
21222 echo "${ECHO_T}$ac_cv_search_gettext" >&6
21223 if test "$ac_cv_search_gettext" != no; then
21224   test "$ac_cv_search_gettext" = "none required" || LIBS="$ac_cv_search_gettext $LIBS"
21225
21226 else
21227   { { echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
21228 echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
21229    { (exit 1); exit 1; }; }
21230 fi
21231
21232   if test "${ac_cv_header_libintl_h+set}" = set; then
21233   echo "$as_me:$LINENO: checking for libintl.h" >&5
21234 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
21235 if test "${ac_cv_header_libintl_h+set}" = set; then
21236   echo $ECHO_N "(cached) $ECHO_C" >&6
21237 fi
21238 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
21239 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
21240 else
21241   # Is the header compilable?
21242 echo "$as_me:$LINENO: checking libintl.h usability" >&5
21243 echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6
21244 cat >conftest.$ac_ext <<_ACEOF
21245 /* confdefs.h.  */
21246 _ACEOF
21247 cat confdefs.h >>conftest.$ac_ext
21248 cat >>conftest.$ac_ext <<_ACEOF
21249 /* end confdefs.h.  */
21250 $ac_includes_default
21251 #include <libintl.h>
21252 _ACEOF
21253 rm -f conftest.$ac_objext
21254 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21255   (eval $ac_compile) 2>conftest.er1
21256   ac_status=$?
21257   grep -v '^ *+' conftest.er1 >conftest.err
21258   rm -f conftest.er1
21259   cat conftest.err >&5
21260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21261   (exit $ac_status); } &&
21262          { ac_try='test -z "$ac_c_werror_flag"
21263                          || test ! -s conftest.err'
21264   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21265   (eval $ac_try) 2>&5
21266   ac_status=$?
21267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21268   (exit $ac_status); }; } &&
21269          { ac_try='test -s conftest.$ac_objext'
21270   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21271   (eval $ac_try) 2>&5
21272   ac_status=$?
21273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21274   (exit $ac_status); }; }; then
21275   ac_header_compiler=yes
21276 else
21277   echo "$as_me: failed program was:" >&5
21278 sed 's/^/| /' conftest.$ac_ext >&5
21279
21280 ac_header_compiler=no
21281 fi
21282 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21283 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21284 echo "${ECHO_T}$ac_header_compiler" >&6
21285
21286 # Is the header present?
21287 echo "$as_me:$LINENO: checking libintl.h presence" >&5
21288 echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6
21289 cat >conftest.$ac_ext <<_ACEOF
21290 /* confdefs.h.  */
21291 _ACEOF
21292 cat confdefs.h >>conftest.$ac_ext
21293 cat >>conftest.$ac_ext <<_ACEOF
21294 /* end confdefs.h.  */
21295 #include <libintl.h>
21296 _ACEOF
21297 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21298   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21299   ac_status=$?
21300   grep -v '^ *+' conftest.er1 >conftest.err
21301   rm -f conftest.er1
21302   cat conftest.err >&5
21303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21304   (exit $ac_status); } >/dev/null; then
21305   if test -s conftest.err; then
21306     ac_cpp_err=$ac_c_preproc_warn_flag
21307     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
21308   else
21309     ac_cpp_err=
21310   fi
21311 else
21312   ac_cpp_err=yes
21313 fi
21314 if test -z "$ac_cpp_err"; then
21315   ac_header_preproc=yes
21316 else
21317   echo "$as_me: failed program was:" >&5
21318 sed 's/^/| /' conftest.$ac_ext >&5
21319
21320   ac_header_preproc=no
21321 fi
21322 rm -f conftest.err conftest.$ac_ext
21323 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21324 echo "${ECHO_T}$ac_header_preproc" >&6
21325
21326 # So?  What about this header?
21327 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21328   yes:no: )
21329     { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
21330 echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21331     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
21332 echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
21333     ac_header_preproc=yes
21334     ;;
21335   no:yes:* )
21336     { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
21337 echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
21338     { echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
21339 echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
21340     { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
21341 echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
21342     { echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
21343 echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21344     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
21345 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
21346     { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
21347 echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
21348     (
21349       cat <<\_ASBOX
21350 ## ---------------------------------------- ##
21351 ## Report this to pgsql-bugs@postgresql.org ##
21352 ## ---------------------------------------- ##
21353 _ASBOX
21354     ) |
21355       sed "s/^/$as_me: WARNING:     /" >&2
21356     ;;
21357 esac
21358 echo "$as_me:$LINENO: checking for libintl.h" >&5
21359 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
21360 if test "${ac_cv_header_libintl_h+set}" = set; then
21361   echo $ECHO_N "(cached) $ECHO_C" >&6
21362 else
21363   ac_cv_header_libintl_h=$ac_header_preproc
21364 fi
21365 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
21366 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
21367
21368 fi
21369 if test $ac_cv_header_libintl_h = yes; then
21370   :
21371 else
21372   { { echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
21373 echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
21374    { (exit 1); exit 1; }; }
21375 fi
21376
21377
21378   for ac_prog in msgfmt
21379 do
21380   # Extract the first word of "$ac_prog", so it can be a program name with args.
21381 set dummy $ac_prog; ac_word=$2
21382 echo "$as_me:$LINENO: checking for $ac_word" >&5
21383 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21384 if test "${ac_cv_prog_MSGFMT+set}" = set; then
21385   echo $ECHO_N "(cached) $ECHO_C" >&6
21386 else
21387   if test -n "$MSGFMT"; then
21388   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
21389 else
21390 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21391 for as_dir in $PATH
21392 do
21393   IFS=$as_save_IFS
21394   test -z "$as_dir" && as_dir=.
21395   for ac_exec_ext in '' $ac_executable_extensions; do
21396   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21397     ac_cv_prog_MSGFMT="$ac_prog"
21398     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21399     break 2
21400   fi
21401 done
21402 done
21403
21404 fi
21405 fi
21406 MSGFMT=$ac_cv_prog_MSGFMT
21407 if test -n "$MSGFMT"; then
21408   echo "$as_me:$LINENO: result: $MSGFMT" >&5
21409 echo "${ECHO_T}$MSGFMT" >&6
21410 else
21411   echo "$as_me:$LINENO: result: no" >&5
21412 echo "${ECHO_T}no" >&6
21413 fi
21414
21415   test -n "$MSGFMT" && break
21416 done
21417
21418   if test -z "$MSGFMT"; then
21419     { { echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
21420 echo "$as_me: error: msgfmt is required for NLS" >&2;}
21421    { (exit 1); exit 1; }; }
21422   fi
21423   for ac_prog in msgmerge
21424 do
21425   # Extract the first word of "$ac_prog", so it can be a program name with args.
21426 set dummy $ac_prog; ac_word=$2
21427 echo "$as_me:$LINENO: checking for $ac_word" >&5
21428 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21429 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
21430   echo $ECHO_N "(cached) $ECHO_C" >&6
21431 else
21432   if test -n "$MSGMERGE"; then
21433   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
21434 else
21435 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21436 for as_dir in $PATH
21437 do
21438   IFS=$as_save_IFS
21439   test -z "$as_dir" && as_dir=.
21440   for ac_exec_ext in '' $ac_executable_extensions; do
21441   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21442     ac_cv_prog_MSGMERGE="$ac_prog"
21443     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21444     break 2
21445   fi
21446 done
21447 done
21448
21449 fi
21450 fi
21451 MSGMERGE=$ac_cv_prog_MSGMERGE
21452 if test -n "$MSGMERGE"; then
21453   echo "$as_me:$LINENO: result: $MSGMERGE" >&5
21454 echo "${ECHO_T}$MSGMERGE" >&6
21455 else
21456   echo "$as_me:$LINENO: result: no" >&5
21457 echo "${ECHO_T}no" >&6
21458 fi
21459
21460   test -n "$MSGMERGE" && break
21461 done
21462
21463   for ac_prog in xgettext
21464 do
21465   # Extract the first word of "$ac_prog", so it can be a program name with args.
21466 set dummy $ac_prog; ac_word=$2
21467 echo "$as_me:$LINENO: checking for $ac_word" >&5
21468 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21469 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
21470   echo $ECHO_N "(cached) $ECHO_C" >&6
21471 else
21472   if test -n "$XGETTEXT"; then
21473   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
21474 else
21475 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21476 for as_dir in $PATH
21477 do
21478   IFS=$as_save_IFS
21479   test -z "$as_dir" && as_dir=.
21480   for ac_exec_ext in '' $ac_executable_extensions; do
21481   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21482     ac_cv_prog_XGETTEXT="$ac_prog"
21483     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21484     break 2
21485   fi
21486 done
21487 done
21488
21489 fi
21490 fi
21491 XGETTEXT=$ac_cv_prog_XGETTEXT
21492 if test -n "$XGETTEXT"; then
21493   echo "$as_me:$LINENO: result: $XGETTEXT" >&5
21494 echo "${ECHO_T}$XGETTEXT" >&6
21495 else
21496   echo "$as_me:$LINENO: result: no" >&5
21497 echo "${ECHO_T}no" >&6
21498 fi
21499
21500   test -n "$XGETTEXT" && break
21501 done
21502
21503
21504   # Note: share/locale is always the default, independent of $datadir
21505   localedir='${prefix}/share/locale'
21506   if test x"$prefix" = x"NONE"; then
21507     exp_localedir="$ac_default_prefix/share/locale"
21508   else
21509     exp_localedir="$prefix/share/locale"
21510   fi
21511
21512
21513
21514 cat >>confdefs.h <<_ACEOF
21515 #define LOCALEDIR "$exp_localedir"
21516 _ACEOF
21517
21518
21519 fi
21520
21521 # Check for Tcl configuration script tclConfig.sh
21522 if test "$with_tcl" = yes; then
21523     for ac_prog in tclsh tcl
21524 do
21525   # Extract the first word of "$ac_prog", so it can be a program name with args.
21526 set dummy $ac_prog; ac_word=$2
21527 echo "$as_me:$LINENO: checking for $ac_word" >&5
21528 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21529 if test "${ac_cv_path_TCLSH+set}" = set; then
21530   echo $ECHO_N "(cached) $ECHO_C" >&6
21531 else
21532   case $TCLSH in
21533   [\\/]* | ?:[\\/]*)
21534   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
21535   ;;
21536   *)
21537   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21538 for as_dir in $PATH
21539 do
21540   IFS=$as_save_IFS
21541   test -z "$as_dir" && as_dir=.
21542   for ac_exec_ext in '' $ac_executable_extensions; do
21543   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21544     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
21545     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21546     break 2
21547   fi
21548 done
21549 done
21550
21551   ;;
21552 esac
21553 fi
21554 TCLSH=$ac_cv_path_TCLSH
21555
21556 if test -n "$TCLSH"; then
21557   echo "$as_me:$LINENO: result: $TCLSH" >&5
21558 echo "${ECHO_T}$TCLSH" >&6
21559 else
21560   echo "$as_me:$LINENO: result: no" >&5
21561 echo "${ECHO_T}no" >&6
21562 fi
21563
21564   test -n "$TCLSH" && break
21565 done
21566
21567 echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
21568 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6
21569 # Let user override test
21570 if test -z "$TCL_CONFIG_SH"; then
21571     pgac_test_dirs="$with_tclconfig"
21572
21573     set X $pgac_test_dirs; shift
21574     if test $# -eq 0; then
21575         test -z "$TCLSH" && { { echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
21576 echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
21577    { (exit 1); exit 1; }; }
21578         set X `echo 'puts $auto_path' | $TCLSH`; shift
21579     fi
21580
21581     for pgac_dir do
21582         if test -r "$pgac_dir/tclConfig.sh"; then
21583             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
21584             break
21585         fi
21586     done
21587 fi
21588
21589 if test -z "$TCL_CONFIG_SH"; then
21590     echo "$as_me:$LINENO: result: no" >&5
21591 echo "${ECHO_T}no" >&6
21592     { { echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
21593 echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
21594    { (exit 1); exit 1; }; }
21595 else
21596     echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
21597 echo "${ECHO_T}$TCL_CONFIG_SH" >&6
21598 fi
21599
21600
21601
21602     . "$TCL_CONFIG_SH"
21603 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
21604 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
21605 eval TCL_LIBS=\"$TCL_LIBS\"
21606 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
21607 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
21608
21609         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
21610     ac_save_CPPFLAGS=$CPPFLAGS
21611     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
21612     if test "${ac_cv_header_tcl_h+set}" = set; then
21613   echo "$as_me:$LINENO: checking for tcl.h" >&5
21614 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
21615 if test "${ac_cv_header_tcl_h+set}" = set; then
21616   echo $ECHO_N "(cached) $ECHO_C" >&6
21617 fi
21618 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
21619 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
21620 else
21621   # Is the header compilable?
21622 echo "$as_me:$LINENO: checking tcl.h usability" >&5
21623 echo $ECHO_N "checking tcl.h usability... $ECHO_C" >&6
21624 cat >conftest.$ac_ext <<_ACEOF
21625 /* confdefs.h.  */
21626 _ACEOF
21627 cat confdefs.h >>conftest.$ac_ext
21628 cat >>conftest.$ac_ext <<_ACEOF
21629 /* end confdefs.h.  */
21630 $ac_includes_default
21631 #include <tcl.h>
21632 _ACEOF
21633 rm -f conftest.$ac_objext
21634 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21635   (eval $ac_compile) 2>conftest.er1
21636   ac_status=$?
21637   grep -v '^ *+' conftest.er1 >conftest.err
21638   rm -f conftest.er1
21639   cat conftest.err >&5
21640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21641   (exit $ac_status); } &&
21642          { ac_try='test -z "$ac_c_werror_flag"
21643                          || test ! -s conftest.err'
21644   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21645   (eval $ac_try) 2>&5
21646   ac_status=$?
21647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21648   (exit $ac_status); }; } &&
21649          { ac_try='test -s conftest.$ac_objext'
21650   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21651   (eval $ac_try) 2>&5
21652   ac_status=$?
21653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21654   (exit $ac_status); }; }; then
21655   ac_header_compiler=yes
21656 else
21657   echo "$as_me: failed program was:" >&5
21658 sed 's/^/| /' conftest.$ac_ext >&5
21659
21660 ac_header_compiler=no
21661 fi
21662 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21663 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21664 echo "${ECHO_T}$ac_header_compiler" >&6
21665
21666 # Is the header present?
21667 echo "$as_me:$LINENO: checking tcl.h presence" >&5
21668 echo $ECHO_N "checking tcl.h presence... $ECHO_C" >&6
21669 cat >conftest.$ac_ext <<_ACEOF
21670 /* confdefs.h.  */
21671 _ACEOF
21672 cat confdefs.h >>conftest.$ac_ext
21673 cat >>conftest.$ac_ext <<_ACEOF
21674 /* end confdefs.h.  */
21675 #include <tcl.h>
21676 _ACEOF
21677 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21678   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21679   ac_status=$?
21680   grep -v '^ *+' conftest.er1 >conftest.err
21681   rm -f conftest.er1
21682   cat conftest.err >&5
21683   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21684   (exit $ac_status); } >/dev/null; then
21685   if test -s conftest.err; then
21686     ac_cpp_err=$ac_c_preproc_warn_flag
21687     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
21688   else
21689     ac_cpp_err=
21690   fi
21691 else
21692   ac_cpp_err=yes
21693 fi
21694 if test -z "$ac_cpp_err"; then
21695   ac_header_preproc=yes
21696 else
21697   echo "$as_me: failed program was:" >&5
21698 sed 's/^/| /' conftest.$ac_ext >&5
21699
21700   ac_header_preproc=no
21701 fi
21702 rm -f conftest.err conftest.$ac_ext
21703 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21704 echo "${ECHO_T}$ac_header_preproc" >&6
21705
21706 # So?  What about this header?
21707 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21708   yes:no: )
21709     { echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
21710 echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21711     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
21712 echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
21713     ac_header_preproc=yes
21714     ;;
21715   no:yes:* )
21716     { echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
21717 echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
21718     { echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
21719 echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
21720     { echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
21721 echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
21722     { echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
21723 echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21724     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
21725 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
21726     { echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
21727 echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
21728     (
21729       cat <<\_ASBOX
21730 ## ---------------------------------------- ##
21731 ## Report this to pgsql-bugs@postgresql.org ##
21732 ## ---------------------------------------- ##
21733 _ASBOX
21734     ) |
21735       sed "s/^/$as_me: WARNING:     /" >&2
21736     ;;
21737 esac
21738 echo "$as_me:$LINENO: checking for tcl.h" >&5
21739 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
21740 if test "${ac_cv_header_tcl_h+set}" = set; then
21741   echo $ECHO_N "(cached) $ECHO_C" >&6
21742 else
21743   ac_cv_header_tcl_h=$ac_header_preproc
21744 fi
21745 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
21746 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
21747
21748 fi
21749 if test $ac_cv_header_tcl_h = yes; then
21750   :
21751 else
21752   { { echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
21753 echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
21754    { (exit 1); exit 1; }; }
21755 fi
21756
21757
21758     CPPFLAGS=$ac_save_CPPFLAGS
21759 fi
21760
21761 #
21762 # Check for DocBook and tools
21763 #
21764 for ac_prog in onsgmls nsgmls
21765 do
21766   # Extract the first word of "$ac_prog", so it can be a program name with args.
21767 set dummy $ac_prog; ac_word=$2
21768 echo "$as_me:$LINENO: checking for $ac_word" >&5
21769 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21770 if test "${ac_cv_prog_NSGMLS+set}" = set; then
21771   echo $ECHO_N "(cached) $ECHO_C" >&6
21772 else
21773   if test -n "$NSGMLS"; then
21774   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
21775 else
21776 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21777 for as_dir in $PATH
21778 do
21779   IFS=$as_save_IFS
21780   test -z "$as_dir" && as_dir=.
21781   for ac_exec_ext in '' $ac_executable_extensions; do
21782   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21783     ac_cv_prog_NSGMLS="$ac_prog"
21784     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21785     break 2
21786   fi
21787 done
21788 done
21789
21790 fi
21791 fi
21792 NSGMLS=$ac_cv_prog_NSGMLS
21793 if test -n "$NSGMLS"; then
21794   echo "$as_me:$LINENO: result: $NSGMLS" >&5
21795 echo "${ECHO_T}$NSGMLS" >&6
21796 else
21797   echo "$as_me:$LINENO: result: no" >&5
21798 echo "${ECHO_T}no" >&6
21799 fi
21800
21801   test -n "$NSGMLS" && break
21802 done
21803
21804 for ac_prog in openjade jade
21805 do
21806   # Extract the first word of "$ac_prog", so it can be a program name with args.
21807 set dummy $ac_prog; ac_word=$2
21808 echo "$as_me:$LINENO: checking for $ac_word" >&5
21809 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21810 if test "${ac_cv_prog_JADE+set}" = set; then
21811   echo $ECHO_N "(cached) $ECHO_C" >&6
21812 else
21813   if test -n "$JADE"; then
21814   ac_cv_prog_JADE="$JADE" # Let the user override the test.
21815 else
21816 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21817 for as_dir in $PATH
21818 do
21819   IFS=$as_save_IFS
21820   test -z "$as_dir" && as_dir=.
21821   for ac_exec_ext in '' $ac_executable_extensions; do
21822   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21823     ac_cv_prog_JADE="$ac_prog"
21824     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21825     break 2
21826   fi
21827 done
21828 done
21829
21830 fi
21831 fi
21832 JADE=$ac_cv_prog_JADE
21833 if test -n "$JADE"; then
21834   echo "$as_me:$LINENO: result: $JADE" >&5
21835 echo "${ECHO_T}$JADE" >&6
21836 else
21837   echo "$as_me:$LINENO: result: no" >&5
21838 echo "${ECHO_T}no" >&6
21839 fi
21840
21841   test -n "$JADE" && break
21842 done
21843
21844
21845 echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
21846 echo $ECHO_N "checking for DocBook V4.2... $ECHO_C" >&6
21847 if test "${pgac_cv_check_docbook+set}" = set; then
21848   echo $ECHO_N "(cached) $ECHO_C" >&6
21849 else
21850   cat >conftest.sgml <<EOF
21851 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
21852 <book>
21853  <title>test</title>
21854  <chapter>
21855   <title>random</title>
21856    <sect1>
21857     <title>testsect</title>
21858     <para>text</para>
21859   </sect1>
21860  </chapter>
21861 </book>
21862 EOF
21863
21864 pgac_cv_check_docbook=no
21865
21866 if test -n "$NSGMLS"; then
21867   $NSGMLS -s conftest.sgml 1>&5 2>&1
21868   if test $? -eq 0; then
21869     pgac_cv_check_docbook=yes
21870   fi
21871 fi
21872 rm -f conftest.sgml
21873 fi
21874 echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
21875 echo "${ECHO_T}$pgac_cv_check_docbook" >&6
21876
21877 have_docbook=$pgac_cv_check_docbook
21878
21879
21880 echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
21881 echo $ECHO_N "checking for DocBook stylesheets... $ECHO_C" >&6
21882 if test "${pgac_cv_path_stylesheets+set}" = set; then
21883   echo $ECHO_N "(cached) $ECHO_C" >&6
21884 else
21885   if test -n "$DOCBOOKSTYLE"; then
21886   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
21887 else
21888   for pgac_prefix in /usr /usr/local /opt; do
21889     for pgac_infix in share lib; do
21890       for pgac_postfix in \
21891         sgml/stylesheets/nwalsh-modular \
21892         sgml/stylesheets/docbook \
21893                 sgml/docbook-dsssl \
21894         sgml/docbook/dsssl/modular \
21895         sgml/docbook/stylesheet/dsssl/modular \
21896         sgml/docbook/dsssl-stylesheets
21897       do
21898         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
21899         if test -r "$pgac_candidate/html/docbook.dsl" \
21900            && test -r "$pgac_candidate/print/docbook.dsl"
21901         then
21902           pgac_cv_path_stylesheets=$pgac_candidate
21903           break 3
21904         fi
21905       done
21906     done
21907   done
21908 fi
21909 fi
21910
21911 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
21912
21913 if test -n "$DOCBOOKSTYLE"; then
21914   echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
21915 echo "${ECHO_T}$DOCBOOKSTYLE" >&6
21916 else
21917   echo "$as_me:$LINENO: result: no" >&5
21918 echo "${ECHO_T}no" >&6
21919 fi
21920 if test -n "$DOCBOOKSTYLE"; then
21921   for ac_prog in collateindex.pl
21922 do
21923   # Extract the first word of "$ac_prog", so it can be a program name with args.
21924 set dummy $ac_prog; ac_word=$2
21925 echo "$as_me:$LINENO: checking for $ac_word" >&5
21926 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21927 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
21928   echo $ECHO_N "(cached) $ECHO_C" >&6
21929 else
21930   case $COLLATEINDEX in
21931   [\\/]* | ?:[\\/]*)
21932   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
21933   ;;
21934   *)
21935   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21936 for as_dir in $DOCBOOKSTYLE/bin $PATH
21937 do
21938   IFS=$as_save_IFS
21939   test -z "$as_dir" && as_dir=.
21940   for ac_exec_ext in '' $ac_executable_extensions; do
21941   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21942     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
21943     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21944     break 2
21945   fi
21946 done
21947 done
21948
21949   ;;
21950 esac
21951 fi
21952 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
21953
21954 if test -n "$COLLATEINDEX"; then
21955   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
21956 echo "${ECHO_T}$COLLATEINDEX" >&6
21957 else
21958   echo "$as_me:$LINENO: result: no" >&5
21959 echo "${ECHO_T}no" >&6
21960 fi
21961
21962   test -n "$COLLATEINDEX" && break
21963 done
21964
21965 else
21966   for ac_prog in collateindex.pl
21967 do
21968   # Extract the first word of "$ac_prog", so it can be a program name with args.
21969 set dummy $ac_prog; ac_word=$2
21970 echo "$as_me:$LINENO: checking for $ac_word" >&5
21971 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21972 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
21973   echo $ECHO_N "(cached) $ECHO_C" >&6
21974 else
21975   case $COLLATEINDEX in
21976   [\\/]* | ?:[\\/]*)
21977   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
21978   ;;
21979   *)
21980   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21981 for as_dir in $PATH
21982 do
21983   IFS=$as_save_IFS
21984   test -z "$as_dir" && as_dir=.
21985   for ac_exec_ext in '' $ac_executable_extensions; do
21986   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21987     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
21988     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21989     break 2
21990   fi
21991 done
21992 done
21993
21994   ;;
21995 esac
21996 fi
21997 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
21998
21999 if test -n "$COLLATEINDEX"; then
22000   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
22001 echo "${ECHO_T}$COLLATEINDEX" >&6
22002 else
22003   echo "$as_me:$LINENO: result: no" >&5
22004 echo "${ECHO_T}no" >&6
22005 fi
22006
22007   test -n "$COLLATEINDEX" && break
22008 done
22009
22010 fi
22011 for ac_prog in sgmlspl
22012 do
22013   # Extract the first word of "$ac_prog", so it can be a program name with args.
22014 set dummy $ac_prog; ac_word=$2
22015 echo "$as_me:$LINENO: checking for $ac_word" >&5
22016 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22017 if test "${ac_cv_prog_SGMLSPL+set}" = set; then
22018   echo $ECHO_N "(cached) $ECHO_C" >&6
22019 else
22020   if test -n "$SGMLSPL"; then
22021   ac_cv_prog_SGMLSPL="$SGMLSPL" # Let the user override the test.
22022 else
22023 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22024 for as_dir in $PATH
22025 do
22026   IFS=$as_save_IFS
22027   test -z "$as_dir" && as_dir=.
22028   for ac_exec_ext in '' $ac_executable_extensions; do
22029   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22030     ac_cv_prog_SGMLSPL="$ac_prog"
22031     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22032     break 2
22033   fi
22034 done
22035 done
22036
22037 fi
22038 fi
22039 SGMLSPL=$ac_cv_prog_SGMLSPL
22040 if test -n "$SGMLSPL"; then
22041   echo "$as_me:$LINENO: result: $SGMLSPL" >&5
22042 echo "${ECHO_T}$SGMLSPL" >&6
22043 else
22044   echo "$as_me:$LINENO: result: no" >&5
22045 echo "${ECHO_T}no" >&6
22046 fi
22047
22048   test -n "$SGMLSPL" && break
22049 done
22050
22051
22052 # Thread testing
22053
22054 # We have to run the thread test near the end so we have all our symbols
22055 # defined.  Cross compiling throws a warning.
22056 #
22057 if test "$enable_thread_safety_force" = yes; then
22058 if test x"$template" != x"win32"
22059 then
22060   { echo "$as_me:$LINENO: WARNING:
22061 *** Skipping thread test program.  --enable-thread-safety-force was used.
22062 *** Run the program in src/test/thread on the your machine and add
22063 proper locking function calls to your applications to guarantee thread
22064 safety.
22065 " >&5
22066 echo "$as_me: WARNING:
22067 *** Skipping thread test program.  --enable-thread-safety-force was used.
22068 *** Run the program in src/test/thread on the your machine and add
22069 proper locking function calls to your applications to guarantee thread
22070 safety.
22071 " >&2;}
22072 else
22073 { echo "$as_me:$LINENO: WARNING: *** Skipping thread test on Win32" >&5
22074 echo "$as_me: WARNING: *** Skipping thread test on Win32" >&2;}
22075 fi
22076 elif test "$enable_thread_safety" = yes; then
22077 if test x"$template" != x"win32"
22078 then
22079 echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
22080 echo $ECHO_N "checking thread safety of required library functions... $ECHO_C" >&6
22081
22082 _CFLAGS="$CFLAGS"
22083 _LIBS="$LIBS"
22084 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
22085 LIBS="$LIBS $PTHREAD_LIBS"
22086 if test "$cross_compiling" = yes; then
22087   echo "$as_me:$LINENO: result: maybe" >&5
22088 echo "${ECHO_T}maybe" >&6
22089   { echo "$as_me:$LINENO: WARNING:
22090 *** Skipping thread test program because of cross-compile build.
22091 *** Run the program in src/test/thread on the target machine.
22092 " >&5
22093 echo "$as_me: WARNING:
22094 *** Skipping thread test program because of cross-compile build.
22095 *** Run the program in src/test/thread on the target machine.
22096 " >&2;}
22097 else
22098   cat >conftest.$ac_ext <<_ACEOF
22099 /* confdefs.h.  */
22100 _ACEOF
22101 cat confdefs.h >>conftest.$ac_ext
22102 cat >>conftest.$ac_ext <<_ACEOF
22103 /* end confdefs.h.  */
22104 #include "$srcdir/src/test/thread/thread_test.c"
22105 _ACEOF
22106 rm -f conftest$ac_exeext
22107 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22108   (eval $ac_link) 2>&5
22109   ac_status=$?
22110   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22111   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22112   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22113   (eval $ac_try) 2>&5
22114   ac_status=$?
22115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22116   (exit $ac_status); }; }; then
22117   echo "$as_me:$LINENO: result: yes" >&5
22118 echo "${ECHO_T}yes" >&6
22119 else
22120   echo "$as_me: program exited with status $ac_status" >&5
22121 echo "$as_me: failed program was:" >&5
22122 sed 's/^/| /' conftest.$ac_ext >&5
22123
22124 ( exit $ac_status )
22125 echo "$as_me:$LINENO: result: no" >&5
22126 echo "${ECHO_T}no" >&6
22127   { { echo "$as_me:$LINENO: error:
22128 *** Thread test program failed.  Your platform is not thread-safe.
22129 *** Check the file 'config.log'for the exact reason.
22130 ***
22131 *** You can use the configure option --enable-thread-safety-force
22132 *** to force threads to be enabled.  However, you must then run
22133 *** the program in src/test/thread and add locking function calls
22134 *** to your applications to guarantee thread safety.
22135 " >&5
22136 echo "$as_me: error:
22137 *** Thread test program failed.  Your platform is not thread-safe.
22138 *** Check the file 'config.log'for the exact reason.
22139 ***
22140 *** You can use the configure option --enable-thread-safety-force
22141 *** to force threads to be enabled.  However, you must then run
22142 *** the program in src/test/thread and add locking function calls
22143 *** to your applications to guarantee thread safety.
22144 " >&2;}
22145    { (exit 1); exit 1; }; }
22146 fi
22147 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22148 fi
22149 CFLAGS="$_CFLAGS"
22150 LIBS="$_LIBS"
22151 else
22152 { echo "$as_me:$LINENO: WARNING: *** Skipping thread test on Win32" >&5
22153 echo "$as_me: WARNING: *** Skipping thread test on Win32" >&2;}
22154 fi
22155 fi
22156
22157 # prepare build tree if outside source tree
22158 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
22159 # Note 2: /bin/pwd might be better than shell's built-in at getting
22160 #         a symlink-free name.
22161 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
22162   vpath_build=no
22163 else
22164   vpath_build=yes
22165   if test "$no_create" != yes; then
22166     echo $ECHO_N "preparing build tree... $ECHO_C" >&6
22167     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
22168     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
22169       || { { echo "$as_me:$LINENO: error: failed" >&5
22170 echo "$as_me: error: failed" >&2;}
22171    { (exit 1); exit 1; }; }
22172     echo "$as_me:$LINENO: result: done" >&5
22173 echo "${ECHO_T}done" >&6
22174   fi
22175 fi
22176
22177
22178
22179                     ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
22180
22181
22182                                                             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}"
22183
22184
22185 if test "$PORTNAME" = "win32"; then
22186           ac_config_commands="$ac_config_commands check_win32_symlinks"
22187
22188 fi
22189
22190           ac_config_headers="$ac_config_headers src/include/pg_config.h"
22191
22192
22193 cat >confcache <<\_ACEOF
22194 # This file is a shell script that caches the results of configure
22195 # tests run on this system so they can be shared between configure
22196 # scripts and configure runs, see configure's option --config-cache.
22197 # It is not useful on other systems.  If it contains results you don't
22198 # want to keep, you may remove or edit it.
22199 #
22200 # config.status only pays attention to the cache file if you give it
22201 # the --recheck option to rerun configure.
22202 #
22203 # `ac_cv_env_foo' variables (set or unset) will be overridden when
22204 # loading this file, other *unset* `ac_cv_foo' will be assigned the
22205 # following values.
22206
22207 _ACEOF
22208
22209 # The following way of writing the cache mishandles newlines in values,
22210 # but we know of no workaround that is simple, portable, and efficient.
22211 # So, don't put newlines in cache variables' values.
22212 # Ultrix sh set writes to stderr and can't be redirected directly,
22213 # and sets the high bit in the cache file unless we assign to the vars.
22214 {
22215   (set) 2>&1 |
22216     case `(ac_space=' '; set | grep ac_space) 2>&1` in
22217     *ac_space=\ *)
22218       # `set' does not quote correctly, so add quotes (double-quote
22219       # substitution turns \\\\ into \\, and sed turns \\ into \).
22220       sed -n \
22221         "s/'/'\\\\''/g;
22222           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22223       ;;
22224     *)
22225       # `set' quotes correctly as required by POSIX, so do not add quotes.
22226       sed -n \
22227         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
22228       ;;
22229     esac;
22230 } |
22231   sed '
22232      t clear
22233      : clear
22234      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22235      t end
22236      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22237      : end' >>confcache
22238 if diff $cache_file confcache >/dev/null 2>&1; then :; else
22239   if test -w $cache_file; then
22240     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
22241     cat confcache >$cache_file
22242   else
22243     echo "not updating unwritable cache $cache_file"
22244   fi
22245 fi
22246 rm -f confcache
22247
22248 test "x$prefix" = xNONE && prefix=$ac_default_prefix
22249 # Let make expand exec_prefix.
22250 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22251
22252 # VPATH may cause trouble with some makes, so we remove $(srcdir),
22253 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
22254 # trailing colons and then remove the whole line if VPATH becomes empty
22255 # (actually we leave an empty line to preserve line numbers).
22256 if test "x$srcdir" = x.; then
22257   ac_vpsub='/^[  ]*VPATH[        ]*=/{
22258 s/:*\$(srcdir):*/:/;
22259 s/:*\${srcdir}:*/:/;
22260 s/:*@srcdir@:*/:/;
22261 s/^\([^=]*=[     ]*\):*/\1/;
22262 s/:*$//;
22263 s/^[^=]*=[       ]*$//;
22264 }'
22265 fi
22266
22267 DEFS=-DHAVE_CONFIG_H
22268
22269 ac_libobjs=
22270 ac_ltlibobjs=
22271 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
22272   # 1. Remove the extension, and $U if already installed.
22273   ac_i=`echo "$ac_i" |
22274          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
22275   # 2. Add them.
22276   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
22277   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
22278 done
22279 LIBOBJS=$ac_libobjs
22280
22281 LTLIBOBJS=$ac_ltlibobjs
22282
22283
22284
22285 : ${CONFIG_STATUS=./config.status}
22286 ac_clean_files_save=$ac_clean_files
22287 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
22288 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
22289 echo "$as_me: creating $CONFIG_STATUS" >&6;}
22290 cat >$CONFIG_STATUS <<_ACEOF
22291 #! $SHELL
22292 # Generated by $as_me.
22293 # Run this file to recreate the current configuration.
22294 # Compiler output produced by configure, useful for debugging
22295 # configure, is in config.log if it exists.
22296
22297 debug=false
22298 ac_cs_recheck=false
22299 ac_cs_silent=false
22300 SHELL=\${CONFIG_SHELL-$SHELL}
22301 _ACEOF
22302
22303 cat >>$CONFIG_STATUS <<\_ACEOF
22304 ## --------------------- ##
22305 ## M4sh Initialization.  ##
22306 ## --------------------- ##
22307
22308 # Be Bourne compatible
22309 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
22310   emulate sh
22311   NULLCMD=:
22312   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
22313   # is contrary to our usage.  Disable this feature.
22314   alias -g '${1+"$@"}'='"$@"'
22315 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
22316   set -o posix
22317 fi
22318 DUALCASE=1; export DUALCASE # for MKS sh
22319
22320 # Support unset when possible.
22321 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
22322   as_unset=unset
22323 else
22324   as_unset=false
22325 fi
22326
22327
22328 # Work around bugs in pre-3.0 UWIN ksh.
22329 $as_unset ENV MAIL MAILPATH
22330 PS1='$ '
22331 PS2='> '
22332 PS4='+ '
22333
22334 # NLS nuisances.
22335 for as_var in \
22336   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
22337   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
22338   LC_TELEPHONE LC_TIME
22339 do
22340   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
22341     eval $as_var=C; export $as_var
22342   else
22343     $as_unset $as_var
22344   fi
22345 done
22346
22347 # Required to use basename.
22348 if expr a : '\(a\)' >/dev/null 2>&1; then
22349   as_expr=expr
22350 else
22351   as_expr=false
22352 fi
22353
22354 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
22355   as_basename=basename
22356 else
22357   as_basename=false
22358 fi
22359
22360
22361 # Name of the executable.
22362 as_me=`$as_basename "$0" ||
22363 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
22364          X"$0" : 'X\(//\)$' \| \
22365          X"$0" : 'X\(/\)$' \| \
22366          .     : '\(.\)' 2>/dev/null ||
22367 echo X/"$0" |
22368     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
22369           /^X\/\(\/\/\)$/{ s//\1/; q; }
22370           /^X\/\(\/\).*/{ s//\1/; q; }
22371           s/.*/./; q'`
22372
22373
22374 # PATH needs CR, and LINENO needs CR and PATH.
22375 # Avoid depending upon Character Ranges.
22376 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
22377 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
22378 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
22379 as_cr_digits='0123456789'
22380 as_cr_alnum=$as_cr_Letters$as_cr_digits
22381
22382 # The user is always right.
22383 if test "${PATH_SEPARATOR+set}" != set; then
22384   echo "#! /bin/sh" >conf$$.sh
22385   echo  "exit 0"   >>conf$$.sh
22386   chmod +x conf$$.sh
22387   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
22388     PATH_SEPARATOR=';'
22389   else
22390     PATH_SEPARATOR=:
22391   fi
22392   rm -f conf$$.sh
22393 fi
22394
22395
22396   as_lineno_1=$LINENO
22397   as_lineno_2=$LINENO
22398   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
22399   test "x$as_lineno_1" != "x$as_lineno_2" &&
22400   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
22401   # Find who we are.  Look in the path if we contain no path at all
22402   # relative or not.
22403   case $0 in
22404     *[\\/]* ) as_myself=$0 ;;
22405     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22406 for as_dir in $PATH
22407 do
22408   IFS=$as_save_IFS
22409   test -z "$as_dir" && as_dir=.
22410   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
22411 done
22412
22413        ;;
22414   esac
22415   # We did not find ourselves, most probably we were run as `sh COMMAND'
22416   # in which case we are not to be found in the path.
22417   if test "x$as_myself" = x; then
22418     as_myself=$0
22419   fi
22420   if test ! -f "$as_myself"; then
22421     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
22422 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
22423    { (exit 1); exit 1; }; }
22424   fi
22425   case $CONFIG_SHELL in
22426   '')
22427     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22428 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
22429 do
22430   IFS=$as_save_IFS
22431   test -z "$as_dir" && as_dir=.
22432   for as_base in sh bash ksh sh5; do
22433          case $as_dir in
22434          /*)
22435            if ("$as_dir/$as_base" -c '
22436   as_lineno_1=$LINENO
22437   as_lineno_2=$LINENO
22438   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
22439   test "x$as_lineno_1" != "x$as_lineno_2" &&
22440   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
22441              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
22442              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
22443              CONFIG_SHELL=$as_dir/$as_base
22444              export CONFIG_SHELL
22445              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
22446            fi;;
22447          esac
22448        done
22449 done
22450 ;;
22451   esac
22452
22453   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
22454   # uniformly replaced by the line number.  The first 'sed' inserts a
22455   # line-number line before each line; the second 'sed' does the real
22456   # work.  The second script uses 'N' to pair each line-number line
22457   # with the numbered line, and appends trailing '-' during
22458   # substitution so that $LINENO is not a special case at line end.
22459   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
22460   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
22461   sed '=' <$as_myself |
22462     sed '
22463       N
22464       s,$,-,
22465       : loop
22466       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
22467       t loop
22468       s,-$,,
22469       s,^['$as_cr_digits']*\n,,
22470     ' >$as_me.lineno &&
22471   chmod +x $as_me.lineno ||
22472     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
22473 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
22474    { (exit 1); exit 1; }; }
22475
22476   # Don't try to exec as it changes $[0], causing all sort of problems
22477   # (the dirname of $[0] is not the place where we might find the
22478   # original and so on.  Autoconf is especially sensible to this).
22479   . ./$as_me.lineno
22480   # Exit status is that of the last command.
22481   exit
22482 }
22483
22484
22485 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
22486   *c*,-n*) ECHO_N= ECHO_C='
22487 ' ECHO_T='      ' ;;
22488   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
22489   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
22490 esac
22491
22492 if expr a : '\(a\)' >/dev/null 2>&1; then
22493   as_expr=expr
22494 else
22495   as_expr=false
22496 fi
22497
22498 rm -f conf$$ conf$$.exe conf$$.file
22499 echo >conf$$.file
22500 if ln -s conf$$.file conf$$ 2>/dev/null; then
22501   # We could just check for DJGPP; but this test a) works b) is more generic
22502   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
22503   if test -f conf$$.exe; then
22504     # Don't use ln at all; we don't have any links
22505     as_ln_s='cp -p'
22506   else
22507     as_ln_s='ln -s'
22508   fi
22509 elif ln conf$$.file conf$$ 2>/dev/null; then
22510   as_ln_s=ln
22511 else
22512   as_ln_s='cp -p'
22513 fi
22514 rm -f conf$$ conf$$.exe conf$$.file
22515
22516 if mkdir -p . 2>/dev/null; then
22517   as_mkdir_p=:
22518 else
22519   test -d ./-p && rmdir ./-p
22520   as_mkdir_p=false
22521 fi
22522
22523 as_executable_p="test -f"
22524
22525 # Sed expression to map a string onto a valid CPP name.
22526 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
22527
22528 # Sed expression to map a string onto a valid variable name.
22529 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
22530
22531
22532 # IFS
22533 # We need space, tab and new line, in precisely that order.
22534 as_nl='
22535 '
22536 IFS="   $as_nl"
22537
22538 # CDPATH.
22539 $as_unset CDPATH
22540
22541 exec 6>&1
22542
22543 # Open the log real soon, to keep \$[0] and so on meaningful, and to
22544 # report actual input values of CONFIG_FILES etc. instead of their
22545 # values after options handling.  Logging --version etc. is OK.
22546 exec 5>>config.log
22547 {
22548   echo
22549   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
22550 ## Running $as_me. ##
22551 _ASBOX
22552 } >&5
22553 cat >&5 <<_CSEOF
22554
22555 This file was extended by PostgreSQL $as_me 8.2devel, which was
22556 generated by GNU Autoconf 2.59.  Invocation command line was
22557
22558   CONFIG_FILES    = $CONFIG_FILES
22559   CONFIG_HEADERS  = $CONFIG_HEADERS
22560   CONFIG_LINKS    = $CONFIG_LINKS
22561   CONFIG_COMMANDS = $CONFIG_COMMANDS
22562   $ $0 $@
22563
22564 _CSEOF
22565 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
22566 echo >&5
22567 _ACEOF
22568
22569 # Files that config.status was made for.
22570 if test -n "$ac_config_files"; then
22571   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
22572 fi
22573
22574 if test -n "$ac_config_headers"; then
22575   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
22576 fi
22577
22578 if test -n "$ac_config_links"; then
22579   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
22580 fi
22581
22582 if test -n "$ac_config_commands"; then
22583   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
22584 fi
22585
22586 cat >>$CONFIG_STATUS <<\_ACEOF
22587
22588 ac_cs_usage="\
22589 \`$as_me' instantiates files from templates according to the
22590 current configuration.
22591
22592 Usage: $0 [OPTIONS] [FILE]...
22593
22594   -h, --help       print this help, then exit
22595   -V, --version    print version number, then exit
22596   -q, --quiet      do not print progress messages
22597   -d, --debug      don't remove temporary files
22598       --recheck    update $as_me by reconfiguring in the same conditions
22599   --file=FILE[:TEMPLATE]
22600                    instantiate the configuration file FILE
22601   --header=FILE[:TEMPLATE]
22602                    instantiate the configuration header FILE
22603
22604 Configuration files:
22605 $config_files
22606
22607 Configuration headers:
22608 $config_headers
22609
22610 Configuration links:
22611 $config_links
22612
22613 Configuration commands:
22614 $config_commands
22615
22616 Report bugs to <bug-autoconf@gnu.org>."
22617 _ACEOF
22618
22619 cat >>$CONFIG_STATUS <<_ACEOF
22620 ac_cs_version="\\
22621 PostgreSQL config.status 8.2devel
22622 configured by $0, generated by GNU Autoconf 2.59,
22623   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
22624
22625 Copyright (C) 2003 Free Software Foundation, Inc.
22626 This config.status script is free software; the Free Software Foundation
22627 gives unlimited permission to copy, distribute and modify it."
22628 srcdir=$srcdir
22629 _ACEOF
22630
22631 cat >>$CONFIG_STATUS <<\_ACEOF
22632 # If no file are specified by the user, then we need to provide default
22633 # value.  By we need to know if files were specified by the user.
22634 ac_need_defaults=:
22635 while test $# != 0
22636 do
22637   case $1 in
22638   --*=*)
22639     ac_option=`expr "x$1" : 'x\([^=]*\)='`
22640     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
22641     ac_shift=:
22642     ;;
22643   -*)
22644     ac_option=$1
22645     ac_optarg=$2
22646     ac_shift=shift
22647     ;;
22648   *) # This is not an option, so the user has probably given explicit
22649      # arguments.
22650      ac_option=$1
22651      ac_need_defaults=false;;
22652   esac
22653
22654   case $ac_option in
22655   # Handling of the options.
22656 _ACEOF
22657 cat >>$CONFIG_STATUS <<\_ACEOF
22658   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
22659     ac_cs_recheck=: ;;
22660   --version | --vers* | -V )
22661     echo "$ac_cs_version"; exit 0 ;;
22662   --he | --h)
22663     # Conflict between --help and --header
22664     { { echo "$as_me:$LINENO: error: ambiguous option: $1
22665 Try \`$0 --help' for more information." >&5
22666 echo "$as_me: error: ambiguous option: $1
22667 Try \`$0 --help' for more information." >&2;}
22668    { (exit 1); exit 1; }; };;
22669   --help | --hel | -h )
22670     echo "$ac_cs_usage"; exit 0 ;;
22671   --debug | --d* | -d )
22672     debug=: ;;
22673   --file | --fil | --fi | --f )
22674     $ac_shift
22675     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
22676     ac_need_defaults=false;;
22677   --header | --heade | --head | --hea )
22678     $ac_shift
22679     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
22680     ac_need_defaults=false;;
22681   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
22682   | -silent | --silent | --silen | --sile | --sil | --si | --s)
22683     ac_cs_silent=: ;;
22684
22685   # This is an error.
22686   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
22687 Try \`$0 --help' for more information." >&5
22688 echo "$as_me: error: unrecognized option: $1
22689 Try \`$0 --help' for more information." >&2;}
22690    { (exit 1); exit 1; }; } ;;
22691
22692   *) ac_config_targets="$ac_config_targets $1" ;;
22693
22694   esac
22695   shift
22696 done
22697
22698 ac_configure_extra_args=
22699
22700 if $ac_cs_silent; then
22701   exec 6>/dev/null
22702   ac_configure_extra_args="$ac_configure_extra_args --silent"
22703 fi
22704
22705 _ACEOF
22706 cat >>$CONFIG_STATUS <<_ACEOF
22707 if \$ac_cs_recheck; then
22708   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
22709   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
22710 fi
22711
22712 _ACEOF
22713
22714
22715
22716
22717
22718 cat >>$CONFIG_STATUS <<\_ACEOF
22719 for ac_config_target in $ac_config_targets
22720 do
22721   case "$ac_config_target" in
22722   # Handling of arguments.
22723   "GNUmakefile" ) CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
22724   "src/Makefile.global" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
22725   "src/backend/port/tas.s" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
22726   "src/backend/port/dynloader.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
22727   "src/backend/port/pg_sema.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
22728   "src/backend/port/pg_shmem.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
22729   "src/include/dynloader.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
22730   "src/include/pg_config_os.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
22731   "src/Makefile.port" ) CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
22732   "check_win32_symlinks" ) CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
22733   "src/include/pg_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
22734   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
22735 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
22736    { (exit 1); exit 1; }; };;
22737   esac
22738 done
22739
22740 # If the user did not use the arguments to specify the items to instantiate,
22741 # then the envvar interface is used.  Set only those that are not.
22742 # We use the long form for the default assignment because of an extremely
22743 # bizarre bug on SunOS 4.1.3.
22744 if $ac_need_defaults; then
22745   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
22746   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
22747   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
22748   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
22749 fi
22750
22751 # Have a temporary directory for convenience.  Make it in the build tree
22752 # simply because there is no reason to put it here, and in addition,
22753 # creating and moving files from /tmp can sometimes cause problems.
22754 # Create a temporary directory, and hook for its removal unless debugging.
22755 $debug ||
22756 {
22757   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
22758   trap '{ (exit 1); exit 1; }' 1 2 13 15
22759 }
22760
22761 # Create a (secure) tmp directory for tmp files.
22762
22763 {
22764   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
22765   test -n "$tmp" && test -d "$tmp"
22766 }  ||
22767 {
22768   tmp=./confstat$$-$RANDOM
22769   (umask 077 && mkdir $tmp)
22770 } ||
22771 {
22772    echo "$me: cannot create a temporary directory in ." >&2
22773    { (exit 1); exit 1; }
22774 }
22775
22776 _ACEOF
22777
22778 cat >>$CONFIG_STATUS <<_ACEOF
22779
22780 #
22781 # CONFIG_FILES section.
22782 #
22783
22784 # No need to generate the scripts if there are no CONFIG_FILES.
22785 # This happens for instance when ./config.status config.h
22786 if test -n "\$CONFIG_FILES"; then
22787   # Protect against being on the right side of a sed subst in config.status.
22788   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
22789    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
22790 s,@SHELL@,$SHELL,;t t
22791 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
22792 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
22793 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
22794 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
22795 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
22796 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
22797 s,@exec_prefix@,$exec_prefix,;t t
22798 s,@prefix@,$prefix,;t t
22799 s,@program_transform_name@,$program_transform_name,;t t
22800 s,@bindir@,$bindir,;t t
22801 s,@sbindir@,$sbindir,;t t
22802 s,@libexecdir@,$libexecdir,;t t
22803 s,@datadir@,$datadir,;t t
22804 s,@sysconfdir@,$sysconfdir,;t t
22805 s,@sharedstatedir@,$sharedstatedir,;t t
22806 s,@localstatedir@,$localstatedir,;t t
22807 s,@libdir@,$libdir,;t t
22808 s,@includedir@,$includedir,;t t
22809 s,@oldincludedir@,$oldincludedir,;t t
22810 s,@infodir@,$infodir,;t t
22811 s,@mandir@,$mandir,;t t
22812 s,@build_alias@,$build_alias,;t t
22813 s,@host_alias@,$host_alias,;t t
22814 s,@target_alias@,$target_alias,;t t
22815 s,@DEFS@,$DEFS,;t t
22816 s,@ECHO_C@,$ECHO_C,;t t
22817 s,@ECHO_N@,$ECHO_N,;t t
22818 s,@ECHO_T@,$ECHO_T,;t t
22819 s,@LIBS@,$LIBS,;t t
22820 s,@configure_args@,$configure_args,;t t
22821 s,@build@,$build,;t t
22822 s,@build_cpu@,$build_cpu,;t t
22823 s,@build_vendor@,$build_vendor,;t t
22824 s,@build_os@,$build_os,;t t
22825 s,@host@,$host,;t t
22826 s,@host_cpu@,$host_cpu,;t t
22827 s,@host_vendor@,$host_vendor,;t t
22828 s,@host_os@,$host_os,;t t
22829 s,@PORTNAME@,$PORTNAME,;t t
22830 s,@docdir@,$docdir,;t t
22831 s,@enable_nls@,$enable_nls,;t t
22832 s,@WANTED_LANGUAGES@,$WANTED_LANGUAGES,;t t
22833 s,@default_port@,$default_port,;t t
22834 s,@enable_shared@,$enable_shared,;t t
22835 s,@enable_rpath@,$enable_rpath,;t t
22836 s,@enable_debug@,$enable_debug,;t t
22837 s,@CC@,$CC,;t t
22838 s,@CFLAGS@,$CFLAGS,;t t
22839 s,@LDFLAGS@,$LDFLAGS,;t t
22840 s,@CPPFLAGS@,$CPPFLAGS,;t t
22841 s,@ac_ct_CC@,$ac_ct_CC,;t t
22842 s,@EXEEXT@,$EXEEXT,;t t
22843 s,@OBJEXT@,$OBJEXT,;t t
22844 s,@CPP@,$CPP,;t t
22845 s,@GCC@,$GCC,;t t
22846 s,@TAS@,$TAS,;t t
22847 s,@autodepend@,$autodepend,;t t
22848 s,@INCLUDES@,$INCLUDES,;t t
22849 s,@enable_thread_safety@,$enable_thread_safety,;t t
22850 s,@with_tcl@,$with_tcl,;t t
22851 s,@with_perl@,$with_perl,;t t
22852 s,@with_python@,$with_python,;t t
22853 s,@with_krb5@,$with_krb5,;t t
22854 s,@krb_srvtab@,$krb_srvtab,;t t
22855 s,@with_pam@,$with_pam,;t t
22856 s,@with_bonjour@,$with_bonjour,;t t
22857 s,@with_openssl@,$with_openssl,;t t
22858 s,@with_zlib@,$with_zlib,;t t
22859 s,@EGREP@,$EGREP,;t t
22860 s,@ELF_SYS@,$ELF_SYS,;t t
22861 s,@LDFLAGS_SL@,$LDFLAGS_SL,;t t
22862 s,@AWK@,$AWK,;t t
22863 s,@FLEX@,$FLEX,;t t
22864 s,@FLEXFLAGS@,$FLEXFLAGS,;t t
22865 s,@LN_S@,$LN_S,;t t
22866 s,@LD@,$LD,;t t
22867 s,@with_gnu_ld@,$with_gnu_ld,;t t
22868 s,@ld_R_works@,$ld_R_works,;t t
22869 s,@RANLIB@,$RANLIB,;t t
22870 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
22871 s,@LORDER@,$LORDER,;t t
22872 s,@TAR@,$TAR,;t t
22873 s,@STRIP@,$STRIP,;t t
22874 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
22875 s,@STRIP_STATIC_LIB@,$STRIP_STATIC_LIB,;t t
22876 s,@STRIP_SHARED_LIB@,$STRIP_SHARED_LIB,;t t
22877 s,@YACC@,$YACC,;t t
22878 s,@YFLAGS@,$YFLAGS,;t t
22879 s,@PERL@,$PERL,;t t
22880 s,@perl_archlibexp@,$perl_archlibexp,;t t
22881 s,@perl_privlibexp@,$perl_privlibexp,;t t
22882 s,@perl_useshrplib@,$perl_useshrplib,;t t
22883 s,@perl_embed_ldflags@,$perl_embed_ldflags,;t t
22884 s,@PYTHON@,$PYTHON,;t t
22885 s,@python_version@,$python_version,;t t
22886 s,@python_configdir@,$python_configdir,;t t
22887 s,@python_includespec@,$python_includespec,;t t
22888 s,@python_libdir@,$python_libdir,;t t
22889 s,@python_libspec@,$python_libspec,;t t
22890 s,@python_additional_libs@,$python_additional_libs,;t t
22891 s,@HAVE_IPV6@,$HAVE_IPV6,;t t
22892 s,@LIBOBJS@,$LIBOBJS,;t t
22893 s,@acx_pthread_config@,$acx_pthread_config,;t t
22894 s,@PTHREAD_CC@,$PTHREAD_CC,;t t
22895 s,@PTHREAD_LIBS@,$PTHREAD_LIBS,;t t
22896 s,@PTHREAD_CFLAGS@,$PTHREAD_CFLAGS,;t t
22897 s,@HAVE_POSIX_SIGNALS@,$HAVE_POSIX_SIGNALS,;t t
22898 s,@MSGFMT@,$MSGFMT,;t t
22899 s,@MSGMERGE@,$MSGMERGE,;t t
22900 s,@XGETTEXT@,$XGETTEXT,;t t
22901 s,@localedir@,$localedir,;t t
22902 s,@TCLSH@,$TCLSH,;t t
22903 s,@TCL_CONFIG_SH@,$TCL_CONFIG_SH,;t t
22904 s,@TCL_INCLUDE_SPEC@,$TCL_INCLUDE_SPEC,;t t
22905 s,@TCL_LIB_FILE@,$TCL_LIB_FILE,;t t
22906 s,@TCL_LIBS@,$TCL_LIBS,;t t
22907 s,@TCL_LIB_SPEC@,$TCL_LIB_SPEC,;t t
22908 s,@TCL_SHARED_BUILD@,$TCL_SHARED_BUILD,;t t
22909 s,@TCL_SHLIB_LD_LIBS@,$TCL_SHLIB_LD_LIBS,;t t
22910 s,@NSGMLS@,$NSGMLS,;t t
22911 s,@JADE@,$JADE,;t t
22912 s,@have_docbook@,$have_docbook,;t t
22913 s,@DOCBOOKSTYLE@,$DOCBOOKSTYLE,;t t
22914 s,@COLLATEINDEX@,$COLLATEINDEX,;t t
22915 s,@SGMLSPL@,$SGMLSPL,;t t
22916 s,@vpath_build@,$vpath_build,;t t
22917 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
22918 CEOF
22919
22920 _ACEOF
22921
22922   cat >>$CONFIG_STATUS <<\_ACEOF
22923   # Split the substitutions into bite-sized pieces for seds with
22924   # small command number limits, like on Digital OSF/1 and HP-UX.
22925   ac_max_sed_lines=48
22926   ac_sed_frag=1 # Number of current file.
22927   ac_beg=1 # First line for current file.
22928   ac_end=$ac_max_sed_lines # Line after last line for current file.
22929   ac_more_lines=:
22930   ac_sed_cmds=
22931   while $ac_more_lines; do
22932     if test $ac_beg -gt 1; then
22933       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22934     else
22935       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
22936     fi
22937     if test ! -s $tmp/subs.frag; then
22938       ac_more_lines=false
22939     else
22940       # The purpose of the label and of the branching condition is to
22941       # speed up the sed processing (if there are no `@' at all, there
22942       # is no need to browse any of the substitutions).
22943       # These are the two extra sed commands mentioned above.
22944       (echo ':t
22945   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
22946       if test -z "$ac_sed_cmds"; then
22947         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
22948       else
22949         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
22950       fi
22951       ac_sed_frag=`expr $ac_sed_frag + 1`
22952       ac_beg=$ac_end
22953       ac_end=`expr $ac_end + $ac_max_sed_lines`
22954     fi
22955   done
22956   if test -z "$ac_sed_cmds"; then
22957     ac_sed_cmds=cat
22958   fi
22959 fi # test -n "$CONFIG_FILES"
22960
22961 _ACEOF
22962 cat >>$CONFIG_STATUS <<\_ACEOF
22963 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
22964   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
22965   case $ac_file in
22966   - | *:- | *:-:* ) # input from stdin
22967         cat >$tmp/stdin
22968         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22969         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
22970   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
22971         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
22972   * )   ac_file_in=$ac_file.in ;;
22973   esac
22974
22975   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
22976   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
22977 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22978          X"$ac_file" : 'X\(//\)[^/]' \| \
22979          X"$ac_file" : 'X\(//\)$' \| \
22980          X"$ac_file" : 'X\(/\)' \| \
22981          .     : '\(.\)' 2>/dev/null ||
22982 echo X"$ac_file" |
22983     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
22984           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
22985           /^X\(\/\/\)$/{ s//\1/; q; }
22986           /^X\(\/\).*/{ s//\1/; q; }
22987           s/.*/./; q'`
22988   { if $as_mkdir_p; then
22989     mkdir -p "$ac_dir"
22990   else
22991     as_dir="$ac_dir"
22992     as_dirs=
22993     while test ! -d "$as_dir"; do
22994       as_dirs="$as_dir $as_dirs"
22995       as_dir=`(dirname "$as_dir") 2>/dev/null ||
22996 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22997          X"$as_dir" : 'X\(//\)[^/]' \| \
22998          X"$as_dir" : 'X\(//\)$' \| \
22999          X"$as_dir" : 'X\(/\)' \| \
23000          .     : '\(.\)' 2>/dev/null ||
23001 echo X"$as_dir" |
23002     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23003           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23004           /^X\(\/\/\)$/{ s//\1/; q; }
23005           /^X\(\/\).*/{ s//\1/; q; }
23006           s/.*/./; q'`
23007     done
23008     test ! -n "$as_dirs" || mkdir $as_dirs
23009   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23010 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23011    { (exit 1); exit 1; }; }; }
23012
23013   ac_builddir=.
23014
23015 if test "$ac_dir" != .; then
23016   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
23017   # A "../" for each directory in $ac_dir_suffix.
23018   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23019 else
23020   ac_dir_suffix= ac_top_builddir=
23021 fi
23022
23023 case $srcdir in
23024   .)  # No --srcdir option.  We are building in place.
23025     ac_srcdir=.
23026     if test -z "$ac_top_builddir"; then
23027        ac_top_srcdir=.
23028     else
23029        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23030     fi ;;
23031   [\\/]* | ?:[\\/]* )  # Absolute path.
23032     ac_srcdir=$srcdir$ac_dir_suffix;
23033     ac_top_srcdir=$srcdir ;;
23034   *) # Relative path.
23035     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23036     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23037 esac
23038
23039 # Do not use `cd foo && pwd` to compute absolute paths, because
23040 # the directories may not exist.
23041 case `pwd` in
23042 .) ac_abs_builddir="$ac_dir";;
23043 *)
23044   case "$ac_dir" in
23045   .) ac_abs_builddir=`pwd`;;
23046   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
23047   *) ac_abs_builddir=`pwd`/"$ac_dir";;
23048   esac;;
23049 esac
23050 case $ac_abs_builddir in
23051 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23052 *)
23053   case ${ac_top_builddir}. in
23054   .) ac_abs_top_builddir=$ac_abs_builddir;;
23055   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23056   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23057   esac;;
23058 esac
23059 case $ac_abs_builddir in
23060 .) ac_abs_srcdir=$ac_srcdir;;
23061 *)
23062   case $ac_srcdir in
23063   .) ac_abs_srcdir=$ac_abs_builddir;;
23064   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23065   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23066   esac;;
23067 esac
23068 case $ac_abs_builddir in
23069 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23070 *)
23071   case $ac_top_srcdir in
23072   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23073   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23074   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23075   esac;;
23076 esac
23077
23078
23079
23080   if test x"$ac_file" != x-; then
23081     { echo "$as_me:$LINENO: creating $ac_file" >&5
23082 echo "$as_me: creating $ac_file" >&6;}
23083     rm -f "$ac_file"
23084   fi
23085   # Let's still pretend it is `configure' which instantiates (i.e., don't
23086   # use $as_me), people would be surprised to read:
23087   #    /* config.h.  Generated by config.status.  */
23088   if test x"$ac_file" = x-; then
23089     configure_input=
23090   else
23091     configure_input="$ac_file.  "
23092   fi
23093   configure_input=$configure_input"Generated from `echo $ac_file_in |
23094                                      sed 's,.*/,,'` by configure."
23095
23096   # First look for the input files in the build tree, otherwise in the
23097   # src tree.
23098   ac_file_inputs=`IFS=:
23099     for f in $ac_file_in; do
23100       case $f in
23101       -) echo $tmp/stdin ;;
23102       [\\/$]*)
23103          # Absolute (can't be DOS-style, as IFS=:)
23104          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23105 echo "$as_me: error: cannot find input file: $f" >&2;}
23106    { (exit 1); exit 1; }; }
23107          echo "$f";;
23108       *) # Relative
23109          if test -f "$f"; then
23110            # Build tree
23111            echo "$f"
23112          elif test -f "$srcdir/$f"; then
23113            # Source tree
23114            echo "$srcdir/$f"
23115          else
23116            # /dev/null tree
23117            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23118 echo "$as_me: error: cannot find input file: $f" >&2;}
23119    { (exit 1); exit 1; }; }
23120          fi;;
23121       esac
23122     done` || { (exit 1); exit 1; }
23123 _ACEOF
23124 cat >>$CONFIG_STATUS <<_ACEOF
23125   sed "$ac_vpsub
23126 $extrasub
23127 _ACEOF
23128 cat >>$CONFIG_STATUS <<\_ACEOF
23129 :t
23130 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23131 s,@configure_input@,$configure_input,;t t
23132 s,@srcdir@,$ac_srcdir,;t t
23133 s,@abs_srcdir@,$ac_abs_srcdir,;t t
23134 s,@top_srcdir@,$ac_top_srcdir,;t t
23135 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
23136 s,@builddir@,$ac_builddir,;t t
23137 s,@abs_builddir@,$ac_abs_builddir,;t t
23138 s,@top_builddir@,$ac_top_builddir,;t t
23139 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
23140 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
23141   rm -f $tmp/stdin
23142   if test x"$ac_file" != x-; then
23143     mv $tmp/out $ac_file
23144   else
23145     cat $tmp/out
23146     rm -f $tmp/out
23147   fi
23148
23149 done
23150 _ACEOF
23151 cat >>$CONFIG_STATUS <<\_ACEOF
23152
23153 #
23154 # CONFIG_HEADER section.
23155 #
23156
23157 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
23158 # NAME is the cpp macro being defined and VALUE is the value it is being given.
23159 #
23160 # ac_d sets the value in "#define NAME VALUE" lines.
23161 ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
23162 ac_dB='[         ].*$,\1#\2'
23163 ac_dC=' '
23164 ac_dD=',;t'
23165 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
23166 ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
23167 ac_uB='$,\1#\2define\3'
23168 ac_uC=' '
23169 ac_uD=',;t'
23170
23171 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
23172   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23173   case $ac_file in
23174   - | *:- | *:-:* ) # input from stdin
23175         cat >$tmp/stdin
23176         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23177         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23178   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23179         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23180   * )   ac_file_in=$ac_file.in ;;
23181   esac
23182
23183   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
23184 echo "$as_me: creating $ac_file" >&6;}
23185
23186   # First look for the input files in the build tree, otherwise in the
23187   # src tree.
23188   ac_file_inputs=`IFS=:
23189     for f in $ac_file_in; do
23190       case $f in
23191       -) echo $tmp/stdin ;;
23192       [\\/$]*)
23193          # Absolute (can't be DOS-style, as IFS=:)
23194          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23195 echo "$as_me: error: cannot find input file: $f" >&2;}
23196    { (exit 1); exit 1; }; }
23197          # Do quote $f, to prevent DOS paths from being IFS'd.
23198          echo "$f";;
23199       *) # Relative
23200          if test -f "$f"; then
23201            # Build tree
23202            echo "$f"
23203          elif test -f "$srcdir/$f"; then
23204            # Source tree
23205            echo "$srcdir/$f"
23206          else
23207            # /dev/null tree
23208            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23209 echo "$as_me: error: cannot find input file: $f" >&2;}
23210    { (exit 1); exit 1; }; }
23211          fi;;
23212       esac
23213     done` || { (exit 1); exit 1; }
23214   # Remove the trailing spaces.
23215   sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
23216
23217 _ACEOF
23218
23219 # Transform confdefs.h into two sed scripts, `conftest.defines' and
23220 # `conftest.undefs', that substitutes the proper values into
23221 # config.h.in to produce config.h.  The first handles `#define'
23222 # templates, and the second `#undef' templates.
23223 # And first: Protect against being on the right side of a sed subst in
23224 # config.status.  Protect against being in an unquoted here document
23225 # in config.status.
23226 rm -f conftest.defines conftest.undefs
23227 # Using a here document instead of a string reduces the quoting nightmare.
23228 # Putting comments in sed scripts is not portable.
23229 #
23230 # `end' is used to avoid that the second main sed command (meant for
23231 # 0-ary CPP macros) applies to n-ary macro definitions.
23232 # See the Autoconf documentation for `clear'.
23233 cat >confdef2sed.sed <<\_ACEOF
23234 s/[\\&,]/\\&/g
23235 s,[\\$`],\\&,g
23236 t clear
23237 : clear
23238 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
23239 t end
23240 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
23241 : end
23242 _ACEOF
23243 # If some macros were called several times there might be several times
23244 # the same #defines, which is useless.  Nevertheless, we may not want to
23245 # sort them, since we want the *last* AC-DEFINE to be honored.
23246 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
23247 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
23248 rm -f confdef2sed.sed
23249
23250 # This sed command replaces #undef with comments.  This is necessary, for
23251 # example, in the case of _POSIX_SOURCE, which is predefined and required
23252 # on some systems where configure will not decide to define it.
23253 cat >>conftest.undefs <<\_ACEOF
23254 s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
23255 _ACEOF
23256
23257 # Break up conftest.defines because some shells have a limit on the size
23258 # of here documents, and old seds have small limits too (100 cmds).
23259 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
23260 echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
23261 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
23262 echo '  :' >>$CONFIG_STATUS
23263 rm -f conftest.tail
23264 while grep . conftest.defines >/dev/null
23265 do
23266   # Write a limited-size here document to $tmp/defines.sed.
23267   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
23268   # Speed up: don't consider the non `#define' lines.
23269   echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
23270   # Work around the forget-to-reset-the-flag bug.
23271   echo 't clr' >>$CONFIG_STATUS
23272   echo ': clr' >>$CONFIG_STATUS
23273   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
23274   echo 'CEOF
23275   sed -f $tmp/defines.sed $tmp/in >$tmp/out
23276   rm -f $tmp/in
23277   mv $tmp/out $tmp/in
23278 ' >>$CONFIG_STATUS
23279   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
23280   rm -f conftest.defines
23281   mv conftest.tail conftest.defines
23282 done
23283 rm -f conftest.defines
23284 echo '  fi # grep' >>$CONFIG_STATUS
23285 echo >>$CONFIG_STATUS
23286
23287 # Break up conftest.undefs because some shells have a limit on the size
23288 # of here documents, and old seds have small limits too (100 cmds).
23289 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
23290 rm -f conftest.tail
23291 while grep . conftest.undefs >/dev/null
23292 do
23293   # Write a limited-size here document to $tmp/undefs.sed.
23294   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
23295   # Speed up: don't consider the non `#undef'
23296   echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
23297   # Work around the forget-to-reset-the-flag bug.
23298   echo 't clr' >>$CONFIG_STATUS
23299   echo ': clr' >>$CONFIG_STATUS
23300   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
23301   echo 'CEOF
23302   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
23303   rm -f $tmp/in
23304   mv $tmp/out $tmp/in
23305 ' >>$CONFIG_STATUS
23306   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
23307   rm -f conftest.undefs
23308   mv conftest.tail conftest.undefs
23309 done
23310 rm -f conftest.undefs
23311
23312 cat >>$CONFIG_STATUS <<\_ACEOF
23313   # Let's still pretend it is `configure' which instantiates (i.e., don't
23314   # use $as_me), people would be surprised to read:
23315   #    /* config.h.  Generated by config.status.  */
23316   if test x"$ac_file" = x-; then
23317     echo "/* Generated by configure.  */" >$tmp/config.h
23318   else
23319     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
23320   fi
23321   cat $tmp/in >>$tmp/config.h
23322   rm -f $tmp/in
23323   if test x"$ac_file" != x-; then
23324     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
23325       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
23326 echo "$as_me: $ac_file is unchanged" >&6;}
23327     else
23328       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
23329 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23330          X"$ac_file" : 'X\(//\)[^/]' \| \
23331          X"$ac_file" : 'X\(//\)$' \| \
23332          X"$ac_file" : 'X\(/\)' \| \
23333          .     : '\(.\)' 2>/dev/null ||
23334 echo X"$ac_file" |
23335     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23336           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23337           /^X\(\/\/\)$/{ s//\1/; q; }
23338           /^X\(\/\).*/{ s//\1/; q; }
23339           s/.*/./; q'`
23340       { if $as_mkdir_p; then
23341     mkdir -p "$ac_dir"
23342   else
23343     as_dir="$ac_dir"
23344     as_dirs=
23345     while test ! -d "$as_dir"; do
23346       as_dirs="$as_dir $as_dirs"
23347       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23348 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23349          X"$as_dir" : 'X\(//\)[^/]' \| \
23350          X"$as_dir" : 'X\(//\)$' \| \
23351          X"$as_dir" : 'X\(/\)' \| \
23352          .     : '\(.\)' 2>/dev/null ||
23353 echo X"$as_dir" |
23354     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23355           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23356           /^X\(\/\/\)$/{ s//\1/; q; }
23357           /^X\(\/\).*/{ s//\1/; q; }
23358           s/.*/./; q'`
23359     done
23360     test ! -n "$as_dirs" || mkdir $as_dirs
23361   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23362 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23363    { (exit 1); exit 1; }; }; }
23364
23365       rm -f $ac_file
23366       mv $tmp/config.h $ac_file
23367     fi
23368   else
23369     cat $tmp/config.h
23370     rm -f $tmp/config.h
23371   fi
23372   # Run the commands associated with the file.
23373   case $ac_file in
23374     src/include/pg_config.h )
23375 # Update timestamp for pg_config.h (see Makefile.global)
23376 echo >src/include/stamp-h
23377  ;;
23378   esac
23379 done
23380 _ACEOF
23381 cat >>$CONFIG_STATUS <<\_ACEOF
23382
23383 #
23384 # CONFIG_LINKS section.
23385 #
23386
23387 for ac_file in : $CONFIG_LINKS; do test "x$ac_file" = x: && continue
23388   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
23389   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
23390
23391   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_dest" >&5
23392 echo "$as_me: linking $srcdir/$ac_source to $ac_dest" >&6;}
23393
23394   if test ! -r $srcdir/$ac_source; then
23395     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
23396 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
23397    { (exit 1); exit 1; }; }
23398   fi
23399   rm -f $ac_dest
23400
23401   # Make relative symlinks.
23402   ac_dest_dir=`(dirname "$ac_dest") 2>/dev/null ||
23403 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23404          X"$ac_dest" : 'X\(//\)[^/]' \| \
23405          X"$ac_dest" : 'X\(//\)$' \| \
23406          X"$ac_dest" : 'X\(/\)' \| \
23407          .     : '\(.\)' 2>/dev/null ||
23408 echo X"$ac_dest" |
23409     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23410           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23411           /^X\(\/\/\)$/{ s//\1/; q; }
23412           /^X\(\/\).*/{ s//\1/; q; }
23413           s/.*/./; q'`
23414   { if $as_mkdir_p; then
23415     mkdir -p "$ac_dest_dir"
23416   else
23417     as_dir="$ac_dest_dir"
23418     as_dirs=
23419     while test ! -d "$as_dir"; do
23420       as_dirs="$as_dir $as_dirs"
23421       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23422 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23423          X"$as_dir" : 'X\(//\)[^/]' \| \
23424          X"$as_dir" : 'X\(//\)$' \| \
23425          X"$as_dir" : 'X\(/\)' \| \
23426          .     : '\(.\)' 2>/dev/null ||
23427 echo X"$as_dir" |
23428     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23429           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23430           /^X\(\/\/\)$/{ s//\1/; q; }
23431           /^X\(\/\).*/{ s//\1/; q; }
23432           s/.*/./; q'`
23433     done
23434     test ! -n "$as_dirs" || mkdir $as_dirs
23435   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dest_dir\"" >&5
23436 echo "$as_me: error: cannot create directory \"$ac_dest_dir\"" >&2;}
23437    { (exit 1); exit 1; }; }; }
23438
23439   ac_builddir=.
23440
23441 if test "$ac_dest_dir" != .; then
23442   ac_dir_suffix=/`echo "$ac_dest_dir" | sed 's,^\.[\\/],,'`
23443   # A "../" for each directory in $ac_dir_suffix.
23444   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23445 else
23446   ac_dir_suffix= ac_top_builddir=
23447 fi
23448
23449 case $srcdir in
23450   .)  # No --srcdir option.  We are building in place.
23451     ac_srcdir=.
23452     if test -z "$ac_top_builddir"; then
23453        ac_top_srcdir=.
23454     else
23455        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23456     fi ;;
23457   [\\/]* | ?:[\\/]* )  # Absolute path.
23458     ac_srcdir=$srcdir$ac_dir_suffix;
23459     ac_top_srcdir=$srcdir ;;
23460   *) # Relative path.
23461     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23462     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23463 esac
23464
23465 # Do not use `cd foo && pwd` to compute absolute paths, because
23466 # the directories may not exist.
23467 case `pwd` in
23468 .) ac_abs_builddir="$ac_dest_dir";;
23469 *)
23470   case "$ac_dest_dir" in
23471   .) ac_abs_builddir=`pwd`;;
23472   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dest_dir";;
23473   *) ac_abs_builddir=`pwd`/"$ac_dest_dir";;
23474   esac;;
23475 esac
23476 case $ac_abs_builddir in
23477 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23478 *)
23479   case ${ac_top_builddir}. in
23480   .) ac_abs_top_builddir=$ac_abs_builddir;;
23481   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23482   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23483   esac;;
23484 esac
23485 case $ac_abs_builddir in
23486 .) ac_abs_srcdir=$ac_srcdir;;
23487 *)
23488   case $ac_srcdir in
23489   .) ac_abs_srcdir=$ac_abs_builddir;;
23490   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23491   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23492   esac;;
23493 esac
23494 case $ac_abs_builddir in
23495 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23496 *)
23497   case $ac_top_srcdir in
23498   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23499   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23500   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23501   esac;;
23502 esac
23503
23504
23505   case $srcdir in
23506   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
23507       *) ac_rel_source=$ac_top_builddir$srcdir/$ac_source ;;
23508   esac
23509
23510   # Try a symlink, then a hard link, then a copy.
23511   ln -s $ac_rel_source $ac_dest 2>/dev/null ||
23512     ln $srcdir/$ac_source $ac_dest 2>/dev/null ||
23513     cp -p $srcdir/$ac_source $ac_dest ||
23514     { { echo "$as_me:$LINENO: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&5
23515 echo "$as_me: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&2;}
23516    { (exit 1); exit 1; }; }
23517 done
23518 _ACEOF
23519 cat >>$CONFIG_STATUS <<\_ACEOF
23520
23521 #
23522 # CONFIG_COMMANDS section.
23523 #
23524 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
23525   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
23526   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
23527   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
23528 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23529          X"$ac_dest" : 'X\(//\)[^/]' \| \
23530          X"$ac_dest" : 'X\(//\)$' \| \
23531          X"$ac_dest" : 'X\(/\)' \| \
23532          .     : '\(.\)' 2>/dev/null ||
23533 echo X"$ac_dest" |
23534     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23535           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23536           /^X\(\/\/\)$/{ s//\1/; q; }
23537           /^X\(\/\).*/{ s//\1/; q; }
23538           s/.*/./; q'`
23539   { if $as_mkdir_p; then
23540     mkdir -p "$ac_dir"
23541   else
23542     as_dir="$ac_dir"
23543     as_dirs=
23544     while test ! -d "$as_dir"; do
23545       as_dirs="$as_dir $as_dirs"
23546       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23547 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23548          X"$as_dir" : 'X\(//\)[^/]' \| \
23549          X"$as_dir" : 'X\(//\)$' \| \
23550          X"$as_dir" : 'X\(/\)' \| \
23551          .     : '\(.\)' 2>/dev/null ||
23552 echo X"$as_dir" |
23553     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23554           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23555           /^X\(\/\/\)$/{ s//\1/; q; }
23556           /^X\(\/\).*/{ s//\1/; q; }
23557           s/.*/./; q'`
23558     done
23559     test ! -n "$as_dirs" || mkdir $as_dirs
23560   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23561 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23562    { (exit 1); exit 1; }; }; }
23563
23564   ac_builddir=.
23565
23566 if test "$ac_dir" != .; then
23567   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
23568   # A "../" for each directory in $ac_dir_suffix.
23569   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23570 else
23571   ac_dir_suffix= ac_top_builddir=
23572 fi
23573
23574 case $srcdir in
23575   .)  # No --srcdir option.  We are building in place.
23576     ac_srcdir=.
23577     if test -z "$ac_top_builddir"; then
23578        ac_top_srcdir=.
23579     else
23580        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23581     fi ;;
23582   [\\/]* | ?:[\\/]* )  # Absolute path.
23583     ac_srcdir=$srcdir$ac_dir_suffix;
23584     ac_top_srcdir=$srcdir ;;
23585   *) # Relative path.
23586     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23587     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23588 esac
23589
23590 # Do not use `cd foo && pwd` to compute absolute paths, because
23591 # the directories may not exist.
23592 case `pwd` in
23593 .) ac_abs_builddir="$ac_dir";;
23594 *)
23595   case "$ac_dir" in
23596   .) ac_abs_builddir=`pwd`;;
23597   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
23598   *) ac_abs_builddir=`pwd`/"$ac_dir";;
23599   esac;;
23600 esac
23601 case $ac_abs_builddir in
23602 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23603 *)
23604   case ${ac_top_builddir}. in
23605   .) ac_abs_top_builddir=$ac_abs_builddir;;
23606   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23607   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23608   esac;;
23609 esac
23610 case $ac_abs_builddir in
23611 .) ac_abs_srcdir=$ac_srcdir;;
23612 *)
23613   case $ac_srcdir in
23614   .) ac_abs_srcdir=$ac_abs_builddir;;
23615   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23616   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23617   esac;;
23618 esac
23619 case $ac_abs_builddir in
23620 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23621 *)
23622   case $ac_top_srcdir in
23623   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23624   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23625   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23626   esac;;
23627 esac
23628
23629
23630   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
23631 echo "$as_me: executing $ac_dest commands" >&6;}
23632   case $ac_dest in
23633     check_win32_symlinks )
23634 # Links sometimes fail undetected on Mingw -
23635 # so here we detect it and warn the user
23636 for FILE in $CONFIG_LINKS
23637  do
23638         # test -e works for symlinks in the MinGW console
23639         test -e `expr "$FILE" : '\([^:]*\)'` || { echo "$as_me:$LINENO: WARNING: *** link for $FILE - please fix by hand" >&5
23640 echo "$as_me: WARNING: *** link for $FILE - please fix by hand" >&2;}
23641  done
23642  ;;
23643   esac
23644 done
23645 _ACEOF
23646
23647 cat >>$CONFIG_STATUS <<\_ACEOF
23648
23649 { (exit 0); exit 0; }
23650 _ACEOF
23651 chmod +x $CONFIG_STATUS
23652 ac_clean_files=$ac_clean_files_save
23653
23654
23655 # configure is writing to config.log, and then calls config.status.
23656 # config.status does its own redirection, appending to config.log.
23657 # Unfortunately, on DOS this fails, as config.log is still kept open
23658 # by configure, so config.status won't be able to write to it; its
23659 # output is simply discarded.  So we exec the FD to /dev/null,
23660 # effectively closing config.log, so it can be properly (re)opened and
23661 # appended to by config.status.  When coming back to configure, we
23662 # need to make the FD available again.
23663 if test "$no_create" != yes; then
23664   ac_cs_success=:
23665   ac_config_status_args=
23666   test "$silent" = yes &&
23667     ac_config_status_args="$ac_config_status_args --quiet"
23668   exec 5>/dev/null
23669   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
23670   exec 5>>config.log
23671   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
23672   # would make configure fail if this is the last instruction.
23673   $ac_cs_success || { (exit 1); exit 1; }
23674 fi
23675
23676