]> granicus.if.org Git - postgresql/blob - configure
Remove:
[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-2006, 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_ldap 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-ldap             build with LDAP support
892   --with-bonjour          build with Bonjour support
893   --with-openssl          build with OpenSSL support
894   --with-libedit-preferred  prefer BSD Libedit over GNU Readline
895   --without-readline      do not use GNU Readline / BSD Libedit line editing
896   --without-zlib          do not use Zlib
897   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
898
899 Some influential environment variables:
900   CC          C compiler command
901   CFLAGS      C compiler flags
902   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
903               nonstandard directory <lib dir>
904   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
905               headers in a nonstandard directory <include dir>
906   CPP         C preprocessor
907   LDFLAGS_SL
908   DOCBOOKSTYLE
909               location of DocBook stylesheets
910
911 Use these variables to override the choices made by `configure' or to help
912 it to find libraries and programs with nonstandard names/locations.
913
914 Report bugs to <pgsql-bugs@postgresql.org>.
915 _ACEOF
916 fi
917
918 if test "$ac_init_help" = "recursive"; then
919   # If there are subdirs, report their specific --help.
920   ac_popdir=`pwd`
921   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
922     test -d $ac_dir || continue
923     ac_builddir=.
924
925 if test "$ac_dir" != .; then
926   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
927   # A "../" for each directory in $ac_dir_suffix.
928   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
929 else
930   ac_dir_suffix= ac_top_builddir=
931 fi
932
933 case $srcdir in
934   .)  # No --srcdir option.  We are building in place.
935     ac_srcdir=.
936     if test -z "$ac_top_builddir"; then
937        ac_top_srcdir=.
938     else
939        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
940     fi ;;
941   [\\/]* | ?:[\\/]* )  # Absolute path.
942     ac_srcdir=$srcdir$ac_dir_suffix;
943     ac_top_srcdir=$srcdir ;;
944   *) # Relative path.
945     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
946     ac_top_srcdir=$ac_top_builddir$srcdir ;;
947 esac
948
949 # Do not use `cd foo && pwd` to compute absolute paths, because
950 # the directories may not exist.
951 case `pwd` in
952 .) ac_abs_builddir="$ac_dir";;
953 *)
954   case "$ac_dir" in
955   .) ac_abs_builddir=`pwd`;;
956   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
957   *) ac_abs_builddir=`pwd`/"$ac_dir";;
958   esac;;
959 esac
960 case $ac_abs_builddir in
961 .) ac_abs_top_builddir=${ac_top_builddir}.;;
962 *)
963   case ${ac_top_builddir}. in
964   .) ac_abs_top_builddir=$ac_abs_builddir;;
965   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
966   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
967   esac;;
968 esac
969 case $ac_abs_builddir in
970 .) ac_abs_srcdir=$ac_srcdir;;
971 *)
972   case $ac_srcdir in
973   .) ac_abs_srcdir=$ac_abs_builddir;;
974   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
975   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
976   esac;;
977 esac
978 case $ac_abs_builddir in
979 .) ac_abs_top_srcdir=$ac_top_srcdir;;
980 *)
981   case $ac_top_srcdir in
982   .) ac_abs_top_srcdir=$ac_abs_builddir;;
983   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
984   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
985   esac;;
986 esac
987
988     cd $ac_dir
989     # Check for guested configure; otherwise get Cygnus style configure.
990     if test -f $ac_srcdir/configure.gnu; then
991       echo
992       $SHELL $ac_srcdir/configure.gnu  --help=recursive
993     elif test -f $ac_srcdir/configure; then
994       echo
995       $SHELL $ac_srcdir/configure  --help=recursive
996     elif test -f $ac_srcdir/configure.ac ||
997            test -f $ac_srcdir/configure.in; then
998       echo
999       $ac_configure --help
1000     else
1001       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1002     fi
1003     cd $ac_popdir
1004   done
1005 fi
1006
1007 test -n "$ac_init_help" && exit 0
1008 if $ac_init_version; then
1009   cat <<\_ACEOF
1010 PostgreSQL configure 8.2devel
1011 generated by GNU Autoconf 2.59
1012
1013 Copyright (C) 2003 Free Software Foundation, Inc.
1014 This configure script is free software; the Free Software Foundation
1015 gives unlimited permission to copy, distribute and modify it.
1016
1017 Copyright (c) 1996-2006, PostgreSQL Global Development Group
1018 _ACEOF
1019   exit 0
1020 fi
1021 exec 5>config.log
1022 cat >&5 <<_ACEOF
1023 This file contains any messages produced by compilers while
1024 running configure, to aid debugging if configure makes a mistake.
1025
1026 It was created by PostgreSQL $as_me 8.2devel, which was
1027 generated by GNU Autoconf 2.59.  Invocation command line was
1028
1029   $ $0 $@
1030
1031 _ACEOF
1032 {
1033 cat <<_ASUNAME
1034 ## --------- ##
1035 ## Platform. ##
1036 ## --------- ##
1037
1038 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1039 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1040 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1041 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1042 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1043
1044 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1045 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1046
1047 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1048 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1049 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1050 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1051 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1052 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1053 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1054
1055 _ASUNAME
1056
1057 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1058 for as_dir in $PATH
1059 do
1060   IFS=$as_save_IFS
1061   test -z "$as_dir" && as_dir=.
1062   echo "PATH: $as_dir"
1063 done
1064
1065 } >&5
1066
1067 cat >&5 <<_ACEOF
1068
1069
1070 ## ----------- ##
1071 ## Core tests. ##
1072 ## ----------- ##
1073
1074 _ACEOF
1075
1076
1077 # Keep a trace of the command line.
1078 # Strip out --no-create and --no-recursion so they do not pile up.
1079 # Strip out --silent because we don't want to record it for future runs.
1080 # Also quote any args containing shell meta-characters.
1081 # Make two passes to allow for proper duplicate-argument suppression.
1082 ac_configure_args=
1083 ac_configure_args0=
1084 ac_configure_args1=
1085 ac_sep=
1086 ac_must_keep_next=false
1087 for ac_pass in 1 2
1088 do
1089   for ac_arg
1090   do
1091     case $ac_arg in
1092     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1093     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1094     | -silent | --silent | --silen | --sile | --sil)
1095       continue ;;
1096     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1097       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1098     esac
1099     case $ac_pass in
1100     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1101     2)
1102       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1103       if test $ac_must_keep_next = true; then
1104         ac_must_keep_next=false # Got value, back to normal.
1105       else
1106         case $ac_arg in
1107           *=* | --config-cache | -C | -disable-* | --disable-* \
1108           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1109           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1110           | -with-* | --with-* | -without-* | --without-* | --x)
1111             case "$ac_configure_args0 " in
1112               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1113             esac
1114             ;;
1115           -* ) ac_must_keep_next=true ;;
1116         esac
1117       fi
1118       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1119       # Get rid of the leading space.
1120       ac_sep=" "
1121       ;;
1122     esac
1123   done
1124 done
1125 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1126 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1127
1128 # When interrupted or exit'd, cleanup temporary files, and complete
1129 # config.log.  We remove comments because anyway the quotes in there
1130 # would cause problems or look ugly.
1131 # WARNING: Be sure not to use single quotes in there, as some shells,
1132 # such as our DU 5.0 friend, will then `close' the trap.
1133 trap 'exit_status=$?
1134   # Save into config.log some information that might help in debugging.
1135   {
1136     echo
1137
1138     cat <<\_ASBOX
1139 ## ---------------- ##
1140 ## Cache variables. ##
1141 ## ---------------- ##
1142 _ASBOX
1143     echo
1144     # The following way of writing the cache mishandles newlines in values,
1145 {
1146   (set) 2>&1 |
1147     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1148     *ac_space=\ *)
1149       sed -n \
1150         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1151           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1152       ;;
1153     *)
1154       sed -n \
1155         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1156       ;;
1157     esac;
1158 }
1159     echo
1160
1161     cat <<\_ASBOX
1162 ## ----------------- ##
1163 ## Output variables. ##
1164 ## ----------------- ##
1165 _ASBOX
1166     echo
1167     for ac_var in $ac_subst_vars
1168     do
1169       eval ac_val=$`echo $ac_var`
1170       echo "$ac_var='"'"'$ac_val'"'"'"
1171     done | sort
1172     echo
1173
1174     if test -n "$ac_subst_files"; then
1175       cat <<\_ASBOX
1176 ## ------------- ##
1177 ## Output files. ##
1178 ## ------------- ##
1179 _ASBOX
1180       echo
1181       for ac_var in $ac_subst_files
1182       do
1183         eval ac_val=$`echo $ac_var`
1184         echo "$ac_var='"'"'$ac_val'"'"'"
1185       done | sort
1186       echo
1187     fi
1188
1189     if test -s confdefs.h; then
1190       cat <<\_ASBOX
1191 ## ----------- ##
1192 ## confdefs.h. ##
1193 ## ----------- ##
1194 _ASBOX
1195       echo
1196       sed "/^$/d" confdefs.h | sort
1197       echo
1198     fi
1199     test "$ac_signal" != 0 &&
1200       echo "$as_me: caught signal $ac_signal"
1201     echo "$as_me: exit $exit_status"
1202   } >&5
1203   rm -f core *.core &&
1204   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1205     exit $exit_status
1206      ' 0
1207 for ac_signal in 1 2 13 15; do
1208   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1209 done
1210 ac_signal=0
1211
1212 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1213 rm -rf conftest* confdefs.h
1214 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1215 echo >confdefs.h
1216
1217 # Predefined preprocessor variables.
1218
1219 cat >>confdefs.h <<_ACEOF
1220 #define PACKAGE_NAME "$PACKAGE_NAME"
1221 _ACEOF
1222
1223
1224 cat >>confdefs.h <<_ACEOF
1225 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1226 _ACEOF
1227
1228
1229 cat >>confdefs.h <<_ACEOF
1230 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1231 _ACEOF
1232
1233
1234 cat >>confdefs.h <<_ACEOF
1235 #define PACKAGE_STRING "$PACKAGE_STRING"
1236 _ACEOF
1237
1238
1239 cat >>confdefs.h <<_ACEOF
1240 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1241 _ACEOF
1242
1243
1244 # Let the site file select an alternate cache file if it wants to.
1245 # Prefer explicitly selected file to automatically selected ones.
1246 if test -z "$CONFIG_SITE"; then
1247   if test "x$prefix" != xNONE; then
1248     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1249   else
1250     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1251   fi
1252 fi
1253 for ac_site_file in $CONFIG_SITE; do
1254   if test -r "$ac_site_file"; then
1255     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1256 echo "$as_me: loading site script $ac_site_file" >&6;}
1257     sed 's/^/| /' "$ac_site_file" >&5
1258     . "$ac_site_file"
1259   fi
1260 done
1261
1262 if test -r "$cache_file"; then
1263   # Some versions of bash will fail to source /dev/null (special
1264   # files actually), so we avoid doing that.
1265   if test -f "$cache_file"; then
1266     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1267 echo "$as_me: loading cache $cache_file" >&6;}
1268     case $cache_file in
1269       [\\/]* | ?:[\\/]* ) . $cache_file;;
1270       *)                      . ./$cache_file;;
1271     esac
1272   fi
1273 else
1274   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1275 echo "$as_me: creating cache $cache_file" >&6;}
1276   >$cache_file
1277 fi
1278
1279 # Check that the precious variables saved in the cache have kept the same
1280 # value.
1281 ac_cache_corrupted=false
1282 for ac_var in `(set) 2>&1 |
1283                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1284   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1285   eval ac_new_set=\$ac_env_${ac_var}_set
1286   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1287   eval ac_new_val="\$ac_env_${ac_var}_value"
1288   case $ac_old_set,$ac_new_set in
1289     set,)
1290       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1291 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1292       ac_cache_corrupted=: ;;
1293     ,set)
1294       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1295 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1296       ac_cache_corrupted=: ;;
1297     ,);;
1298     *)
1299       if test "x$ac_old_val" != "x$ac_new_val"; then
1300         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1301 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1302         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1303 echo "$as_me:   former value:  $ac_old_val" >&2;}
1304         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1305 echo "$as_me:   current value: $ac_new_val" >&2;}
1306         ac_cache_corrupted=:
1307       fi;;
1308   esac
1309   # Pass precious variables to config.status.
1310   if test "$ac_new_set" = set; then
1311     case $ac_new_val in
1312     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1313       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1314     *) ac_arg=$ac_var=$ac_new_val ;;
1315     esac
1316     case " $ac_configure_args " in
1317       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1318       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1319     esac
1320   fi
1321 done
1322 if $ac_cache_corrupted; then
1323   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1324 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1325   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1326 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1327    { (exit 1); exit 1; }; }
1328 fi
1329
1330 ac_ext=c
1331 ac_cpp='$CPP $CPPFLAGS'
1332 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1333 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1334 ac_compiler_gnu=$ac_cv_c_compiler_gnu
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
1366 ac_aux_dir=
1367 for ac_dir in config $srcdir/config; do
1368   if test -f $ac_dir/install-sh; then
1369     ac_aux_dir=$ac_dir
1370     ac_install_sh="$ac_aux_dir/install-sh -c"
1371     break
1372   elif test -f $ac_dir/install.sh; then
1373     ac_aux_dir=$ac_dir
1374     ac_install_sh="$ac_aux_dir/install.sh -c"
1375     break
1376   elif test -f $ac_dir/shtool; then
1377     ac_aux_dir=$ac_dir
1378     ac_install_sh="$ac_aux_dir/shtool install -c"
1379     break
1380   fi
1381 done
1382 if test -z "$ac_aux_dir"; then
1383   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config $srcdir/config" >&5
1384 echo "$as_me: error: cannot find install-sh or install.sh in config $srcdir/config" >&2;}
1385    { (exit 1); exit 1; }; }
1386 fi
1387 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1388 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1389 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1390
1391
1392 configure_args=$ac_configure_args
1393
1394
1395
1396 cat >>confdefs.h <<_ACEOF
1397 #define PG_VERSION "$PACKAGE_VERSION"
1398 _ACEOF
1399
1400
1401 # Make sure we can run config.sub.
1402 $ac_config_sub sun4 >/dev/null 2>&1 ||
1403   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1404 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1405    { (exit 1); exit 1; }; }
1406
1407 echo "$as_me:$LINENO: checking build system type" >&5
1408 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1409 if test "${ac_cv_build+set}" = set; then
1410   echo $ECHO_N "(cached) $ECHO_C" >&6
1411 else
1412   ac_cv_build_alias=$build_alias
1413 test -z "$ac_cv_build_alias" &&
1414   ac_cv_build_alias=`$ac_config_guess`
1415 test -z "$ac_cv_build_alias" &&
1416   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1417 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1418    { (exit 1); exit 1; }; }
1419 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1420   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1421 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1422    { (exit 1); exit 1; }; }
1423
1424 fi
1425 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1426 echo "${ECHO_T}$ac_cv_build" >&6
1427 build=$ac_cv_build
1428 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1429 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1430 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1431
1432
1433 echo "$as_me:$LINENO: checking host system type" >&5
1434 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1435 if test "${ac_cv_host+set}" = set; then
1436   echo $ECHO_N "(cached) $ECHO_C" >&6
1437 else
1438   ac_cv_host_alias=$host_alias
1439 test -z "$ac_cv_host_alias" &&
1440   ac_cv_host_alias=$ac_cv_build_alias
1441 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1442   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1443 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1444    { (exit 1); exit 1; }; }
1445
1446 fi
1447 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1448 echo "${ECHO_T}$ac_cv_host" >&6
1449 host=$ac_cv_host
1450 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1451 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1452 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1453
1454
1455
1456 template=
1457 echo "$as_me:$LINENO: checking which template to use" >&5
1458 echo $ECHO_N "checking which template to use... $ECHO_C" >&6
1459
1460
1461
1462
1463 # Check whether --with-template or --without-template was given.
1464 if test "${with_template+set}" = set; then
1465   withval="$with_template"
1466
1467   case $withval in
1468     yes)
1469       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1470 echo "$as_me: error: argument required for --with-template option" >&2;}
1471    { (exit 1); exit 1; }; }
1472       ;;
1473     no)
1474       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1475 echo "$as_me: error: argument required for --with-template option" >&2;}
1476    { (exit 1); exit 1; }; }
1477       ;;
1478     *)
1479
1480   case $withval in
1481     list)   echo; ls "$srcdir/src/template"; exit;;
1482     *)      if test -f "$srcdir/src/template/$with_template" ; then
1483               template=$withval
1484             else
1485               { { echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
1486 echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
1487    { (exit 1); exit 1; }; }
1488             fi;;
1489   esac
1490
1491       ;;
1492   esac
1493
1494 else
1495
1496 # --with-template not given
1497
1498 case $host_os in
1499      aix*) template=aix ;;
1500     bsdi*) template=bsdi ;;
1501   cygwin*) template=cygwin ;;
1502   darwin*) template=darwin ;;
1503     dgux*) template=dgux ;;
1504  freebsd*) template=freebsd ;;
1505     hpux*) template=hpux ;;
1506     irix*) template=irix ;;
1507  linux*|gnu*|k*bsd*-gnu)
1508            template=linux ;;
1509    mingw*) template=win32 ;;
1510   netbsd*) template=netbsd ;;
1511 nextstep*) template=nextstep ;;
1512  openbsd*) template=openbsd ;;
1513      osf*) template=osf ;;
1514      sco*) template=sco ;;
1515  solaris*) template=solaris ;;
1516    sunos*) template=sunos4 ;;
1517  sysv4.2*)
1518         case $host_vendor in
1519           univel) template=univel ;;
1520         esac ;;
1521    sysv4*) template=svr4 ;;
1522    sysv5*) template=unixware ;;
1523   ultrix*) template=ultrix4 ;;
1524 esac
1525
1526   if test x"$template" = x"" ; then
1527     { { echo "$as_me:$LINENO: error:
1528 *******************************************************************
1529 PostgreSQL has apparently not been ported to your platform yet.
1530 To try a manual configuration, look into the src/template directory
1531 for a similar platform and use the '--with-template=' option.
1532
1533 Please also contact <pgsql-ports@postgresql.org> to see about
1534 rectifying this.  Include the above 'checking host system type...'
1535 line.
1536 *******************************************************************
1537 " >&5
1538 echo "$as_me: error:
1539 *******************************************************************
1540 PostgreSQL has apparently not been ported to your platform yet.
1541 To try a manual configuration, look into the src/template directory
1542 for a similar platform and use the '--with-template=' option.
1543
1544 Please also contact <pgsql-ports@postgresql.org> to see about
1545 rectifying this.  Include the above 'checking host system type...'
1546 line.
1547 *******************************************************************
1548 " >&2;}
1549    { (exit 1); exit 1; }; }
1550   fi
1551
1552
1553 fi;
1554
1555
1556 echo "$as_me:$LINENO: result: $template" >&5
1557 echo "${ECHO_T}$template" >&6
1558
1559 PORTNAME=$template
1560
1561
1562 # Initialize default assumption that we do not need separate assembly code
1563 # for TAS (test-and-set).  This can be overridden by the template file
1564 # when it's executed.
1565 need_tas=no
1566 tas_file=dummy.s
1567
1568
1569
1570 ##
1571 ## Command line options
1572 ##
1573
1574 #
1575 # Installation directory for documentation
1576 #
1577
1578
1579
1580 # Check whether --with-docdir or --without-docdir was given.
1581 if test "${with_docdir+set}" = set; then
1582   withval="$with_docdir"
1583
1584   case $withval in
1585     yes)
1586       { { echo "$as_me:$LINENO: error: option --with-docdir requires an argument" >&5
1587 echo "$as_me: error: option --with-docdir requires an argument" >&2;}
1588    { (exit 1); exit 1; }; }
1589       ;;
1590     no)
1591       docdir=
1592       ;;
1593     *)
1594       docdir=$withval
1595       ;;
1596   esac
1597
1598 else
1599   docdir='${prefix}/doc'
1600 fi;
1601
1602
1603
1604
1605 #
1606 # Add non-standard directories to the include path
1607 #
1608
1609
1610
1611 # Check whether --with-includes or --without-includes was given.
1612 if test "${with_includes+set}" = set; then
1613   withval="$with_includes"
1614
1615   case $withval in
1616     yes)
1617       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1618 echo "$as_me: error: argument required for --with-includes option" >&2;}
1619    { (exit 1); exit 1; }; }
1620       ;;
1621     no)
1622       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1623 echo "$as_me: error: argument required for --with-includes option" >&2;}
1624    { (exit 1); exit 1; }; }
1625       ;;
1626     *)
1627
1628       ;;
1629   esac
1630
1631 fi;
1632
1633
1634
1635 #
1636 # Add non-standard directories to the library search path
1637 #
1638
1639
1640
1641 # Check whether --with-libraries or --without-libraries was given.
1642 if test "${with_libraries+set}" = set; then
1643   withval="$with_libraries"
1644
1645   case $withval in
1646     yes)
1647       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
1648 echo "$as_me: error: argument required for --with-libraries option" >&2;}
1649    { (exit 1); exit 1; }; }
1650       ;;
1651     no)
1652       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
1653 echo "$as_me: error: argument required for --with-libraries option" >&2;}
1654    { (exit 1); exit 1; }; }
1655       ;;
1656     *)
1657       LIBRARY_DIRS=$withval
1658       ;;
1659   esac
1660
1661 fi;
1662
1663
1664
1665
1666
1667 # Check whether --with-libs or --without-libs was given.
1668 if test "${with_libs+set}" = set; then
1669   withval="$with_libs"
1670
1671   case $withval in
1672     yes)
1673       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1674 echo "$as_me: error: argument required for --with-libs option" >&2;}
1675    { (exit 1); exit 1; }; }
1676       ;;
1677     no)
1678       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1679 echo "$as_me: error: argument required for --with-libs option" >&2;}
1680    { (exit 1); exit 1; }; }
1681       ;;
1682     *)
1683       LIBRARY_DIRS=$withval
1684       ;;
1685   esac
1686
1687 fi;
1688
1689
1690
1691 #
1692 # 64-bit integer date/time storage (--enable-integer-datetimes)
1693 #
1694 echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
1695 echo $ECHO_N "checking whether to build with 64-bit integer date/time support... $ECHO_C" >&6
1696
1697
1698 # Check whether --enable-integer-datetimes or --disable-integer-datetimes was given.
1699 if test "${enable_integer_datetimes+set}" = set; then
1700   enableval="$enable_integer_datetimes"
1701
1702   case $enableval in
1703     yes)
1704
1705 cat >>confdefs.h <<\_ACEOF
1706 #define USE_INTEGER_DATETIMES 1
1707 _ACEOF
1708
1709       ;;
1710     no)
1711       :
1712       ;;
1713     *)
1714       { { echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
1715 echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
1716    { (exit 1); exit 1; }; }
1717       ;;
1718   esac
1719
1720 else
1721   enable_integer_datetimes=no
1722
1723 fi;
1724
1725 echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
1726 echo "${ECHO_T}$enable_integer_datetimes" >&6
1727
1728
1729 #
1730 # NLS
1731 #
1732 echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
1733 echo $ECHO_N "checking whether NLS is wanted... $ECHO_C" >&6
1734
1735
1736 # Check whether --enable-nls or --disable-nls was given.
1737 if test "${enable_nls+set}" = set; then
1738   enableval="$enable_nls"
1739
1740   case $enableval in
1741     yes)
1742       :
1743       ;;
1744     no)
1745       :
1746       ;;
1747     *)
1748       enable_nls=yes
1749 WANTED_LANGUAGES=$enableval
1750       ;;
1751   esac
1752
1753 else
1754   enable_nls=no
1755 fi;
1756
1757
1758 if test "$enable_nls" = yes; then
1759
1760 cat >>confdefs.h <<\_ACEOF
1761 #define ENABLE_NLS 1
1762 _ACEOF
1763
1764 fi
1765
1766 echo "$as_me:$LINENO: result: $enable_nls" >&5
1767 echo "${ECHO_T}$enable_nls" >&6
1768
1769
1770
1771 #
1772 # Default port number (--with-pgport), default 5432
1773 #
1774 echo "$as_me:$LINENO: checking for default port number" >&5
1775 echo $ECHO_N "checking for default port number... $ECHO_C" >&6
1776
1777
1778
1779 # Check whether --with-pgport or --without-pgport was given.
1780 if test "${with_pgport+set}" = set; then
1781   withval="$with_pgport"
1782
1783   case $withval in
1784     yes)
1785       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1786 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1787    { (exit 1); exit 1; }; }
1788       ;;
1789     no)
1790       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1791 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1792    { (exit 1); exit 1; }; }
1793       ;;
1794     *)
1795       default_port=$withval
1796       ;;
1797   esac
1798
1799 else
1800   default_port=5432
1801 fi;
1802
1803 echo "$as_me:$LINENO: result: $default_port" >&5
1804 echo "${ECHO_T}$default_port" >&6
1805 # Need both of these because some places want an integer and some a string
1806
1807 cat >>confdefs.h <<_ACEOF
1808 #define DEF_PGPORT ${default_port}
1809 _ACEOF
1810
1811
1812 cat >>confdefs.h <<_ACEOF
1813 #define DEF_PGPORT_STR "${default_port}"
1814 _ACEOF
1815
1816
1817
1818 #
1819 # Option to disable shared libraries
1820 #
1821
1822
1823 # Check whether --enable-shared or --disable-shared was given.
1824 if test "${enable_shared+set}" = set; then
1825   enableval="$enable_shared"
1826
1827   case $enableval in
1828     yes)
1829       :
1830       ;;
1831     no)
1832       :
1833       ;;
1834     *)
1835       { { echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
1836 echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
1837    { (exit 1); exit 1; }; }
1838       ;;
1839   esac
1840
1841 else
1842   enable_shared=yes
1843
1844 fi;
1845
1846
1847
1848 #
1849 # '-rpath'-like feature can be disabled
1850 #
1851
1852
1853 # Check whether --enable-rpath or --disable-rpath was given.
1854 if test "${enable_rpath+set}" = set; then
1855   enableval="$enable_rpath"
1856
1857   case $enableval in
1858     yes)
1859       :
1860       ;;
1861     no)
1862       :
1863       ;;
1864     *)
1865       { { echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
1866 echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
1867    { (exit 1); exit 1; }; }
1868       ;;
1869   esac
1870
1871 else
1872   enable_rpath=yes
1873
1874 fi;
1875
1876
1877
1878 #
1879 # Spinlocks
1880 #
1881
1882
1883 # Check whether --enable-spinlocks or --disable-spinlocks was given.
1884 if test "${enable_spinlocks+set}" = set; then
1885   enableval="$enable_spinlocks"
1886
1887   case $enableval in
1888     yes)
1889       :
1890       ;;
1891     no)
1892       :
1893       ;;
1894     *)
1895       { { echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
1896 echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
1897    { (exit 1); exit 1; }; }
1898       ;;
1899   esac
1900
1901 else
1902   enable_spinlocks=yes
1903
1904 fi;
1905
1906
1907 #
1908 # --enable-debug adds -g to compiler flags
1909 #
1910
1911
1912 # Check whether --enable-debug or --disable-debug was given.
1913 if test "${enable_debug+set}" = set; then
1914   enableval="$enable_debug"
1915
1916   case $enableval in
1917     yes)
1918       :
1919       ;;
1920     no)
1921       :
1922       ;;
1923     *)
1924       { { echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
1925 echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
1926    { (exit 1); exit 1; }; }
1927       ;;
1928   esac
1929
1930 else
1931   enable_debug=no
1932
1933 fi;
1934
1935
1936
1937 #
1938 # C compiler
1939 #
1940
1941 # For historical reasons you can also use --with-CC to specify the C compiler
1942 # to use, although the standard way to do this is to set the CC environment
1943 # variable.
1944
1945
1946
1947 # Check whether --with-CC or --without-CC was given.
1948 if test "${with_CC+set}" = set; then
1949   withval="$with_CC"
1950
1951   case $withval in
1952     yes)
1953       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
1954 echo "$as_me: error: argument required for --with-CC option" >&2;}
1955    { (exit 1); exit 1; }; }
1956       ;;
1957     no)
1958       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
1959 echo "$as_me: error: argument required for --with-CC option" >&2;}
1960    { (exit 1); exit 1; }; }
1961       ;;
1962     *)
1963       CC=$with_CC
1964       ;;
1965   esac
1966
1967 fi;
1968
1969
1970 case $template in
1971   aix) pgac_cc_list="gcc xlc";;
1972  irix) pgac_cc_list="cc";; # no gcc
1973     *) pgac_cc_list="gcc cc";;
1974 esac
1975
1976 ac_ext=c
1977 ac_cpp='$CPP $CPPFLAGS'
1978 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1979 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1980 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1981 if test -n "$ac_tool_prefix"; then
1982   for ac_prog in $pgac_cc_list
1983   do
1984     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1985 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1986 echo "$as_me:$LINENO: checking for $ac_word" >&5
1987 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1988 if test "${ac_cv_prog_CC+set}" = set; then
1989   echo $ECHO_N "(cached) $ECHO_C" >&6
1990 else
1991   if test -n "$CC"; then
1992   ac_cv_prog_CC="$CC" # Let the user override the test.
1993 else
1994 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1995 for as_dir in $PATH
1996 do
1997   IFS=$as_save_IFS
1998   test -z "$as_dir" && as_dir=.
1999   for ac_exec_ext in '' $ac_executable_extensions; do
2000   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2001     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2002     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2003     break 2
2004   fi
2005 done
2006 done
2007
2008 fi
2009 fi
2010 CC=$ac_cv_prog_CC
2011 if test -n "$CC"; then
2012   echo "$as_me:$LINENO: result: $CC" >&5
2013 echo "${ECHO_T}$CC" >&6
2014 else
2015   echo "$as_me:$LINENO: result: no" >&5
2016 echo "${ECHO_T}no" >&6
2017 fi
2018
2019     test -n "$CC" && break
2020   done
2021 fi
2022 if test -z "$CC"; then
2023   ac_ct_CC=$CC
2024   for ac_prog in $pgac_cc_list
2025 do
2026   # Extract the first word of "$ac_prog", so it can be a program name with args.
2027 set dummy $ac_prog; ac_word=$2
2028 echo "$as_me:$LINENO: checking for $ac_word" >&5
2029 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2030 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2031   echo $ECHO_N "(cached) $ECHO_C" >&6
2032 else
2033   if test -n "$ac_ct_CC"; then
2034   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2035 else
2036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2037 for as_dir in $PATH
2038 do
2039   IFS=$as_save_IFS
2040   test -z "$as_dir" && as_dir=.
2041   for ac_exec_ext in '' $ac_executable_extensions; do
2042   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2043     ac_cv_prog_ac_ct_CC="$ac_prog"
2044     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2045     break 2
2046   fi
2047 done
2048 done
2049
2050 fi
2051 fi
2052 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2053 if test -n "$ac_ct_CC"; then
2054   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2055 echo "${ECHO_T}$ac_ct_CC" >&6
2056 else
2057   echo "$as_me:$LINENO: result: no" >&5
2058 echo "${ECHO_T}no" >&6
2059 fi
2060
2061   test -n "$ac_ct_CC" && break
2062 done
2063
2064   CC=$ac_ct_CC
2065 fi
2066
2067
2068 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2069 See \`config.log' for more details." >&5
2070 echo "$as_me: error: no acceptable C compiler found in \$PATH
2071 See \`config.log' for more details." >&2;}
2072    { (exit 1); exit 1; }; }
2073
2074 # Provide some information about the compiler.
2075 echo "$as_me:$LINENO:" \
2076      "checking for C compiler version" >&5
2077 ac_compiler=`set X $ac_compile; echo $2`
2078 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
2079   (eval $ac_compiler --version </dev/null >&5) 2>&5
2080   ac_status=$?
2081   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2082   (exit $ac_status); }
2083 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
2084   (eval $ac_compiler -v </dev/null >&5) 2>&5
2085   ac_status=$?
2086   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2087   (exit $ac_status); }
2088 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
2089   (eval $ac_compiler -V </dev/null >&5) 2>&5
2090   ac_status=$?
2091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2092   (exit $ac_status); }
2093
2094 cat >conftest.$ac_ext <<_ACEOF
2095 /* confdefs.h.  */
2096 _ACEOF
2097 cat confdefs.h >>conftest.$ac_ext
2098 cat >>conftest.$ac_ext <<_ACEOF
2099 /* end confdefs.h.  */
2100
2101 int
2102 main ()
2103 {
2104
2105   ;
2106   return 0;
2107 }
2108 _ACEOF
2109 ac_clean_files_save=$ac_clean_files
2110 ac_clean_files="$ac_clean_files a.out a.exe b.out"
2111 # Try to create an executable without -o first, disregard a.out.
2112 # It will help us diagnose broken compilers, and finding out an intuition
2113 # of exeext.
2114 echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2115 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
2116 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2117 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2118   (eval $ac_link_default) 2>&5
2119   ac_status=$?
2120   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2121   (exit $ac_status); }; then
2122   # Find the output, starting from the most likely.  This scheme is
2123 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
2124 # resort.
2125
2126 # Be careful to initialize this variable, since it used to be cached.
2127 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2128 ac_cv_exeext=
2129 # b.out is created by i960 compilers.
2130 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
2131 do
2132   test -f "$ac_file" || continue
2133   case $ac_file in
2134     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
2135         ;;
2136     conftest.$ac_ext )
2137         # This is the source file.
2138         ;;
2139     [ab].out )
2140         # We found the default executable, but exeext='' is most
2141         # certainly right.
2142         break;;
2143     *.* )
2144         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2145         # FIXME: I believe we export ac_cv_exeext for Libtool,
2146         # but it would be cool to find out if it's true.  Does anybody
2147         # maintain Libtool? --akim.
2148         export ac_cv_exeext
2149         break;;
2150     * )
2151         break;;
2152   esac
2153 done
2154 else
2155   echo "$as_me: failed program was:" >&5
2156 sed 's/^/| /' conftest.$ac_ext >&5
2157
2158 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
2159 See \`config.log' for more details." >&5
2160 echo "$as_me: error: C compiler cannot create executables
2161 See \`config.log' for more details." >&2;}
2162    { (exit 77); exit 77; }; }
2163 fi
2164
2165 ac_exeext=$ac_cv_exeext
2166 echo "$as_me:$LINENO: result: $ac_file" >&5
2167 echo "${ECHO_T}$ac_file" >&6
2168
2169 # Check the compiler produces executables we can run.  If not, either
2170 # the compiler is broken, or we cross compile.
2171 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2172 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2173 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2174 # If not cross compiling, check that we can run a simple program.
2175 if test "$cross_compiling" != yes; then
2176   if { ac_try='./$ac_file'
2177   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2178   (eval $ac_try) 2>&5
2179   ac_status=$?
2180   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2181   (exit $ac_status); }; }; then
2182     cross_compiling=no
2183   else
2184     if test "$cross_compiling" = maybe; then
2185         cross_compiling=yes
2186     else
2187         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2188 If you meant to cross compile, use \`--host'.
2189 See \`config.log' for more details." >&5
2190 echo "$as_me: error: cannot run C compiled programs.
2191 If you meant to cross compile, use \`--host'.
2192 See \`config.log' for more details." >&2;}
2193    { (exit 1); exit 1; }; }
2194     fi
2195   fi
2196 fi
2197 echo "$as_me:$LINENO: result: yes" >&5
2198 echo "${ECHO_T}yes" >&6
2199
2200 rm -f a.out a.exe conftest$ac_cv_exeext b.out
2201 ac_clean_files=$ac_clean_files_save
2202 # Check the compiler produces executables we can run.  If not, either
2203 # the compiler is broken, or we cross compile.
2204 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2205 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2206 echo "$as_me:$LINENO: result: $cross_compiling" >&5
2207 echo "${ECHO_T}$cross_compiling" >&6
2208
2209 echo "$as_me:$LINENO: checking for suffix of executables" >&5
2210 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2211 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2212   (eval $ac_link) 2>&5
2213   ac_status=$?
2214   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2215   (exit $ac_status); }; then
2216   # If both `conftest.exe' and `conftest' are `present' (well, observable)
2217 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
2218 # work properly (i.e., refer to `conftest.exe'), while it won't with
2219 # `rm'.
2220 for ac_file in conftest.exe conftest conftest.*; do
2221   test -f "$ac_file" || continue
2222   case $ac_file in
2223     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
2224     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2225           export ac_cv_exeext
2226           break;;
2227     * ) break;;
2228   esac
2229 done
2230 else
2231   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
2232 See \`config.log' for more details." >&5
2233 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
2234 See \`config.log' for more details." >&2;}
2235    { (exit 1); exit 1; }; }
2236 fi
2237
2238 rm -f conftest$ac_cv_exeext
2239 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2240 echo "${ECHO_T}$ac_cv_exeext" >&6
2241
2242 rm -f conftest.$ac_ext
2243 EXEEXT=$ac_cv_exeext
2244 ac_exeext=$EXEEXT
2245 echo "$as_me:$LINENO: checking for suffix of object files" >&5
2246 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2247 if test "${ac_cv_objext+set}" = set; then
2248   echo $ECHO_N "(cached) $ECHO_C" >&6
2249 else
2250   cat >conftest.$ac_ext <<_ACEOF
2251 /* confdefs.h.  */
2252 _ACEOF
2253 cat confdefs.h >>conftest.$ac_ext
2254 cat >>conftest.$ac_ext <<_ACEOF
2255 /* end confdefs.h.  */
2256
2257 int
2258 main ()
2259 {
2260
2261   ;
2262   return 0;
2263 }
2264 _ACEOF
2265 rm -f conftest.o conftest.obj
2266 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2267   (eval $ac_compile) 2>&5
2268   ac_status=$?
2269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2270   (exit $ac_status); }; then
2271   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2272   case $ac_file in
2273     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
2274     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2275        break;;
2276   esac
2277 done
2278 else
2279   echo "$as_me: failed program was:" >&5
2280 sed 's/^/| /' conftest.$ac_ext >&5
2281
2282 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
2283 See \`config.log' for more details." >&5
2284 echo "$as_me: error: cannot compute suffix of object files: cannot compile
2285 See \`config.log' for more details." >&2;}
2286    { (exit 1); exit 1; }; }
2287 fi
2288
2289 rm -f conftest.$ac_cv_objext conftest.$ac_ext
2290 fi
2291 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2292 echo "${ECHO_T}$ac_cv_objext" >&6
2293 OBJEXT=$ac_cv_objext
2294 ac_objext=$OBJEXT
2295 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2296 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2297 if test "${ac_cv_c_compiler_gnu+set}" = set; then
2298   echo $ECHO_N "(cached) $ECHO_C" >&6
2299 else
2300   cat >conftest.$ac_ext <<_ACEOF
2301 /* confdefs.h.  */
2302 _ACEOF
2303 cat confdefs.h >>conftest.$ac_ext
2304 cat >>conftest.$ac_ext <<_ACEOF
2305 /* end confdefs.h.  */
2306
2307 int
2308 main ()
2309 {
2310 #ifndef __GNUC__
2311        choke me
2312 #endif
2313
2314   ;
2315   return 0;
2316 }
2317 _ACEOF
2318 rm -f conftest.$ac_objext
2319 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2320   (eval $ac_compile) 2>conftest.er1
2321   ac_status=$?
2322   grep -v '^ *+' conftest.er1 >conftest.err
2323   rm -f conftest.er1
2324   cat conftest.err >&5
2325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2326   (exit $ac_status); } &&
2327          { ac_try='test -z "$ac_c_werror_flag"
2328                          || test ! -s conftest.err'
2329   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2330   (eval $ac_try) 2>&5
2331   ac_status=$?
2332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2333   (exit $ac_status); }; } &&
2334          { ac_try='test -s conftest.$ac_objext'
2335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2336   (eval $ac_try) 2>&5
2337   ac_status=$?
2338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2339   (exit $ac_status); }; }; then
2340   ac_compiler_gnu=yes
2341 else
2342   echo "$as_me: failed program was:" >&5
2343 sed 's/^/| /' conftest.$ac_ext >&5
2344
2345 ac_compiler_gnu=no
2346 fi
2347 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2348 ac_cv_c_compiler_gnu=$ac_compiler_gnu
2349
2350 fi
2351 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2352 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2353 GCC=`test $ac_compiler_gnu = yes && echo yes`
2354 ac_test_CFLAGS=${CFLAGS+set}
2355 ac_save_CFLAGS=$CFLAGS
2356 CFLAGS="-g"
2357 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2358 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2359 if test "${ac_cv_prog_cc_g+set}" = set; then
2360   echo $ECHO_N "(cached) $ECHO_C" >&6
2361 else
2362   cat >conftest.$ac_ext <<_ACEOF
2363 /* confdefs.h.  */
2364 _ACEOF
2365 cat confdefs.h >>conftest.$ac_ext
2366 cat >>conftest.$ac_ext <<_ACEOF
2367 /* end confdefs.h.  */
2368
2369 int
2370 main ()
2371 {
2372
2373   ;
2374   return 0;
2375 }
2376 _ACEOF
2377 rm -f conftest.$ac_objext
2378 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2379   (eval $ac_compile) 2>conftest.er1
2380   ac_status=$?
2381   grep -v '^ *+' conftest.er1 >conftest.err
2382   rm -f conftest.er1
2383   cat conftest.err >&5
2384   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2385   (exit $ac_status); } &&
2386          { ac_try='test -z "$ac_c_werror_flag"
2387                          || test ! -s conftest.err'
2388   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2389   (eval $ac_try) 2>&5
2390   ac_status=$?
2391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2392   (exit $ac_status); }; } &&
2393          { ac_try='test -s conftest.$ac_objext'
2394   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2395   (eval $ac_try) 2>&5
2396   ac_status=$?
2397   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2398   (exit $ac_status); }; }; then
2399   ac_cv_prog_cc_g=yes
2400 else
2401   echo "$as_me: failed program was:" >&5
2402 sed 's/^/| /' conftest.$ac_ext >&5
2403
2404 ac_cv_prog_cc_g=no
2405 fi
2406 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2407 fi
2408 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2409 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2410 if test "$ac_test_CFLAGS" = set; then
2411   CFLAGS=$ac_save_CFLAGS
2412 elif test $ac_cv_prog_cc_g = yes; then
2413   if test "$GCC" = yes; then
2414     CFLAGS="-g -O2"
2415   else
2416     CFLAGS="-g"
2417   fi
2418 else
2419   if test "$GCC" = yes; then
2420     CFLAGS="-O2"
2421   else
2422     CFLAGS=
2423   fi
2424 fi
2425 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
2426 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2427 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2428   echo $ECHO_N "(cached) $ECHO_C" >&6
2429 else
2430   ac_cv_prog_cc_stdc=no
2431 ac_save_CC=$CC
2432 cat >conftest.$ac_ext <<_ACEOF
2433 /* confdefs.h.  */
2434 _ACEOF
2435 cat confdefs.h >>conftest.$ac_ext
2436 cat >>conftest.$ac_ext <<_ACEOF
2437 /* end confdefs.h.  */
2438 #include <stdarg.h>
2439 #include <stdio.h>
2440 #include <sys/types.h>
2441 #include <sys/stat.h>
2442 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2443 struct buf { int x; };
2444 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2445 static char *e (p, i)
2446      char **p;
2447      int i;
2448 {
2449   return p[i];
2450 }
2451 static char *f (char * (*g) (char **, int), char **p, ...)
2452 {
2453   char *s;
2454   va_list v;
2455   va_start (v,p);
2456   s = g (p, va_arg (v,int));
2457   va_end (v);
2458   return s;
2459 }
2460
2461 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
2462    function prototypes and stuff, but not '\xHH' hex character constants.
2463    These don't provoke an error unfortunately, instead are silently treated
2464    as 'x'.  The following induces an error, until -std1 is added to get
2465    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
2466    array size at least.  It's necessary to write '\x00'==0 to get something
2467    that's true only with -std1.  */
2468 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
2469
2470 int test (int i, double x);
2471 struct s1 {int (*f) (int a);};
2472 struct s2 {int (*f) (double a);};
2473 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2474 int argc;
2475 char **argv;
2476 int
2477 main ()
2478 {
2479 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2480   ;
2481   return 0;
2482 }
2483 _ACEOF
2484 # Don't try gcc -ansi; that turns off useful extensions and
2485 # breaks some systems' header files.
2486 # AIX                   -qlanglvl=ansi
2487 # Ultrix and OSF/1      -std1
2488 # HP-UX 10.20 and later -Ae
2489 # HP-UX older versions  -Aa -D_HPUX_SOURCE
2490 # SVR4                  -Xc -D__EXTENSIONS__
2491 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2492 do
2493   CC="$ac_save_CC $ac_arg"
2494   rm -f conftest.$ac_objext
2495 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2496   (eval $ac_compile) 2>conftest.er1
2497   ac_status=$?
2498   grep -v '^ *+' conftest.er1 >conftest.err
2499   rm -f conftest.er1
2500   cat conftest.err >&5
2501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2502   (exit $ac_status); } &&
2503          { ac_try='test -z "$ac_c_werror_flag"
2504                          || test ! -s conftest.err'
2505   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2506   (eval $ac_try) 2>&5
2507   ac_status=$?
2508   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2509   (exit $ac_status); }; } &&
2510          { ac_try='test -s conftest.$ac_objext'
2511   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2512   (eval $ac_try) 2>&5
2513   ac_status=$?
2514   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2515   (exit $ac_status); }; }; then
2516   ac_cv_prog_cc_stdc=$ac_arg
2517 break
2518 else
2519   echo "$as_me: failed program was:" >&5
2520 sed 's/^/| /' conftest.$ac_ext >&5
2521
2522 fi
2523 rm -f conftest.err conftest.$ac_objext
2524 done
2525 rm -f conftest.$ac_ext conftest.$ac_objext
2526 CC=$ac_save_CC
2527
2528 fi
2529
2530 case "x$ac_cv_prog_cc_stdc" in
2531   x|xno)
2532     echo "$as_me:$LINENO: result: none needed" >&5
2533 echo "${ECHO_T}none needed" >&6 ;;
2534   *)
2535     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2536 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2537     CC="$CC $ac_cv_prog_cc_stdc" ;;
2538 esac
2539
2540 # Some people use a C++ compiler to compile C.  Since we use `exit',
2541 # in C++ we need to declare it.  In case someone uses the same compiler
2542 # for both compiling C and C++ we need to have the C++ compiler decide
2543 # the declaration of exit, since it's the most demanding environment.
2544 cat >conftest.$ac_ext <<_ACEOF
2545 #ifndef __cplusplus
2546   choke me
2547 #endif
2548 _ACEOF
2549 rm -f conftest.$ac_objext
2550 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2551   (eval $ac_compile) 2>conftest.er1
2552   ac_status=$?
2553   grep -v '^ *+' conftest.er1 >conftest.err
2554   rm -f conftest.er1
2555   cat conftest.err >&5
2556   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2557   (exit $ac_status); } &&
2558          { ac_try='test -z "$ac_c_werror_flag"
2559                          || test ! -s conftest.err'
2560   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2561   (eval $ac_try) 2>&5
2562   ac_status=$?
2563   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2564   (exit $ac_status); }; } &&
2565          { ac_try='test -s conftest.$ac_objext'
2566   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2567   (eval $ac_try) 2>&5
2568   ac_status=$?
2569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2570   (exit $ac_status); }; }; then
2571   for ac_declaration in \
2572    '' \
2573    'extern "C" void std::exit (int) throw (); using std::exit;' \
2574    'extern "C" void std::exit (int); using std::exit;' \
2575    'extern "C" void exit (int) throw ();' \
2576    'extern "C" void exit (int);' \
2577    'void exit (int);'
2578 do
2579   cat >conftest.$ac_ext <<_ACEOF
2580 /* confdefs.h.  */
2581 _ACEOF
2582 cat confdefs.h >>conftest.$ac_ext
2583 cat >>conftest.$ac_ext <<_ACEOF
2584 /* end confdefs.h.  */
2585 $ac_declaration
2586 #include <stdlib.h>
2587 int
2588 main ()
2589 {
2590 exit (42);
2591   ;
2592   return 0;
2593 }
2594 _ACEOF
2595 rm -f conftest.$ac_objext
2596 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2597   (eval $ac_compile) 2>conftest.er1
2598   ac_status=$?
2599   grep -v '^ *+' conftest.er1 >conftest.err
2600   rm -f conftest.er1
2601   cat conftest.err >&5
2602   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2603   (exit $ac_status); } &&
2604          { ac_try='test -z "$ac_c_werror_flag"
2605                          || test ! -s conftest.err'
2606   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2607   (eval $ac_try) 2>&5
2608   ac_status=$?
2609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2610   (exit $ac_status); }; } &&
2611          { ac_try='test -s conftest.$ac_objext'
2612   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2613   (eval $ac_try) 2>&5
2614   ac_status=$?
2615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2616   (exit $ac_status); }; }; then
2617   :
2618 else
2619   echo "$as_me: failed program was:" >&5
2620 sed 's/^/| /' conftest.$ac_ext >&5
2621
2622 continue
2623 fi
2624 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2625   cat >conftest.$ac_ext <<_ACEOF
2626 /* confdefs.h.  */
2627 _ACEOF
2628 cat confdefs.h >>conftest.$ac_ext
2629 cat >>conftest.$ac_ext <<_ACEOF
2630 /* end confdefs.h.  */
2631 $ac_declaration
2632 int
2633 main ()
2634 {
2635 exit (42);
2636   ;
2637   return 0;
2638 }
2639 _ACEOF
2640 rm -f conftest.$ac_objext
2641 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2642   (eval $ac_compile) 2>conftest.er1
2643   ac_status=$?
2644   grep -v '^ *+' conftest.er1 >conftest.err
2645   rm -f conftest.er1
2646   cat conftest.err >&5
2647   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2648   (exit $ac_status); } &&
2649          { ac_try='test -z "$ac_c_werror_flag"
2650                          || test ! -s conftest.err'
2651   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2652   (eval $ac_try) 2>&5
2653   ac_status=$?
2654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2655   (exit $ac_status); }; } &&
2656          { ac_try='test -s conftest.$ac_objext'
2657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2658   (eval $ac_try) 2>&5
2659   ac_status=$?
2660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2661   (exit $ac_status); }; }; then
2662   break
2663 else
2664   echo "$as_me: failed program was:" >&5
2665 sed 's/^/| /' conftest.$ac_ext >&5
2666
2667 fi
2668 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2669 done
2670 rm -f conftest*
2671 if test -n "$ac_declaration"; then
2672   echo '#ifdef __cplusplus' >>confdefs.h
2673   echo $ac_declaration      >>confdefs.h
2674   echo '#endif'             >>confdefs.h
2675 fi
2676
2677 else
2678   echo "$as_me: failed program was:" >&5
2679 sed 's/^/| /' conftest.$ac_ext >&5
2680
2681 fi
2682 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2683 ac_ext=c
2684 ac_cpp='$CPP $CPPFLAGS'
2685 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2686 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2687 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2688
2689
2690 unset CFLAGS
2691
2692 #
2693 # Read the template
2694 #
2695 . "$srcdir/src/template/$template" || exit
2696
2697 # CFLAGS are selected so:
2698 # If the user specifies something in the environment, that is used.
2699 # else:  If the template file set something, that is used.
2700 # else:  If the compiler is GCC, then we use -O2.
2701 # else:  If the compiler is something else, then we use -0.
2702
2703 if test "$ac_env_CFLAGS_set" = set; then
2704   CFLAGS=$ac_env_CFLAGS_value
2705 elif test "${CFLAGS+set}" = set; then
2706   : # (keep what template set)
2707 elif test "$GCC" = yes; then
2708   CFLAGS="-O2"
2709 else
2710   # if the user selected debug mode, don't use -O
2711   if test "$enable_debug" != yes; then
2712     CFLAGS="-O"
2713   fi
2714 fi
2715
2716 if test "$GCC" = yes; then
2717   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith -Winline"
2718
2719   # Some versions of GCC support some additional useful warning flags.
2720   # Check whether they are supported, and add them to CFLAGS if so.
2721   echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
2722 echo $ECHO_N "checking if $CC supports -Wdeclaration-after-statement... $ECHO_C" >&6
2723 pgac_save_CFLAGS=$CFLAGS
2724 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
2725 cat >conftest.$ac_ext <<_ACEOF
2726 /* confdefs.h.  */
2727 _ACEOF
2728 cat confdefs.h >>conftest.$ac_ext
2729 cat >>conftest.$ac_ext <<_ACEOF
2730 /* end confdefs.h.  */
2731
2732 int
2733 main ()
2734 {
2735
2736   ;
2737   return 0;
2738 }
2739 _ACEOF
2740 rm -f conftest.$ac_objext
2741 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2742   (eval $ac_compile) 2>conftest.er1
2743   ac_status=$?
2744   grep -v '^ *+' conftest.er1 >conftest.err
2745   rm -f conftest.er1
2746   cat conftest.err >&5
2747   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2748   (exit $ac_status); } &&
2749          { ac_try='test -z "$ac_c_werror_flag"
2750                          || test ! -s conftest.err'
2751   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2752   (eval $ac_try) 2>&5
2753   ac_status=$?
2754   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2755   (exit $ac_status); }; } &&
2756          { ac_try='test -s conftest.$ac_objext'
2757   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2758   (eval $ac_try) 2>&5
2759   ac_status=$?
2760   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2761   (exit $ac_status); }; }; then
2762   echo "$as_me:$LINENO: result: yes" >&5
2763 echo "${ECHO_T}yes" >&6
2764 else
2765   echo "$as_me: failed program was:" >&5
2766 sed 's/^/| /' conftest.$ac_ext >&5
2767
2768 CFLAGS="$pgac_save_CFLAGS"
2769                     echo "$as_me:$LINENO: result: no" >&5
2770 echo "${ECHO_T}no" >&6
2771 fi
2772 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2773
2774   echo "$as_me:$LINENO: checking if $CC supports -Wendif-labels" >&5
2775 echo $ECHO_N "checking if $CC supports -Wendif-labels... $ECHO_C" >&6
2776 pgac_save_CFLAGS=$CFLAGS
2777 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
2778 cat >conftest.$ac_ext <<_ACEOF
2779 /* confdefs.h.  */
2780 _ACEOF
2781 cat confdefs.h >>conftest.$ac_ext
2782 cat >>conftest.$ac_ext <<_ACEOF
2783 /* end confdefs.h.  */
2784
2785 int
2786 main ()
2787 {
2788
2789   ;
2790   return 0;
2791 }
2792 _ACEOF
2793 rm -f conftest.$ac_objext
2794 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2795   (eval $ac_compile) 2>conftest.er1
2796   ac_status=$?
2797   grep -v '^ *+' conftest.er1 >conftest.err
2798   rm -f conftest.er1
2799   cat conftest.err >&5
2800   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2801   (exit $ac_status); } &&
2802          { ac_try='test -z "$ac_c_werror_flag"
2803                          || test ! -s conftest.err'
2804   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2805   (eval $ac_try) 2>&5
2806   ac_status=$?
2807   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2808   (exit $ac_status); }; } &&
2809          { ac_try='test -s conftest.$ac_objext'
2810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2811   (eval $ac_try) 2>&5
2812   ac_status=$?
2813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2814   (exit $ac_status); }; }; then
2815   echo "$as_me:$LINENO: result: yes" >&5
2816 echo "${ECHO_T}yes" >&6
2817 else
2818   echo "$as_me: failed program was:" >&5
2819 sed 's/^/| /' conftest.$ac_ext >&5
2820
2821 CFLAGS="$pgac_save_CFLAGS"
2822                     echo "$as_me:$LINENO: result: no" >&5
2823 echo "${ECHO_T}no" >&6
2824 fi
2825 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2826
2827
2828   # Disable strict-aliasing rules; needed for gcc 3.3+
2829   echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
2830 echo $ECHO_N "checking if $CC supports -fno-strict-aliasing... $ECHO_C" >&6
2831 pgac_save_CFLAGS=$CFLAGS
2832 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
2833 cat >conftest.$ac_ext <<_ACEOF
2834 /* confdefs.h.  */
2835 _ACEOF
2836 cat confdefs.h >>conftest.$ac_ext
2837 cat >>conftest.$ac_ext <<_ACEOF
2838 /* end confdefs.h.  */
2839
2840 int
2841 main ()
2842 {
2843
2844   ;
2845   return 0;
2846 }
2847 _ACEOF
2848 rm -f conftest.$ac_objext
2849 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2850   (eval $ac_compile) 2>conftest.er1
2851   ac_status=$?
2852   grep -v '^ *+' conftest.er1 >conftest.err
2853   rm -f conftest.er1
2854   cat conftest.err >&5
2855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2856   (exit $ac_status); } &&
2857          { ac_try='test -z "$ac_c_werror_flag"
2858                          || test ! -s conftest.err'
2859   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2860   (eval $ac_try) 2>&5
2861   ac_status=$?
2862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2863   (exit $ac_status); }; } &&
2864          { ac_try='test -s conftest.$ac_objext'
2865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2866   (eval $ac_try) 2>&5
2867   ac_status=$?
2868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2869   (exit $ac_status); }; }; then
2870   echo "$as_me:$LINENO: result: yes" >&5
2871 echo "${ECHO_T}yes" >&6
2872 else
2873   echo "$as_me: failed program was:" >&5
2874 sed 's/^/| /' conftest.$ac_ext >&5
2875
2876 CFLAGS="$pgac_save_CFLAGS"
2877                     echo "$as_me:$LINENO: result: no" >&5
2878 echo "${ECHO_T}no" >&6
2879 fi
2880 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2881
2882 fi
2883
2884 # supply -g if --enable-debug
2885 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
2886   CFLAGS="$CFLAGS -g"
2887 fi
2888
2889 { echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
2890 echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
2891
2892 # We already have this in Makefile.win32, but configure needs it too
2893 if test "$PORTNAME" = "win32"; then
2894   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
2895 fi
2896
2897 # Check if the compiler still works with the template settings
2898 echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
2899 echo $ECHO_N "checking whether the C compiler still works... $ECHO_C" >&6
2900
2901 cat >conftest.$ac_ext <<_ACEOF
2902 /* confdefs.h.  */
2903 _ACEOF
2904 cat confdefs.h >>conftest.$ac_ext
2905 cat >>conftest.$ac_ext <<_ACEOF
2906 /* end confdefs.h.  */
2907
2908 int
2909 main ()
2910 {
2911 return 0;
2912   ;
2913   return 0;
2914 }
2915 _ACEOF
2916 rm -f conftest.$ac_objext conftest$ac_exeext
2917 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2918   (eval $ac_link) 2>conftest.er1
2919   ac_status=$?
2920   grep -v '^ *+' conftest.er1 >conftest.err
2921   rm -f conftest.er1
2922   cat conftest.err >&5
2923   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2924   (exit $ac_status); } &&
2925          { ac_try='test -z "$ac_c_werror_flag"
2926                          || test ! -s conftest.err'
2927   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2928   (eval $ac_try) 2>&5
2929   ac_status=$?
2930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2931   (exit $ac_status); }; } &&
2932          { ac_try='test -s conftest$ac_exeext'
2933   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2934   (eval $ac_try) 2>&5
2935   ac_status=$?
2936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2937   (exit $ac_status); }; }; then
2938   echo "$as_me:$LINENO: result: yes" >&5
2939 echo "${ECHO_T}yes" >&6
2940 else
2941   echo "$as_me: failed program was:" >&5
2942 sed 's/^/| /' conftest.$ac_ext >&5
2943
2944 echo "$as_me:$LINENO: result: no" >&5
2945 echo "${ECHO_T}no" >&6
2946    { { echo "$as_me:$LINENO: error: cannot proceed" >&5
2947 echo "$as_me: error: cannot proceed" >&2;}
2948    { (exit 1); exit 1; }; }
2949 fi
2950 rm -f conftest.err conftest.$ac_objext \
2951       conftest$ac_exeext conftest.$ac_ext
2952
2953 # Defend against gcc -ffast-math
2954 if test "$GCC" = yes; then
2955 cat >conftest.$ac_ext <<_ACEOF
2956 /* confdefs.h.  */
2957 _ACEOF
2958 cat confdefs.h >>conftest.$ac_ext
2959 cat >>conftest.$ac_ext <<_ACEOF
2960 /* end confdefs.h.  */
2961
2962 int
2963 main ()
2964 {
2965 #ifdef __FAST_MATH__
2966 choke me
2967 #endif
2968   ;
2969   return 0;
2970 }
2971 _ACEOF
2972 rm -f conftest.$ac_objext
2973 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2974   (eval $ac_compile) 2>conftest.er1
2975   ac_status=$?
2976   grep -v '^ *+' conftest.er1 >conftest.err
2977   rm -f conftest.er1
2978   cat conftest.err >&5
2979   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2980   (exit $ac_status); } &&
2981          { ac_try='test -z "$ac_c_werror_flag"
2982                          || test ! -s conftest.err'
2983   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2984   (eval $ac_try) 2>&5
2985   ac_status=$?
2986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2987   (exit $ac_status); }; } &&
2988          { ac_try='test -s conftest.$ac_objext'
2989   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2990   (eval $ac_try) 2>&5
2991   ac_status=$?
2992   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2993   (exit $ac_status); }; }; then
2994   :
2995 else
2996   echo "$as_me: failed program was:" >&5
2997 sed 's/^/| /' conftest.$ac_ext >&5
2998
2999 { { echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
3000 echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
3001    { (exit 1); exit 1; }; }
3002 fi
3003 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3004 fi
3005
3006 ac_ext=c
3007 ac_cpp='$CPP $CPPFLAGS'
3008 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3009 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3010 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3011 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
3012 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
3013 # On Suns, sometimes $CPP names a directory.
3014 if test -n "$CPP" && test -d "$CPP"; then
3015   CPP=
3016 fi
3017 if test -z "$CPP"; then
3018   if test "${ac_cv_prog_CPP+set}" = set; then
3019   echo $ECHO_N "(cached) $ECHO_C" >&6
3020 else
3021       # Double quotes because CPP needs to be expanded
3022     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3023     do
3024       ac_preproc_ok=false
3025 for ac_c_preproc_warn_flag in '' yes
3026 do
3027   # Use a header file that comes with gcc, so configuring glibc
3028   # with a fresh cross-compiler works.
3029   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3030   # <limits.h> exists even on freestanding compilers.
3031   # On the NeXT, cc -E runs the code through the compiler's parser,
3032   # not just through cpp. "Syntax error" is here to catch this case.
3033   cat >conftest.$ac_ext <<_ACEOF
3034 /* confdefs.h.  */
3035 _ACEOF
3036 cat confdefs.h >>conftest.$ac_ext
3037 cat >>conftest.$ac_ext <<_ACEOF
3038 /* end confdefs.h.  */
3039 #ifdef __STDC__
3040 # include <limits.h>
3041 #else
3042 # include <assert.h>
3043 #endif
3044                      Syntax error
3045 _ACEOF
3046 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3047   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3048   ac_status=$?
3049   grep -v '^ *+' conftest.er1 >conftest.err
3050   rm -f conftest.er1
3051   cat conftest.err >&5
3052   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3053   (exit $ac_status); } >/dev/null; then
3054   if test -s conftest.err; then
3055     ac_cpp_err=$ac_c_preproc_warn_flag
3056     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3057   else
3058     ac_cpp_err=
3059   fi
3060 else
3061   ac_cpp_err=yes
3062 fi
3063 if test -z "$ac_cpp_err"; then
3064   :
3065 else
3066   echo "$as_me: failed program was:" >&5
3067 sed 's/^/| /' conftest.$ac_ext >&5
3068
3069   # Broken: fails on valid input.
3070 continue
3071 fi
3072 rm -f conftest.err conftest.$ac_ext
3073
3074   # OK, works on sane cases.  Now check whether non-existent headers
3075   # can be detected and how.
3076   cat >conftest.$ac_ext <<_ACEOF
3077 /* confdefs.h.  */
3078 _ACEOF
3079 cat confdefs.h >>conftest.$ac_ext
3080 cat >>conftest.$ac_ext <<_ACEOF
3081 /* end confdefs.h.  */
3082 #include <ac_nonexistent.h>
3083 _ACEOF
3084 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3085   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3086   ac_status=$?
3087   grep -v '^ *+' conftest.er1 >conftest.err
3088   rm -f conftest.er1
3089   cat conftest.err >&5
3090   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3091   (exit $ac_status); } >/dev/null; then
3092   if test -s conftest.err; then
3093     ac_cpp_err=$ac_c_preproc_warn_flag
3094     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3095   else
3096     ac_cpp_err=
3097   fi
3098 else
3099   ac_cpp_err=yes
3100 fi
3101 if test -z "$ac_cpp_err"; then
3102   # Broken: success on invalid input.
3103 continue
3104 else
3105   echo "$as_me: failed program was:" >&5
3106 sed 's/^/| /' conftest.$ac_ext >&5
3107
3108   # Passes both tests.
3109 ac_preproc_ok=:
3110 break
3111 fi
3112 rm -f conftest.err conftest.$ac_ext
3113
3114 done
3115 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3116 rm -f conftest.err conftest.$ac_ext
3117 if $ac_preproc_ok; then
3118   break
3119 fi
3120
3121     done
3122     ac_cv_prog_CPP=$CPP
3123
3124 fi
3125   CPP=$ac_cv_prog_CPP
3126 else
3127   ac_cv_prog_CPP=$CPP
3128 fi
3129 echo "$as_me:$LINENO: result: $CPP" >&5
3130 echo "${ECHO_T}$CPP" >&6
3131 ac_preproc_ok=false
3132 for ac_c_preproc_warn_flag in '' yes
3133 do
3134   # Use a header file that comes with gcc, so configuring glibc
3135   # with a fresh cross-compiler works.
3136   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3137   # <limits.h> exists even on freestanding compilers.
3138   # On the NeXT, cc -E runs the code through the compiler's parser,
3139   # not just through cpp. "Syntax error" is here to catch this case.
3140   cat >conftest.$ac_ext <<_ACEOF
3141 /* confdefs.h.  */
3142 _ACEOF
3143 cat confdefs.h >>conftest.$ac_ext
3144 cat >>conftest.$ac_ext <<_ACEOF
3145 /* end confdefs.h.  */
3146 #ifdef __STDC__
3147 # include <limits.h>
3148 #else
3149 # include <assert.h>
3150 #endif
3151                      Syntax error
3152 _ACEOF
3153 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3154   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3155   ac_status=$?
3156   grep -v '^ *+' conftest.er1 >conftest.err
3157   rm -f conftest.er1
3158   cat conftest.err >&5
3159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3160   (exit $ac_status); } >/dev/null; then
3161   if test -s conftest.err; then
3162     ac_cpp_err=$ac_c_preproc_warn_flag
3163     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3164   else
3165     ac_cpp_err=
3166   fi
3167 else
3168   ac_cpp_err=yes
3169 fi
3170 if test -z "$ac_cpp_err"; then
3171   :
3172 else
3173   echo "$as_me: failed program was:" >&5
3174 sed 's/^/| /' conftest.$ac_ext >&5
3175
3176   # Broken: fails on valid input.
3177 continue
3178 fi
3179 rm -f conftest.err conftest.$ac_ext
3180
3181   # OK, works on sane cases.  Now check whether non-existent headers
3182   # can be detected and how.
3183   cat >conftest.$ac_ext <<_ACEOF
3184 /* confdefs.h.  */
3185 _ACEOF
3186 cat confdefs.h >>conftest.$ac_ext
3187 cat >>conftest.$ac_ext <<_ACEOF
3188 /* end confdefs.h.  */
3189 #include <ac_nonexistent.h>
3190 _ACEOF
3191 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3192   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3193   ac_status=$?
3194   grep -v '^ *+' conftest.er1 >conftest.err
3195   rm -f conftest.er1
3196   cat conftest.err >&5
3197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3198   (exit $ac_status); } >/dev/null; then
3199   if test -s conftest.err; then
3200     ac_cpp_err=$ac_c_preproc_warn_flag
3201     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3202   else
3203     ac_cpp_err=
3204   fi
3205 else
3206   ac_cpp_err=yes
3207 fi
3208 if test -z "$ac_cpp_err"; then
3209   # Broken: success on invalid input.
3210 continue
3211 else
3212   echo "$as_me: failed program was:" >&5
3213 sed 's/^/| /' conftest.$ac_ext >&5
3214
3215   # Passes both tests.
3216 ac_preproc_ok=:
3217 break
3218 fi
3219 rm -f conftest.err conftest.$ac_ext
3220
3221 done
3222 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3223 rm -f conftest.err conftest.$ac_ext
3224 if $ac_preproc_ok; then
3225   :
3226 else
3227   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3228 See \`config.log' for more details." >&5
3229 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3230 See \`config.log' for more details." >&2;}
3231    { (exit 1); exit 1; }; }
3232 fi
3233
3234 ac_ext=c
3235 ac_cpp='$CPP $CPPFLAGS'
3236 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3237 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3238 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3239
3240
3241
3242 # Create compiler version string
3243 if test x"$GCC" = x"yes" ; then
3244   cc_string="GCC `${CC} --version | sed q`"
3245 else
3246   cc_string=$CC
3247 fi
3248
3249 cat >>confdefs.h <<_ACEOF
3250 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string"
3251 _ACEOF
3252
3253
3254
3255 #
3256 # Set up TAS assembly code if needed; the template file has now had its
3257 # chance to request this.
3258 #
3259           ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
3260
3261
3262 if test "$need_tas" = yes ; then
3263   TAS=tas.o
3264 else
3265   TAS=""
3266 fi
3267
3268
3269
3270 #
3271 # Automatic dependency tracking
3272 #
3273
3274
3275 # Check whether --enable-depend or --disable-depend was given.
3276 if test "${enable_depend+set}" = set; then
3277   enableval="$enable_depend"
3278
3279   case $enableval in
3280     yes)
3281       autodepend=yes
3282       ;;
3283     no)
3284       :
3285       ;;
3286     *)
3287       { { echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
3288 echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
3289    { (exit 1); exit 1; }; }
3290       ;;
3291   esac
3292
3293 else
3294   enable_depend=no
3295
3296 fi;
3297
3298
3299
3300
3301 #
3302 # Enable assert checks
3303 #
3304
3305
3306 # Check whether --enable-cassert or --disable-cassert was given.
3307 if test "${enable_cassert+set}" = set; then
3308   enableval="$enable_cassert"
3309
3310   case $enableval in
3311     yes)
3312
3313 cat >>confdefs.h <<\_ACEOF
3314 #define USE_ASSERT_CHECKING 1
3315 _ACEOF
3316
3317       ;;
3318     no)
3319       :
3320       ;;
3321     *)
3322       { { echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
3323 echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
3324    { (exit 1); exit 1; }; }
3325       ;;
3326   esac
3327
3328 else
3329   enable_cassert=no
3330
3331 fi;
3332
3333
3334
3335 #
3336 # Include directories
3337 #
3338 ac_save_IFS=$IFS
3339 IFS="${IFS}${PATH_SEPARATOR}"
3340 # SRCH_INC comes from the template file
3341 for dir in $with_includes $SRCH_INC; do
3342   if test -d "$dir"; then
3343     INCLUDES="$INCLUDES -I$dir"
3344   else
3345     { echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
3346 echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
3347   fi
3348 done
3349 IFS=$ac_save_IFS
3350
3351
3352
3353 #
3354 # Library directories
3355 #
3356 ac_save_IFS=$IFS
3357 IFS="${IFS}${PATH_SEPARATOR}"
3358 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
3359 for dir in $LIBRARY_DIRS $SRCH_LIB; do
3360   if test -d "$dir"; then
3361     LIBDIRS="$LIBDIRS -L$dir"
3362   else
3363     { echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
3364 echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
3365   fi
3366 done
3367 IFS=$ac_save_IFS
3368
3369 #
3370 # Enable thread-safe client libraries
3371 #
3372 echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
3373 echo $ECHO_N "checking allow thread-safe client libraries... $ECHO_C" >&6
3374
3375
3376 # Check whether --enable-thread-safety or --disable-thread-safety was given.
3377 if test "${enable_thread_safety+set}" = set; then
3378   enableval="$enable_thread_safety"
3379
3380   case $enableval in
3381     yes)
3382       :
3383       ;;
3384     no)
3385       :
3386       ;;
3387     *)
3388       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
3389 echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
3390    { (exit 1); exit 1; }; }
3391       ;;
3392   esac
3393
3394 else
3395   enable_thread_safety=no
3396
3397 fi;
3398
3399
3400
3401 # Check whether --enable-thread-safety-force or --disable-thread-safety-force was given.
3402 if test "${enable_thread_safety_force+set}" = set; then
3403   enableval="$enable_thread_safety_force"
3404
3405   case $enableval in
3406     yes)
3407       :
3408       ;;
3409     no)
3410       :
3411       ;;
3412     *)
3413       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety-force option" >&5
3414 echo "$as_me: error: no argument expected for --enable-thread-safety-force option" >&2;}
3415    { (exit 1); exit 1; }; }
3416       ;;
3417   esac
3418
3419 else
3420   enable_thread_safety_force=no
3421
3422 fi;
3423
3424 if test "$enable_thread_safety" = yes -o \
3425         "$enable_thread_safety_force" = yes; then
3426   enable_thread_safety="yes"    # for 'force'
3427
3428 cat >>confdefs.h <<\_ACEOF
3429 #define ENABLE_THREAD_SAFETY 1
3430 _ACEOF
3431
3432 fi
3433 echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
3434 echo "${ECHO_T}$enable_thread_safety" >&6
3435
3436
3437 #
3438 # Optionally build Tcl modules (PL/Tcl)
3439 #
3440 echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
3441 echo $ECHO_N "checking whether to build with Tcl... $ECHO_C" >&6
3442
3443
3444
3445 # Check whether --with-tcl or --without-tcl was given.
3446 if test "${with_tcl+set}" = set; then
3447   withval="$with_tcl"
3448
3449   case $withval in
3450     yes)
3451       :
3452       ;;
3453     no)
3454       :
3455       ;;
3456     *)
3457       { { echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
3458 echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
3459    { (exit 1); exit 1; }; }
3460       ;;
3461   esac
3462
3463 else
3464   with_tcl=no
3465
3466 fi;
3467
3468 echo "$as_me:$LINENO: result: $with_tcl" >&5
3469 echo "${ECHO_T}$with_tcl" >&6
3470
3471
3472 # We see if the path to the Tcl/Tk configuration scripts is specified.
3473 # This will override the use of tclsh to find the paths to search.
3474
3475
3476
3477
3478 # Check whether --with-tclconfig or --without-tclconfig was given.
3479 if test "${with_tclconfig+set}" = set; then
3480   withval="$with_tclconfig"
3481
3482   case $withval in
3483     yes)
3484       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3485 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3486    { (exit 1); exit 1; }; }
3487       ;;
3488     no)
3489       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3490 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3491    { (exit 1); exit 1; }; }
3492       ;;
3493     *)
3494
3495       ;;
3496   esac
3497
3498 fi;
3499
3500
3501 #
3502 # Optionally build Perl modules (PL/Perl)
3503 #
3504 echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
3505 echo $ECHO_N "checking whether to build Perl modules... $ECHO_C" >&6
3506
3507
3508
3509 # Check whether --with-perl or --without-perl was given.
3510 if test "${with_perl+set}" = set; then
3511   withval="$with_perl"
3512
3513   case $withval in
3514     yes)
3515       :
3516       ;;
3517     no)
3518       :
3519       ;;
3520     *)
3521       { { echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
3522 echo "$as_me: error: no argument expected for --with-perl option" >&2;}
3523    { (exit 1); exit 1; }; }
3524       ;;
3525   esac
3526
3527 else
3528   with_perl=no
3529
3530 fi;
3531
3532 echo "$as_me:$LINENO: result: $with_perl" >&5
3533 echo "${ECHO_T}$with_perl" >&6
3534
3535
3536 #
3537 # Optionally build Python modules (PL/Python)
3538 #
3539 echo "$as_me:$LINENO: checking whether to build Python modules" >&5
3540 echo $ECHO_N "checking whether to build Python modules... $ECHO_C" >&6
3541
3542
3543
3544 # Check whether --with-python or --without-python was given.
3545 if test "${with_python+set}" = set; then
3546   withval="$with_python"
3547
3548   case $withval in
3549     yes)
3550       :
3551       ;;
3552     no)
3553       :
3554       ;;
3555     *)
3556       { { echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
3557 echo "$as_me: error: no argument expected for --with-python option" >&2;}
3558    { (exit 1); exit 1; }; }
3559       ;;
3560   esac
3561
3562 else
3563   with_python=no
3564
3565 fi;
3566
3567 echo "$as_me:$LINENO: result: $with_python" >&5
3568 echo "${ECHO_T}$with_python" >&6
3569
3570
3571 #
3572 # Kerberos 5
3573 #
3574 echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
3575 echo $ECHO_N "checking whether to build with Kerberos 5 support... $ECHO_C" >&6
3576
3577
3578
3579 # Check whether --with-krb5 or --without-krb5 was given.
3580 if test "${with_krb5+set}" = set; then
3581   withval="$with_krb5"
3582
3583   case $withval in
3584     yes)
3585
3586
3587 cat >>confdefs.h <<\_ACEOF
3588 #define KRB5 1
3589 _ACEOF
3590
3591   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
3592
3593       ;;
3594     no)
3595       :
3596       ;;
3597     *)
3598       { { echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
3599 echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
3600    { (exit 1); exit 1; }; }
3601       ;;
3602   esac
3603
3604 else
3605   with_krb5=no
3606
3607 fi;
3608
3609 echo "$as_me:$LINENO: result: $with_krb5" >&5
3610 echo "${ECHO_T}$with_krb5" >&6
3611
3612
3613
3614
3615
3616
3617 #
3618 # Kerberos configuration parameters
3619 #
3620
3621
3622
3623 # Check whether --with-krb-srvnam or --without-krb-srvnam was given.
3624 if test "${with_krb_srvnam+set}" = set; then
3625   withval="$with_krb_srvnam"
3626
3627   case $withval in
3628     yes)
3629       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3630 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3631    { (exit 1); exit 1; }; }
3632       ;;
3633     no)
3634       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3635 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3636    { (exit 1); exit 1; }; }
3637       ;;
3638     *)
3639
3640       ;;
3641   esac
3642
3643 else
3644   with_krb_srvnam="postgres"
3645 fi;
3646
3647
3648 cat >>confdefs.h <<_ACEOF
3649 #define PG_KRB_SRVNAM "$with_krb_srvnam"
3650 _ACEOF
3651
3652
3653
3654 #
3655 # PAM
3656 #
3657 echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
3658 echo $ECHO_N "checking whether to build with PAM support... $ECHO_C" >&6
3659
3660
3661
3662 # Check whether --with-pam or --without-pam was given.
3663 if test "${with_pam+set}" = set; then
3664   withval="$with_pam"
3665
3666   case $withval in
3667     yes)
3668
3669 cat >>confdefs.h <<\_ACEOF
3670 #define USE_PAM 1
3671 _ACEOF
3672
3673       ;;
3674     no)
3675       :
3676       ;;
3677     *)
3678       { { echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
3679 echo "$as_me: error: no argument expected for --with-pam option" >&2;}
3680    { (exit 1); exit 1; }; }
3681       ;;
3682   esac
3683
3684 else
3685   with_pam=no
3686
3687 fi;
3688
3689 echo "$as_me:$LINENO: result: $with_pam" >&5
3690 echo "${ECHO_T}$with_pam" >&6
3691
3692
3693
3694 #
3695 # LDAP
3696 #
3697 echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
3698 echo $ECHO_N "checking whether to build with LDAP support... $ECHO_C" >&6
3699
3700
3701
3702 # Check whether --with-ldap or --without-ldap was given.
3703 if test "${with_ldap+set}" = set; then
3704   withval="$with_ldap"
3705
3706   case $withval in
3707     yes)
3708
3709 cat >>confdefs.h <<\_ACEOF
3710 #define USE_LDAP 1
3711 _ACEOF
3712
3713       ;;
3714     no)
3715       :
3716       ;;
3717     *)
3718       { { echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
3719 echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
3720    { (exit 1); exit 1; }; }
3721       ;;
3722   esac
3723
3724 else
3725   with_ldap=no
3726
3727 fi;
3728
3729 echo "$as_me:$LINENO: result: $with_ldap" >&5
3730 echo "${ECHO_T}$with_ldap" >&6
3731
3732
3733
3734 #
3735 # Bonjour
3736 #
3737 echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
3738 echo $ECHO_N "checking whether to build with Bonjour support... $ECHO_C" >&6
3739
3740
3741
3742 # Check whether --with-bonjour or --without-bonjour was given.
3743 if test "${with_bonjour+set}" = set; then
3744   withval="$with_bonjour"
3745
3746   case $withval in
3747     yes)
3748
3749 cat >>confdefs.h <<\_ACEOF
3750 #define USE_BONJOUR 1
3751 _ACEOF
3752
3753       ;;
3754     no)
3755       :
3756       ;;
3757     *)
3758       { { echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
3759 echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
3760    { (exit 1); exit 1; }; }
3761       ;;
3762   esac
3763
3764 else
3765   with_bonjour=no
3766
3767 fi;
3768
3769 echo "$as_me:$LINENO: result: $with_bonjour" >&5
3770 echo "${ECHO_T}$with_bonjour" >&6
3771
3772
3773
3774 #
3775 # OpenSSL
3776 #
3777 echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
3778 echo $ECHO_N "checking whether to build with OpenSSL support... $ECHO_C" >&6
3779
3780
3781
3782 # Check whether --with-openssl or --without-openssl was given.
3783 if test "${with_openssl+set}" = set; then
3784   withval="$with_openssl"
3785
3786   case $withval in
3787     yes)
3788
3789 cat >>confdefs.h <<\_ACEOF
3790 #define USE_SSL 1
3791 _ACEOF
3792
3793       ;;
3794     no)
3795       :
3796       ;;
3797     *)
3798       { { echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
3799 echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
3800    { (exit 1); exit 1; }; }
3801       ;;
3802   esac
3803
3804 else
3805   with_openssl=no
3806
3807 fi;
3808
3809 echo "$as_me:$LINENO: result: $with_openssl" >&5
3810 echo "${ECHO_T}$with_openssl" >&6
3811
3812
3813
3814 #
3815 # Prefer libedit
3816 #
3817
3818
3819
3820 # Check whether --with-libedit-preferred or --without-libedit-preferred was given.
3821 if test "${with_libedit_preferred+set}" = set; then
3822   withval="$with_libedit_preferred"
3823
3824   case $withval in
3825     yes)
3826       :
3827       ;;
3828     no)
3829       :
3830       ;;
3831     *)
3832       { { echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
3833 echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
3834    { (exit 1); exit 1; }; }
3835       ;;
3836   esac
3837
3838 else
3839   with_libedit_preferred=no
3840
3841 fi;
3842
3843
3844
3845 #
3846 # Readline
3847 #
3848
3849
3850
3851 # Check whether --with-readline or --without-readline was given.
3852 if test "${with_readline+set}" = set; then
3853   withval="$with_readline"
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-readline option" >&5
3864 echo "$as_me: error: no argument expected for --with-readline option" >&2;}
3865    { (exit 1); exit 1; }; }
3866       ;;
3867   esac
3868
3869 else
3870   with_readline=yes
3871
3872 fi;
3873
3874 # readline on MinGW has problems with backslashes in psql and other bugs.
3875 # This is particularly a problem with non-US code pages.
3876 # Therefore disable its use until we understand the cause. 2004-07-20
3877 if test "$PORTNAME" = "win32"; then
3878   if test "$with_readline" = yes; then
3879     { echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
3880 echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
3881     with_readline=no
3882   fi
3883 fi
3884
3885
3886 #
3887 # Zlib
3888 #
3889
3890
3891
3892 # Check whether --with-zlib or --without-zlib was given.
3893 if test "${with_zlib+set}" = set; then
3894   withval="$with_zlib"
3895
3896   case $withval in
3897     yes)
3898       :
3899       ;;
3900     no)
3901       :
3902       ;;
3903     *)
3904       { { echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
3905 echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
3906    { (exit 1); exit 1; }; }
3907       ;;
3908   esac
3909
3910 else
3911   with_zlib=yes
3912
3913 fi;
3914
3915
3916
3917 #
3918 # Elf
3919 #
3920
3921 # Assume system is ELF if it predefines __ELF__ as 1,
3922 # otherwise believe host_os based default.
3923 case $host_os in
3924     freebsd1*|freebsd2*) elf=no;;
3925     freebsd3*|freebsd4*) elf=yes;;
3926 esac
3927
3928
3929 echo "$as_me:$LINENO: checking for egrep" >&5
3930 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
3931 if test "${ac_cv_prog_egrep+set}" = set; then
3932   echo $ECHO_N "(cached) $ECHO_C" >&6
3933 else
3934   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
3935     then ac_cv_prog_egrep='grep -E'
3936     else ac_cv_prog_egrep='egrep'
3937     fi
3938 fi
3939 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
3940 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
3941  EGREP=$ac_cv_prog_egrep
3942
3943
3944 cat >conftest.$ac_ext <<_ACEOF
3945 /* confdefs.h.  */
3946 _ACEOF
3947 cat confdefs.h >>conftest.$ac_ext
3948 cat >>conftest.$ac_ext <<_ACEOF
3949 /* end confdefs.h.  */
3950 #if __ELF__
3951   yes
3952 #endif
3953
3954 _ACEOF
3955 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3956   $EGREP "yes" >/dev/null 2>&1; then
3957   ELF_SYS=true
3958 else
3959   if test "X$elf" = "Xyes" ; then
3960   ELF_SYS=true
3961 else
3962   ELF_SYS=
3963 fi
3964 fi
3965 rm -f conftest*
3966
3967
3968
3969 #
3970 # Assignments
3971 #
3972
3973 CPPFLAGS="$CPPFLAGS $INCLUDES"
3974 LDFLAGS="$LDFLAGS $LIBDIRS"
3975
3976 { echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
3977 echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
3978 { echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
3979 echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
3980
3981
3982
3983 for ac_prog in gawk mawk nawk awk
3984 do
3985   # Extract the first word of "$ac_prog", so it can be a program name with args.
3986 set dummy $ac_prog; ac_word=$2
3987 echo "$as_me:$LINENO: checking for $ac_word" >&5
3988 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3989 if test "${ac_cv_prog_AWK+set}" = set; then
3990   echo $ECHO_N "(cached) $ECHO_C" >&6
3991 else
3992   if test -n "$AWK"; then
3993   ac_cv_prog_AWK="$AWK" # Let the user override the test.
3994 else
3995 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3996 for as_dir in $PATH
3997 do
3998   IFS=$as_save_IFS
3999   test -z "$as_dir" && as_dir=.
4000   for ac_exec_ext in '' $ac_executable_extensions; do
4001   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4002     ac_cv_prog_AWK="$ac_prog"
4003     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4004     break 2
4005   fi
4006 done
4007 done
4008
4009 fi
4010 fi
4011 AWK=$ac_cv_prog_AWK
4012 if test -n "$AWK"; then
4013   echo "$as_me:$LINENO: result: $AWK" >&5
4014 echo "${ECHO_T}$AWK" >&6
4015 else
4016   echo "$as_me:$LINENO: result: no" >&5
4017 echo "${ECHO_T}no" >&6
4018 fi
4019
4020   test -n "$AWK" && break
4021 done
4022
4023 echo "$as_me:$LINENO: checking for flex" >&5
4024 echo $ECHO_N "checking for flex... $ECHO_C" >&6
4025 if test "${pgac_cv_path_flex+set}" = set; then
4026   echo $ECHO_N "(cached) $ECHO_C" >&6
4027 else
4028   # Let the user override the test
4029 if test -n "$FLEX"; then
4030   pgac_cv_path_flex=$FLEX
4031 else
4032   pgac_save_IFS=$IFS
4033   IFS=$PATH_SEPARATOR
4034   for pgac_dir in $PATH; do
4035     IFS=$pgac_save_IFS
4036     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
4037       pgac_dir=`pwd`
4038     fi
4039     for pgac_prog in flex lex; do
4040       pgac_candidate="$pgac_dir/$pgac_prog"
4041       if test -f "$pgac_candidate" \
4042         && $pgac_candidate --version </dev/null >/dev/null 2>&1
4043       then
4044         echo '%%'  > conftest.l
4045         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
4046           if $pgac_candidate --version | grep ' 2\.5\.3$' >/dev/null 2>&1; then
4047             pgac_broken_flex=$pgac_candidate
4048             continue
4049           fi
4050
4051           pgac_cv_path_flex=$pgac_candidate
4052           break 2
4053         fi
4054       fi
4055     done
4056   done
4057   rm -f conftest.l lex.yy.c
4058   : ${pgac_cv_path_flex=no}
4059 fi
4060
4061 fi
4062 echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
4063 echo "${ECHO_T}$pgac_cv_path_flex" >&6
4064 if test x"$pgac_cv_path_flex" = x"no"; then
4065   if test -n "$pgac_broken_flex"; then
4066     { echo "$as_me:$LINENO: WARNING:
4067 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
4068 *** should get version 2.5.4 or later." >&5
4069 echo "$as_me: WARNING:
4070 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
4071 *** should get version 2.5.4 or later." >&2;}
4072   fi
4073
4074   { echo "$as_me:$LINENO: WARNING:
4075 *** Without Flex you will not be able to build PostgreSQL from CVS or
4076 *** change any of the scanner definition files.  You can obtain Flex from
4077 *** a GNU mirror site.  (If you are using the official distribution of
4078 *** PostgreSQL then you do not need to worry about this because the Flex
4079 *** output is pre-generated.)" >&5
4080 echo "$as_me: WARNING:
4081 *** Without Flex you will not be able to build PostgreSQL from CVS or
4082 *** change any of the scanner definition files.  You can obtain Flex from
4083 *** a GNU mirror site.  (If you are using the official distribution of
4084 *** PostgreSQL then you do not need to worry about this because the Flex
4085 *** output is pre-generated.)" >&2;}
4086 fi
4087
4088 if test x"$pgac_cv_path_flex" = x"no"; then
4089   FLEX=
4090 else
4091   FLEX=$pgac_cv_path_flex
4092 fi
4093
4094
4095
4096
4097 echo "$as_me:$LINENO: checking whether ln -s works" >&5
4098 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
4099 LN_S=$as_ln_s
4100 if test "$LN_S" = "ln -s"; then
4101   echo "$as_me:$LINENO: result: yes" >&5
4102 echo "${ECHO_T}yes" >&6
4103 else
4104   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
4105 echo "${ECHO_T}no, using $LN_S" >&6
4106 fi
4107
4108
4109 # Check whether --with-gnu-ld or --without-gnu-ld was given.
4110 if test "${with_gnu_ld+set}" = set; then
4111   withval="$with_gnu_ld"
4112   test "$withval" = no || with_gnu_ld=yes
4113 else
4114   with_gnu_ld=no
4115 fi;
4116 ac_prog=ld
4117 if test "$GCC" = yes; then
4118   # Check if gcc -print-prog-name=ld gives a path.
4119   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
4120 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
4121   case $host in
4122   *-*-mingw*)
4123     # gcc leaves a trailing carriage return which upsets mingw
4124     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4125   *)
4126     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4127   esac
4128   case "$ac_prog" in
4129     # Accept absolute paths.
4130     [\\/]* | [A-Za-z]:[\\/]*)
4131       re_direlt='/[^/][^/]*/\.\./'
4132       # Canonicalize the path of ld
4133       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
4134       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
4135         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
4136       done
4137       test -z "$LD" && LD="$ac_prog"
4138       ;;
4139   "")
4140     # If it fails, then pretend we aren't using GCC.
4141     ac_prog=ld
4142     ;;
4143   *)
4144     # If it is relative, then search for the first ld in PATH.
4145     with_gnu_ld=unknown
4146     ;;
4147   esac
4148 elif test "$with_gnu_ld" = yes; then
4149   echo "$as_me:$LINENO: checking for GNU ld" >&5
4150 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
4151 else
4152   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
4153 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
4154 fi
4155 if test "${ac_cv_path_LD+set}" = set; then
4156   echo $ECHO_N "(cached) $ECHO_C" >&6
4157 else
4158   if test -z "$LD"; then
4159   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
4160   for ac_dir in $PATH; do
4161     test -z "$ac_dir" && ac_dir=.
4162     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4163       ac_cv_path_LD="$ac_dir/$ac_prog"
4164       # Check to see if the program is GNU ld.  I'd rather use --version,
4165       # but apparently some GNU ld's only accept -v.
4166       # Break only if it was the GNU/non-GNU ld that we prefer.
4167       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
4168         test "$with_gnu_ld" != no && break
4169       else
4170         test "$with_gnu_ld" != yes && break
4171       fi
4172     fi
4173   done
4174   IFS="$ac_save_ifs"
4175 else
4176   ac_cv_path_LD="$LD" # Let the user override the test with a path.
4177 fi
4178 fi
4179
4180 LD="$ac_cv_path_LD"
4181 if test -n "$LD"; then
4182   echo "$as_me:$LINENO: result: $LD" >&5
4183 echo "${ECHO_T}$LD" >&6
4184 else
4185   echo "$as_me:$LINENO: result: no" >&5
4186 echo "${ECHO_T}no" >&6
4187 fi
4188 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
4189 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
4190    { (exit 1); exit 1; }; }
4191 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
4192 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
4193 if test "${ac_cv_prog_gnu_ld+set}" = set; then
4194   echo $ECHO_N "(cached) $ECHO_C" >&6
4195 else
4196   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
4197 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
4198   ac_cv_prog_gnu_ld=yes
4199 else
4200   ac_cv_prog_gnu_ld=no
4201 fi
4202 fi
4203 echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
4204 echo "${ECHO_T}$ac_cv_prog_gnu_ld" >&6
4205 with_gnu_ld=$ac_cv_prog_gnu_ld
4206
4207
4208
4209
4210 case $host_os in sysv5*)
4211   echo "$as_me:$LINENO: checking whether ld -R works" >&5
4212 echo $ECHO_N "checking whether ld -R works... $ECHO_C" >&6
4213 if test "${pgac_cv_prog_ld_R+set}" = set; then
4214   echo $ECHO_N "(cached) $ECHO_C" >&6
4215 else
4216
4217     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
4218     cat >conftest.$ac_ext <<_ACEOF
4219 /* confdefs.h.  */
4220 _ACEOF
4221 cat confdefs.h >>conftest.$ac_ext
4222 cat >>conftest.$ac_ext <<_ACEOF
4223 /* end confdefs.h.  */
4224
4225 int
4226 main ()
4227 {
4228
4229   ;
4230   return 0;
4231 }
4232 _ACEOF
4233 rm -f conftest.$ac_objext conftest$ac_exeext
4234 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4235   (eval $ac_link) 2>conftest.er1
4236   ac_status=$?
4237   grep -v '^ *+' conftest.er1 >conftest.err
4238   rm -f conftest.er1
4239   cat conftest.err >&5
4240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4241   (exit $ac_status); } &&
4242          { ac_try='test -z "$ac_c_werror_flag"
4243                          || test ! -s conftest.err'
4244   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4245   (eval $ac_try) 2>&5
4246   ac_status=$?
4247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4248   (exit $ac_status); }; } &&
4249          { ac_try='test -s conftest$ac_exeext'
4250   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4251   (eval $ac_try) 2>&5
4252   ac_status=$?
4253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4254   (exit $ac_status); }; }; then
4255   pgac_cv_prog_ld_R=yes
4256 else
4257   echo "$as_me: failed program was:" >&5
4258 sed 's/^/| /' conftest.$ac_ext >&5
4259
4260 pgac_cv_prog_ld_R=no
4261 fi
4262 rm -f conftest.err conftest.$ac_objext \
4263       conftest$ac_exeext conftest.$ac_ext
4264     LDFLAGS=$pgac_save_LDFLAGS
4265
4266 fi
4267 echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
4268 echo "${ECHO_T}$pgac_cv_prog_ld_R" >&6
4269   ld_R_works=$pgac_cv_prog_ld_R
4270
4271 esac
4272 if test -n "$ac_tool_prefix"; then
4273   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4274 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4275 echo "$as_me:$LINENO: checking for $ac_word" >&5
4276 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4277 if test "${ac_cv_prog_RANLIB+set}" = set; then
4278   echo $ECHO_N "(cached) $ECHO_C" >&6
4279 else
4280   if test -n "$RANLIB"; then
4281   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4282 else
4283 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4284 for as_dir in $PATH
4285 do
4286   IFS=$as_save_IFS
4287   test -z "$as_dir" && as_dir=.
4288   for ac_exec_ext in '' $ac_executable_extensions; do
4289   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4290     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4291     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4292     break 2
4293   fi
4294 done
4295 done
4296
4297 fi
4298 fi
4299 RANLIB=$ac_cv_prog_RANLIB
4300 if test -n "$RANLIB"; then
4301   echo "$as_me:$LINENO: result: $RANLIB" >&5
4302 echo "${ECHO_T}$RANLIB" >&6
4303 else
4304   echo "$as_me:$LINENO: result: no" >&5
4305 echo "${ECHO_T}no" >&6
4306 fi
4307
4308 fi
4309 if test -z "$ac_cv_prog_RANLIB"; then
4310   ac_ct_RANLIB=$RANLIB
4311   # Extract the first word of "ranlib", so it can be a program name with args.
4312 set dummy ranlib; ac_word=$2
4313 echo "$as_me:$LINENO: checking for $ac_word" >&5
4314 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4315 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4316   echo $ECHO_N "(cached) $ECHO_C" >&6
4317 else
4318   if test -n "$ac_ct_RANLIB"; then
4319   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4320 else
4321 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4322 for as_dir in $PATH
4323 do
4324   IFS=$as_save_IFS
4325   test -z "$as_dir" && as_dir=.
4326   for ac_exec_ext in '' $ac_executable_extensions; do
4327   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4328     ac_cv_prog_ac_ct_RANLIB="ranlib"
4329     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4330     break 2
4331   fi
4332 done
4333 done
4334
4335   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
4336 fi
4337 fi
4338 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4339 if test -n "$ac_ct_RANLIB"; then
4340   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
4341 echo "${ECHO_T}$ac_ct_RANLIB" >&6
4342 else
4343   echo "$as_me:$LINENO: result: no" >&5
4344 echo "${ECHO_T}no" >&6
4345 fi
4346
4347   RANLIB=$ac_ct_RANLIB
4348 else
4349   RANLIB="$ac_cv_prog_RANLIB"
4350 fi
4351
4352 for ac_prog in lorder
4353 do
4354   # Extract the first word of "$ac_prog", so it can be a program name with args.
4355 set dummy $ac_prog; ac_word=$2
4356 echo "$as_me:$LINENO: checking for $ac_word" >&5
4357 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4358 if test "${ac_cv_prog_LORDER+set}" = set; then
4359   echo $ECHO_N "(cached) $ECHO_C" >&6
4360 else
4361   if test -n "$LORDER"; then
4362   ac_cv_prog_LORDER="$LORDER" # Let the user override the test.
4363 else
4364 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4365 for as_dir in $PATH
4366 do
4367   IFS=$as_save_IFS
4368   test -z "$as_dir" && as_dir=.
4369   for ac_exec_ext in '' $ac_executable_extensions; do
4370   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4371     ac_cv_prog_LORDER="$ac_prog"
4372     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4373     break 2
4374   fi
4375 done
4376 done
4377
4378 fi
4379 fi
4380 LORDER=$ac_cv_prog_LORDER
4381 if test -n "$LORDER"; then
4382   echo "$as_me:$LINENO: result: $LORDER" >&5
4383 echo "${ECHO_T}$LORDER" >&6
4384 else
4385   echo "$as_me:$LINENO: result: no" >&5
4386 echo "${ECHO_T}no" >&6
4387 fi
4388
4389   test -n "$LORDER" && break
4390 done
4391
4392 # Extract the first word of "tar", so it can be a program name with args.
4393 set dummy tar; 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_path_TAR+set}" = set; then
4397   echo $ECHO_N "(cached) $ECHO_C" >&6
4398 else
4399   case $TAR in
4400   [\\/]* | ?:[\\/]*)
4401   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
4402   ;;
4403   *)
4404   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4405 for as_dir in $PATH
4406 do
4407   IFS=$as_save_IFS
4408   test -z "$as_dir" && as_dir=.
4409   for ac_exec_ext in '' $ac_executable_extensions; do
4410   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4411     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
4412     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4413     break 2
4414   fi
4415 done
4416 done
4417
4418   ;;
4419 esac
4420 fi
4421 TAR=$ac_cv_path_TAR
4422
4423 if test -n "$TAR"; then
4424   echo "$as_me:$LINENO: result: $TAR" >&5
4425 echo "${ECHO_T}$TAR" >&6
4426 else
4427   echo "$as_me:$LINENO: result: no" >&5
4428 echo "${ECHO_T}no" >&6
4429 fi
4430
4431
4432   if test -n "$ac_tool_prefix"; then
4433   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4434 set dummy ${ac_tool_prefix}strip; ac_word=$2
4435 echo "$as_me:$LINENO: checking for $ac_word" >&5
4436 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4437 if test "${ac_cv_prog_STRIP+set}" = set; then
4438   echo $ECHO_N "(cached) $ECHO_C" >&6
4439 else
4440   if test -n "$STRIP"; then
4441   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4442 else
4443 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4444 for as_dir in $PATH
4445 do
4446   IFS=$as_save_IFS
4447   test -z "$as_dir" && as_dir=.
4448   for ac_exec_ext in '' $ac_executable_extensions; do
4449   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4450     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4451     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4452     break 2
4453   fi
4454 done
4455 done
4456
4457 fi
4458 fi
4459 STRIP=$ac_cv_prog_STRIP
4460 if test -n "$STRIP"; then
4461   echo "$as_me:$LINENO: result: $STRIP" >&5
4462 echo "${ECHO_T}$STRIP" >&6
4463 else
4464   echo "$as_me:$LINENO: result: no" >&5
4465 echo "${ECHO_T}no" >&6
4466 fi
4467
4468 fi
4469 if test -z "$ac_cv_prog_STRIP"; then
4470   ac_ct_STRIP=$STRIP
4471   # Extract the first word of "strip", so it can be a program name with args.
4472 set dummy strip; ac_word=$2
4473 echo "$as_me:$LINENO: checking for $ac_word" >&5
4474 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4475 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
4476   echo $ECHO_N "(cached) $ECHO_C" >&6
4477 else
4478   if test -n "$ac_ct_STRIP"; then
4479   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
4480 else
4481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4482 for as_dir in $PATH
4483 do
4484   IFS=$as_save_IFS
4485   test -z "$as_dir" && as_dir=.
4486   for ac_exec_ext in '' $ac_executable_extensions; do
4487   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4488     ac_cv_prog_ac_ct_STRIP="strip"
4489     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4490     break 2
4491   fi
4492 done
4493 done
4494
4495   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
4496 fi
4497 fi
4498 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4499 if test -n "$ac_ct_STRIP"; then
4500   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
4501 echo "${ECHO_T}$ac_ct_STRIP" >&6
4502 else
4503   echo "$as_me:$LINENO: result: no" >&5
4504 echo "${ECHO_T}no" >&6
4505 fi
4506
4507   STRIP=$ac_ct_STRIP
4508 else
4509   STRIP="$ac_cv_prog_STRIP"
4510 fi
4511
4512
4513   echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
4514 echo $ECHO_N "checking whether it is possible to strip libraries... $ECHO_C" >&6
4515   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
4516     STRIP_STATIC_LIB="$STRIP -x"
4517     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
4518     echo "$as_me:$LINENO: result: yes" >&5
4519 echo "${ECHO_T}yes" >&6
4520   else
4521     STRIP_STATIC_LIB=:
4522     STRIP_SHARED_LIB=:
4523     echo "$as_me:$LINENO: result: no" >&5
4524 echo "${ECHO_T}no" >&6
4525   fi
4526
4527
4528
4529
4530 for ac_prog in 'bison -y'
4531 do
4532   # Extract the first word of "$ac_prog", so it can be a program name with args.
4533 set dummy $ac_prog; ac_word=$2
4534 echo "$as_me:$LINENO: checking for $ac_word" >&5
4535 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4536 if test "${ac_cv_prog_YACC+set}" = set; then
4537   echo $ECHO_N "(cached) $ECHO_C" >&6
4538 else
4539   if test -n "$YACC"; then
4540   ac_cv_prog_YACC="$YACC" # Let the user override the test.
4541 else
4542 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4543 for as_dir in $PATH
4544 do
4545   IFS=$as_save_IFS
4546   test -z "$as_dir" && as_dir=.
4547   for ac_exec_ext in '' $ac_executable_extensions; do
4548   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4549     ac_cv_prog_YACC="$ac_prog"
4550     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4551     break 2
4552   fi
4553 done
4554 done
4555
4556 fi
4557 fi
4558 YACC=$ac_cv_prog_YACC
4559 if test -n "$YACC"; then
4560   echo "$as_me:$LINENO: result: $YACC" >&5
4561 echo "${ECHO_T}$YACC" >&6
4562 else
4563   echo "$as_me:$LINENO: result: no" >&5
4564 echo "${ECHO_T}no" >&6
4565 fi
4566
4567   test -n "$YACC" && break
4568 done
4569
4570
4571 if test "$YACC"; then
4572   if $YACC --version | sed q | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'; then
4573     { echo "$as_me:$LINENO: WARNING:
4574 *** If you are going to modify the grammar files or build from CVS, the installed
4575 *** version of Bison is too old.  Bison version 1.875 or later is required." >&5
4576 echo "$as_me: WARNING:
4577 *** If you are going to modify the grammar files or build from CVS, the installed
4578 *** version of Bison is too old.  Bison version 1.875 or later is required." >&2;}
4579   fi
4580 fi
4581
4582 if test -z "$YACC"; then
4583   { echo "$as_me:$LINENO: WARNING:
4584 *** Without Bison you will not be able to build PostgreSQL from CVS or
4585 *** change any of the parser definition files.  You can obtain Bison from
4586 *** a GNU mirror site.  (If you are using the official distribution of
4587 *** PostgreSQL then you do not need to worry about this because the Bison
4588 *** output is pre-generated.)  To use a different yacc program (possible,
4589 *** but not recommended), set the environment variable YACC before running
4590 *** 'configure'." >&5
4591 echo "$as_me: WARNING:
4592 *** Without Bison you will not be able to build PostgreSQL from CVS or
4593 *** change any of the parser definition files.  You can obtain Bison from
4594 *** a GNU mirror site.  (If you are using the official distribution of
4595 *** PostgreSQL then you do not need to worry about this because the Bison
4596 *** output is pre-generated.)  To use a different yacc program (possible,
4597 *** but not recommended), set the environment variable YACC before running
4598 *** 'configure'." >&2;}
4599 fi
4600
4601
4602 # Extract the first word of "perl", so it can be a program name with args.
4603 set dummy perl; ac_word=$2
4604 echo "$as_me:$LINENO: checking for $ac_word" >&5
4605 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4606 if test "${ac_cv_path_PERL+set}" = set; then
4607   echo $ECHO_N "(cached) $ECHO_C" >&6
4608 else
4609   case $PERL in
4610   [\\/]* | ?:[\\/]*)
4611   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
4612   ;;
4613   *)
4614   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4615 for as_dir in $PATH
4616 do
4617   IFS=$as_save_IFS
4618   test -z "$as_dir" && as_dir=.
4619   for ac_exec_ext in '' $ac_executable_extensions; do
4620   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4621     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
4622     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4623     break 2
4624   fi
4625 done
4626 done
4627
4628   ;;
4629 esac
4630 fi
4631 PERL=$ac_cv_path_PERL
4632
4633 if test -n "$PERL"; then
4634   echo "$as_me:$LINENO: result: $PERL" >&5
4635 echo "${ECHO_T}$PERL" >&6
4636 else
4637   echo "$as_me:$LINENO: result: no" >&5
4638 echo "${ECHO_T}no" >&6
4639 fi
4640
4641 if test "$with_perl" = yes; then
4642
4643 echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
4644 echo $ECHO_N "checking for Perl archlibexp... $ECHO_C" >&6
4645 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
4646 echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
4647 echo "${ECHO_T}$perl_archlibexp" >&6
4648 echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
4649 echo $ECHO_N "checking for Perl privlibexp... $ECHO_C" >&6
4650 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
4651 echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
4652 echo "${ECHO_T}$perl_privlibexp" >&6
4653 echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
4654 echo $ECHO_N "checking for Perl useshrplib... $ECHO_C" >&6
4655 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
4656 echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
4657 echo "${ECHO_T}$perl_useshrplib" >&6
4658
4659 echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
4660 echo $ECHO_N "checking for flags to link embedded Perl... $ECHO_C" >&6
4661 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
4662 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
4663 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed "s/^X//;s%$pgac_tmp2%%"`
4664 echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
4665 echo "${ECHO_T}$perl_embed_ldflags" >&6
4666 fi
4667
4668 if test "$with_python" = yes; then
4669   # Extract the first word of "python", so it can be a program name with args.
4670 set dummy python; ac_word=$2
4671 echo "$as_me:$LINENO: checking for $ac_word" >&5
4672 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4673 if test "${ac_cv_path_PYTHON+set}" = set; then
4674   echo $ECHO_N "(cached) $ECHO_C" >&6
4675 else
4676   case $PYTHON in
4677   [\\/]* | ?:[\\/]*)
4678   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
4679   ;;
4680   *)
4681   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4682 for as_dir in $PATH
4683 do
4684   IFS=$as_save_IFS
4685   test -z "$as_dir" && as_dir=.
4686   for ac_exec_ext in '' $ac_executable_extensions; do
4687   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4688     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
4689     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4690     break 2
4691   fi
4692 done
4693 done
4694
4695   ;;
4696 esac
4697 fi
4698 PYTHON=$ac_cv_path_PYTHON
4699
4700 if test -n "$PYTHON"; then
4701   echo "$as_me:$LINENO: result: $PYTHON" >&5
4702 echo "${ECHO_T}$PYTHON" >&6
4703 else
4704   echo "$as_me:$LINENO: result: no" >&5
4705 echo "${ECHO_T}no" >&6
4706 fi
4707
4708 if test x"$PYTHON" = x""; then
4709   { { echo "$as_me:$LINENO: error: Python not found" >&5
4710 echo "$as_me: error: Python not found" >&2;}
4711    { (exit 1); exit 1; }; }
4712 fi
4713
4714
4715 echo "$as_me:$LINENO: checking for Python distutils module" >&5
4716 echo $ECHO_N "checking for Python distutils module... $ECHO_C" >&6
4717 if "${PYTHON}" 2>&- -c 'import distutils'
4718 then
4719     echo "$as_me:$LINENO: result: yes" >&5
4720 echo "${ECHO_T}yes" >&6
4721 else
4722     echo "$as_me:$LINENO: result: no" >&5
4723 echo "${ECHO_T}no" >&6
4724     { { echo "$as_me:$LINENO: error: distutils module not found" >&5
4725 echo "$as_me: error: distutils module not found" >&2;}
4726    { (exit 1); exit 1; }; }
4727 fi
4728 echo "$as_me:$LINENO: checking Python configuration directory" >&5
4729 echo $ECHO_N "checking Python configuration directory... $ECHO_C" >&6
4730 python_version=`${PYTHON} -c "import sys; print sys.version[:3]"`
4731 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')"`
4732 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print '-I'+distutils.sysconfig.get_python_inc()"`
4733
4734 # This should be enough of a message.
4735 echo "$as_me:$LINENO: result: $python_configdir" >&5
4736 echo "${ECHO_T}$python_configdir" >&6
4737
4738
4739 echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
4740 echo $ECHO_N "checking how to link an embedded Python application... $ECHO_C" >&6
4741
4742 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR')))"`
4743 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY')))"`
4744 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('SO')))"`
4745 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
4746
4747 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
4748 then
4749         # New way: use the official shared library
4750         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
4751         python_libspec="-L${python_libdir} -l${ldlibrary}"
4752 else
4753         # Old way: use libpython from python_configdir
4754         python_libdir="${python_configdir}"
4755         python_libspec="-L${python_libdir} -lpython${python_version}"
4756 fi
4757
4758 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','LOCALMODLIBS','BASEMODLIBS')))"`
4759
4760 echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
4761 echo "${ECHO_T}${python_libspec} ${python_additional_libs}" >&6
4762
4763
4764 # threaded python is not supported on bsd's
4765 echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
4766 echo $ECHO_N "checking whether Python is compiled with thread support... $ECHO_C" >&6
4767 pythreads=`${PYTHON} -c "import sys; print int('thread' in sys.builtin_module_names)"`
4768 if test "$pythreads" = "1"; then
4769   echo "$as_me:$LINENO: result: yes" >&5
4770 echo "${ECHO_T}yes" >&6
4771   case $host_os in
4772   openbsd*|freebsd4*)
4773     { { echo "$as_me:$LINENO: error: *** Threaded Python not supported on this platform ***" >&5
4774 echo "$as_me: error: *** Threaded Python not supported on this platform ***" >&2;}
4775    { (exit 1); exit 1; }; }
4776     ;;
4777   esac
4778 else
4779   echo "$as_me:$LINENO: result: no" >&5
4780 echo "${ECHO_T}no" >&6
4781 fi
4782
4783
4784 fi
4785
4786 # Supply a numeric version string for use by 3rd party add-ons
4787 # awk -F is a regex on some platforms, and not on others, so make "." a tab
4788 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/A-Za-z.*$//' |
4789 tr '.' '        ' |
4790 $AWK '{printf \"%d%02d%02d\", $1, $2, (NF >= 3) ? $3 : 0}'`"
4791
4792 cat >>confdefs.h <<_ACEOF
4793 #define PG_VERSION_NUM $PG_VERSION_NUM
4794 _ACEOF
4795
4796
4797 ##
4798 ## Libraries
4799 ##
4800
4801 echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
4802 echo $ECHO_N "checking for library containing setproctitle... $ECHO_C" >&6
4803 if test "${ac_cv_search_setproctitle+set}" = set; then
4804   echo $ECHO_N "(cached) $ECHO_C" >&6
4805 else
4806   ac_func_search_save_LIBS=$LIBS
4807 ac_cv_search_setproctitle=no
4808 cat >conftest.$ac_ext <<_ACEOF
4809 /* confdefs.h.  */
4810 _ACEOF
4811 cat confdefs.h >>conftest.$ac_ext
4812 cat >>conftest.$ac_ext <<_ACEOF
4813 /* end confdefs.h.  */
4814
4815 /* Override any gcc2 internal prototype to avoid an error.  */
4816 #ifdef __cplusplus
4817 extern "C"
4818 #endif
4819 /* We use char because int might match the return type of a gcc2
4820    builtin and then its argument prototype would still apply.  */
4821 char setproctitle ();
4822 int
4823 main ()
4824 {
4825 setproctitle ();
4826   ;
4827   return 0;
4828 }
4829 _ACEOF
4830 rm -f conftest.$ac_objext conftest$ac_exeext
4831 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4832   (eval $ac_link) 2>conftest.er1
4833   ac_status=$?
4834   grep -v '^ *+' conftest.er1 >conftest.err
4835   rm -f conftest.er1
4836   cat conftest.err >&5
4837   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4838   (exit $ac_status); } &&
4839          { ac_try='test -z "$ac_c_werror_flag"
4840                          || test ! -s conftest.err'
4841   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4842   (eval $ac_try) 2>&5
4843   ac_status=$?
4844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4845   (exit $ac_status); }; } &&
4846          { ac_try='test -s conftest$ac_exeext'
4847   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4848   (eval $ac_try) 2>&5
4849   ac_status=$?
4850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4851   (exit $ac_status); }; }; then
4852   ac_cv_search_setproctitle="none required"
4853 else
4854   echo "$as_me: failed program was:" >&5
4855 sed 's/^/| /' conftest.$ac_ext >&5
4856
4857 fi
4858 rm -f conftest.err conftest.$ac_objext \
4859       conftest$ac_exeext conftest.$ac_ext
4860 if test "$ac_cv_search_setproctitle" = no; then
4861   for ac_lib in util; do
4862     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
4863     cat >conftest.$ac_ext <<_ACEOF
4864 /* confdefs.h.  */
4865 _ACEOF
4866 cat confdefs.h >>conftest.$ac_ext
4867 cat >>conftest.$ac_ext <<_ACEOF
4868 /* end confdefs.h.  */
4869
4870 /* Override any gcc2 internal prototype to avoid an error.  */
4871 #ifdef __cplusplus
4872 extern "C"
4873 #endif
4874 /* We use char because int might match the return type of a gcc2
4875    builtin and then its argument prototype would still apply.  */
4876 char setproctitle ();
4877 int
4878 main ()
4879 {
4880 setproctitle ();
4881   ;
4882   return 0;
4883 }
4884 _ACEOF
4885 rm -f conftest.$ac_objext conftest$ac_exeext
4886 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4887   (eval $ac_link) 2>conftest.er1
4888   ac_status=$?
4889   grep -v '^ *+' conftest.er1 >conftest.err
4890   rm -f conftest.er1
4891   cat conftest.err >&5
4892   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4893   (exit $ac_status); } &&
4894          { ac_try='test -z "$ac_c_werror_flag"
4895                          || test ! -s conftest.err'
4896   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4897   (eval $ac_try) 2>&5
4898   ac_status=$?
4899   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4900   (exit $ac_status); }; } &&
4901          { ac_try='test -s conftest$ac_exeext'
4902   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4903   (eval $ac_try) 2>&5
4904   ac_status=$?
4905   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4906   (exit $ac_status); }; }; then
4907   ac_cv_search_setproctitle="-l$ac_lib"
4908 break
4909 else
4910   echo "$as_me: failed program was:" >&5
4911 sed 's/^/| /' conftest.$ac_ext >&5
4912
4913 fi
4914 rm -f conftest.err conftest.$ac_objext \
4915       conftest$ac_exeext conftest.$ac_ext
4916   done
4917 fi
4918 LIBS=$ac_func_search_save_LIBS
4919 fi
4920 echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
4921 echo "${ECHO_T}$ac_cv_search_setproctitle" >&6
4922 if test "$ac_cv_search_setproctitle" != no; then
4923   test "$ac_cv_search_setproctitle" = "none required" || LIBS="$ac_cv_search_setproctitle $LIBS"
4924
4925 fi
4926
4927 echo "$as_me:$LINENO: checking for library containing pow" >&5
4928 echo $ECHO_N "checking for library containing pow... $ECHO_C" >&6
4929 if test "${ac_cv_search_pow+set}" = set; then
4930   echo $ECHO_N "(cached) $ECHO_C" >&6
4931 else
4932   ac_func_search_save_LIBS=$LIBS
4933 ac_cv_search_pow=no
4934 cat >conftest.$ac_ext <<_ACEOF
4935 /* confdefs.h.  */
4936 _ACEOF
4937 cat confdefs.h >>conftest.$ac_ext
4938 cat >>conftest.$ac_ext <<_ACEOF
4939 /* end confdefs.h.  */
4940
4941 /* Override any gcc2 internal prototype to avoid an error.  */
4942 #ifdef __cplusplus
4943 extern "C"
4944 #endif
4945 /* We use char because int might match the return type of a gcc2
4946    builtin and then its argument prototype would still apply.  */
4947 char pow ();
4948 int
4949 main ()
4950 {
4951 pow ();
4952   ;
4953   return 0;
4954 }
4955 _ACEOF
4956 rm -f conftest.$ac_objext conftest$ac_exeext
4957 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4958   (eval $ac_link) 2>conftest.er1
4959   ac_status=$?
4960   grep -v '^ *+' conftest.er1 >conftest.err
4961   rm -f conftest.er1
4962   cat conftest.err >&5
4963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4964   (exit $ac_status); } &&
4965          { ac_try='test -z "$ac_c_werror_flag"
4966                          || test ! -s conftest.err'
4967   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4968   (eval $ac_try) 2>&5
4969   ac_status=$?
4970   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4971   (exit $ac_status); }; } &&
4972          { ac_try='test -s conftest$ac_exeext'
4973   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4974   (eval $ac_try) 2>&5
4975   ac_status=$?
4976   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4977   (exit $ac_status); }; }; then
4978   ac_cv_search_pow="none required"
4979 else
4980   echo "$as_me: failed program was:" >&5
4981 sed 's/^/| /' conftest.$ac_ext >&5
4982
4983 fi
4984 rm -f conftest.err conftest.$ac_objext \
4985       conftest$ac_exeext conftest.$ac_ext
4986 if test "$ac_cv_search_pow" = no; then
4987   for ac_lib in m; do
4988     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
4989     cat >conftest.$ac_ext <<_ACEOF
4990 /* confdefs.h.  */
4991 _ACEOF
4992 cat confdefs.h >>conftest.$ac_ext
4993 cat >>conftest.$ac_ext <<_ACEOF
4994 /* end confdefs.h.  */
4995
4996 /* Override any gcc2 internal prototype to avoid an error.  */
4997 #ifdef __cplusplus
4998 extern "C"
4999 #endif
5000 /* We use char because int might match the return type of a gcc2
5001    builtin and then its argument prototype would still apply.  */
5002 char pow ();
5003 int
5004 main ()
5005 {
5006 pow ();
5007   ;
5008   return 0;
5009 }
5010 _ACEOF
5011 rm -f conftest.$ac_objext conftest$ac_exeext
5012 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5013   (eval $ac_link) 2>conftest.er1
5014   ac_status=$?
5015   grep -v '^ *+' conftest.er1 >conftest.err
5016   rm -f conftest.er1
5017   cat conftest.err >&5
5018   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5019   (exit $ac_status); } &&
5020          { ac_try='test -z "$ac_c_werror_flag"
5021                          || test ! -s conftest.err'
5022   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5023   (eval $ac_try) 2>&5
5024   ac_status=$?
5025   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5026   (exit $ac_status); }; } &&
5027          { ac_try='test -s conftest$ac_exeext'
5028   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5029   (eval $ac_try) 2>&5
5030   ac_status=$?
5031   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5032   (exit $ac_status); }; }; then
5033   ac_cv_search_pow="-l$ac_lib"
5034 break
5035 else
5036   echo "$as_me: failed program was:" >&5
5037 sed 's/^/| /' conftest.$ac_ext >&5
5038
5039 fi
5040 rm -f conftest.err conftest.$ac_objext \
5041       conftest$ac_exeext conftest.$ac_ext
5042   done
5043 fi
5044 LIBS=$ac_func_search_save_LIBS
5045 fi
5046 echo "$as_me:$LINENO: result: $ac_cv_search_pow" >&5
5047 echo "${ECHO_T}$ac_cv_search_pow" >&6
5048 if test "$ac_cv_search_pow" != no; then
5049   test "$ac_cv_search_pow" = "none required" || LIBS="$ac_cv_search_pow $LIBS"
5050
5051 fi
5052
5053 echo "$as_me:$LINENO: checking for library containing dlopen" >&5
5054 echo $ECHO_N "checking for library containing dlopen... $ECHO_C" >&6
5055 if test "${ac_cv_search_dlopen+set}" = set; then
5056   echo $ECHO_N "(cached) $ECHO_C" >&6
5057 else
5058   ac_func_search_save_LIBS=$LIBS
5059 ac_cv_search_dlopen=no
5060 cat >conftest.$ac_ext <<_ACEOF
5061 /* confdefs.h.  */
5062 _ACEOF
5063 cat confdefs.h >>conftest.$ac_ext
5064 cat >>conftest.$ac_ext <<_ACEOF
5065 /* end confdefs.h.  */
5066
5067 /* Override any gcc2 internal prototype to avoid an error.  */
5068 #ifdef __cplusplus
5069 extern "C"
5070 #endif
5071 /* We use char because int might match the return type of a gcc2
5072    builtin and then its argument prototype would still apply.  */
5073 char dlopen ();
5074 int
5075 main ()
5076 {
5077 dlopen ();
5078   ;
5079   return 0;
5080 }
5081 _ACEOF
5082 rm -f conftest.$ac_objext conftest$ac_exeext
5083 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5084   (eval $ac_link) 2>conftest.er1
5085   ac_status=$?
5086   grep -v '^ *+' conftest.er1 >conftest.err
5087   rm -f conftest.er1
5088   cat conftest.err >&5
5089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5090   (exit $ac_status); } &&
5091          { ac_try='test -z "$ac_c_werror_flag"
5092                          || test ! -s conftest.err'
5093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5094   (eval $ac_try) 2>&5
5095   ac_status=$?
5096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5097   (exit $ac_status); }; } &&
5098          { ac_try='test -s conftest$ac_exeext'
5099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5100   (eval $ac_try) 2>&5
5101   ac_status=$?
5102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5103   (exit $ac_status); }; }; then
5104   ac_cv_search_dlopen="none required"
5105 else
5106   echo "$as_me: failed program was:" >&5
5107 sed 's/^/| /' conftest.$ac_ext >&5
5108
5109 fi
5110 rm -f conftest.err conftest.$ac_objext \
5111       conftest$ac_exeext conftest.$ac_ext
5112 if test "$ac_cv_search_dlopen" = no; then
5113   for ac_lib in dl; do
5114     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5115     cat >conftest.$ac_ext <<_ACEOF
5116 /* confdefs.h.  */
5117 _ACEOF
5118 cat confdefs.h >>conftest.$ac_ext
5119 cat >>conftest.$ac_ext <<_ACEOF
5120 /* end confdefs.h.  */
5121
5122 /* Override any gcc2 internal prototype to avoid an error.  */
5123 #ifdef __cplusplus
5124 extern "C"
5125 #endif
5126 /* We use char because int might match the return type of a gcc2
5127    builtin and then its argument prototype would still apply.  */
5128 char dlopen ();
5129 int
5130 main ()
5131 {
5132 dlopen ();
5133   ;
5134   return 0;
5135 }
5136 _ACEOF
5137 rm -f conftest.$ac_objext conftest$ac_exeext
5138 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5139   (eval $ac_link) 2>conftest.er1
5140   ac_status=$?
5141   grep -v '^ *+' conftest.er1 >conftest.err
5142   rm -f conftest.er1
5143   cat conftest.err >&5
5144   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5145   (exit $ac_status); } &&
5146          { ac_try='test -z "$ac_c_werror_flag"
5147                          || test ! -s conftest.err'
5148   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5149   (eval $ac_try) 2>&5
5150   ac_status=$?
5151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5152   (exit $ac_status); }; } &&
5153          { ac_try='test -s conftest$ac_exeext'
5154   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5155   (eval $ac_try) 2>&5
5156   ac_status=$?
5157   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5158   (exit $ac_status); }; }; then
5159   ac_cv_search_dlopen="-l$ac_lib"
5160 break
5161 else
5162   echo "$as_me: failed program was:" >&5
5163 sed 's/^/| /' conftest.$ac_ext >&5
5164
5165 fi
5166 rm -f conftest.err conftest.$ac_objext \
5167       conftest$ac_exeext conftest.$ac_ext
5168   done
5169 fi
5170 LIBS=$ac_func_search_save_LIBS
5171 fi
5172 echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
5173 echo "${ECHO_T}$ac_cv_search_dlopen" >&6
5174 if test "$ac_cv_search_dlopen" != no; then
5175   test "$ac_cv_search_dlopen" = "none required" || LIBS="$ac_cv_search_dlopen $LIBS"
5176
5177 fi
5178
5179 echo "$as_me:$LINENO: checking for library containing socket" >&5
5180 echo $ECHO_N "checking for library containing socket... $ECHO_C" >&6
5181 if test "${ac_cv_search_socket+set}" = set; then
5182   echo $ECHO_N "(cached) $ECHO_C" >&6
5183 else
5184   ac_func_search_save_LIBS=$LIBS
5185 ac_cv_search_socket=no
5186 cat >conftest.$ac_ext <<_ACEOF
5187 /* confdefs.h.  */
5188 _ACEOF
5189 cat confdefs.h >>conftest.$ac_ext
5190 cat >>conftest.$ac_ext <<_ACEOF
5191 /* end confdefs.h.  */
5192
5193 /* Override any gcc2 internal prototype to avoid an error.  */
5194 #ifdef __cplusplus
5195 extern "C"
5196 #endif
5197 /* We use char because int might match the return type of a gcc2
5198    builtin and then its argument prototype would still apply.  */
5199 char socket ();
5200 int
5201 main ()
5202 {
5203 socket ();
5204   ;
5205   return 0;
5206 }
5207 _ACEOF
5208 rm -f conftest.$ac_objext conftest$ac_exeext
5209 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5210   (eval $ac_link) 2>conftest.er1
5211   ac_status=$?
5212   grep -v '^ *+' conftest.er1 >conftest.err
5213   rm -f conftest.er1
5214   cat conftest.err >&5
5215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5216   (exit $ac_status); } &&
5217          { ac_try='test -z "$ac_c_werror_flag"
5218                          || test ! -s conftest.err'
5219   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5220   (eval $ac_try) 2>&5
5221   ac_status=$?
5222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5223   (exit $ac_status); }; } &&
5224          { ac_try='test -s conftest$ac_exeext'
5225   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5226   (eval $ac_try) 2>&5
5227   ac_status=$?
5228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5229   (exit $ac_status); }; }; then
5230   ac_cv_search_socket="none required"
5231 else
5232   echo "$as_me: failed program was:" >&5
5233 sed 's/^/| /' conftest.$ac_ext >&5
5234
5235 fi
5236 rm -f conftest.err conftest.$ac_objext \
5237       conftest$ac_exeext conftest.$ac_ext
5238 if test "$ac_cv_search_socket" = no; then
5239   for ac_lib in socket wsock32; do
5240     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5241     cat >conftest.$ac_ext <<_ACEOF
5242 /* confdefs.h.  */
5243 _ACEOF
5244 cat confdefs.h >>conftest.$ac_ext
5245 cat >>conftest.$ac_ext <<_ACEOF
5246 /* end confdefs.h.  */
5247
5248 /* Override any gcc2 internal prototype to avoid an error.  */
5249 #ifdef __cplusplus
5250 extern "C"
5251 #endif
5252 /* We use char because int might match the return type of a gcc2
5253    builtin and then its argument prototype would still apply.  */
5254 char socket ();
5255 int
5256 main ()
5257 {
5258 socket ();
5259   ;
5260   return 0;
5261 }
5262 _ACEOF
5263 rm -f conftest.$ac_objext conftest$ac_exeext
5264 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5265   (eval $ac_link) 2>conftest.er1
5266   ac_status=$?
5267   grep -v '^ *+' conftest.er1 >conftest.err
5268   rm -f conftest.er1
5269   cat conftest.err >&5
5270   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5271   (exit $ac_status); } &&
5272          { ac_try='test -z "$ac_c_werror_flag"
5273                          || test ! -s conftest.err'
5274   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5275   (eval $ac_try) 2>&5
5276   ac_status=$?
5277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5278   (exit $ac_status); }; } &&
5279          { ac_try='test -s conftest$ac_exeext'
5280   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5281   (eval $ac_try) 2>&5
5282   ac_status=$?
5283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5284   (exit $ac_status); }; }; then
5285   ac_cv_search_socket="-l$ac_lib"
5286 break
5287 else
5288   echo "$as_me: failed program was:" >&5
5289 sed 's/^/| /' conftest.$ac_ext >&5
5290
5291 fi
5292 rm -f conftest.err conftest.$ac_objext \
5293       conftest$ac_exeext conftest.$ac_ext
5294   done
5295 fi
5296 LIBS=$ac_func_search_save_LIBS
5297 fi
5298 echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
5299 echo "${ECHO_T}$ac_cv_search_socket" >&6
5300 if test "$ac_cv_search_socket" != no; then
5301   test "$ac_cv_search_socket" = "none required" || LIBS="$ac_cv_search_socket $LIBS"
5302
5303 fi
5304
5305 echo "$as_me:$LINENO: checking for library containing shl_load" >&5
5306 echo $ECHO_N "checking for library containing shl_load... $ECHO_C" >&6
5307 if test "${ac_cv_search_shl_load+set}" = set; then
5308   echo $ECHO_N "(cached) $ECHO_C" >&6
5309 else
5310   ac_func_search_save_LIBS=$LIBS
5311 ac_cv_search_shl_load=no
5312 cat >conftest.$ac_ext <<_ACEOF
5313 /* confdefs.h.  */
5314 _ACEOF
5315 cat confdefs.h >>conftest.$ac_ext
5316 cat >>conftest.$ac_ext <<_ACEOF
5317 /* end confdefs.h.  */
5318
5319 /* Override any gcc2 internal prototype to avoid an error.  */
5320 #ifdef __cplusplus
5321 extern "C"
5322 #endif
5323 /* We use char because int might match the return type of a gcc2
5324    builtin and then its argument prototype would still apply.  */
5325 char shl_load ();
5326 int
5327 main ()
5328 {
5329 shl_load ();
5330   ;
5331   return 0;
5332 }
5333 _ACEOF
5334 rm -f conftest.$ac_objext conftest$ac_exeext
5335 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5336   (eval $ac_link) 2>conftest.er1
5337   ac_status=$?
5338   grep -v '^ *+' conftest.er1 >conftest.err
5339   rm -f conftest.er1
5340   cat conftest.err >&5
5341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5342   (exit $ac_status); } &&
5343          { ac_try='test -z "$ac_c_werror_flag"
5344                          || test ! -s conftest.err'
5345   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5346   (eval $ac_try) 2>&5
5347   ac_status=$?
5348   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5349   (exit $ac_status); }; } &&
5350          { ac_try='test -s conftest$ac_exeext'
5351   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5352   (eval $ac_try) 2>&5
5353   ac_status=$?
5354   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5355   (exit $ac_status); }; }; then
5356   ac_cv_search_shl_load="none required"
5357 else
5358   echo "$as_me: failed program was:" >&5
5359 sed 's/^/| /' conftest.$ac_ext >&5
5360
5361 fi
5362 rm -f conftest.err conftest.$ac_objext \
5363       conftest$ac_exeext conftest.$ac_ext
5364 if test "$ac_cv_search_shl_load" = no; then
5365   for ac_lib in dld; do
5366     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5367     cat >conftest.$ac_ext <<_ACEOF
5368 /* confdefs.h.  */
5369 _ACEOF
5370 cat confdefs.h >>conftest.$ac_ext
5371 cat >>conftest.$ac_ext <<_ACEOF
5372 /* end confdefs.h.  */
5373
5374 /* Override any gcc2 internal prototype to avoid an error.  */
5375 #ifdef __cplusplus
5376 extern "C"
5377 #endif
5378 /* We use char because int might match the return type of a gcc2
5379    builtin and then its argument prototype would still apply.  */
5380 char shl_load ();
5381 int
5382 main ()
5383 {
5384 shl_load ();
5385   ;
5386   return 0;
5387 }
5388 _ACEOF
5389 rm -f conftest.$ac_objext conftest$ac_exeext
5390 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5391   (eval $ac_link) 2>conftest.er1
5392   ac_status=$?
5393   grep -v '^ *+' conftest.er1 >conftest.err
5394   rm -f conftest.er1
5395   cat conftest.err >&5
5396   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5397   (exit $ac_status); } &&
5398          { ac_try='test -z "$ac_c_werror_flag"
5399                          || test ! -s conftest.err'
5400   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5401   (eval $ac_try) 2>&5
5402   ac_status=$?
5403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5404   (exit $ac_status); }; } &&
5405          { ac_try='test -s conftest$ac_exeext'
5406   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5407   (eval $ac_try) 2>&5
5408   ac_status=$?
5409   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5410   (exit $ac_status); }; }; then
5411   ac_cv_search_shl_load="-l$ac_lib"
5412 break
5413 else
5414   echo "$as_me: failed program was:" >&5
5415 sed 's/^/| /' conftest.$ac_ext >&5
5416
5417 fi
5418 rm -f conftest.err conftest.$ac_objext \
5419       conftest$ac_exeext conftest.$ac_ext
5420   done
5421 fi
5422 LIBS=$ac_func_search_save_LIBS
5423 fi
5424 echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
5425 echo "${ECHO_T}$ac_cv_search_shl_load" >&6
5426 if test "$ac_cv_search_shl_load" != no; then
5427   test "$ac_cv_search_shl_load" = "none required" || LIBS="$ac_cv_search_shl_load $LIBS"
5428
5429 fi
5430
5431 # We only use libld in port/dynloader/aix.c
5432 case $host_os in
5433      aix*)
5434         echo "$as_me:$LINENO: checking for library containing ldopen" >&5
5435 echo $ECHO_N "checking for library containing ldopen... $ECHO_C" >&6
5436 if test "${ac_cv_search_ldopen+set}" = set; then
5437   echo $ECHO_N "(cached) $ECHO_C" >&6
5438 else
5439   ac_func_search_save_LIBS=$LIBS
5440 ac_cv_search_ldopen=no
5441 cat >conftest.$ac_ext <<_ACEOF
5442 /* confdefs.h.  */
5443 _ACEOF
5444 cat confdefs.h >>conftest.$ac_ext
5445 cat >>conftest.$ac_ext <<_ACEOF
5446 /* end confdefs.h.  */
5447
5448 /* Override any gcc2 internal prototype to avoid an error.  */
5449 #ifdef __cplusplus
5450 extern "C"
5451 #endif
5452 /* We use char because int might match the return type of a gcc2
5453    builtin and then its argument prototype would still apply.  */
5454 char ldopen ();
5455 int
5456 main ()
5457 {
5458 ldopen ();
5459   ;
5460   return 0;
5461 }
5462 _ACEOF
5463 rm -f conftest.$ac_objext conftest$ac_exeext
5464 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5465   (eval $ac_link) 2>conftest.er1
5466   ac_status=$?
5467   grep -v '^ *+' conftest.er1 >conftest.err
5468   rm -f conftest.er1
5469   cat conftest.err >&5
5470   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5471   (exit $ac_status); } &&
5472          { ac_try='test -z "$ac_c_werror_flag"
5473                          || test ! -s conftest.err'
5474   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5475   (eval $ac_try) 2>&5
5476   ac_status=$?
5477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5478   (exit $ac_status); }; } &&
5479          { ac_try='test -s conftest$ac_exeext'
5480   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5481   (eval $ac_try) 2>&5
5482   ac_status=$?
5483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5484   (exit $ac_status); }; }; then
5485   ac_cv_search_ldopen="none required"
5486 else
5487   echo "$as_me: failed program was:" >&5
5488 sed 's/^/| /' conftest.$ac_ext >&5
5489
5490 fi
5491 rm -f conftest.err conftest.$ac_objext \
5492       conftest$ac_exeext conftest.$ac_ext
5493 if test "$ac_cv_search_ldopen" = no; then
5494   for ac_lib in ld; do
5495     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5496     cat >conftest.$ac_ext <<_ACEOF
5497 /* confdefs.h.  */
5498 _ACEOF
5499 cat confdefs.h >>conftest.$ac_ext
5500 cat >>conftest.$ac_ext <<_ACEOF
5501 /* end confdefs.h.  */
5502
5503 /* Override any gcc2 internal prototype to avoid an error.  */
5504 #ifdef __cplusplus
5505 extern "C"
5506 #endif
5507 /* We use char because int might match the return type of a gcc2
5508    builtin and then its argument prototype would still apply.  */
5509 char ldopen ();
5510 int
5511 main ()
5512 {
5513 ldopen ();
5514   ;
5515   return 0;
5516 }
5517 _ACEOF
5518 rm -f conftest.$ac_objext conftest$ac_exeext
5519 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5520   (eval $ac_link) 2>conftest.er1
5521   ac_status=$?
5522   grep -v '^ *+' conftest.er1 >conftest.err
5523   rm -f conftest.er1
5524   cat conftest.err >&5
5525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5526   (exit $ac_status); } &&
5527          { ac_try='test -z "$ac_c_werror_flag"
5528                          || test ! -s conftest.err'
5529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5530   (eval $ac_try) 2>&5
5531   ac_status=$?
5532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5533   (exit $ac_status); }; } &&
5534          { ac_try='test -s conftest$ac_exeext'
5535   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5536   (eval $ac_try) 2>&5
5537   ac_status=$?
5538   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5539   (exit $ac_status); }; }; then
5540   ac_cv_search_ldopen="-l$ac_lib"
5541 break
5542 else
5543   echo "$as_me: failed program was:" >&5
5544 sed 's/^/| /' conftest.$ac_ext >&5
5545
5546 fi
5547 rm -f conftest.err conftest.$ac_objext \
5548       conftest$ac_exeext conftest.$ac_ext
5549   done
5550 fi
5551 LIBS=$ac_func_search_save_LIBS
5552 fi
5553 echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
5554 echo "${ECHO_T}$ac_cv_search_ldopen" >&6
5555 if test "$ac_cv_search_ldopen" != no; then
5556   test "$ac_cv_search_ldopen" = "none required" || LIBS="$ac_cv_search_ldopen $LIBS"
5557
5558 fi
5559
5560         ;;
5561 esac
5562 echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
5563 echo $ECHO_N "checking for library containing getopt_long... $ECHO_C" >&6
5564 if test "${ac_cv_search_getopt_long+set}" = set; then
5565   echo $ECHO_N "(cached) $ECHO_C" >&6
5566 else
5567   ac_func_search_save_LIBS=$LIBS
5568 ac_cv_search_getopt_long=no
5569 cat >conftest.$ac_ext <<_ACEOF
5570 /* confdefs.h.  */
5571 _ACEOF
5572 cat confdefs.h >>conftest.$ac_ext
5573 cat >>conftest.$ac_ext <<_ACEOF
5574 /* end confdefs.h.  */
5575
5576 /* Override any gcc2 internal prototype to avoid an error.  */
5577 #ifdef __cplusplus
5578 extern "C"
5579 #endif
5580 /* We use char because int might match the return type of a gcc2
5581    builtin and then its argument prototype would still apply.  */
5582 char getopt_long ();
5583 int
5584 main ()
5585 {
5586 getopt_long ();
5587   ;
5588   return 0;
5589 }
5590 _ACEOF
5591 rm -f conftest.$ac_objext conftest$ac_exeext
5592 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5593   (eval $ac_link) 2>conftest.er1
5594   ac_status=$?
5595   grep -v '^ *+' conftest.er1 >conftest.err
5596   rm -f conftest.er1
5597   cat conftest.err >&5
5598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5599   (exit $ac_status); } &&
5600          { ac_try='test -z "$ac_c_werror_flag"
5601                          || test ! -s conftest.err'
5602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5603   (eval $ac_try) 2>&5
5604   ac_status=$?
5605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5606   (exit $ac_status); }; } &&
5607          { ac_try='test -s conftest$ac_exeext'
5608   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5609   (eval $ac_try) 2>&5
5610   ac_status=$?
5611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5612   (exit $ac_status); }; }; then
5613   ac_cv_search_getopt_long="none required"
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 if test "$ac_cv_search_getopt_long" = no; then
5622   for ac_lib in getopt gnugetopt; do
5623     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5624     cat >conftest.$ac_ext <<_ACEOF
5625 /* confdefs.h.  */
5626 _ACEOF
5627 cat confdefs.h >>conftest.$ac_ext
5628 cat >>conftest.$ac_ext <<_ACEOF
5629 /* end confdefs.h.  */
5630
5631 /* Override any gcc2 internal prototype to avoid an error.  */
5632 #ifdef __cplusplus
5633 extern "C"
5634 #endif
5635 /* We use char because int might match the return type of a gcc2
5636    builtin and then its argument prototype would still apply.  */
5637 char getopt_long ();
5638 int
5639 main ()
5640 {
5641 getopt_long ();
5642   ;
5643   return 0;
5644 }
5645 _ACEOF
5646 rm -f conftest.$ac_objext conftest$ac_exeext
5647 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5648   (eval $ac_link) 2>conftest.er1
5649   ac_status=$?
5650   grep -v '^ *+' conftest.er1 >conftest.err
5651   rm -f conftest.er1
5652   cat conftest.err >&5
5653   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5654   (exit $ac_status); } &&
5655          { ac_try='test -z "$ac_c_werror_flag"
5656                          || test ! -s conftest.err'
5657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5658   (eval $ac_try) 2>&5
5659   ac_status=$?
5660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5661   (exit $ac_status); }; } &&
5662          { ac_try='test -s conftest$ac_exeext'
5663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5664   (eval $ac_try) 2>&5
5665   ac_status=$?
5666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5667   (exit $ac_status); }; }; then
5668   ac_cv_search_getopt_long="-l$ac_lib"
5669 break
5670 else
5671   echo "$as_me: failed program was:" >&5
5672 sed 's/^/| /' conftest.$ac_ext >&5
5673
5674 fi
5675 rm -f conftest.err conftest.$ac_objext \
5676       conftest$ac_exeext conftest.$ac_ext
5677   done
5678 fi
5679 LIBS=$ac_func_search_save_LIBS
5680 fi
5681 echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
5682 echo "${ECHO_T}$ac_cv_search_getopt_long" >&6
5683 if test "$ac_cv_search_getopt_long" != no; then
5684   test "$ac_cv_search_getopt_long" = "none required" || LIBS="$ac_cv_search_getopt_long $LIBS"
5685
5686 fi
5687
5688 echo "$as_me:$LINENO: checking for library containing crypt" >&5
5689 echo $ECHO_N "checking for library containing crypt... $ECHO_C" >&6
5690 if test "${ac_cv_search_crypt+set}" = set; then
5691   echo $ECHO_N "(cached) $ECHO_C" >&6
5692 else
5693   ac_func_search_save_LIBS=$LIBS
5694 ac_cv_search_crypt=no
5695 cat >conftest.$ac_ext <<_ACEOF
5696 /* confdefs.h.  */
5697 _ACEOF
5698 cat confdefs.h >>conftest.$ac_ext
5699 cat >>conftest.$ac_ext <<_ACEOF
5700 /* end confdefs.h.  */
5701
5702 /* Override any gcc2 internal prototype to avoid an error.  */
5703 #ifdef __cplusplus
5704 extern "C"
5705 #endif
5706 /* We use char because int might match the return type of a gcc2
5707    builtin and then its argument prototype would still apply.  */
5708 char crypt ();
5709 int
5710 main ()
5711 {
5712 crypt ();
5713   ;
5714   return 0;
5715 }
5716 _ACEOF
5717 rm -f conftest.$ac_objext conftest$ac_exeext
5718 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5719   (eval $ac_link) 2>conftest.er1
5720   ac_status=$?
5721   grep -v '^ *+' conftest.er1 >conftest.err
5722   rm -f conftest.er1
5723   cat conftest.err >&5
5724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5725   (exit $ac_status); } &&
5726          { ac_try='test -z "$ac_c_werror_flag"
5727                          || test ! -s conftest.err'
5728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5729   (eval $ac_try) 2>&5
5730   ac_status=$?
5731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5732   (exit $ac_status); }; } &&
5733          { ac_try='test -s conftest$ac_exeext'
5734   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5735   (eval $ac_try) 2>&5
5736   ac_status=$?
5737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5738   (exit $ac_status); }; }; then
5739   ac_cv_search_crypt="none required"
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 if test "$ac_cv_search_crypt" = no; then
5748   for ac_lib in crypt; do
5749     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5750     cat >conftest.$ac_ext <<_ACEOF
5751 /* confdefs.h.  */
5752 _ACEOF
5753 cat confdefs.h >>conftest.$ac_ext
5754 cat >>conftest.$ac_ext <<_ACEOF
5755 /* end confdefs.h.  */
5756
5757 /* Override any gcc2 internal prototype to avoid an error.  */
5758 #ifdef __cplusplus
5759 extern "C"
5760 #endif
5761 /* We use char because int might match the return type of a gcc2
5762    builtin and then its argument prototype would still apply.  */
5763 char crypt ();
5764 int
5765 main ()
5766 {
5767 crypt ();
5768   ;
5769   return 0;
5770 }
5771 _ACEOF
5772 rm -f conftest.$ac_objext conftest$ac_exeext
5773 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5774   (eval $ac_link) 2>conftest.er1
5775   ac_status=$?
5776   grep -v '^ *+' conftest.er1 >conftest.err
5777   rm -f conftest.er1
5778   cat conftest.err >&5
5779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5780   (exit $ac_status); } &&
5781          { ac_try='test -z "$ac_c_werror_flag"
5782                          || test ! -s conftest.err'
5783   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5784   (eval $ac_try) 2>&5
5785   ac_status=$?
5786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5787   (exit $ac_status); }; } &&
5788          { ac_try='test -s conftest$ac_exeext'
5789   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5790   (eval $ac_try) 2>&5
5791   ac_status=$?
5792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5793   (exit $ac_status); }; }; then
5794   ac_cv_search_crypt="-l$ac_lib"
5795 break
5796 else
5797   echo "$as_me: failed program was:" >&5
5798 sed 's/^/| /' conftest.$ac_ext >&5
5799
5800 fi
5801 rm -f conftest.err conftest.$ac_objext \
5802       conftest$ac_exeext conftest.$ac_ext
5803   done
5804 fi
5805 LIBS=$ac_func_search_save_LIBS
5806 fi
5807 echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
5808 echo "${ECHO_T}$ac_cv_search_crypt" >&6
5809 if test "$ac_cv_search_crypt" != no; then
5810   test "$ac_cv_search_crypt" = "none required" || LIBS="$ac_cv_search_crypt $LIBS"
5811
5812 fi
5813
5814 # Solaris:
5815 echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
5816 echo $ECHO_N "checking for library containing fdatasync... $ECHO_C" >&6
5817 if test "${ac_cv_search_fdatasync+set}" = set; then
5818   echo $ECHO_N "(cached) $ECHO_C" >&6
5819 else
5820   ac_func_search_save_LIBS=$LIBS
5821 ac_cv_search_fdatasync=no
5822 cat >conftest.$ac_ext <<_ACEOF
5823 /* confdefs.h.  */
5824 _ACEOF
5825 cat confdefs.h >>conftest.$ac_ext
5826 cat >>conftest.$ac_ext <<_ACEOF
5827 /* end confdefs.h.  */
5828
5829 /* Override any gcc2 internal prototype to avoid an error.  */
5830 #ifdef __cplusplus
5831 extern "C"
5832 #endif
5833 /* We use char because int might match the return type of a gcc2
5834    builtin and then its argument prototype would still apply.  */
5835 char fdatasync ();
5836 int
5837 main ()
5838 {
5839 fdatasync ();
5840   ;
5841   return 0;
5842 }
5843 _ACEOF
5844 rm -f conftest.$ac_objext conftest$ac_exeext
5845 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5846   (eval $ac_link) 2>conftest.er1
5847   ac_status=$?
5848   grep -v '^ *+' conftest.er1 >conftest.err
5849   rm -f conftest.er1
5850   cat conftest.err >&5
5851   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5852   (exit $ac_status); } &&
5853          { ac_try='test -z "$ac_c_werror_flag"
5854                          || test ! -s conftest.err'
5855   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5856   (eval $ac_try) 2>&5
5857   ac_status=$?
5858   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5859   (exit $ac_status); }; } &&
5860          { ac_try='test -s conftest$ac_exeext'
5861   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5862   (eval $ac_try) 2>&5
5863   ac_status=$?
5864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5865   (exit $ac_status); }; }; then
5866   ac_cv_search_fdatasync="none required"
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 if test "$ac_cv_search_fdatasync" = no; then
5875   for ac_lib in rt posix4; do
5876     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5877     cat >conftest.$ac_ext <<_ACEOF
5878 /* confdefs.h.  */
5879 _ACEOF
5880 cat confdefs.h >>conftest.$ac_ext
5881 cat >>conftest.$ac_ext <<_ACEOF
5882 /* end confdefs.h.  */
5883
5884 /* Override any gcc2 internal prototype to avoid an error.  */
5885 #ifdef __cplusplus
5886 extern "C"
5887 #endif
5888 /* We use char because int might match the return type of a gcc2
5889    builtin and then its argument prototype would still apply.  */
5890 char fdatasync ();
5891 int
5892 main ()
5893 {
5894 fdatasync ();
5895   ;
5896   return 0;
5897 }
5898 _ACEOF
5899 rm -f conftest.$ac_objext conftest$ac_exeext
5900 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5901   (eval $ac_link) 2>conftest.er1
5902   ac_status=$?
5903   grep -v '^ *+' conftest.er1 >conftest.err
5904   rm -f conftest.er1
5905   cat conftest.err >&5
5906   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5907   (exit $ac_status); } &&
5908          { ac_try='test -z "$ac_c_werror_flag"
5909                          || test ! -s conftest.err'
5910   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5911   (eval $ac_try) 2>&5
5912   ac_status=$?
5913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5914   (exit $ac_status); }; } &&
5915          { ac_try='test -s conftest$ac_exeext'
5916   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5917   (eval $ac_try) 2>&5
5918   ac_status=$?
5919   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5920   (exit $ac_status); }; }; then
5921   ac_cv_search_fdatasync="-l$ac_lib"
5922 break
5923 else
5924   echo "$as_me: failed program was:" >&5
5925 sed 's/^/| /' conftest.$ac_ext >&5
5926
5927 fi
5928 rm -f conftest.err conftest.$ac_objext \
5929       conftest$ac_exeext conftest.$ac_ext
5930   done
5931 fi
5932 LIBS=$ac_func_search_save_LIBS
5933 fi
5934 echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
5935 echo "${ECHO_T}$ac_cv_search_fdatasync" >&6
5936 if test "$ac_cv_search_fdatasync" != no; then
5937   test "$ac_cv_search_fdatasync" = "none required" || LIBS="$ac_cv_search_fdatasync $LIBS"
5938
5939 fi
5940
5941 # Cygwin:
5942 echo "$as_me:$LINENO: checking for library containing shmget" >&5
5943 echo $ECHO_N "checking for library containing shmget... $ECHO_C" >&6
5944 if test "${ac_cv_search_shmget+set}" = set; then
5945   echo $ECHO_N "(cached) $ECHO_C" >&6
5946 else
5947   ac_func_search_save_LIBS=$LIBS
5948 ac_cv_search_shmget=no
5949 cat >conftest.$ac_ext <<_ACEOF
5950 /* confdefs.h.  */
5951 _ACEOF
5952 cat confdefs.h >>conftest.$ac_ext
5953 cat >>conftest.$ac_ext <<_ACEOF
5954 /* end confdefs.h.  */
5955
5956 /* Override any gcc2 internal prototype to avoid an error.  */
5957 #ifdef __cplusplus
5958 extern "C"
5959 #endif
5960 /* We use char because int might match the return type of a gcc2
5961    builtin and then its argument prototype would still apply.  */
5962 char shmget ();
5963 int
5964 main ()
5965 {
5966 shmget ();
5967   ;
5968   return 0;
5969 }
5970 _ACEOF
5971 rm -f conftest.$ac_objext conftest$ac_exeext
5972 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5973   (eval $ac_link) 2>conftest.er1
5974   ac_status=$?
5975   grep -v '^ *+' conftest.er1 >conftest.err
5976   rm -f conftest.er1
5977   cat conftest.err >&5
5978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5979   (exit $ac_status); } &&
5980          { ac_try='test -z "$ac_c_werror_flag"
5981                          || test ! -s conftest.err'
5982   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5983   (eval $ac_try) 2>&5
5984   ac_status=$?
5985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5986   (exit $ac_status); }; } &&
5987          { ac_try='test -s conftest$ac_exeext'
5988   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5989   (eval $ac_try) 2>&5
5990   ac_status=$?
5991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5992   (exit $ac_status); }; }; then
5993   ac_cv_search_shmget="none required"
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 if test "$ac_cv_search_shmget" = no; then
6002   for ac_lib in cygipc; do
6003     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6004     cat >conftest.$ac_ext <<_ACEOF
6005 /* confdefs.h.  */
6006 _ACEOF
6007 cat confdefs.h >>conftest.$ac_ext
6008 cat >>conftest.$ac_ext <<_ACEOF
6009 /* end confdefs.h.  */
6010
6011 /* Override any gcc2 internal prototype to avoid an error.  */
6012 #ifdef __cplusplus
6013 extern "C"
6014 #endif
6015 /* We use char because int might match the return type of a gcc2
6016    builtin and then its argument prototype would still apply.  */
6017 char shmget ();
6018 int
6019 main ()
6020 {
6021 shmget ();
6022   ;
6023   return 0;
6024 }
6025 _ACEOF
6026 rm -f conftest.$ac_objext conftest$ac_exeext
6027 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6028   (eval $ac_link) 2>conftest.er1
6029   ac_status=$?
6030   grep -v '^ *+' conftest.er1 >conftest.err
6031   rm -f conftest.er1
6032   cat conftest.err >&5
6033   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6034   (exit $ac_status); } &&
6035          { ac_try='test -z "$ac_c_werror_flag"
6036                          || test ! -s conftest.err'
6037   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6038   (eval $ac_try) 2>&5
6039   ac_status=$?
6040   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6041   (exit $ac_status); }; } &&
6042          { ac_try='test -s conftest$ac_exeext'
6043   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6044   (eval $ac_try) 2>&5
6045   ac_status=$?
6046   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6047   (exit $ac_status); }; }; then
6048   ac_cv_search_shmget="-l$ac_lib"
6049 break
6050 else
6051   echo "$as_me: failed program was:" >&5
6052 sed 's/^/| /' conftest.$ac_ext >&5
6053
6054 fi
6055 rm -f conftest.err conftest.$ac_objext \
6056       conftest$ac_exeext conftest.$ac_ext
6057   done
6058 fi
6059 LIBS=$ac_func_search_save_LIBS
6060 fi
6061 echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
6062 echo "${ECHO_T}$ac_cv_search_shmget" >&6
6063 if test "$ac_cv_search_shmget" != no; then
6064   test "$ac_cv_search_shmget" = "none required" || LIBS="$ac_cv_search_shmget $LIBS"
6065
6066 fi
6067
6068
6069 if test "$with_readline" = yes; then
6070
6071
6072 if test "${pgac_cv_check_readline+set}" = set; then
6073   echo $ECHO_N "(cached) $ECHO_C" >&6
6074 else
6075   pgac_cv_check_readline=no
6076 pgac_save_LIBS=$LIBS
6077 if test x"$with_libedit_preferred" != x"yes"
6078 then    READLINE_ORDER="-lreadline -ledit"
6079 else    READLINE_ORDER="-ledit -lreadline"
6080 fi
6081 for pgac_rllib in $READLINE_ORDER ; do
6082   echo "$as_me:$LINENO: checking for ${pgac_rllib}" >&5
6083 echo $ECHO_N "checking for ${pgac_rllib}... $ECHO_C" >&6
6084   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
6085     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
6086     cat >conftest.$ac_ext <<_ACEOF
6087 /* confdefs.h.  */
6088 _ACEOF
6089 cat confdefs.h >>conftest.$ac_ext
6090 cat >>conftest.$ac_ext <<_ACEOF
6091 /* end confdefs.h.  */
6092
6093 /* Override any gcc2 internal prototype to avoid an error.  */
6094 #ifdef __cplusplus
6095 extern "C"
6096 #endif
6097 /* We use char because int might match the return type of a gcc2
6098    builtin and then its argument prototype would still apply.  */
6099 char readline ();
6100 int
6101 main ()
6102 {
6103 readline ();
6104   ;
6105   return 0;
6106 }
6107 _ACEOF
6108 rm -f conftest.$ac_objext conftest$ac_exeext
6109 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6110   (eval $ac_link) 2>conftest.er1
6111   ac_status=$?
6112   grep -v '^ *+' conftest.er1 >conftest.err
6113   rm -f conftest.er1
6114   cat conftest.err >&5
6115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6116   (exit $ac_status); } &&
6117          { ac_try='test -z "$ac_c_werror_flag"
6118                          || test ! -s conftest.err'
6119   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6120   (eval $ac_try) 2>&5
6121   ac_status=$?
6122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6123   (exit $ac_status); }; } &&
6124          { ac_try='test -s conftest$ac_exeext'
6125   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6126   (eval $ac_try) 2>&5
6127   ac_status=$?
6128   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6129   (exit $ac_status); }; }; then
6130
6131       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
6132       # recognize dependent libraries; assume curses is needed if we didn't
6133       # find any dependency.
6134       case $host_os in
6135         netbsd* | openbsd* | irix*)
6136           if test x"$pgac_lib" = x"" ; then
6137             pgac_lib=" -lcurses"
6138           fi ;;
6139       esac
6140
6141       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
6142       break
6143
6144 else
6145   echo "$as_me: failed program was:" >&5
6146 sed 's/^/| /' conftest.$ac_ext >&5
6147
6148 fi
6149 rm -f conftest.err conftest.$ac_objext \
6150       conftest$ac_exeext conftest.$ac_ext
6151   done
6152   if test "$pgac_cv_check_readline" != no ; then
6153     echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
6154 echo "${ECHO_T}yes ($pgac_cv_check_readline)" >&6
6155     break
6156   else
6157     echo "$as_me:$LINENO: result: no" >&5
6158 echo "${ECHO_T}no" >&6
6159   fi
6160 done
6161 LIBS=$pgac_save_LIBS
6162
6163 fi
6164
6165 if test "$pgac_cv_check_readline" != no ; then
6166   LIBS="$pgac_cv_check_readline $LIBS"
6167
6168 cat >>confdefs.h <<\_ACEOF
6169 #define HAVE_LIBREADLINE 1
6170 _ACEOF
6171
6172 fi
6173
6174
6175   if test x"$pgac_cv_check_readline" = x"no"; then
6176     { { echo "$as_me:$LINENO: error: readline library not found
6177 If you have readline already installed, see config.log for details on the
6178 failure.  It is possible the compiler isn't looking in the proper directory.
6179 Use --without-readline to disable readline support." >&5
6180 echo "$as_me: error: readline library not found
6181 If you have readline already installed, see config.log for details on the
6182 failure.  It is possible the compiler isn't looking in the proper directory.
6183 Use --without-readline to disable readline support." >&2;}
6184    { (exit 1); exit 1; }; }
6185   fi
6186 fi
6187
6188 if test "$with_zlib" = yes; then
6189
6190 echo "$as_me:$LINENO: checking for inflate in -lz" >&5
6191 echo $ECHO_N "checking for inflate in -lz... $ECHO_C" >&6
6192 if test "${ac_cv_lib_z_inflate+set}" = set; then
6193   echo $ECHO_N "(cached) $ECHO_C" >&6
6194 else
6195   ac_check_lib_save_LIBS=$LIBS
6196 LIBS="-lz  $LIBS"
6197 cat >conftest.$ac_ext <<_ACEOF
6198 /* confdefs.h.  */
6199 _ACEOF
6200 cat confdefs.h >>conftest.$ac_ext
6201 cat >>conftest.$ac_ext <<_ACEOF
6202 /* end confdefs.h.  */
6203
6204 /* Override any gcc2 internal prototype to avoid an error.  */
6205 #ifdef __cplusplus
6206 extern "C"
6207 #endif
6208 /* We use char because int might match the return type of a gcc2
6209    builtin and then its argument prototype would still apply.  */
6210 char inflate ();
6211 int
6212 main ()
6213 {
6214 inflate ();
6215   ;
6216   return 0;
6217 }
6218 _ACEOF
6219 rm -f conftest.$ac_objext conftest$ac_exeext
6220 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6221   (eval $ac_link) 2>conftest.er1
6222   ac_status=$?
6223   grep -v '^ *+' conftest.er1 >conftest.err
6224   rm -f conftest.er1
6225   cat conftest.err >&5
6226   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6227   (exit $ac_status); } &&
6228          { ac_try='test -z "$ac_c_werror_flag"
6229                          || test ! -s conftest.err'
6230   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6231   (eval $ac_try) 2>&5
6232   ac_status=$?
6233   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6234   (exit $ac_status); }; } &&
6235          { ac_try='test -s conftest$ac_exeext'
6236   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6237   (eval $ac_try) 2>&5
6238   ac_status=$?
6239   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6240   (exit $ac_status); }; }; then
6241   ac_cv_lib_z_inflate=yes
6242 else
6243   echo "$as_me: failed program was:" >&5
6244 sed 's/^/| /' conftest.$ac_ext >&5
6245
6246 ac_cv_lib_z_inflate=no
6247 fi
6248 rm -f conftest.err conftest.$ac_objext \
6249       conftest$ac_exeext conftest.$ac_ext
6250 LIBS=$ac_check_lib_save_LIBS
6251 fi
6252 echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
6253 echo "${ECHO_T}$ac_cv_lib_z_inflate" >&6
6254 if test $ac_cv_lib_z_inflate = yes; then
6255   cat >>confdefs.h <<_ACEOF
6256 #define HAVE_LIBZ 1
6257 _ACEOF
6258
6259   LIBS="-lz $LIBS"
6260
6261 else
6262   { { echo "$as_me:$LINENO: error: zlib library not found
6263 If you have zlib already installed, see config.log for details on the
6264 failure.  It is possible the compiler isn't looking in the proper directory.
6265 Use --without-zlib to disable zlib support." >&5
6266 echo "$as_me: error: zlib library not found
6267 If you have zlib already installed, see config.log for details on the
6268 failure.  It is possible the compiler isn't looking in the proper directory.
6269 Use --without-zlib to disable zlib support." >&2;}
6270    { (exit 1); exit 1; }; }
6271 fi
6272
6273 fi
6274
6275 if test "$enable_spinlocks" = yes; then
6276
6277 cat >>confdefs.h <<\_ACEOF
6278 #define HAVE_SPINLOCKS 1
6279 _ACEOF
6280
6281 else
6282   { echo "$as_me:$LINENO: WARNING:
6283 *** Not using spinlocks will cause poor performance." >&5
6284 echo "$as_me: WARNING:
6285 *** Not using spinlocks will cause poor performance." >&2;}
6286 fi
6287
6288 if test "$with_krb5" = yes ; then
6289   if test "$PORTNAME" != "win32"; then
6290      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6291 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6292 if test "${ac_cv_search_com_err+set}" = set; then
6293   echo $ECHO_N "(cached) $ECHO_C" >&6
6294 else
6295   ac_func_search_save_LIBS=$LIBS
6296 ac_cv_search_com_err=no
6297 cat >conftest.$ac_ext <<_ACEOF
6298 /* confdefs.h.  */
6299 _ACEOF
6300 cat confdefs.h >>conftest.$ac_ext
6301 cat >>conftest.$ac_ext <<_ACEOF
6302 /* end confdefs.h.  */
6303
6304 /* Override any gcc2 internal prototype to avoid an error.  */
6305 #ifdef __cplusplus
6306 extern "C"
6307 #endif
6308 /* We use char because int might match the return type of a gcc2
6309    builtin and then its argument prototype would still apply.  */
6310 char com_err ();
6311 int
6312 main ()
6313 {
6314 com_err ();
6315   ;
6316   return 0;
6317 }
6318 _ACEOF
6319 rm -f conftest.$ac_objext conftest$ac_exeext
6320 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6321   (eval $ac_link) 2>conftest.er1
6322   ac_status=$?
6323   grep -v '^ *+' conftest.er1 >conftest.err
6324   rm -f conftest.er1
6325   cat conftest.err >&5
6326   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6327   (exit $ac_status); } &&
6328          { ac_try='test -z "$ac_c_werror_flag"
6329                          || test ! -s conftest.err'
6330   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6331   (eval $ac_try) 2>&5
6332   ac_status=$?
6333   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6334   (exit $ac_status); }; } &&
6335          { ac_try='test -s conftest$ac_exeext'
6336   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6337   (eval $ac_try) 2>&5
6338   ac_status=$?
6339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6340   (exit $ac_status); }; }; then
6341   ac_cv_search_com_err="none required"
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 if test "$ac_cv_search_com_err" = no; then
6350   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' com_err; do
6351     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6352     cat >conftest.$ac_ext <<_ACEOF
6353 /* confdefs.h.  */
6354 _ACEOF
6355 cat confdefs.h >>conftest.$ac_ext
6356 cat >>conftest.$ac_ext <<_ACEOF
6357 /* end confdefs.h.  */
6358
6359 /* Override any gcc2 internal prototype to avoid an error.  */
6360 #ifdef __cplusplus
6361 extern "C"
6362 #endif
6363 /* We use char because int might match the return type of a gcc2
6364    builtin and then its argument prototype would still apply.  */
6365 char com_err ();
6366 int
6367 main ()
6368 {
6369 com_err ();
6370   ;
6371   return 0;
6372 }
6373 _ACEOF
6374 rm -f conftest.$ac_objext conftest$ac_exeext
6375 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6376   (eval $ac_link) 2>conftest.er1
6377   ac_status=$?
6378   grep -v '^ *+' conftest.er1 >conftest.err
6379   rm -f conftest.er1
6380   cat conftest.err >&5
6381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6382   (exit $ac_status); } &&
6383          { ac_try='test -z "$ac_c_werror_flag"
6384                          || test ! -s conftest.err'
6385   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6386   (eval $ac_try) 2>&5
6387   ac_status=$?
6388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6389   (exit $ac_status); }; } &&
6390          { ac_try='test -s conftest$ac_exeext'
6391   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6392   (eval $ac_try) 2>&5
6393   ac_status=$?
6394   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6395   (exit $ac_status); }; }; then
6396   ac_cv_search_com_err="-l$ac_lib"
6397 break
6398 else
6399   echo "$as_me: failed program was:" >&5
6400 sed 's/^/| /' conftest.$ac_ext >&5
6401
6402 fi
6403 rm -f conftest.err conftest.$ac_objext \
6404       conftest$ac_exeext conftest.$ac_ext
6405   done
6406 fi
6407 LIBS=$ac_func_search_save_LIBS
6408 fi
6409 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6410 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6411 if test "$ac_cv_search_com_err" != no; then
6412   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6413
6414 else
6415   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6416 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6417    { (exit 1); exit 1; }; }
6418 fi
6419
6420      echo "$as_me:$LINENO: checking for library containing krb5_encrypt" >&5
6421 echo $ECHO_N "checking for library containing krb5_encrypt... $ECHO_C" >&6
6422 if test "${ac_cv_search_krb5_encrypt+set}" = set; then
6423   echo $ECHO_N "(cached) $ECHO_C" >&6
6424 else
6425   ac_func_search_save_LIBS=$LIBS
6426 ac_cv_search_krb5_encrypt=no
6427 cat >conftest.$ac_ext <<_ACEOF
6428 /* confdefs.h.  */
6429 _ACEOF
6430 cat confdefs.h >>conftest.$ac_ext
6431 cat >>conftest.$ac_ext <<_ACEOF
6432 /* end confdefs.h.  */
6433
6434 /* Override any gcc2 internal prototype to avoid an error.  */
6435 #ifdef __cplusplus
6436 extern "C"
6437 #endif
6438 /* We use char because int might match the return type of a gcc2
6439    builtin and then its argument prototype would still apply.  */
6440 char krb5_encrypt ();
6441 int
6442 main ()
6443 {
6444 krb5_encrypt ();
6445   ;
6446   return 0;
6447 }
6448 _ACEOF
6449 rm -f conftest.$ac_objext conftest$ac_exeext
6450 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6451   (eval $ac_link) 2>conftest.er1
6452   ac_status=$?
6453   grep -v '^ *+' conftest.er1 >conftest.err
6454   rm -f conftest.er1
6455   cat conftest.err >&5
6456   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6457   (exit $ac_status); } &&
6458          { ac_try='test -z "$ac_c_werror_flag"
6459                          || test ! -s conftest.err'
6460   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6461   (eval $ac_try) 2>&5
6462   ac_status=$?
6463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6464   (exit $ac_status); }; } &&
6465          { ac_try='test -s conftest$ac_exeext'
6466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6467   (eval $ac_try) 2>&5
6468   ac_status=$?
6469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6470   (exit $ac_status); }; }; then
6471   ac_cv_search_krb5_encrypt="none required"
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 if test "$ac_cv_search_krb5_encrypt" = no; then
6480   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' crypto k5crypto; do
6481     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6482     cat >conftest.$ac_ext <<_ACEOF
6483 /* confdefs.h.  */
6484 _ACEOF
6485 cat confdefs.h >>conftest.$ac_ext
6486 cat >>conftest.$ac_ext <<_ACEOF
6487 /* end confdefs.h.  */
6488
6489 /* Override any gcc2 internal prototype to avoid an error.  */
6490 #ifdef __cplusplus
6491 extern "C"
6492 #endif
6493 /* We use char because int might match the return type of a gcc2
6494    builtin and then its argument prototype would still apply.  */
6495 char krb5_encrypt ();
6496 int
6497 main ()
6498 {
6499 krb5_encrypt ();
6500   ;
6501   return 0;
6502 }
6503 _ACEOF
6504 rm -f conftest.$ac_objext conftest$ac_exeext
6505 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6506   (eval $ac_link) 2>conftest.er1
6507   ac_status=$?
6508   grep -v '^ *+' conftest.er1 >conftest.err
6509   rm -f conftest.er1
6510   cat conftest.err >&5
6511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6512   (exit $ac_status); } &&
6513          { ac_try='test -z "$ac_c_werror_flag"
6514                          || test ! -s conftest.err'
6515   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6516   (eval $ac_try) 2>&5
6517   ac_status=$?
6518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6519   (exit $ac_status); }; } &&
6520          { ac_try='test -s conftest$ac_exeext'
6521   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6522   (eval $ac_try) 2>&5
6523   ac_status=$?
6524   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6525   (exit $ac_status); }; }; then
6526   ac_cv_search_krb5_encrypt="-l$ac_lib"
6527 break
6528 else
6529   echo "$as_me: failed program was:" >&5
6530 sed 's/^/| /' conftest.$ac_ext >&5
6531
6532 fi
6533 rm -f conftest.err conftest.$ac_objext \
6534       conftest$ac_exeext conftest.$ac_ext
6535   done
6536 fi
6537 LIBS=$ac_func_search_save_LIBS
6538 fi
6539 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_encrypt" >&5
6540 echo "${ECHO_T}$ac_cv_search_krb5_encrypt" >&6
6541 if test "$ac_cv_search_krb5_encrypt" != no; then
6542   test "$ac_cv_search_krb5_encrypt" = "none required" || LIBS="$ac_cv_search_krb5_encrypt $LIBS"
6543
6544 else
6545   { { echo "$as_me:$LINENO: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&5
6546 echo "$as_me: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&2;}
6547    { (exit 1); exit 1; }; }
6548 fi
6549
6550      echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
6551 echo $ECHO_N "checking for library containing krb5_sendauth... $ECHO_C" >&6
6552 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
6553   echo $ECHO_N "(cached) $ECHO_C" >&6
6554 else
6555   ac_func_search_save_LIBS=$LIBS
6556 ac_cv_search_krb5_sendauth=no
6557 cat >conftest.$ac_ext <<_ACEOF
6558 /* confdefs.h.  */
6559 _ACEOF
6560 cat confdefs.h >>conftest.$ac_ext
6561 cat >>conftest.$ac_ext <<_ACEOF
6562 /* end confdefs.h.  */
6563
6564 /* Override any gcc2 internal prototype to avoid an error.  */
6565 #ifdef __cplusplus
6566 extern "C"
6567 #endif
6568 /* We use char because int might match the return type of a gcc2
6569    builtin and then its argument prototype would still apply.  */
6570 char krb5_sendauth ();
6571 int
6572 main ()
6573 {
6574 krb5_sendauth ();
6575   ;
6576   return 0;
6577 }
6578 _ACEOF
6579 rm -f conftest.$ac_objext conftest$ac_exeext
6580 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6581   (eval $ac_link) 2>conftest.er1
6582   ac_status=$?
6583   grep -v '^ *+' conftest.er1 >conftest.err
6584   rm -f conftest.er1
6585   cat conftest.err >&5
6586   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6587   (exit $ac_status); } &&
6588          { ac_try='test -z "$ac_c_werror_flag"
6589                          || test ! -s conftest.err'
6590   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6591   (eval $ac_try) 2>&5
6592   ac_status=$?
6593   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6594   (exit $ac_status); }; } &&
6595          { ac_try='test -s conftest$ac_exeext'
6596   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6597   (eval $ac_try) 2>&5
6598   ac_status=$?
6599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6600   (exit $ac_status); }; }; then
6601   ac_cv_search_krb5_sendauth="none required"
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 if test "$ac_cv_search_krb5_sendauth" = no; then
6610   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken'; do
6611     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6612     cat >conftest.$ac_ext <<_ACEOF
6613 /* confdefs.h.  */
6614 _ACEOF
6615 cat confdefs.h >>conftest.$ac_ext
6616 cat >>conftest.$ac_ext <<_ACEOF
6617 /* end confdefs.h.  */
6618
6619 /* Override any gcc2 internal prototype to avoid an error.  */
6620 #ifdef __cplusplus
6621 extern "C"
6622 #endif
6623 /* We use char because int might match the return type of a gcc2
6624    builtin and then its argument prototype would still apply.  */
6625 char krb5_sendauth ();
6626 int
6627 main ()
6628 {
6629 krb5_sendauth ();
6630   ;
6631   return 0;
6632 }
6633 _ACEOF
6634 rm -f conftest.$ac_objext conftest$ac_exeext
6635 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6636   (eval $ac_link) 2>conftest.er1
6637   ac_status=$?
6638   grep -v '^ *+' conftest.er1 >conftest.err
6639   rm -f conftest.er1
6640   cat conftest.err >&5
6641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6642   (exit $ac_status); } &&
6643          { ac_try='test -z "$ac_c_werror_flag"
6644                          || test ! -s conftest.err'
6645   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6646   (eval $ac_try) 2>&5
6647   ac_status=$?
6648   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6649   (exit $ac_status); }; } &&
6650          { ac_try='test -s conftest$ac_exeext'
6651   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6652   (eval $ac_try) 2>&5
6653   ac_status=$?
6654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6655   (exit $ac_status); }; }; then
6656   ac_cv_search_krb5_sendauth="-l$ac_lib"
6657 break
6658 else
6659   echo "$as_me: failed program was:" >&5
6660 sed 's/^/| /' conftest.$ac_ext >&5
6661
6662 fi
6663 rm -f conftest.err conftest.$ac_objext \
6664       conftest$ac_exeext conftest.$ac_ext
6665   done
6666 fi
6667 LIBS=$ac_func_search_save_LIBS
6668 fi
6669 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
6670 echo "${ECHO_T}$ac_cv_search_krb5_sendauth" >&6
6671 if test "$ac_cv_search_krb5_sendauth" != no; then
6672   test "$ac_cv_search_krb5_sendauth" = "none required" || LIBS="$ac_cv_search_krb5_sendauth $LIBS"
6673
6674 else
6675   { { echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
6676 echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
6677    { (exit 1); exit 1; }; }
6678 fi
6679
6680   else
6681      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6682 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6683 if test "${ac_cv_search_com_err+set}" = set; then
6684   echo $ECHO_N "(cached) $ECHO_C" >&6
6685 else
6686   ac_func_search_save_LIBS=$LIBS
6687 ac_cv_search_com_err=no
6688 cat >conftest.$ac_ext <<_ACEOF
6689 /* confdefs.h.  */
6690 _ACEOF
6691 cat confdefs.h >>conftest.$ac_ext
6692 cat >>conftest.$ac_ext <<_ACEOF
6693 /* end confdefs.h.  */
6694
6695 /* Override any gcc2 internal prototype to avoid an error.  */
6696 #ifdef __cplusplus
6697 extern "C"
6698 #endif
6699 /* We use char because int might match the return type of a gcc2
6700    builtin and then its argument prototype would still apply.  */
6701 char com_err ();
6702 int
6703 main ()
6704 {
6705 com_err ();
6706   ;
6707   return 0;
6708 }
6709 _ACEOF
6710 rm -f conftest.$ac_objext conftest$ac_exeext
6711 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6712   (eval $ac_link) 2>conftest.er1
6713   ac_status=$?
6714   grep -v '^ *+' conftest.er1 >conftest.err
6715   rm -f conftest.er1
6716   cat conftest.err >&5
6717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6718   (exit $ac_status); } &&
6719          { ac_try='test -z "$ac_c_werror_flag"
6720                          || test ! -s conftest.err'
6721   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6722   (eval $ac_try) 2>&5
6723   ac_status=$?
6724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6725   (exit $ac_status); }; } &&
6726          { ac_try='test -s conftest$ac_exeext'
6727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6728   (eval $ac_try) 2>&5
6729   ac_status=$?
6730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6731   (exit $ac_status); }; }; then
6732   ac_cv_search_com_err="none required"
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 if test "$ac_cv_search_com_err" = no; then
6741   for ac_lib in 'comerr32 -lkrb5_32'; do
6742     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6743     cat >conftest.$ac_ext <<_ACEOF
6744 /* confdefs.h.  */
6745 _ACEOF
6746 cat confdefs.h >>conftest.$ac_ext
6747 cat >>conftest.$ac_ext <<_ACEOF
6748 /* end confdefs.h.  */
6749
6750 /* Override any gcc2 internal prototype to avoid an error.  */
6751 #ifdef __cplusplus
6752 extern "C"
6753 #endif
6754 /* We use char because int might match the return type of a gcc2
6755    builtin and then its argument prototype would still apply.  */
6756 char com_err ();
6757 int
6758 main ()
6759 {
6760 com_err ();
6761   ;
6762   return 0;
6763 }
6764 _ACEOF
6765 rm -f conftest.$ac_objext conftest$ac_exeext
6766 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6767   (eval $ac_link) 2>conftest.er1
6768   ac_status=$?
6769   grep -v '^ *+' conftest.er1 >conftest.err
6770   rm -f conftest.er1
6771   cat conftest.err >&5
6772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6773   (exit $ac_status); } &&
6774          { ac_try='test -z "$ac_c_werror_flag"
6775                          || test ! -s conftest.err'
6776   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6777   (eval $ac_try) 2>&5
6778   ac_status=$?
6779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6780   (exit $ac_status); }; } &&
6781          { ac_try='test -s conftest$ac_exeext'
6782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6783   (eval $ac_try) 2>&5
6784   ac_status=$?
6785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6786   (exit $ac_status); }; }; then
6787   ac_cv_search_com_err="-l$ac_lib"
6788 break
6789 else
6790   echo "$as_me: failed program was:" >&5
6791 sed 's/^/| /' conftest.$ac_ext >&5
6792
6793 fi
6794 rm -f conftest.err conftest.$ac_objext \
6795       conftest$ac_exeext conftest.$ac_ext
6796   done
6797 fi
6798 LIBS=$ac_func_search_save_LIBS
6799 fi
6800 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6801 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6802 if test "$ac_cv_search_com_err" != no; then
6803   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6804
6805 else
6806   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6807 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6808    { (exit 1); exit 1; }; }
6809 fi
6810
6811   fi
6812 fi
6813
6814 if test "$with_openssl" = yes ; then
6815     if test "$PORTNAME" != "win32"; then
6816
6817 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
6818 echo $ECHO_N "checking for CRYPTO_new_ex_data in -lcrypto... $ECHO_C" >&6
6819 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
6820   echo $ECHO_N "(cached) $ECHO_C" >&6
6821 else
6822   ac_check_lib_save_LIBS=$LIBS
6823 LIBS="-lcrypto  $LIBS"
6824 cat >conftest.$ac_ext <<_ACEOF
6825 /* confdefs.h.  */
6826 _ACEOF
6827 cat confdefs.h >>conftest.$ac_ext
6828 cat >>conftest.$ac_ext <<_ACEOF
6829 /* end confdefs.h.  */
6830
6831 /* Override any gcc2 internal prototype to avoid an error.  */
6832 #ifdef __cplusplus
6833 extern "C"
6834 #endif
6835 /* We use char because int might match the return type of a gcc2
6836    builtin and then its argument prototype would still apply.  */
6837 char CRYPTO_new_ex_data ();
6838 int
6839 main ()
6840 {
6841 CRYPTO_new_ex_data ();
6842   ;
6843   return 0;
6844 }
6845 _ACEOF
6846 rm -f conftest.$ac_objext conftest$ac_exeext
6847 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6848   (eval $ac_link) 2>conftest.er1
6849   ac_status=$?
6850   grep -v '^ *+' conftest.er1 >conftest.err
6851   rm -f conftest.er1
6852   cat conftest.err >&5
6853   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6854   (exit $ac_status); } &&
6855          { ac_try='test -z "$ac_c_werror_flag"
6856                          || test ! -s conftest.err'
6857   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6858   (eval $ac_try) 2>&5
6859   ac_status=$?
6860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6861   (exit $ac_status); }; } &&
6862          { ac_try='test -s conftest$ac_exeext'
6863   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6864   (eval $ac_try) 2>&5
6865   ac_status=$?
6866   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6867   (exit $ac_status); }; }; then
6868   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
6869 else
6870   echo "$as_me: failed program was:" >&5
6871 sed 's/^/| /' conftest.$ac_ext >&5
6872
6873 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
6874 fi
6875 rm -f conftest.err conftest.$ac_objext \
6876       conftest$ac_exeext conftest.$ac_ext
6877 LIBS=$ac_check_lib_save_LIBS
6878 fi
6879 echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
6880 echo "${ECHO_T}$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6
6881 if test $ac_cv_lib_crypto_CRYPTO_new_ex_data = yes; then
6882   cat >>confdefs.h <<_ACEOF
6883 #define HAVE_LIBCRYPTO 1
6884 _ACEOF
6885
6886   LIBS="-lcrypto $LIBS"
6887
6888 else
6889   { { echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
6890 echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
6891    { (exit 1); exit 1; }; }
6892 fi
6893
6894
6895 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
6896 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
6897 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
6898   echo $ECHO_N "(cached) $ECHO_C" >&6
6899 else
6900   ac_check_lib_save_LIBS=$LIBS
6901 LIBS="-lssl  $LIBS"
6902 cat >conftest.$ac_ext <<_ACEOF
6903 /* confdefs.h.  */
6904 _ACEOF
6905 cat confdefs.h >>conftest.$ac_ext
6906 cat >>conftest.$ac_ext <<_ACEOF
6907 /* end confdefs.h.  */
6908
6909 /* Override any gcc2 internal prototype to avoid an error.  */
6910 #ifdef __cplusplus
6911 extern "C"
6912 #endif
6913 /* We use char because int might match the return type of a gcc2
6914    builtin and then its argument prototype would still apply.  */
6915 char SSL_library_init ();
6916 int
6917 main ()
6918 {
6919 SSL_library_init ();
6920   ;
6921   return 0;
6922 }
6923 _ACEOF
6924 rm -f conftest.$ac_objext conftest$ac_exeext
6925 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6926   (eval $ac_link) 2>conftest.er1
6927   ac_status=$?
6928   grep -v '^ *+' conftest.er1 >conftest.err
6929   rm -f conftest.er1
6930   cat conftest.err >&5
6931   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6932   (exit $ac_status); } &&
6933          { ac_try='test -z "$ac_c_werror_flag"
6934                          || test ! -s conftest.err'
6935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6936   (eval $ac_try) 2>&5
6937   ac_status=$?
6938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6939   (exit $ac_status); }; } &&
6940          { ac_try='test -s conftest$ac_exeext'
6941   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6942   (eval $ac_try) 2>&5
6943   ac_status=$?
6944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6945   (exit $ac_status); }; }; then
6946   ac_cv_lib_ssl_SSL_library_init=yes
6947 else
6948   echo "$as_me: failed program was:" >&5
6949 sed 's/^/| /' conftest.$ac_ext >&5
6950
6951 ac_cv_lib_ssl_SSL_library_init=no
6952 fi
6953 rm -f conftest.err conftest.$ac_objext \
6954       conftest$ac_exeext conftest.$ac_ext
6955 LIBS=$ac_check_lib_save_LIBS
6956 fi
6957 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
6958 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
6959 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
6960   cat >>confdefs.h <<_ACEOF
6961 #define HAVE_LIBSSL 1
6962 _ACEOF
6963
6964   LIBS="-lssl $LIBS"
6965
6966 else
6967   { { echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
6968 echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
6969    { (exit 1); exit 1; }; }
6970 fi
6971
6972   else
6973
6974 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
6975 echo $ECHO_N "checking for CRYPTO_new_ex_data in -leay32... $ECHO_C" >&6
6976 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
6977   echo $ECHO_N "(cached) $ECHO_C" >&6
6978 else
6979   ac_check_lib_save_LIBS=$LIBS
6980 LIBS="-leay32  $LIBS"
6981 cat >conftest.$ac_ext <<_ACEOF
6982 /* confdefs.h.  */
6983 _ACEOF
6984 cat confdefs.h >>conftest.$ac_ext
6985 cat >>conftest.$ac_ext <<_ACEOF
6986 /* end confdefs.h.  */
6987
6988 /* Override any gcc2 internal prototype to avoid an error.  */
6989 #ifdef __cplusplus
6990 extern "C"
6991 #endif
6992 /* We use char because int might match the return type of a gcc2
6993    builtin and then its argument prototype would still apply.  */
6994 char CRYPTO_new_ex_data ();
6995 int
6996 main ()
6997 {
6998 CRYPTO_new_ex_data ();
6999   ;
7000   return 0;
7001 }
7002 _ACEOF
7003 rm -f conftest.$ac_objext conftest$ac_exeext
7004 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7005   (eval $ac_link) 2>conftest.er1
7006   ac_status=$?
7007   grep -v '^ *+' conftest.er1 >conftest.err
7008   rm -f conftest.er1
7009   cat conftest.err >&5
7010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7011   (exit $ac_status); } &&
7012          { ac_try='test -z "$ac_c_werror_flag"
7013                          || test ! -s conftest.err'
7014   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7015   (eval $ac_try) 2>&5
7016   ac_status=$?
7017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7018   (exit $ac_status); }; } &&
7019          { ac_try='test -s conftest$ac_exeext'
7020   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7021   (eval $ac_try) 2>&5
7022   ac_status=$?
7023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7024   (exit $ac_status); }; }; then
7025   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
7026 else
7027   echo "$as_me: failed program was:" >&5
7028 sed 's/^/| /' conftest.$ac_ext >&5
7029
7030 ac_cv_lib_eay32_CRYPTO_new_ex_data=no
7031 fi
7032 rm -f conftest.err conftest.$ac_objext \
7033       conftest$ac_exeext conftest.$ac_ext
7034 LIBS=$ac_check_lib_save_LIBS
7035 fi
7036 echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
7037 echo "${ECHO_T}$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6
7038 if test $ac_cv_lib_eay32_CRYPTO_new_ex_data = yes; then
7039   cat >>confdefs.h <<_ACEOF
7040 #define HAVE_LIBEAY32 1
7041 _ACEOF
7042
7043   LIBS="-leay32 $LIBS"
7044
7045 else
7046   { { echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
7047 echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
7048    { (exit 1); exit 1; }; }
7049 fi
7050
7051
7052 echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
7053 echo $ECHO_N "checking for SSL_library_init in -lssleay32... $ECHO_C" >&6
7054 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
7055   echo $ECHO_N "(cached) $ECHO_C" >&6
7056 else
7057   ac_check_lib_save_LIBS=$LIBS
7058 LIBS="-lssleay32  $LIBS"
7059 cat >conftest.$ac_ext <<_ACEOF
7060 /* confdefs.h.  */
7061 _ACEOF
7062 cat confdefs.h >>conftest.$ac_ext
7063 cat >>conftest.$ac_ext <<_ACEOF
7064 /* end confdefs.h.  */
7065
7066 /* Override any gcc2 internal prototype to avoid an error.  */
7067 #ifdef __cplusplus
7068 extern "C"
7069 #endif
7070 /* We use char because int might match the return type of a gcc2
7071    builtin and then its argument prototype would still apply.  */
7072 char SSL_library_init ();
7073 int
7074 main ()
7075 {
7076 SSL_library_init ();
7077   ;
7078   return 0;
7079 }
7080 _ACEOF
7081 rm -f conftest.$ac_objext conftest$ac_exeext
7082 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7083   (eval $ac_link) 2>conftest.er1
7084   ac_status=$?
7085   grep -v '^ *+' conftest.er1 >conftest.err
7086   rm -f conftest.er1
7087   cat conftest.err >&5
7088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7089   (exit $ac_status); } &&
7090          { ac_try='test -z "$ac_c_werror_flag"
7091                          || test ! -s conftest.err'
7092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7093   (eval $ac_try) 2>&5
7094   ac_status=$?
7095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7096   (exit $ac_status); }; } &&
7097          { ac_try='test -s conftest$ac_exeext'
7098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7099   (eval $ac_try) 2>&5
7100   ac_status=$?
7101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7102   (exit $ac_status); }; }; then
7103   ac_cv_lib_ssleay32_SSL_library_init=yes
7104 else
7105   echo "$as_me: failed program was:" >&5
7106 sed 's/^/| /' conftest.$ac_ext >&5
7107
7108 ac_cv_lib_ssleay32_SSL_library_init=no
7109 fi
7110 rm -f conftest.err conftest.$ac_objext \
7111       conftest$ac_exeext conftest.$ac_ext
7112 LIBS=$ac_check_lib_save_LIBS
7113 fi
7114 echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
7115 echo "${ECHO_T}$ac_cv_lib_ssleay32_SSL_library_init" >&6
7116 if test $ac_cv_lib_ssleay32_SSL_library_init = yes; then
7117   cat >>confdefs.h <<_ACEOF
7118 #define HAVE_LIBSSLEAY32 1
7119 _ACEOF
7120
7121   LIBS="-lssleay32 $LIBS"
7122
7123 else
7124   { { echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
7125 echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
7126    { (exit 1); exit 1; }; }
7127 fi
7128
7129   fi
7130 fi
7131
7132 if test "$with_pam" = yes ; then
7133
7134 echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
7135 echo $ECHO_N "checking for pam_start in -lpam... $ECHO_C" >&6
7136 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
7137   echo $ECHO_N "(cached) $ECHO_C" >&6
7138 else
7139   ac_check_lib_save_LIBS=$LIBS
7140 LIBS="-lpam  $LIBS"
7141 cat >conftest.$ac_ext <<_ACEOF
7142 /* confdefs.h.  */
7143 _ACEOF
7144 cat confdefs.h >>conftest.$ac_ext
7145 cat >>conftest.$ac_ext <<_ACEOF
7146 /* end confdefs.h.  */
7147
7148 /* Override any gcc2 internal prototype to avoid an error.  */
7149 #ifdef __cplusplus
7150 extern "C"
7151 #endif
7152 /* We use char because int might match the return type of a gcc2
7153    builtin and then its argument prototype would still apply.  */
7154 char pam_start ();
7155 int
7156 main ()
7157 {
7158 pam_start ();
7159   ;
7160   return 0;
7161 }
7162 _ACEOF
7163 rm -f conftest.$ac_objext conftest$ac_exeext
7164 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7165   (eval $ac_link) 2>conftest.er1
7166   ac_status=$?
7167   grep -v '^ *+' conftest.er1 >conftest.err
7168   rm -f conftest.er1
7169   cat conftest.err >&5
7170   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7171   (exit $ac_status); } &&
7172          { ac_try='test -z "$ac_c_werror_flag"
7173                          || test ! -s conftest.err'
7174   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7175   (eval $ac_try) 2>&5
7176   ac_status=$?
7177   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7178   (exit $ac_status); }; } &&
7179          { ac_try='test -s conftest$ac_exeext'
7180   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7181   (eval $ac_try) 2>&5
7182   ac_status=$?
7183   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7184   (exit $ac_status); }; }; then
7185   ac_cv_lib_pam_pam_start=yes
7186 else
7187   echo "$as_me: failed program was:" >&5
7188 sed 's/^/| /' conftest.$ac_ext >&5
7189
7190 ac_cv_lib_pam_pam_start=no
7191 fi
7192 rm -f conftest.err conftest.$ac_objext \
7193       conftest$ac_exeext conftest.$ac_ext
7194 LIBS=$ac_check_lib_save_LIBS
7195 fi
7196 echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
7197 echo "${ECHO_T}$ac_cv_lib_pam_pam_start" >&6
7198 if test $ac_cv_lib_pam_pam_start = yes; then
7199   cat >>confdefs.h <<_ACEOF
7200 #define HAVE_LIBPAM 1
7201 _ACEOF
7202
7203   LIBS="-lpam $LIBS"
7204
7205 else
7206   { { echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
7207 echo "$as_me: error: library 'pam' is required for PAM" >&2;}
7208    { (exit 1); exit 1; }; }
7209 fi
7210
7211 fi
7212
7213
7214 if test "$with_ldap" = yes ; then
7215   if test "$PORTNAME" != "win32"; then
7216
7217 echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
7218 echo $ECHO_N "checking for ldap_bind in -lldap... $ECHO_C" >&6
7219 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
7220   echo $ECHO_N "(cached) $ECHO_C" >&6
7221 else
7222   ac_check_lib_save_LIBS=$LIBS
7223 LIBS="-lldap  $LIBS"
7224 cat >conftest.$ac_ext <<_ACEOF
7225 /* confdefs.h.  */
7226 _ACEOF
7227 cat confdefs.h >>conftest.$ac_ext
7228 cat >>conftest.$ac_ext <<_ACEOF
7229 /* end confdefs.h.  */
7230
7231 /* Override any gcc2 internal prototype to avoid an error.  */
7232 #ifdef __cplusplus
7233 extern "C"
7234 #endif
7235 /* We use char because int might match the return type of a gcc2
7236    builtin and then its argument prototype would still apply.  */
7237 char ldap_bind ();
7238 int
7239 main ()
7240 {
7241 ldap_bind ();
7242   ;
7243   return 0;
7244 }
7245 _ACEOF
7246 rm -f conftest.$ac_objext conftest$ac_exeext
7247 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7248   (eval $ac_link) 2>conftest.er1
7249   ac_status=$?
7250   grep -v '^ *+' conftest.er1 >conftest.err
7251   rm -f conftest.er1
7252   cat conftest.err >&5
7253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7254   (exit $ac_status); } &&
7255          { ac_try='test -z "$ac_c_werror_flag"
7256                          || test ! -s conftest.err'
7257   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7258   (eval $ac_try) 2>&5
7259   ac_status=$?
7260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7261   (exit $ac_status); }; } &&
7262          { ac_try='test -s conftest$ac_exeext'
7263   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7264   (eval $ac_try) 2>&5
7265   ac_status=$?
7266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7267   (exit $ac_status); }; }; then
7268   ac_cv_lib_ldap_ldap_bind=yes
7269 else
7270   echo "$as_me: failed program was:" >&5
7271 sed 's/^/| /' conftest.$ac_ext >&5
7272
7273 ac_cv_lib_ldap_ldap_bind=no
7274 fi
7275 rm -f conftest.err conftest.$ac_objext \
7276       conftest$ac_exeext conftest.$ac_ext
7277 LIBS=$ac_check_lib_save_LIBS
7278 fi
7279 echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
7280 echo "${ECHO_T}$ac_cv_lib_ldap_ldap_bind" >&6
7281 if test $ac_cv_lib_ldap_ldap_bind = yes; then
7282   cat >>confdefs.h <<_ACEOF
7283 #define HAVE_LIBLDAP 1
7284 _ACEOF
7285
7286   LIBS="-lldap $LIBS"
7287
7288 else
7289   { { echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
7290 echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
7291    { (exit 1); exit 1; }; }
7292 fi
7293
7294   else
7295
7296 echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
7297 echo $ECHO_N "checking for ldap_bind in -lwldap32... $ECHO_C" >&6
7298 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
7299   echo $ECHO_N "(cached) $ECHO_C" >&6
7300 else
7301   ac_check_lib_save_LIBS=$LIBS
7302 LIBS="-lwldap32  $LIBS"
7303 cat >conftest.$ac_ext <<_ACEOF
7304 /* confdefs.h.  */
7305 _ACEOF
7306 cat confdefs.h >>conftest.$ac_ext
7307 cat >>conftest.$ac_ext <<_ACEOF
7308 /* end confdefs.h.  */
7309
7310 /* Override any gcc2 internal prototype to avoid an error.  */
7311 #ifdef __cplusplus
7312 extern "C"
7313 #endif
7314 /* We use char because int might match the return type of a gcc2
7315    builtin and then its argument prototype would still apply.  */
7316 char ldap_bind ();
7317 int
7318 main ()
7319 {
7320 ldap_bind ();
7321   ;
7322   return 0;
7323 }
7324 _ACEOF
7325 rm -f conftest.$ac_objext conftest$ac_exeext
7326 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7327   (eval $ac_link) 2>conftest.er1
7328   ac_status=$?
7329   grep -v '^ *+' conftest.er1 >conftest.err
7330   rm -f conftest.er1
7331   cat conftest.err >&5
7332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7333   (exit $ac_status); } &&
7334          { ac_try='test -z "$ac_c_werror_flag"
7335                          || test ! -s conftest.err'
7336   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7337   (eval $ac_try) 2>&5
7338   ac_status=$?
7339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7340   (exit $ac_status); }; } &&
7341          { ac_try='test -s conftest$ac_exeext'
7342   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7343   (eval $ac_try) 2>&5
7344   ac_status=$?
7345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7346   (exit $ac_status); }; }; then
7347   ac_cv_lib_wldap32_ldap_bind=yes
7348 else
7349   echo "$as_me: failed program was:" >&5
7350 sed 's/^/| /' conftest.$ac_ext >&5
7351
7352 ac_cv_lib_wldap32_ldap_bind=no
7353 fi
7354 rm -f conftest.err conftest.$ac_objext \
7355       conftest$ac_exeext conftest.$ac_ext
7356 LIBS=$ac_check_lib_save_LIBS
7357 fi
7358 echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
7359 echo "${ECHO_T}$ac_cv_lib_wldap32_ldap_bind" >&6
7360 if test $ac_cv_lib_wldap32_ldap_bind = yes; then
7361   cat >>confdefs.h <<_ACEOF
7362 #define HAVE_LIBWLDAP32 1
7363 _ACEOF
7364
7365   LIBS="-lwldap32 $LIBS"
7366
7367 else
7368   { { echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
7369 echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
7370    { (exit 1); exit 1; }; }
7371 fi
7372
7373   fi
7374 fi
7375
7376 ##
7377 ## Header files
7378 ##
7379
7380 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
7381 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
7382 if test "${ac_cv_header_stdc+set}" = set; then
7383   echo $ECHO_N "(cached) $ECHO_C" >&6
7384 else
7385   cat >conftest.$ac_ext <<_ACEOF
7386 /* confdefs.h.  */
7387 _ACEOF
7388 cat confdefs.h >>conftest.$ac_ext
7389 cat >>conftest.$ac_ext <<_ACEOF
7390 /* end confdefs.h.  */
7391 #include <stdlib.h>
7392 #include <stdarg.h>
7393 #include <string.h>
7394 #include <float.h>
7395
7396 int
7397 main ()
7398 {
7399
7400   ;
7401   return 0;
7402 }
7403 _ACEOF
7404 rm -f conftest.$ac_objext
7405 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7406   (eval $ac_compile) 2>conftest.er1
7407   ac_status=$?
7408   grep -v '^ *+' conftest.er1 >conftest.err
7409   rm -f conftest.er1
7410   cat conftest.err >&5
7411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7412   (exit $ac_status); } &&
7413          { ac_try='test -z "$ac_c_werror_flag"
7414                          || test ! -s conftest.err'
7415   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7416   (eval $ac_try) 2>&5
7417   ac_status=$?
7418   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7419   (exit $ac_status); }; } &&
7420          { ac_try='test -s conftest.$ac_objext'
7421   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7422   (eval $ac_try) 2>&5
7423   ac_status=$?
7424   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7425   (exit $ac_status); }; }; then
7426   ac_cv_header_stdc=yes
7427 else
7428   echo "$as_me: failed program was:" >&5
7429 sed 's/^/| /' conftest.$ac_ext >&5
7430
7431 ac_cv_header_stdc=no
7432 fi
7433 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7434
7435 if test $ac_cv_header_stdc = yes; then
7436   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7437   cat >conftest.$ac_ext <<_ACEOF
7438 /* confdefs.h.  */
7439 _ACEOF
7440 cat confdefs.h >>conftest.$ac_ext
7441 cat >>conftest.$ac_ext <<_ACEOF
7442 /* end confdefs.h.  */
7443 #include <string.h>
7444
7445 _ACEOF
7446 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7447   $EGREP "memchr" >/dev/null 2>&1; then
7448   :
7449 else
7450   ac_cv_header_stdc=no
7451 fi
7452 rm -f conftest*
7453
7454 fi
7455
7456 if test $ac_cv_header_stdc = yes; then
7457   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7458   cat >conftest.$ac_ext <<_ACEOF
7459 /* confdefs.h.  */
7460 _ACEOF
7461 cat confdefs.h >>conftest.$ac_ext
7462 cat >>conftest.$ac_ext <<_ACEOF
7463 /* end confdefs.h.  */
7464 #include <stdlib.h>
7465
7466 _ACEOF
7467 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7468   $EGREP "free" >/dev/null 2>&1; then
7469   :
7470 else
7471   ac_cv_header_stdc=no
7472 fi
7473 rm -f conftest*
7474
7475 fi
7476
7477 if test $ac_cv_header_stdc = yes; then
7478   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7479   if test "$cross_compiling" = yes; then
7480   :
7481 else
7482   cat >conftest.$ac_ext <<_ACEOF
7483 /* confdefs.h.  */
7484 _ACEOF
7485 cat confdefs.h >>conftest.$ac_ext
7486 cat >>conftest.$ac_ext <<_ACEOF
7487 /* end confdefs.h.  */
7488 #include <ctype.h>
7489 #if ((' ' & 0x0FF) == 0x020)
7490 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7491 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7492 #else
7493 # define ISLOWER(c) \
7494                    (('a' <= (c) && (c) <= 'i') \
7495                      || ('j' <= (c) && (c) <= 'r') \
7496                      || ('s' <= (c) && (c) <= 'z'))
7497 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7498 #endif
7499
7500 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7501 int
7502 main ()
7503 {
7504   int i;
7505   for (i = 0; i < 256; i++)
7506     if (XOR (islower (i), ISLOWER (i))
7507         || toupper (i) != TOUPPER (i))
7508       exit(2);
7509   exit (0);
7510 }
7511 _ACEOF
7512 rm -f conftest$ac_exeext
7513 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7514   (eval $ac_link) 2>&5
7515   ac_status=$?
7516   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7517   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7518   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7519   (eval $ac_try) 2>&5
7520   ac_status=$?
7521   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7522   (exit $ac_status); }; }; then
7523   :
7524 else
7525   echo "$as_me: program exited with status $ac_status" >&5
7526 echo "$as_me: failed program was:" >&5
7527 sed 's/^/| /' conftest.$ac_ext >&5
7528
7529 ( exit $ac_status )
7530 ac_cv_header_stdc=no
7531 fi
7532 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7533 fi
7534 fi
7535 fi
7536 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
7537 echo "${ECHO_T}$ac_cv_header_stdc" >&6
7538 if test $ac_cv_header_stdc = yes; then
7539
7540 cat >>confdefs.h <<\_ACEOF
7541 #define STDC_HEADERS 1
7542 _ACEOF
7543
7544 fi
7545
7546 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
7547
7548
7549
7550
7551
7552
7553
7554
7555
7556 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7557                   inttypes.h stdint.h unistd.h
7558 do
7559 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7560 echo "$as_me:$LINENO: checking for $ac_header" >&5
7561 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7562 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7563   echo $ECHO_N "(cached) $ECHO_C" >&6
7564 else
7565   cat >conftest.$ac_ext <<_ACEOF
7566 /* confdefs.h.  */
7567 _ACEOF
7568 cat confdefs.h >>conftest.$ac_ext
7569 cat >>conftest.$ac_ext <<_ACEOF
7570 /* end confdefs.h.  */
7571 $ac_includes_default
7572
7573 #include <$ac_header>
7574 _ACEOF
7575 rm -f conftest.$ac_objext
7576 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7577   (eval $ac_compile) 2>conftest.er1
7578   ac_status=$?
7579   grep -v '^ *+' conftest.er1 >conftest.err
7580   rm -f conftest.er1
7581   cat conftest.err >&5
7582   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7583   (exit $ac_status); } &&
7584          { ac_try='test -z "$ac_c_werror_flag"
7585                          || test ! -s conftest.err'
7586   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7587   (eval $ac_try) 2>&5
7588   ac_status=$?
7589   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7590   (exit $ac_status); }; } &&
7591          { ac_try='test -s conftest.$ac_objext'
7592   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7593   (eval $ac_try) 2>&5
7594   ac_status=$?
7595   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7596   (exit $ac_status); }; }; then
7597   eval "$as_ac_Header=yes"
7598 else
7599   echo "$as_me: failed program was:" >&5
7600 sed 's/^/| /' conftest.$ac_ext >&5
7601
7602 eval "$as_ac_Header=no"
7603 fi
7604 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7605 fi
7606 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7607 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7608 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7609   cat >>confdefs.h <<_ACEOF
7610 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7611 _ACEOF
7612
7613 fi
7614
7615 done
7616
7617
7618
7619
7620
7621
7622
7623
7624
7625
7626
7627
7628
7629
7630
7631
7632
7633
7634
7635
7636
7637
7638
7639
7640
7641
7642
7643 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
7644 do
7645 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7646 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7647   echo "$as_me:$LINENO: checking for $ac_header" >&5
7648 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7649 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7650   echo $ECHO_N "(cached) $ECHO_C" >&6
7651 fi
7652 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7653 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7654 else
7655   # Is the header compilable?
7656 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7657 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7658 cat >conftest.$ac_ext <<_ACEOF
7659 /* confdefs.h.  */
7660 _ACEOF
7661 cat confdefs.h >>conftest.$ac_ext
7662 cat >>conftest.$ac_ext <<_ACEOF
7663 /* end confdefs.h.  */
7664 $ac_includes_default
7665 #include <$ac_header>
7666 _ACEOF
7667 rm -f conftest.$ac_objext
7668 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7669   (eval $ac_compile) 2>conftest.er1
7670   ac_status=$?
7671   grep -v '^ *+' conftest.er1 >conftest.err
7672   rm -f conftest.er1
7673   cat conftest.err >&5
7674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7675   (exit $ac_status); } &&
7676          { ac_try='test -z "$ac_c_werror_flag"
7677                          || test ! -s conftest.err'
7678   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7679   (eval $ac_try) 2>&5
7680   ac_status=$?
7681   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7682   (exit $ac_status); }; } &&
7683          { ac_try='test -s conftest.$ac_objext'
7684   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7685   (eval $ac_try) 2>&5
7686   ac_status=$?
7687   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7688   (exit $ac_status); }; }; then
7689   ac_header_compiler=yes
7690 else
7691   echo "$as_me: failed program was:" >&5
7692 sed 's/^/| /' conftest.$ac_ext >&5
7693
7694 ac_header_compiler=no
7695 fi
7696 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7697 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7698 echo "${ECHO_T}$ac_header_compiler" >&6
7699
7700 # Is the header present?
7701 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7702 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7703 cat >conftest.$ac_ext <<_ACEOF
7704 /* confdefs.h.  */
7705 _ACEOF
7706 cat confdefs.h >>conftest.$ac_ext
7707 cat >>conftest.$ac_ext <<_ACEOF
7708 /* end confdefs.h.  */
7709 #include <$ac_header>
7710 _ACEOF
7711 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7712   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7713   ac_status=$?
7714   grep -v '^ *+' conftest.er1 >conftest.err
7715   rm -f conftest.er1
7716   cat conftest.err >&5
7717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7718   (exit $ac_status); } >/dev/null; then
7719   if test -s conftest.err; then
7720     ac_cpp_err=$ac_c_preproc_warn_flag
7721     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7722   else
7723     ac_cpp_err=
7724   fi
7725 else
7726   ac_cpp_err=yes
7727 fi
7728 if test -z "$ac_cpp_err"; then
7729   ac_header_preproc=yes
7730 else
7731   echo "$as_me: failed program was:" >&5
7732 sed 's/^/| /' conftest.$ac_ext >&5
7733
7734   ac_header_preproc=no
7735 fi
7736 rm -f conftest.err conftest.$ac_ext
7737 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7738 echo "${ECHO_T}$ac_header_preproc" >&6
7739
7740 # So?  What about this header?
7741 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7742   yes:no: )
7743     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7744 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7745     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7746 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7747     ac_header_preproc=yes
7748     ;;
7749   no:yes:* )
7750     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7751 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7752     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7753 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7754     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7755 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7756     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7757 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7758     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7759 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7760     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7761 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7762     (
7763       cat <<\_ASBOX
7764 ## ---------------------------------------- ##
7765 ## Report this to pgsql-bugs@postgresql.org ##
7766 ## ---------------------------------------- ##
7767 _ASBOX
7768     ) |
7769       sed "s/^/$as_me: WARNING:     /" >&2
7770     ;;
7771 esac
7772 echo "$as_me:$LINENO: checking for $ac_header" >&5
7773 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7774 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7775   echo $ECHO_N "(cached) $ECHO_C" >&6
7776 else
7777   eval "$as_ac_Header=\$ac_header_preproc"
7778 fi
7779 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7780 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7781
7782 fi
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 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
7794 # netinet/in.h is included first.
7795
7796 for ac_header in netinet/in.h
7797 do
7798 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7799 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7800   echo "$as_me:$LINENO: checking for $ac_header" >&5
7801 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7802 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7803   echo $ECHO_N "(cached) $ECHO_C" >&6
7804 fi
7805 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7806 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7807 else
7808   # Is the header compilable?
7809 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7810 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7811 cat >conftest.$ac_ext <<_ACEOF
7812 /* confdefs.h.  */
7813 _ACEOF
7814 cat confdefs.h >>conftest.$ac_ext
7815 cat >>conftest.$ac_ext <<_ACEOF
7816 /* end confdefs.h.  */
7817 $ac_includes_default
7818 #include <$ac_header>
7819 _ACEOF
7820 rm -f conftest.$ac_objext
7821 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7822   (eval $ac_compile) 2>conftest.er1
7823   ac_status=$?
7824   grep -v '^ *+' conftest.er1 >conftest.err
7825   rm -f conftest.er1
7826   cat conftest.err >&5
7827   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7828   (exit $ac_status); } &&
7829          { ac_try='test -z "$ac_c_werror_flag"
7830                          || test ! -s conftest.err'
7831   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7832   (eval $ac_try) 2>&5
7833   ac_status=$?
7834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7835   (exit $ac_status); }; } &&
7836          { ac_try='test -s conftest.$ac_objext'
7837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7838   (eval $ac_try) 2>&5
7839   ac_status=$?
7840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7841   (exit $ac_status); }; }; then
7842   ac_header_compiler=yes
7843 else
7844   echo "$as_me: failed program was:" >&5
7845 sed 's/^/| /' conftest.$ac_ext >&5
7846
7847 ac_header_compiler=no
7848 fi
7849 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7850 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7851 echo "${ECHO_T}$ac_header_compiler" >&6
7852
7853 # Is the header present?
7854 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7855 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7856 cat >conftest.$ac_ext <<_ACEOF
7857 /* confdefs.h.  */
7858 _ACEOF
7859 cat confdefs.h >>conftest.$ac_ext
7860 cat >>conftest.$ac_ext <<_ACEOF
7861 /* end confdefs.h.  */
7862 #include <$ac_header>
7863 _ACEOF
7864 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7865   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7866   ac_status=$?
7867   grep -v '^ *+' conftest.er1 >conftest.err
7868   rm -f conftest.er1
7869   cat conftest.err >&5
7870   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7871   (exit $ac_status); } >/dev/null; then
7872   if test -s conftest.err; then
7873     ac_cpp_err=$ac_c_preproc_warn_flag
7874     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7875   else
7876     ac_cpp_err=
7877   fi
7878 else
7879   ac_cpp_err=yes
7880 fi
7881 if test -z "$ac_cpp_err"; then
7882   ac_header_preproc=yes
7883 else
7884   echo "$as_me: failed program was:" >&5
7885 sed 's/^/| /' conftest.$ac_ext >&5
7886
7887   ac_header_preproc=no
7888 fi
7889 rm -f conftest.err conftest.$ac_ext
7890 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7891 echo "${ECHO_T}$ac_header_preproc" >&6
7892
7893 # So?  What about this header?
7894 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7895   yes:no: )
7896     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7897 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7898     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7899 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7900     ac_header_preproc=yes
7901     ;;
7902   no:yes:* )
7903     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7904 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7905     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7906 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7907     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7908 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7909     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7910 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7911     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7912 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7913     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7914 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7915     (
7916       cat <<\_ASBOX
7917 ## ---------------------------------------- ##
7918 ## Report this to pgsql-bugs@postgresql.org ##
7919 ## ---------------------------------------- ##
7920 _ASBOX
7921     ) |
7922       sed "s/^/$as_me: WARNING:     /" >&2
7923     ;;
7924 esac
7925 echo "$as_me:$LINENO: checking for $ac_header" >&5
7926 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7927 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7928   echo $ECHO_N "(cached) $ECHO_C" >&6
7929 else
7930   eval "$as_ac_Header=\$ac_header_preproc"
7931 fi
7932 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7933 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7934
7935 fi
7936 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7937   cat >>confdefs.h <<_ACEOF
7938 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7939 _ACEOF
7940
7941 fi
7942
7943 done
7944
7945
7946 for ac_header in netinet/tcp.h
7947 do
7948 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7949 echo "$as_me:$LINENO: checking for $ac_header" >&5
7950 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7951 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7952   echo $ECHO_N "(cached) $ECHO_C" >&6
7953 else
7954   cat >conftest.$ac_ext <<_ACEOF
7955 /* confdefs.h.  */
7956 _ACEOF
7957 cat confdefs.h >>conftest.$ac_ext
7958 cat >>conftest.$ac_ext <<_ACEOF
7959 /* end confdefs.h.  */
7960 $ac_includes_default
7961 #ifdef HAVE_NETINET_IN_H
7962 #include <netinet/in.h>
7963 #endif
7964
7965
7966 #include <$ac_header>
7967 _ACEOF
7968 rm -f conftest.$ac_objext
7969 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7970   (eval $ac_compile) 2>conftest.er1
7971   ac_status=$?
7972   grep -v '^ *+' conftest.er1 >conftest.err
7973   rm -f conftest.er1
7974   cat conftest.err >&5
7975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7976   (exit $ac_status); } &&
7977          { ac_try='test -z "$ac_c_werror_flag"
7978                          || test ! -s conftest.err'
7979   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7980   (eval $ac_try) 2>&5
7981   ac_status=$?
7982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7983   (exit $ac_status); }; } &&
7984          { ac_try='test -s conftest.$ac_objext'
7985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7986   (eval $ac_try) 2>&5
7987   ac_status=$?
7988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7989   (exit $ac_status); }; }; then
7990   eval "$as_ac_Header=yes"
7991 else
7992   echo "$as_me: failed program was:" >&5
7993 sed 's/^/| /' conftest.$ac_ext >&5
7994
7995 eval "$as_ac_Header=no"
7996 fi
7997 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7998 fi
7999 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8000 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8001 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8002   cat >>confdefs.h <<_ACEOF
8003 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8004 _ACEOF
8005
8006 fi
8007
8008 done
8009
8010
8011 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
8012
8013 for ac_header in readline/readline.h
8014 do
8015 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8016 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8017   echo "$as_me:$LINENO: checking for $ac_header" >&5
8018 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8019 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8020   echo $ECHO_N "(cached) $ECHO_C" >&6
8021 fi
8022 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8023 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8024 else
8025   # Is the header compilable?
8026 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8027 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8028 cat >conftest.$ac_ext <<_ACEOF
8029 /* confdefs.h.  */
8030 _ACEOF
8031 cat confdefs.h >>conftest.$ac_ext
8032 cat >>conftest.$ac_ext <<_ACEOF
8033 /* end confdefs.h.  */
8034 $ac_includes_default
8035 #include <$ac_header>
8036 _ACEOF
8037 rm -f conftest.$ac_objext
8038 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8039   (eval $ac_compile) 2>conftest.er1
8040   ac_status=$?
8041   grep -v '^ *+' conftest.er1 >conftest.err
8042   rm -f conftest.er1
8043   cat conftest.err >&5
8044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8045   (exit $ac_status); } &&
8046          { ac_try='test -z "$ac_c_werror_flag"
8047                          || test ! -s conftest.err'
8048   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8049   (eval $ac_try) 2>&5
8050   ac_status=$?
8051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8052   (exit $ac_status); }; } &&
8053          { ac_try='test -s conftest.$ac_objext'
8054   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8055   (eval $ac_try) 2>&5
8056   ac_status=$?
8057   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8058   (exit $ac_status); }; }; then
8059   ac_header_compiler=yes
8060 else
8061   echo "$as_me: failed program was:" >&5
8062 sed 's/^/| /' conftest.$ac_ext >&5
8063
8064 ac_header_compiler=no
8065 fi
8066 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8067 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8068 echo "${ECHO_T}$ac_header_compiler" >&6
8069
8070 # Is the header present?
8071 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8072 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8073 cat >conftest.$ac_ext <<_ACEOF
8074 /* confdefs.h.  */
8075 _ACEOF
8076 cat confdefs.h >>conftest.$ac_ext
8077 cat >>conftest.$ac_ext <<_ACEOF
8078 /* end confdefs.h.  */
8079 #include <$ac_header>
8080 _ACEOF
8081 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8082   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8083   ac_status=$?
8084   grep -v '^ *+' conftest.er1 >conftest.err
8085   rm -f conftest.er1
8086   cat conftest.err >&5
8087   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8088   (exit $ac_status); } >/dev/null; then
8089   if test -s conftest.err; then
8090     ac_cpp_err=$ac_c_preproc_warn_flag
8091     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8092   else
8093     ac_cpp_err=
8094   fi
8095 else
8096   ac_cpp_err=yes
8097 fi
8098 if test -z "$ac_cpp_err"; then
8099   ac_header_preproc=yes
8100 else
8101   echo "$as_me: failed program was:" >&5
8102 sed 's/^/| /' conftest.$ac_ext >&5
8103
8104   ac_header_preproc=no
8105 fi
8106 rm -f conftest.err conftest.$ac_ext
8107 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8108 echo "${ECHO_T}$ac_header_preproc" >&6
8109
8110 # So?  What about this header?
8111 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8112   yes:no: )
8113     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8114 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8115     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8116 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8117     ac_header_preproc=yes
8118     ;;
8119   no:yes:* )
8120     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8121 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8122     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8123 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8124     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8125 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8126     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8127 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8128     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8129 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8130     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8131 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8132     (
8133       cat <<\_ASBOX
8134 ## ---------------------------------------- ##
8135 ## Report this to pgsql-bugs@postgresql.org ##
8136 ## ---------------------------------------- ##
8137 _ASBOX
8138     ) |
8139       sed "s/^/$as_me: WARNING:     /" >&2
8140     ;;
8141 esac
8142 echo "$as_me:$LINENO: checking for $ac_header" >&5
8143 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8144 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8145   echo $ECHO_N "(cached) $ECHO_C" >&6
8146 else
8147   eval "$as_ac_Header=\$ac_header_preproc"
8148 fi
8149 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8150 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8151
8152 fi
8153 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8154   cat >>confdefs.h <<_ACEOF
8155 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8156 _ACEOF
8157
8158 else
8159
8160 for ac_header in readline.h
8161 do
8162 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8163 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8164   echo "$as_me:$LINENO: checking for $ac_header" >&5
8165 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8166 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8167   echo $ECHO_N "(cached) $ECHO_C" >&6
8168 fi
8169 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8170 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8171 else
8172   # Is the header compilable?
8173 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8174 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8175 cat >conftest.$ac_ext <<_ACEOF
8176 /* confdefs.h.  */
8177 _ACEOF
8178 cat confdefs.h >>conftest.$ac_ext
8179 cat >>conftest.$ac_ext <<_ACEOF
8180 /* end confdefs.h.  */
8181 $ac_includes_default
8182 #include <$ac_header>
8183 _ACEOF
8184 rm -f conftest.$ac_objext
8185 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8186   (eval $ac_compile) 2>conftest.er1
8187   ac_status=$?
8188   grep -v '^ *+' conftest.er1 >conftest.err
8189   rm -f conftest.er1
8190   cat conftest.err >&5
8191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8192   (exit $ac_status); } &&
8193          { ac_try='test -z "$ac_c_werror_flag"
8194                          || test ! -s conftest.err'
8195   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8196   (eval $ac_try) 2>&5
8197   ac_status=$?
8198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8199   (exit $ac_status); }; } &&
8200          { ac_try='test -s conftest.$ac_objext'
8201   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8202   (eval $ac_try) 2>&5
8203   ac_status=$?
8204   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8205   (exit $ac_status); }; }; then
8206   ac_header_compiler=yes
8207 else
8208   echo "$as_me: failed program was:" >&5
8209 sed 's/^/| /' conftest.$ac_ext >&5
8210
8211 ac_header_compiler=no
8212 fi
8213 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8214 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8215 echo "${ECHO_T}$ac_header_compiler" >&6
8216
8217 # Is the header present?
8218 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8219 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8220 cat >conftest.$ac_ext <<_ACEOF
8221 /* confdefs.h.  */
8222 _ACEOF
8223 cat confdefs.h >>conftest.$ac_ext
8224 cat >>conftest.$ac_ext <<_ACEOF
8225 /* end confdefs.h.  */
8226 #include <$ac_header>
8227 _ACEOF
8228 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8229   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8230   ac_status=$?
8231   grep -v '^ *+' conftest.er1 >conftest.err
8232   rm -f conftest.er1
8233   cat conftest.err >&5
8234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8235   (exit $ac_status); } >/dev/null; then
8236   if test -s conftest.err; then
8237     ac_cpp_err=$ac_c_preproc_warn_flag
8238     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8239   else
8240     ac_cpp_err=
8241   fi
8242 else
8243   ac_cpp_err=yes
8244 fi
8245 if test -z "$ac_cpp_err"; then
8246   ac_header_preproc=yes
8247 else
8248   echo "$as_me: failed program was:" >&5
8249 sed 's/^/| /' conftest.$ac_ext >&5
8250
8251   ac_header_preproc=no
8252 fi
8253 rm -f conftest.err conftest.$ac_ext
8254 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8255 echo "${ECHO_T}$ac_header_preproc" >&6
8256
8257 # So?  What about this header?
8258 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8259   yes:no: )
8260     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8261 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8262     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8263 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8264     ac_header_preproc=yes
8265     ;;
8266   no:yes:* )
8267     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8268 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8269     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8270 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8271     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8272 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8273     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8274 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8275     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8276 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8277     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8278 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8279     (
8280       cat <<\_ASBOX
8281 ## ---------------------------------------- ##
8282 ## Report this to pgsql-bugs@postgresql.org ##
8283 ## ---------------------------------------- ##
8284 _ASBOX
8285     ) |
8286       sed "s/^/$as_me: WARNING:     /" >&2
8287     ;;
8288 esac
8289 echo "$as_me:$LINENO: checking for $ac_header" >&5
8290 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8291 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8292   echo $ECHO_N "(cached) $ECHO_C" >&6
8293 else
8294   eval "$as_ac_Header=\$ac_header_preproc"
8295 fi
8296 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8297 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8298
8299 fi
8300 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8301   cat >>confdefs.h <<_ACEOF
8302 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8303 _ACEOF
8304
8305 else
8306   { { echo "$as_me:$LINENO: error: readline header not found
8307 If you have readline already installed, see config.log for details on the
8308 failure.  It is possible the compiler isn't looking in the proper directory.
8309 Use --without-readline to disable readline support." >&5
8310 echo "$as_me: error: readline header not found
8311 If you have readline already installed, see config.log for details on the
8312 failure.  It is possible the compiler isn't looking in the proper directory.
8313 Use --without-readline to disable readline support." >&2;}
8314    { (exit 1); exit 1; }; }
8315 fi
8316
8317 done
8318
8319 fi
8320
8321 done
8322
8323
8324 for ac_header in readline/history.h
8325 do
8326 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8327 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8328   echo "$as_me:$LINENO: checking for $ac_header" >&5
8329 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8330 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8331   echo $ECHO_N "(cached) $ECHO_C" >&6
8332 fi
8333 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8334 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8335 else
8336   # Is the header compilable?
8337 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8338 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8339 cat >conftest.$ac_ext <<_ACEOF
8340 /* confdefs.h.  */
8341 _ACEOF
8342 cat confdefs.h >>conftest.$ac_ext
8343 cat >>conftest.$ac_ext <<_ACEOF
8344 /* end confdefs.h.  */
8345 $ac_includes_default
8346 #include <$ac_header>
8347 _ACEOF
8348 rm -f conftest.$ac_objext
8349 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8350   (eval $ac_compile) 2>conftest.er1
8351   ac_status=$?
8352   grep -v '^ *+' conftest.er1 >conftest.err
8353   rm -f conftest.er1
8354   cat conftest.err >&5
8355   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8356   (exit $ac_status); } &&
8357          { ac_try='test -z "$ac_c_werror_flag"
8358                          || test ! -s conftest.err'
8359   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8360   (eval $ac_try) 2>&5
8361   ac_status=$?
8362   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8363   (exit $ac_status); }; } &&
8364          { ac_try='test -s conftest.$ac_objext'
8365   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8366   (eval $ac_try) 2>&5
8367   ac_status=$?
8368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8369   (exit $ac_status); }; }; then
8370   ac_header_compiler=yes
8371 else
8372   echo "$as_me: failed program was:" >&5
8373 sed 's/^/| /' conftest.$ac_ext >&5
8374
8375 ac_header_compiler=no
8376 fi
8377 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8378 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8379 echo "${ECHO_T}$ac_header_compiler" >&6
8380
8381 # Is the header present?
8382 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8383 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8384 cat >conftest.$ac_ext <<_ACEOF
8385 /* confdefs.h.  */
8386 _ACEOF
8387 cat confdefs.h >>conftest.$ac_ext
8388 cat >>conftest.$ac_ext <<_ACEOF
8389 /* end confdefs.h.  */
8390 #include <$ac_header>
8391 _ACEOF
8392 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8393   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8394   ac_status=$?
8395   grep -v '^ *+' conftest.er1 >conftest.err
8396   rm -f conftest.er1
8397   cat conftest.err >&5
8398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8399   (exit $ac_status); } >/dev/null; then
8400   if test -s conftest.err; then
8401     ac_cpp_err=$ac_c_preproc_warn_flag
8402     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8403   else
8404     ac_cpp_err=
8405   fi
8406 else
8407   ac_cpp_err=yes
8408 fi
8409 if test -z "$ac_cpp_err"; then
8410   ac_header_preproc=yes
8411 else
8412   echo "$as_me: failed program was:" >&5
8413 sed 's/^/| /' conftest.$ac_ext >&5
8414
8415   ac_header_preproc=no
8416 fi
8417 rm -f conftest.err conftest.$ac_ext
8418 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8419 echo "${ECHO_T}$ac_header_preproc" >&6
8420
8421 # So?  What about this header?
8422 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8423   yes:no: )
8424     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8425 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8426     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8427 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8428     ac_header_preproc=yes
8429     ;;
8430   no:yes:* )
8431     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8432 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8433     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8434 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8435     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8436 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8437     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8438 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8439     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8440 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8441     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8442 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8443     (
8444       cat <<\_ASBOX
8445 ## ---------------------------------------- ##
8446 ## Report this to pgsql-bugs@postgresql.org ##
8447 ## ---------------------------------------- ##
8448 _ASBOX
8449     ) |
8450       sed "s/^/$as_me: WARNING:     /" >&2
8451     ;;
8452 esac
8453 echo "$as_me:$LINENO: checking for $ac_header" >&5
8454 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8455 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8456   echo $ECHO_N "(cached) $ECHO_C" >&6
8457 else
8458   eval "$as_ac_Header=\$ac_header_preproc"
8459 fi
8460 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8461 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8462
8463 fi
8464 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8465   cat >>confdefs.h <<_ACEOF
8466 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8467 _ACEOF
8468
8469 else
8470
8471 for ac_header in history.h
8472 do
8473 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8474 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8475   echo "$as_me:$LINENO: checking for $ac_header" >&5
8476 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8477 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8478   echo $ECHO_N "(cached) $ECHO_C" >&6
8479 fi
8480 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8481 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8482 else
8483   # Is the header compilable?
8484 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8485 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8486 cat >conftest.$ac_ext <<_ACEOF
8487 /* confdefs.h.  */
8488 _ACEOF
8489 cat confdefs.h >>conftest.$ac_ext
8490 cat >>conftest.$ac_ext <<_ACEOF
8491 /* end confdefs.h.  */
8492 $ac_includes_default
8493 #include <$ac_header>
8494 _ACEOF
8495 rm -f conftest.$ac_objext
8496 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8497   (eval $ac_compile) 2>conftest.er1
8498   ac_status=$?
8499   grep -v '^ *+' conftest.er1 >conftest.err
8500   rm -f conftest.er1
8501   cat conftest.err >&5
8502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8503   (exit $ac_status); } &&
8504          { ac_try='test -z "$ac_c_werror_flag"
8505                          || test ! -s conftest.err'
8506   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8507   (eval $ac_try) 2>&5
8508   ac_status=$?
8509   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8510   (exit $ac_status); }; } &&
8511          { ac_try='test -s conftest.$ac_objext'
8512   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8513   (eval $ac_try) 2>&5
8514   ac_status=$?
8515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8516   (exit $ac_status); }; }; then
8517   ac_header_compiler=yes
8518 else
8519   echo "$as_me: failed program was:" >&5
8520 sed 's/^/| /' conftest.$ac_ext >&5
8521
8522 ac_header_compiler=no
8523 fi
8524 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8525 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8526 echo "${ECHO_T}$ac_header_compiler" >&6
8527
8528 # Is the header present?
8529 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8530 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8531 cat >conftest.$ac_ext <<_ACEOF
8532 /* confdefs.h.  */
8533 _ACEOF
8534 cat confdefs.h >>conftest.$ac_ext
8535 cat >>conftest.$ac_ext <<_ACEOF
8536 /* end confdefs.h.  */
8537 #include <$ac_header>
8538 _ACEOF
8539 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8540   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8541   ac_status=$?
8542   grep -v '^ *+' conftest.er1 >conftest.err
8543   rm -f conftest.er1
8544   cat conftest.err >&5
8545   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8546   (exit $ac_status); } >/dev/null; then
8547   if test -s conftest.err; then
8548     ac_cpp_err=$ac_c_preproc_warn_flag
8549     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8550   else
8551     ac_cpp_err=
8552   fi
8553 else
8554   ac_cpp_err=yes
8555 fi
8556 if test -z "$ac_cpp_err"; then
8557   ac_header_preproc=yes
8558 else
8559   echo "$as_me: failed program was:" >&5
8560 sed 's/^/| /' conftest.$ac_ext >&5
8561
8562   ac_header_preproc=no
8563 fi
8564 rm -f conftest.err conftest.$ac_ext
8565 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8566 echo "${ECHO_T}$ac_header_preproc" >&6
8567
8568 # So?  What about this header?
8569 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8570   yes:no: )
8571     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8572 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8573     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8574 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8575     ac_header_preproc=yes
8576     ;;
8577   no:yes:* )
8578     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8579 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8580     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8581 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8582     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8583 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8584     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8585 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8586     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8587 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8588     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8589 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8590     (
8591       cat <<\_ASBOX
8592 ## ---------------------------------------- ##
8593 ## Report this to pgsql-bugs@postgresql.org ##
8594 ## ---------------------------------------- ##
8595 _ASBOX
8596     ) |
8597       sed "s/^/$as_me: WARNING:     /" >&2
8598     ;;
8599 esac
8600 echo "$as_me:$LINENO: checking for $ac_header" >&5
8601 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8602 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8603   echo $ECHO_N "(cached) $ECHO_C" >&6
8604 else
8605   eval "$as_ac_Header=\$ac_header_preproc"
8606 fi
8607 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8608 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8609
8610 fi
8611 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8612   cat >>confdefs.h <<_ACEOF
8613 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8614 _ACEOF
8615
8616 else
8617   { { echo "$as_me:$LINENO: error: history header not found
8618 If you have readline already installed, see config.log for details on the
8619 failure.  It is possible the compiler isn't looking in the proper directory.
8620 Use --without-readline to disable readline support." >&5
8621 echo "$as_me: error: history header not found
8622 If you have readline already installed, see config.log for details on the
8623 failure.  It is possible the compiler isn't looking in the proper directory.
8624 Use --without-readline to disable readline support." >&2;}
8625    { (exit 1); exit 1; }; }
8626 fi
8627
8628 done
8629
8630 fi
8631
8632 done
8633
8634 fi
8635
8636 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
8637 # Some installations of libedit usurp /usr/include/readline/, which seems
8638 # bad practice, since in combined installations readline will have its headers
8639 # there.  We might have to resort to AC_EGREP checks to make sure we found
8640 # the proper header...
8641
8642 for ac_header in editline/readline.h
8643 do
8644 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8645 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8646   echo "$as_me:$LINENO: checking for $ac_header" >&5
8647 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8648 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8649   echo $ECHO_N "(cached) $ECHO_C" >&6
8650 fi
8651 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8652 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8653 else
8654   # Is the header compilable?
8655 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8656 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8657 cat >conftest.$ac_ext <<_ACEOF
8658 /* confdefs.h.  */
8659 _ACEOF
8660 cat confdefs.h >>conftest.$ac_ext
8661 cat >>conftest.$ac_ext <<_ACEOF
8662 /* end confdefs.h.  */
8663 $ac_includes_default
8664 #include <$ac_header>
8665 _ACEOF
8666 rm -f conftest.$ac_objext
8667 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8668   (eval $ac_compile) 2>conftest.er1
8669   ac_status=$?
8670   grep -v '^ *+' conftest.er1 >conftest.err
8671   rm -f conftest.er1
8672   cat conftest.err >&5
8673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8674   (exit $ac_status); } &&
8675          { ac_try='test -z "$ac_c_werror_flag"
8676                          || test ! -s conftest.err'
8677   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8678   (eval $ac_try) 2>&5
8679   ac_status=$?
8680   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8681   (exit $ac_status); }; } &&
8682          { ac_try='test -s conftest.$ac_objext'
8683   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8684   (eval $ac_try) 2>&5
8685   ac_status=$?
8686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8687   (exit $ac_status); }; }; then
8688   ac_header_compiler=yes
8689 else
8690   echo "$as_me: failed program was:" >&5
8691 sed 's/^/| /' conftest.$ac_ext >&5
8692
8693 ac_header_compiler=no
8694 fi
8695 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8696 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8697 echo "${ECHO_T}$ac_header_compiler" >&6
8698
8699 # Is the header present?
8700 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8701 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8702 cat >conftest.$ac_ext <<_ACEOF
8703 /* confdefs.h.  */
8704 _ACEOF
8705 cat confdefs.h >>conftest.$ac_ext
8706 cat >>conftest.$ac_ext <<_ACEOF
8707 /* end confdefs.h.  */
8708 #include <$ac_header>
8709 _ACEOF
8710 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8711   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8712   ac_status=$?
8713   grep -v '^ *+' conftest.er1 >conftest.err
8714   rm -f conftest.er1
8715   cat conftest.err >&5
8716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8717   (exit $ac_status); } >/dev/null; then
8718   if test -s conftest.err; then
8719     ac_cpp_err=$ac_c_preproc_warn_flag
8720     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8721   else
8722     ac_cpp_err=
8723   fi
8724 else
8725   ac_cpp_err=yes
8726 fi
8727 if test -z "$ac_cpp_err"; then
8728   ac_header_preproc=yes
8729 else
8730   echo "$as_me: failed program was:" >&5
8731 sed 's/^/| /' conftest.$ac_ext >&5
8732
8733   ac_header_preproc=no
8734 fi
8735 rm -f conftest.err conftest.$ac_ext
8736 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8737 echo "${ECHO_T}$ac_header_preproc" >&6
8738
8739 # So?  What about this header?
8740 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8741   yes:no: )
8742     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8743 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8744     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8745 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8746     ac_header_preproc=yes
8747     ;;
8748   no:yes:* )
8749     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8750 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8751     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8752 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8753     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8754 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8755     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8756 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8757     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8758 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8759     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8760 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8761     (
8762       cat <<\_ASBOX
8763 ## ---------------------------------------- ##
8764 ## Report this to pgsql-bugs@postgresql.org ##
8765 ## ---------------------------------------- ##
8766 _ASBOX
8767     ) |
8768       sed "s/^/$as_me: WARNING:     /" >&2
8769     ;;
8770 esac
8771 echo "$as_me:$LINENO: checking for $ac_header" >&5
8772 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8773 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8774   echo $ECHO_N "(cached) $ECHO_C" >&6
8775 else
8776   eval "$as_ac_Header=\$ac_header_preproc"
8777 fi
8778 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8779 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8780
8781 fi
8782 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8783   cat >>confdefs.h <<_ACEOF
8784 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8785 _ACEOF
8786
8787 else
8788
8789 for ac_header in readline.h
8790 do
8791 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8792 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8793   echo "$as_me:$LINENO: checking for $ac_header" >&5
8794 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8795 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8796   echo $ECHO_N "(cached) $ECHO_C" >&6
8797 fi
8798 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8799 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8800 else
8801   # Is the header compilable?
8802 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8803 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8804 cat >conftest.$ac_ext <<_ACEOF
8805 /* confdefs.h.  */
8806 _ACEOF
8807 cat confdefs.h >>conftest.$ac_ext
8808 cat >>conftest.$ac_ext <<_ACEOF
8809 /* end confdefs.h.  */
8810 $ac_includes_default
8811 #include <$ac_header>
8812 _ACEOF
8813 rm -f conftest.$ac_objext
8814 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8815   (eval $ac_compile) 2>conftest.er1
8816   ac_status=$?
8817   grep -v '^ *+' conftest.er1 >conftest.err
8818   rm -f conftest.er1
8819   cat conftest.err >&5
8820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8821   (exit $ac_status); } &&
8822          { ac_try='test -z "$ac_c_werror_flag"
8823                          || test ! -s conftest.err'
8824   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8825   (eval $ac_try) 2>&5
8826   ac_status=$?
8827   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8828   (exit $ac_status); }; } &&
8829          { ac_try='test -s conftest.$ac_objext'
8830   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8831   (eval $ac_try) 2>&5
8832   ac_status=$?
8833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8834   (exit $ac_status); }; }; then
8835   ac_header_compiler=yes
8836 else
8837   echo "$as_me: failed program was:" >&5
8838 sed 's/^/| /' conftest.$ac_ext >&5
8839
8840 ac_header_compiler=no
8841 fi
8842 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8843 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8844 echo "${ECHO_T}$ac_header_compiler" >&6
8845
8846 # Is the header present?
8847 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8848 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8849 cat >conftest.$ac_ext <<_ACEOF
8850 /* confdefs.h.  */
8851 _ACEOF
8852 cat confdefs.h >>conftest.$ac_ext
8853 cat >>conftest.$ac_ext <<_ACEOF
8854 /* end confdefs.h.  */
8855 #include <$ac_header>
8856 _ACEOF
8857 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8858   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8859   ac_status=$?
8860   grep -v '^ *+' conftest.er1 >conftest.err
8861   rm -f conftest.er1
8862   cat conftest.err >&5
8863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8864   (exit $ac_status); } >/dev/null; then
8865   if test -s conftest.err; then
8866     ac_cpp_err=$ac_c_preproc_warn_flag
8867     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8868   else
8869     ac_cpp_err=
8870   fi
8871 else
8872   ac_cpp_err=yes
8873 fi
8874 if test -z "$ac_cpp_err"; then
8875   ac_header_preproc=yes
8876 else
8877   echo "$as_me: failed program was:" >&5
8878 sed 's/^/| /' conftest.$ac_ext >&5
8879
8880   ac_header_preproc=no
8881 fi
8882 rm -f conftest.err conftest.$ac_ext
8883 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8884 echo "${ECHO_T}$ac_header_preproc" >&6
8885
8886 # So?  What about this header?
8887 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8888   yes:no: )
8889     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8890 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8891     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8892 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8893     ac_header_preproc=yes
8894     ;;
8895   no:yes:* )
8896     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8897 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8898     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8899 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8900     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8901 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8902     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8903 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8904     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8905 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8906     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8907 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8908     (
8909       cat <<\_ASBOX
8910 ## ---------------------------------------- ##
8911 ## Report this to pgsql-bugs@postgresql.org ##
8912 ## ---------------------------------------- ##
8913 _ASBOX
8914     ) |
8915       sed "s/^/$as_me: WARNING:     /" >&2
8916     ;;
8917 esac
8918 echo "$as_me:$LINENO: checking for $ac_header" >&5
8919 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8920 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8921   echo $ECHO_N "(cached) $ECHO_C" >&6
8922 else
8923   eval "$as_ac_Header=\$ac_header_preproc"
8924 fi
8925 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8926 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8927
8928 fi
8929 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8930   cat >>confdefs.h <<_ACEOF
8931 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8932 _ACEOF
8933
8934 else
8935
8936 for ac_header in readline/readline.h
8937 do
8938 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8939 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8940   echo "$as_me:$LINENO: checking for $ac_header" >&5
8941 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8942 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8943   echo $ECHO_N "(cached) $ECHO_C" >&6
8944 fi
8945 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8946 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8947 else
8948   # Is the header compilable?
8949 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8950 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8951 cat >conftest.$ac_ext <<_ACEOF
8952 /* confdefs.h.  */
8953 _ACEOF
8954 cat confdefs.h >>conftest.$ac_ext
8955 cat >>conftest.$ac_ext <<_ACEOF
8956 /* end confdefs.h.  */
8957 $ac_includes_default
8958 #include <$ac_header>
8959 _ACEOF
8960 rm -f conftest.$ac_objext
8961 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8962   (eval $ac_compile) 2>conftest.er1
8963   ac_status=$?
8964   grep -v '^ *+' conftest.er1 >conftest.err
8965   rm -f conftest.er1
8966   cat conftest.err >&5
8967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8968   (exit $ac_status); } &&
8969          { ac_try='test -z "$ac_c_werror_flag"
8970                          || test ! -s conftest.err'
8971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8972   (eval $ac_try) 2>&5
8973   ac_status=$?
8974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8975   (exit $ac_status); }; } &&
8976          { ac_try='test -s conftest.$ac_objext'
8977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8978   (eval $ac_try) 2>&5
8979   ac_status=$?
8980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8981   (exit $ac_status); }; }; then
8982   ac_header_compiler=yes
8983 else
8984   echo "$as_me: failed program was:" >&5
8985 sed 's/^/| /' conftest.$ac_ext >&5
8986
8987 ac_header_compiler=no
8988 fi
8989 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8990 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8991 echo "${ECHO_T}$ac_header_compiler" >&6
8992
8993 # Is the header present?
8994 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8995 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8996 cat >conftest.$ac_ext <<_ACEOF
8997 /* confdefs.h.  */
8998 _ACEOF
8999 cat confdefs.h >>conftest.$ac_ext
9000 cat >>conftest.$ac_ext <<_ACEOF
9001 /* end confdefs.h.  */
9002 #include <$ac_header>
9003 _ACEOF
9004 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9005   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9006   ac_status=$?
9007   grep -v '^ *+' conftest.er1 >conftest.err
9008   rm -f conftest.er1
9009   cat conftest.err >&5
9010   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9011   (exit $ac_status); } >/dev/null; then
9012   if test -s conftest.err; then
9013     ac_cpp_err=$ac_c_preproc_warn_flag
9014     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9015   else
9016     ac_cpp_err=
9017   fi
9018 else
9019   ac_cpp_err=yes
9020 fi
9021 if test -z "$ac_cpp_err"; then
9022   ac_header_preproc=yes
9023 else
9024   echo "$as_me: failed program was:" >&5
9025 sed 's/^/| /' conftest.$ac_ext >&5
9026
9027   ac_header_preproc=no
9028 fi
9029 rm -f conftest.err conftest.$ac_ext
9030 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9031 echo "${ECHO_T}$ac_header_preproc" >&6
9032
9033 # So?  What about this header?
9034 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9035   yes:no: )
9036     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9037 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9038     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9039 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9040     ac_header_preproc=yes
9041     ;;
9042   no:yes:* )
9043     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9044 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9045     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9046 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9047     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9048 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9049     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9050 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9051     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9052 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9053     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9054 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9055     (
9056       cat <<\_ASBOX
9057 ## ---------------------------------------- ##
9058 ## Report this to pgsql-bugs@postgresql.org ##
9059 ## ---------------------------------------- ##
9060 _ASBOX
9061     ) |
9062       sed "s/^/$as_me: WARNING:     /" >&2
9063     ;;
9064 esac
9065 echo "$as_me:$LINENO: checking for $ac_header" >&5
9066 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9067 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9068   echo $ECHO_N "(cached) $ECHO_C" >&6
9069 else
9070   eval "$as_ac_Header=\$ac_header_preproc"
9071 fi
9072 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9073 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9074
9075 fi
9076 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9077   cat >>confdefs.h <<_ACEOF
9078 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9079 _ACEOF
9080
9081 else
9082   { { echo "$as_me:$LINENO: error: readline header not found
9083 If you have libedit already installed, see config.log for details on the
9084 failure.  It is possible the compiler isn't looking in the proper directory.
9085 Use --without-readline to disable libedit support." >&5
9086 echo "$as_me: error: readline header not found
9087 If you have libedit already installed, see config.log for details on the
9088 failure.  It is possible the compiler isn't looking in the proper directory.
9089 Use --without-readline to disable libedit support." >&2;}
9090    { (exit 1); exit 1; }; }
9091 fi
9092
9093 done
9094
9095 fi
9096
9097 done
9098
9099 fi
9100
9101 done
9102
9103
9104 for ac_header in editline/history.h
9105 do
9106 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9107 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9108   echo "$as_me:$LINENO: checking for $ac_header" >&5
9109 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9110 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9111   echo $ECHO_N "(cached) $ECHO_C" >&6
9112 fi
9113 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9114 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9115 else
9116   # Is the header compilable?
9117 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9118 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9119 cat >conftest.$ac_ext <<_ACEOF
9120 /* confdefs.h.  */
9121 _ACEOF
9122 cat confdefs.h >>conftest.$ac_ext
9123 cat >>conftest.$ac_ext <<_ACEOF
9124 /* end confdefs.h.  */
9125 $ac_includes_default
9126 #include <$ac_header>
9127 _ACEOF
9128 rm -f conftest.$ac_objext
9129 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9130   (eval $ac_compile) 2>conftest.er1
9131   ac_status=$?
9132   grep -v '^ *+' conftest.er1 >conftest.err
9133   rm -f conftest.er1
9134   cat conftest.err >&5
9135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9136   (exit $ac_status); } &&
9137          { ac_try='test -z "$ac_c_werror_flag"
9138                          || test ! -s conftest.err'
9139   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9140   (eval $ac_try) 2>&5
9141   ac_status=$?
9142   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9143   (exit $ac_status); }; } &&
9144          { ac_try='test -s conftest.$ac_objext'
9145   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9146   (eval $ac_try) 2>&5
9147   ac_status=$?
9148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9149   (exit $ac_status); }; }; then
9150   ac_header_compiler=yes
9151 else
9152   echo "$as_me: failed program was:" >&5
9153 sed 's/^/| /' conftest.$ac_ext >&5
9154
9155 ac_header_compiler=no
9156 fi
9157 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9158 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9159 echo "${ECHO_T}$ac_header_compiler" >&6
9160
9161 # Is the header present?
9162 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9163 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9164 cat >conftest.$ac_ext <<_ACEOF
9165 /* confdefs.h.  */
9166 _ACEOF
9167 cat confdefs.h >>conftest.$ac_ext
9168 cat >>conftest.$ac_ext <<_ACEOF
9169 /* end confdefs.h.  */
9170 #include <$ac_header>
9171 _ACEOF
9172 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9173   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9174   ac_status=$?
9175   grep -v '^ *+' conftest.er1 >conftest.err
9176   rm -f conftest.er1
9177   cat conftest.err >&5
9178   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9179   (exit $ac_status); } >/dev/null; then
9180   if test -s conftest.err; then
9181     ac_cpp_err=$ac_c_preproc_warn_flag
9182     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9183   else
9184     ac_cpp_err=
9185   fi
9186 else
9187   ac_cpp_err=yes
9188 fi
9189 if test -z "$ac_cpp_err"; then
9190   ac_header_preproc=yes
9191 else
9192   echo "$as_me: failed program was:" >&5
9193 sed 's/^/| /' conftest.$ac_ext >&5
9194
9195   ac_header_preproc=no
9196 fi
9197 rm -f conftest.err conftest.$ac_ext
9198 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9199 echo "${ECHO_T}$ac_header_preproc" >&6
9200
9201 # So?  What about this header?
9202 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9203   yes:no: )
9204     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9205 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9206     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9207 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9208     ac_header_preproc=yes
9209     ;;
9210   no:yes:* )
9211     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9212 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9213     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9214 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9215     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9216 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9217     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9218 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9219     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9220 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9221     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9222 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9223     (
9224       cat <<\_ASBOX
9225 ## ---------------------------------------- ##
9226 ## Report this to pgsql-bugs@postgresql.org ##
9227 ## ---------------------------------------- ##
9228 _ASBOX
9229     ) |
9230       sed "s/^/$as_me: WARNING:     /" >&2
9231     ;;
9232 esac
9233 echo "$as_me:$LINENO: checking for $ac_header" >&5
9234 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9235 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9236   echo $ECHO_N "(cached) $ECHO_C" >&6
9237 else
9238   eval "$as_ac_Header=\$ac_header_preproc"
9239 fi
9240 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9241 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9242
9243 fi
9244 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9245   cat >>confdefs.h <<_ACEOF
9246 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9247 _ACEOF
9248
9249 else
9250
9251 for ac_header in history.h
9252 do
9253 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9254 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9255   echo "$as_me:$LINENO: checking for $ac_header" >&5
9256 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9257 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9258   echo $ECHO_N "(cached) $ECHO_C" >&6
9259 fi
9260 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9261 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9262 else
9263   # Is the header compilable?
9264 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9265 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9266 cat >conftest.$ac_ext <<_ACEOF
9267 /* confdefs.h.  */
9268 _ACEOF
9269 cat confdefs.h >>conftest.$ac_ext
9270 cat >>conftest.$ac_ext <<_ACEOF
9271 /* end confdefs.h.  */
9272 $ac_includes_default
9273 #include <$ac_header>
9274 _ACEOF
9275 rm -f conftest.$ac_objext
9276 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9277   (eval $ac_compile) 2>conftest.er1
9278   ac_status=$?
9279   grep -v '^ *+' conftest.er1 >conftest.err
9280   rm -f conftest.er1
9281   cat conftest.err >&5
9282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9283   (exit $ac_status); } &&
9284          { ac_try='test -z "$ac_c_werror_flag"
9285                          || test ! -s conftest.err'
9286   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9287   (eval $ac_try) 2>&5
9288   ac_status=$?
9289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9290   (exit $ac_status); }; } &&
9291          { ac_try='test -s conftest.$ac_objext'
9292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9293   (eval $ac_try) 2>&5
9294   ac_status=$?
9295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9296   (exit $ac_status); }; }; then
9297   ac_header_compiler=yes
9298 else
9299   echo "$as_me: failed program was:" >&5
9300 sed 's/^/| /' conftest.$ac_ext >&5
9301
9302 ac_header_compiler=no
9303 fi
9304 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9305 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9306 echo "${ECHO_T}$ac_header_compiler" >&6
9307
9308 # Is the header present?
9309 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9310 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9311 cat >conftest.$ac_ext <<_ACEOF
9312 /* confdefs.h.  */
9313 _ACEOF
9314 cat confdefs.h >>conftest.$ac_ext
9315 cat >>conftest.$ac_ext <<_ACEOF
9316 /* end confdefs.h.  */
9317 #include <$ac_header>
9318 _ACEOF
9319 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9320   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9321   ac_status=$?
9322   grep -v '^ *+' conftest.er1 >conftest.err
9323   rm -f conftest.er1
9324   cat conftest.err >&5
9325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9326   (exit $ac_status); } >/dev/null; then
9327   if test -s conftest.err; then
9328     ac_cpp_err=$ac_c_preproc_warn_flag
9329     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9330   else
9331     ac_cpp_err=
9332   fi
9333 else
9334   ac_cpp_err=yes
9335 fi
9336 if test -z "$ac_cpp_err"; then
9337   ac_header_preproc=yes
9338 else
9339   echo "$as_me: failed program was:" >&5
9340 sed 's/^/| /' conftest.$ac_ext >&5
9341
9342   ac_header_preproc=no
9343 fi
9344 rm -f conftest.err conftest.$ac_ext
9345 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9346 echo "${ECHO_T}$ac_header_preproc" >&6
9347
9348 # So?  What about this header?
9349 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9350   yes:no: )
9351     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9352 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9353     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9354 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9355     ac_header_preproc=yes
9356     ;;
9357   no:yes:* )
9358     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9359 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9360     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9361 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9362     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9363 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9364     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9365 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9366     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9367 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9368     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9369 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9370     (
9371       cat <<\_ASBOX
9372 ## ---------------------------------------- ##
9373 ## Report this to pgsql-bugs@postgresql.org ##
9374 ## ---------------------------------------- ##
9375 _ASBOX
9376     ) |
9377       sed "s/^/$as_me: WARNING:     /" >&2
9378     ;;
9379 esac
9380 echo "$as_me:$LINENO: checking for $ac_header" >&5
9381 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9382 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9383   echo $ECHO_N "(cached) $ECHO_C" >&6
9384 else
9385   eval "$as_ac_Header=\$ac_header_preproc"
9386 fi
9387 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9388 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9389
9390 fi
9391 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9392   cat >>confdefs.h <<_ACEOF
9393 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9394 _ACEOF
9395
9396 else
9397
9398 for ac_header in readline/history.h
9399 do
9400 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9401 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9402   echo "$as_me:$LINENO: checking for $ac_header" >&5
9403 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9404 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9405   echo $ECHO_N "(cached) $ECHO_C" >&6
9406 fi
9407 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9408 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9409 else
9410   # Is the header compilable?
9411 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9412 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9413 cat >conftest.$ac_ext <<_ACEOF
9414 /* confdefs.h.  */
9415 _ACEOF
9416 cat confdefs.h >>conftest.$ac_ext
9417 cat >>conftest.$ac_ext <<_ACEOF
9418 /* end confdefs.h.  */
9419 $ac_includes_default
9420 #include <$ac_header>
9421 _ACEOF
9422 rm -f conftest.$ac_objext
9423 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9424   (eval $ac_compile) 2>conftest.er1
9425   ac_status=$?
9426   grep -v '^ *+' conftest.er1 >conftest.err
9427   rm -f conftest.er1
9428   cat conftest.err >&5
9429   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9430   (exit $ac_status); } &&
9431          { ac_try='test -z "$ac_c_werror_flag"
9432                          || test ! -s conftest.err'
9433   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9434   (eval $ac_try) 2>&5
9435   ac_status=$?
9436   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9437   (exit $ac_status); }; } &&
9438          { ac_try='test -s conftest.$ac_objext'
9439   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9440   (eval $ac_try) 2>&5
9441   ac_status=$?
9442   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9443   (exit $ac_status); }; }; then
9444   ac_header_compiler=yes
9445 else
9446   echo "$as_me: failed program was:" >&5
9447 sed 's/^/| /' conftest.$ac_ext >&5
9448
9449 ac_header_compiler=no
9450 fi
9451 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9452 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9453 echo "${ECHO_T}$ac_header_compiler" >&6
9454
9455 # Is the header present?
9456 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9457 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9458 cat >conftest.$ac_ext <<_ACEOF
9459 /* confdefs.h.  */
9460 _ACEOF
9461 cat confdefs.h >>conftest.$ac_ext
9462 cat >>conftest.$ac_ext <<_ACEOF
9463 /* end confdefs.h.  */
9464 #include <$ac_header>
9465 _ACEOF
9466 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9467   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9468   ac_status=$?
9469   grep -v '^ *+' conftest.er1 >conftest.err
9470   rm -f conftest.er1
9471   cat conftest.err >&5
9472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9473   (exit $ac_status); } >/dev/null; then
9474   if test -s conftest.err; then
9475     ac_cpp_err=$ac_c_preproc_warn_flag
9476     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9477   else
9478     ac_cpp_err=
9479   fi
9480 else
9481   ac_cpp_err=yes
9482 fi
9483 if test -z "$ac_cpp_err"; then
9484   ac_header_preproc=yes
9485 else
9486   echo "$as_me: failed program was:" >&5
9487 sed 's/^/| /' conftest.$ac_ext >&5
9488
9489   ac_header_preproc=no
9490 fi
9491 rm -f conftest.err conftest.$ac_ext
9492 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9493 echo "${ECHO_T}$ac_header_preproc" >&6
9494
9495 # So?  What about this header?
9496 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9497   yes:no: )
9498     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9499 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9500     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9501 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9502     ac_header_preproc=yes
9503     ;;
9504   no:yes:* )
9505     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9506 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9507     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9508 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9509     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9510 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9511     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9512 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9513     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9514 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9515     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9516 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9517     (
9518       cat <<\_ASBOX
9519 ## ---------------------------------------- ##
9520 ## Report this to pgsql-bugs@postgresql.org ##
9521 ## ---------------------------------------- ##
9522 _ASBOX
9523     ) |
9524       sed "s/^/$as_me: WARNING:     /" >&2
9525     ;;
9526 esac
9527 echo "$as_me:$LINENO: checking for $ac_header" >&5
9528 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9529 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9530   echo $ECHO_N "(cached) $ECHO_C" >&6
9531 else
9532   eval "$as_ac_Header=\$ac_header_preproc"
9533 fi
9534 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9535 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9536
9537 fi
9538 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9539   cat >>confdefs.h <<_ACEOF
9540 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9541 _ACEOF
9542
9543 else
9544   { { echo "$as_me:$LINENO: error: history header not found
9545 If you have libedit already installed, see config.log for details on the
9546 failure.  It is possible the compiler isn't looking in the proper directory.
9547 Use --without-readline to disable libedit support." >&5
9548 echo "$as_me: error: history header not found
9549 If you have libedit already installed, see config.log for details on the
9550 failure.  It is possible the compiler isn't looking in the proper directory.
9551 Use --without-readline to disable libedit support." >&2;}
9552    { (exit 1); exit 1; }; }
9553 fi
9554
9555 done
9556
9557 fi
9558
9559 done
9560
9561 fi
9562
9563 done
9564
9565 fi
9566
9567 if test "$with_zlib" = yes; then
9568   if test "${ac_cv_header_zlib_h+set}" = set; then
9569   echo "$as_me:$LINENO: checking for zlib.h" >&5
9570 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
9571 if test "${ac_cv_header_zlib_h+set}" = set; then
9572   echo $ECHO_N "(cached) $ECHO_C" >&6
9573 fi
9574 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
9575 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
9576 else
9577   # Is the header compilable?
9578 echo "$as_me:$LINENO: checking zlib.h usability" >&5
9579 echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6
9580 cat >conftest.$ac_ext <<_ACEOF
9581 /* confdefs.h.  */
9582 _ACEOF
9583 cat confdefs.h >>conftest.$ac_ext
9584 cat >>conftest.$ac_ext <<_ACEOF
9585 /* end confdefs.h.  */
9586 $ac_includes_default
9587 #include <zlib.h>
9588 _ACEOF
9589 rm -f conftest.$ac_objext
9590 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9591   (eval $ac_compile) 2>conftest.er1
9592   ac_status=$?
9593   grep -v '^ *+' conftest.er1 >conftest.err
9594   rm -f conftest.er1
9595   cat conftest.err >&5
9596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9597   (exit $ac_status); } &&
9598          { ac_try='test -z "$ac_c_werror_flag"
9599                          || test ! -s conftest.err'
9600   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9601   (eval $ac_try) 2>&5
9602   ac_status=$?
9603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9604   (exit $ac_status); }; } &&
9605          { ac_try='test -s conftest.$ac_objext'
9606   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9607   (eval $ac_try) 2>&5
9608   ac_status=$?
9609   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9610   (exit $ac_status); }; }; then
9611   ac_header_compiler=yes
9612 else
9613   echo "$as_me: failed program was:" >&5
9614 sed 's/^/| /' conftest.$ac_ext >&5
9615
9616 ac_header_compiler=no
9617 fi
9618 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9619 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9620 echo "${ECHO_T}$ac_header_compiler" >&6
9621
9622 # Is the header present?
9623 echo "$as_me:$LINENO: checking zlib.h presence" >&5
9624 echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6
9625 cat >conftest.$ac_ext <<_ACEOF
9626 /* confdefs.h.  */
9627 _ACEOF
9628 cat confdefs.h >>conftest.$ac_ext
9629 cat >>conftest.$ac_ext <<_ACEOF
9630 /* end confdefs.h.  */
9631 #include <zlib.h>
9632 _ACEOF
9633 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9634   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9635   ac_status=$?
9636   grep -v '^ *+' conftest.er1 >conftest.err
9637   rm -f conftest.er1
9638   cat conftest.err >&5
9639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9640   (exit $ac_status); } >/dev/null; then
9641   if test -s conftest.err; then
9642     ac_cpp_err=$ac_c_preproc_warn_flag
9643     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9644   else
9645     ac_cpp_err=
9646   fi
9647 else
9648   ac_cpp_err=yes
9649 fi
9650 if test -z "$ac_cpp_err"; then
9651   ac_header_preproc=yes
9652 else
9653   echo "$as_me: failed program was:" >&5
9654 sed 's/^/| /' conftest.$ac_ext >&5
9655
9656   ac_header_preproc=no
9657 fi
9658 rm -f conftest.err conftest.$ac_ext
9659 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9660 echo "${ECHO_T}$ac_header_preproc" >&6
9661
9662 # So?  What about this header?
9663 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9664   yes:no: )
9665     { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
9666 echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9667     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
9668 echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
9669     ac_header_preproc=yes
9670     ;;
9671   no:yes:* )
9672     { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
9673 echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
9674     { echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
9675 echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
9676     { echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
9677 echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
9678     { echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
9679 echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9680     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
9681 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
9682     { echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
9683 echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
9684     (
9685       cat <<\_ASBOX
9686 ## ---------------------------------------- ##
9687 ## Report this to pgsql-bugs@postgresql.org ##
9688 ## ---------------------------------------- ##
9689 _ASBOX
9690     ) |
9691       sed "s/^/$as_me: WARNING:     /" >&2
9692     ;;
9693 esac
9694 echo "$as_me:$LINENO: checking for zlib.h" >&5
9695 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
9696 if test "${ac_cv_header_zlib_h+set}" = set; then
9697   echo $ECHO_N "(cached) $ECHO_C" >&6
9698 else
9699   ac_cv_header_zlib_h=$ac_header_preproc
9700 fi
9701 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
9702 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
9703
9704 fi
9705 if test $ac_cv_header_zlib_h = yes; then
9706   :
9707 else
9708   { { echo "$as_me:$LINENO: error: zlib header not found
9709 If you have zlib already installed, see config.log for details on the
9710 failure.  It is possible the compiler isn't looking in the proper directory.
9711 Use --without-zlib to disable zlib support." >&5
9712 echo "$as_me: error: zlib header not found
9713 If you have zlib already installed, see config.log for details on the
9714 failure.  It is possible the compiler isn't looking in the proper directory.
9715 Use --without-zlib to disable zlib support." >&2;}
9716    { (exit 1); exit 1; }; }
9717 fi
9718
9719
9720 fi
9721
9722 if test "$with_krb5" = yes ; then
9723   if test "${ac_cv_header_krb5_h+set}" = set; then
9724   echo "$as_me:$LINENO: checking for krb5.h" >&5
9725 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9726 if test "${ac_cv_header_krb5_h+set}" = set; then
9727   echo $ECHO_N "(cached) $ECHO_C" >&6
9728 fi
9729 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9730 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9731 else
9732   # Is the header compilable?
9733 echo "$as_me:$LINENO: checking krb5.h usability" >&5
9734 echo $ECHO_N "checking krb5.h usability... $ECHO_C" >&6
9735 cat >conftest.$ac_ext <<_ACEOF
9736 /* confdefs.h.  */
9737 _ACEOF
9738 cat confdefs.h >>conftest.$ac_ext
9739 cat >>conftest.$ac_ext <<_ACEOF
9740 /* end confdefs.h.  */
9741 $ac_includes_default
9742 #include <krb5.h>
9743 _ACEOF
9744 rm -f conftest.$ac_objext
9745 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9746   (eval $ac_compile) 2>conftest.er1
9747   ac_status=$?
9748   grep -v '^ *+' conftest.er1 >conftest.err
9749   rm -f conftest.er1
9750   cat conftest.err >&5
9751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9752   (exit $ac_status); } &&
9753          { ac_try='test -z "$ac_c_werror_flag"
9754                          || test ! -s conftest.err'
9755   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9756   (eval $ac_try) 2>&5
9757   ac_status=$?
9758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9759   (exit $ac_status); }; } &&
9760          { ac_try='test -s conftest.$ac_objext'
9761   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9762   (eval $ac_try) 2>&5
9763   ac_status=$?
9764   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9765   (exit $ac_status); }; }; then
9766   ac_header_compiler=yes
9767 else
9768   echo "$as_me: failed program was:" >&5
9769 sed 's/^/| /' conftest.$ac_ext >&5
9770
9771 ac_header_compiler=no
9772 fi
9773 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9774 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9775 echo "${ECHO_T}$ac_header_compiler" >&6
9776
9777 # Is the header present?
9778 echo "$as_me:$LINENO: checking krb5.h presence" >&5
9779 echo $ECHO_N "checking krb5.h presence... $ECHO_C" >&6
9780 cat >conftest.$ac_ext <<_ACEOF
9781 /* confdefs.h.  */
9782 _ACEOF
9783 cat confdefs.h >>conftest.$ac_ext
9784 cat >>conftest.$ac_ext <<_ACEOF
9785 /* end confdefs.h.  */
9786 #include <krb5.h>
9787 _ACEOF
9788 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9789   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9790   ac_status=$?
9791   grep -v '^ *+' conftest.er1 >conftest.err
9792   rm -f conftest.er1
9793   cat conftest.err >&5
9794   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9795   (exit $ac_status); } >/dev/null; then
9796   if test -s conftest.err; then
9797     ac_cpp_err=$ac_c_preproc_warn_flag
9798     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9799   else
9800     ac_cpp_err=
9801   fi
9802 else
9803   ac_cpp_err=yes
9804 fi
9805 if test -z "$ac_cpp_err"; then
9806   ac_header_preproc=yes
9807 else
9808   echo "$as_me: failed program was:" >&5
9809 sed 's/^/| /' conftest.$ac_ext >&5
9810
9811   ac_header_preproc=no
9812 fi
9813 rm -f conftest.err conftest.$ac_ext
9814 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9815 echo "${ECHO_T}$ac_header_preproc" >&6
9816
9817 # So?  What about this header?
9818 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9819   yes:no: )
9820     { echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
9821 echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9822     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
9823 echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
9824     ac_header_preproc=yes
9825     ;;
9826   no:yes:* )
9827     { echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
9828 echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
9829     { echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
9830 echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
9831     { echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
9832 echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
9833     { echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
9834 echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9835     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
9836 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
9837     { echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
9838 echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
9839     (
9840       cat <<\_ASBOX
9841 ## ---------------------------------------- ##
9842 ## Report this to pgsql-bugs@postgresql.org ##
9843 ## ---------------------------------------- ##
9844 _ASBOX
9845     ) |
9846       sed "s/^/$as_me: WARNING:     /" >&2
9847     ;;
9848 esac
9849 echo "$as_me:$LINENO: checking for krb5.h" >&5
9850 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9851 if test "${ac_cv_header_krb5_h+set}" = set; then
9852   echo $ECHO_N "(cached) $ECHO_C" >&6
9853 else
9854   ac_cv_header_krb5_h=$ac_header_preproc
9855 fi
9856 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9857 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9858
9859 fi
9860 if test $ac_cv_header_krb5_h = yes; then
9861   :
9862 else
9863   { { echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
9864 echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
9865    { (exit 1); exit 1; }; }
9866 fi
9867
9868
9869 fi
9870
9871 if test "$with_openssl" = yes ; then
9872   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9873   echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9874 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9875 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9876   echo $ECHO_N "(cached) $ECHO_C" >&6
9877 fi
9878 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9879 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9880 else
9881   # Is the header compilable?
9882 echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
9883 echo $ECHO_N "checking openssl/ssl.h usability... $ECHO_C" >&6
9884 cat >conftest.$ac_ext <<_ACEOF
9885 /* confdefs.h.  */
9886 _ACEOF
9887 cat confdefs.h >>conftest.$ac_ext
9888 cat >>conftest.$ac_ext <<_ACEOF
9889 /* end confdefs.h.  */
9890 $ac_includes_default
9891 #include <openssl/ssl.h>
9892 _ACEOF
9893 rm -f conftest.$ac_objext
9894 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9895   (eval $ac_compile) 2>conftest.er1
9896   ac_status=$?
9897   grep -v '^ *+' conftest.er1 >conftest.err
9898   rm -f conftest.er1
9899   cat conftest.err >&5
9900   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9901   (exit $ac_status); } &&
9902          { ac_try='test -z "$ac_c_werror_flag"
9903                          || test ! -s conftest.err'
9904   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9905   (eval $ac_try) 2>&5
9906   ac_status=$?
9907   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9908   (exit $ac_status); }; } &&
9909          { ac_try='test -s conftest.$ac_objext'
9910   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9911   (eval $ac_try) 2>&5
9912   ac_status=$?
9913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9914   (exit $ac_status); }; }; then
9915   ac_header_compiler=yes
9916 else
9917   echo "$as_me: failed program was:" >&5
9918 sed 's/^/| /' conftest.$ac_ext >&5
9919
9920 ac_header_compiler=no
9921 fi
9922 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9923 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9924 echo "${ECHO_T}$ac_header_compiler" >&6
9925
9926 # Is the header present?
9927 echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
9928 echo $ECHO_N "checking openssl/ssl.h presence... $ECHO_C" >&6
9929 cat >conftest.$ac_ext <<_ACEOF
9930 /* confdefs.h.  */
9931 _ACEOF
9932 cat confdefs.h >>conftest.$ac_ext
9933 cat >>conftest.$ac_ext <<_ACEOF
9934 /* end confdefs.h.  */
9935 #include <openssl/ssl.h>
9936 _ACEOF
9937 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9938   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9939   ac_status=$?
9940   grep -v '^ *+' conftest.er1 >conftest.err
9941   rm -f conftest.er1
9942   cat conftest.err >&5
9943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9944   (exit $ac_status); } >/dev/null; then
9945   if test -s conftest.err; then
9946     ac_cpp_err=$ac_c_preproc_warn_flag
9947     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9948   else
9949     ac_cpp_err=
9950   fi
9951 else
9952   ac_cpp_err=yes
9953 fi
9954 if test -z "$ac_cpp_err"; then
9955   ac_header_preproc=yes
9956 else
9957   echo "$as_me: failed program was:" >&5
9958 sed 's/^/| /' conftest.$ac_ext >&5
9959
9960   ac_header_preproc=no
9961 fi
9962 rm -f conftest.err conftest.$ac_ext
9963 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9964 echo "${ECHO_T}$ac_header_preproc" >&6
9965
9966 # So?  What about this header?
9967 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9968   yes:no: )
9969     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
9970 echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9971     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
9972 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
9973     ac_header_preproc=yes
9974     ;;
9975   no:yes:* )
9976     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
9977 echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
9978     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
9979 echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
9980     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
9981 echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
9982     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
9983 echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9984     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
9985 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
9986     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
9987 echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
9988     (
9989       cat <<\_ASBOX
9990 ## ---------------------------------------- ##
9991 ## Report this to pgsql-bugs@postgresql.org ##
9992 ## ---------------------------------------- ##
9993 _ASBOX
9994     ) |
9995       sed "s/^/$as_me: WARNING:     /" >&2
9996     ;;
9997 esac
9998 echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9999 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
10000 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
10001   echo $ECHO_N "(cached) $ECHO_C" >&6
10002 else
10003   ac_cv_header_openssl_ssl_h=$ac_header_preproc
10004 fi
10005 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
10006 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
10007
10008 fi
10009 if test $ac_cv_header_openssl_ssl_h = yes; then
10010   :
10011 else
10012   { { echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
10013 echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
10014    { (exit 1); exit 1; }; }
10015 fi
10016
10017
10018   if test "${ac_cv_header_openssl_err_h+set}" = set; then
10019   echo "$as_me:$LINENO: checking for openssl/err.h" >&5
10020 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
10021 if test "${ac_cv_header_openssl_err_h+set}" = set; then
10022   echo $ECHO_N "(cached) $ECHO_C" >&6
10023 fi
10024 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
10025 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
10026 else
10027   # Is the header compilable?
10028 echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
10029 echo $ECHO_N "checking openssl/err.h usability... $ECHO_C" >&6
10030 cat >conftest.$ac_ext <<_ACEOF
10031 /* confdefs.h.  */
10032 _ACEOF
10033 cat confdefs.h >>conftest.$ac_ext
10034 cat >>conftest.$ac_ext <<_ACEOF
10035 /* end confdefs.h.  */
10036 $ac_includes_default
10037 #include <openssl/err.h>
10038 _ACEOF
10039 rm -f conftest.$ac_objext
10040 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10041   (eval $ac_compile) 2>conftest.er1
10042   ac_status=$?
10043   grep -v '^ *+' conftest.er1 >conftest.err
10044   rm -f conftest.er1
10045   cat conftest.err >&5
10046   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10047   (exit $ac_status); } &&
10048          { ac_try='test -z "$ac_c_werror_flag"
10049                          || test ! -s conftest.err'
10050   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10051   (eval $ac_try) 2>&5
10052   ac_status=$?
10053   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10054   (exit $ac_status); }; } &&
10055          { ac_try='test -s conftest.$ac_objext'
10056   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10057   (eval $ac_try) 2>&5
10058   ac_status=$?
10059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10060   (exit $ac_status); }; }; then
10061   ac_header_compiler=yes
10062 else
10063   echo "$as_me: failed program was:" >&5
10064 sed 's/^/| /' conftest.$ac_ext >&5
10065
10066 ac_header_compiler=no
10067 fi
10068 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10069 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10070 echo "${ECHO_T}$ac_header_compiler" >&6
10071
10072 # Is the header present?
10073 echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
10074 echo $ECHO_N "checking openssl/err.h presence... $ECHO_C" >&6
10075 cat >conftest.$ac_ext <<_ACEOF
10076 /* confdefs.h.  */
10077 _ACEOF
10078 cat confdefs.h >>conftest.$ac_ext
10079 cat >>conftest.$ac_ext <<_ACEOF
10080 /* end confdefs.h.  */
10081 #include <openssl/err.h>
10082 _ACEOF
10083 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10084   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10085   ac_status=$?
10086   grep -v '^ *+' conftest.er1 >conftest.err
10087   rm -f conftest.er1
10088   cat conftest.err >&5
10089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10090   (exit $ac_status); } >/dev/null; then
10091   if test -s conftest.err; then
10092     ac_cpp_err=$ac_c_preproc_warn_flag
10093     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10094   else
10095     ac_cpp_err=
10096   fi
10097 else
10098   ac_cpp_err=yes
10099 fi
10100 if test -z "$ac_cpp_err"; then
10101   ac_header_preproc=yes
10102 else
10103   echo "$as_me: failed program was:" >&5
10104 sed 's/^/| /' conftest.$ac_ext >&5
10105
10106   ac_header_preproc=no
10107 fi
10108 rm -f conftest.err conftest.$ac_ext
10109 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10110 echo "${ECHO_T}$ac_header_preproc" >&6
10111
10112 # So?  What about this header?
10113 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10114   yes:no: )
10115     { echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
10116 echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10117     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
10118 echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
10119     ac_header_preproc=yes
10120     ;;
10121   no:yes:* )
10122     { echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
10123 echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
10124     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
10125 echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
10126     { echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
10127 echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
10128     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
10129 echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10130     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
10131 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
10132     { echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
10133 echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
10134     (
10135       cat <<\_ASBOX
10136 ## ---------------------------------------- ##
10137 ## Report this to pgsql-bugs@postgresql.org ##
10138 ## ---------------------------------------- ##
10139 _ASBOX
10140     ) |
10141       sed "s/^/$as_me: WARNING:     /" >&2
10142     ;;
10143 esac
10144 echo "$as_me:$LINENO: checking for openssl/err.h" >&5
10145 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
10146 if test "${ac_cv_header_openssl_err_h+set}" = set; then
10147   echo $ECHO_N "(cached) $ECHO_C" >&6
10148 else
10149   ac_cv_header_openssl_err_h=$ac_header_preproc
10150 fi
10151 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
10152 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
10153
10154 fi
10155 if test $ac_cv_header_openssl_err_h = yes; then
10156   :
10157 else
10158   { { echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
10159 echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
10160    { (exit 1); exit 1; }; }
10161 fi
10162
10163
10164 fi
10165
10166 if test "$with_pam" = yes ; then
10167
10168 for ac_header in security/pam_appl.h
10169 do
10170 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10171 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10172   echo "$as_me:$LINENO: checking for $ac_header" >&5
10173 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10174 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10175   echo $ECHO_N "(cached) $ECHO_C" >&6
10176 fi
10177 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10178 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10179 else
10180   # Is the header compilable?
10181 echo "$as_me:$LINENO: checking $ac_header usability" >&5
10182 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10183 cat >conftest.$ac_ext <<_ACEOF
10184 /* confdefs.h.  */
10185 _ACEOF
10186 cat confdefs.h >>conftest.$ac_ext
10187 cat >>conftest.$ac_ext <<_ACEOF
10188 /* end confdefs.h.  */
10189 $ac_includes_default
10190 #include <$ac_header>
10191 _ACEOF
10192 rm -f conftest.$ac_objext
10193 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10194   (eval $ac_compile) 2>conftest.er1
10195   ac_status=$?
10196   grep -v '^ *+' conftest.er1 >conftest.err
10197   rm -f conftest.er1
10198   cat conftest.err >&5
10199   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10200   (exit $ac_status); } &&
10201          { ac_try='test -z "$ac_c_werror_flag"
10202                          || test ! -s conftest.err'
10203   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10204   (eval $ac_try) 2>&5
10205   ac_status=$?
10206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10207   (exit $ac_status); }; } &&
10208          { ac_try='test -s conftest.$ac_objext'
10209   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10210   (eval $ac_try) 2>&5
10211   ac_status=$?
10212   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10213   (exit $ac_status); }; }; then
10214   ac_header_compiler=yes
10215 else
10216   echo "$as_me: failed program was:" >&5
10217 sed 's/^/| /' conftest.$ac_ext >&5
10218
10219 ac_header_compiler=no
10220 fi
10221 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10222 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10223 echo "${ECHO_T}$ac_header_compiler" >&6
10224
10225 # Is the header present?
10226 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10227 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10228 cat >conftest.$ac_ext <<_ACEOF
10229 /* confdefs.h.  */
10230 _ACEOF
10231 cat confdefs.h >>conftest.$ac_ext
10232 cat >>conftest.$ac_ext <<_ACEOF
10233 /* end confdefs.h.  */
10234 #include <$ac_header>
10235 _ACEOF
10236 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10237   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10238   ac_status=$?
10239   grep -v '^ *+' conftest.er1 >conftest.err
10240   rm -f conftest.er1
10241   cat conftest.err >&5
10242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10243   (exit $ac_status); } >/dev/null; then
10244   if test -s conftest.err; then
10245     ac_cpp_err=$ac_c_preproc_warn_flag
10246     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10247   else
10248     ac_cpp_err=
10249   fi
10250 else
10251   ac_cpp_err=yes
10252 fi
10253 if test -z "$ac_cpp_err"; then
10254   ac_header_preproc=yes
10255 else
10256   echo "$as_me: failed program was:" >&5
10257 sed 's/^/| /' conftest.$ac_ext >&5
10258
10259   ac_header_preproc=no
10260 fi
10261 rm -f conftest.err conftest.$ac_ext
10262 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10263 echo "${ECHO_T}$ac_header_preproc" >&6
10264
10265 # So?  What about this header?
10266 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10267   yes:no: )
10268     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10269 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10270     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10271 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10272     ac_header_preproc=yes
10273     ;;
10274   no:yes:* )
10275     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10276 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10277     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10278 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10279     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10280 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10281     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10282 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10283     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10284 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10285     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10286 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10287     (
10288       cat <<\_ASBOX
10289 ## ---------------------------------------- ##
10290 ## Report this to pgsql-bugs@postgresql.org ##
10291 ## ---------------------------------------- ##
10292 _ASBOX
10293     ) |
10294       sed "s/^/$as_me: WARNING:     /" >&2
10295     ;;
10296 esac
10297 echo "$as_me:$LINENO: checking for $ac_header" >&5
10298 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10299 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10300   echo $ECHO_N "(cached) $ECHO_C" >&6
10301 else
10302   eval "$as_ac_Header=\$ac_header_preproc"
10303 fi
10304 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10305 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10306
10307 fi
10308 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10309   cat >>confdefs.h <<_ACEOF
10310 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10311 _ACEOF
10312
10313 else
10314
10315 for ac_header in pam/pam_appl.h
10316 do
10317 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10318 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10319   echo "$as_me:$LINENO: checking for $ac_header" >&5
10320 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10321 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10322   echo $ECHO_N "(cached) $ECHO_C" >&6
10323 fi
10324 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10325 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10326 else
10327   # Is the header compilable?
10328 echo "$as_me:$LINENO: checking $ac_header usability" >&5
10329 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10330 cat >conftest.$ac_ext <<_ACEOF
10331 /* confdefs.h.  */
10332 _ACEOF
10333 cat confdefs.h >>conftest.$ac_ext
10334 cat >>conftest.$ac_ext <<_ACEOF
10335 /* end confdefs.h.  */
10336 $ac_includes_default
10337 #include <$ac_header>
10338 _ACEOF
10339 rm -f conftest.$ac_objext
10340 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10341   (eval $ac_compile) 2>conftest.er1
10342   ac_status=$?
10343   grep -v '^ *+' conftest.er1 >conftest.err
10344   rm -f conftest.er1
10345   cat conftest.err >&5
10346   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10347   (exit $ac_status); } &&
10348          { ac_try='test -z "$ac_c_werror_flag"
10349                          || test ! -s conftest.err'
10350   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10351   (eval $ac_try) 2>&5
10352   ac_status=$?
10353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10354   (exit $ac_status); }; } &&
10355          { ac_try='test -s conftest.$ac_objext'
10356   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10357   (eval $ac_try) 2>&5
10358   ac_status=$?
10359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10360   (exit $ac_status); }; }; then
10361   ac_header_compiler=yes
10362 else
10363   echo "$as_me: failed program was:" >&5
10364 sed 's/^/| /' conftest.$ac_ext >&5
10365
10366 ac_header_compiler=no
10367 fi
10368 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10369 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10370 echo "${ECHO_T}$ac_header_compiler" >&6
10371
10372 # Is the header present?
10373 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10374 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10375 cat >conftest.$ac_ext <<_ACEOF
10376 /* confdefs.h.  */
10377 _ACEOF
10378 cat confdefs.h >>conftest.$ac_ext
10379 cat >>conftest.$ac_ext <<_ACEOF
10380 /* end confdefs.h.  */
10381 #include <$ac_header>
10382 _ACEOF
10383 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10384   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10385   ac_status=$?
10386   grep -v '^ *+' conftest.er1 >conftest.err
10387   rm -f conftest.er1
10388   cat conftest.err >&5
10389   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10390   (exit $ac_status); } >/dev/null; then
10391   if test -s conftest.err; then
10392     ac_cpp_err=$ac_c_preproc_warn_flag
10393     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10394   else
10395     ac_cpp_err=
10396   fi
10397 else
10398   ac_cpp_err=yes
10399 fi
10400 if test -z "$ac_cpp_err"; then
10401   ac_header_preproc=yes
10402 else
10403   echo "$as_me: failed program was:" >&5
10404 sed 's/^/| /' conftest.$ac_ext >&5
10405
10406   ac_header_preproc=no
10407 fi
10408 rm -f conftest.err conftest.$ac_ext
10409 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10410 echo "${ECHO_T}$ac_header_preproc" >&6
10411
10412 # So?  What about this header?
10413 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10414   yes:no: )
10415     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10416 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10417     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10418 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10419     ac_header_preproc=yes
10420     ;;
10421   no:yes:* )
10422     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10423 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10424     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10425 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10426     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10427 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10428     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10429 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10430     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10431 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10432     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10433 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10434     (
10435       cat <<\_ASBOX
10436 ## ---------------------------------------- ##
10437 ## Report this to pgsql-bugs@postgresql.org ##
10438 ## ---------------------------------------- ##
10439 _ASBOX
10440     ) |
10441       sed "s/^/$as_me: WARNING:     /" >&2
10442     ;;
10443 esac
10444 echo "$as_me:$LINENO: checking for $ac_header" >&5
10445 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10446 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10447   echo $ECHO_N "(cached) $ECHO_C" >&6
10448 else
10449   eval "$as_ac_Header=\$ac_header_preproc"
10450 fi
10451 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10452 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10453
10454 fi
10455 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10456   cat >>confdefs.h <<_ACEOF
10457 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10458 _ACEOF
10459
10460 else
10461   { { echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
10462 echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
10463    { (exit 1); exit 1; }; }
10464 fi
10465
10466 done
10467
10468 fi
10469
10470 done
10471
10472 fi
10473
10474 if test "$with_ldap" = yes ; then
10475   if test "$PORTNAME" != "win32"; then
10476
10477 for ac_header in ldap.h
10478 do
10479 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10480 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10481   echo "$as_me:$LINENO: checking for $ac_header" >&5
10482 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10483 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10484   echo $ECHO_N "(cached) $ECHO_C" >&6
10485 fi
10486 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10487 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10488 else
10489   # Is the header compilable?
10490 echo "$as_me:$LINENO: checking $ac_header usability" >&5
10491 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10492 cat >conftest.$ac_ext <<_ACEOF
10493 /* confdefs.h.  */
10494 _ACEOF
10495 cat confdefs.h >>conftest.$ac_ext
10496 cat >>conftest.$ac_ext <<_ACEOF
10497 /* end confdefs.h.  */
10498 $ac_includes_default
10499 #include <$ac_header>
10500 _ACEOF
10501 rm -f conftest.$ac_objext
10502 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10503   (eval $ac_compile) 2>conftest.er1
10504   ac_status=$?
10505   grep -v '^ *+' conftest.er1 >conftest.err
10506   rm -f conftest.er1
10507   cat conftest.err >&5
10508   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10509   (exit $ac_status); } &&
10510          { ac_try='test -z "$ac_c_werror_flag"
10511                          || test ! -s conftest.err'
10512   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10513   (eval $ac_try) 2>&5
10514   ac_status=$?
10515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10516   (exit $ac_status); }; } &&
10517          { ac_try='test -s conftest.$ac_objext'
10518   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10519   (eval $ac_try) 2>&5
10520   ac_status=$?
10521   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10522   (exit $ac_status); }; }; then
10523   ac_header_compiler=yes
10524 else
10525   echo "$as_me: failed program was:" >&5
10526 sed 's/^/| /' conftest.$ac_ext >&5
10527
10528 ac_header_compiler=no
10529 fi
10530 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10531 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10532 echo "${ECHO_T}$ac_header_compiler" >&6
10533
10534 # Is the header present?
10535 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10536 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10537 cat >conftest.$ac_ext <<_ACEOF
10538 /* confdefs.h.  */
10539 _ACEOF
10540 cat confdefs.h >>conftest.$ac_ext
10541 cat >>conftest.$ac_ext <<_ACEOF
10542 /* end confdefs.h.  */
10543 #include <$ac_header>
10544 _ACEOF
10545 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10546   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10547   ac_status=$?
10548   grep -v '^ *+' conftest.er1 >conftest.err
10549   rm -f conftest.er1
10550   cat conftest.err >&5
10551   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10552   (exit $ac_status); } >/dev/null; then
10553   if test -s conftest.err; then
10554     ac_cpp_err=$ac_c_preproc_warn_flag
10555     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10556   else
10557     ac_cpp_err=
10558   fi
10559 else
10560   ac_cpp_err=yes
10561 fi
10562 if test -z "$ac_cpp_err"; then
10563   ac_header_preproc=yes
10564 else
10565   echo "$as_me: failed program was:" >&5
10566 sed 's/^/| /' conftest.$ac_ext >&5
10567
10568   ac_header_preproc=no
10569 fi
10570 rm -f conftest.err conftest.$ac_ext
10571 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10572 echo "${ECHO_T}$ac_header_preproc" >&6
10573
10574 # So?  What about this header?
10575 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10576   yes:no: )
10577     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10578 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10579     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10580 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10581     ac_header_preproc=yes
10582     ;;
10583   no:yes:* )
10584     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10585 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10586     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10587 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10588     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10589 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10590     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10591 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10592     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10593 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10594     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10595 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10596     (
10597       cat <<\_ASBOX
10598 ## ---------------------------------------- ##
10599 ## Report this to pgsql-bugs@postgresql.org ##
10600 ## ---------------------------------------- ##
10601 _ASBOX
10602     ) |
10603       sed "s/^/$as_me: WARNING:     /" >&2
10604     ;;
10605 esac
10606 echo "$as_me:$LINENO: checking for $ac_header" >&5
10607 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10608 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10609   echo $ECHO_N "(cached) $ECHO_C" >&6
10610 else
10611   eval "$as_ac_Header=\$ac_header_preproc"
10612 fi
10613 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10614 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10615
10616 fi
10617 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10618   cat >>confdefs.h <<_ACEOF
10619 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10620 _ACEOF
10621
10622 else
10623   { { echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
10624 echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
10625    { (exit 1); exit 1; }; }
10626 fi
10627
10628 done
10629
10630   else
10631
10632 for ac_header in winldap.h
10633 do
10634 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10635 echo "$as_me:$LINENO: checking for $ac_header" >&5
10636 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10637 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10638   echo $ECHO_N "(cached) $ECHO_C" >&6
10639 else
10640   cat >conftest.$ac_ext <<_ACEOF
10641 /* confdefs.h.  */
10642 _ACEOF
10643 cat confdefs.h >>conftest.$ac_ext
10644 cat >>conftest.$ac_ext <<_ACEOF
10645 /* end confdefs.h.  */
10646 $ac_includes_default
10647 #include <windows.h>
10648
10649
10650 #include <$ac_header>
10651 _ACEOF
10652 rm -f conftest.$ac_objext
10653 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10654   (eval $ac_compile) 2>conftest.er1
10655   ac_status=$?
10656   grep -v '^ *+' conftest.er1 >conftest.err
10657   rm -f conftest.er1
10658   cat conftest.err >&5
10659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10660   (exit $ac_status); } &&
10661          { ac_try='test -z "$ac_c_werror_flag"
10662                          || test ! -s conftest.err'
10663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10664   (eval $ac_try) 2>&5
10665   ac_status=$?
10666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10667   (exit $ac_status); }; } &&
10668          { ac_try='test -s conftest.$ac_objext'
10669   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10670   (eval $ac_try) 2>&5
10671   ac_status=$?
10672   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10673   (exit $ac_status); }; }; then
10674   eval "$as_ac_Header=yes"
10675 else
10676   echo "$as_me: failed program was:" >&5
10677 sed 's/^/| /' conftest.$ac_ext >&5
10678
10679 eval "$as_ac_Header=no"
10680 fi
10681 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10682 fi
10683 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10684 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10685 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10686   cat >>confdefs.h <<_ACEOF
10687 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10688 _ACEOF
10689
10690 else
10691   { { echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
10692 echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
10693    { (exit 1); exit 1; }; }
10694 fi
10695
10696 done
10697
10698   fi
10699 fi
10700
10701 if test "$with_bonjour" = yes ; then
10702   if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10703   echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
10704 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
10705 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10706   echo $ECHO_N "(cached) $ECHO_C" >&6
10707 fi
10708 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
10709 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
10710 else
10711   # Is the header compilable?
10712 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h usability" >&5
10713 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h usability... $ECHO_C" >&6
10714 cat >conftest.$ac_ext <<_ACEOF
10715 /* confdefs.h.  */
10716 _ACEOF
10717 cat confdefs.h >>conftest.$ac_ext
10718 cat >>conftest.$ac_ext <<_ACEOF
10719 /* end confdefs.h.  */
10720 $ac_includes_default
10721 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
10722 _ACEOF
10723 rm -f conftest.$ac_objext
10724 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10725   (eval $ac_compile) 2>conftest.er1
10726   ac_status=$?
10727   grep -v '^ *+' conftest.er1 >conftest.err
10728   rm -f conftest.er1
10729   cat conftest.err >&5
10730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10731   (exit $ac_status); } &&
10732          { ac_try='test -z "$ac_c_werror_flag"
10733                          || test ! -s conftest.err'
10734   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10735   (eval $ac_try) 2>&5
10736   ac_status=$?
10737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10738   (exit $ac_status); }; } &&
10739          { ac_try='test -s conftest.$ac_objext'
10740   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10741   (eval $ac_try) 2>&5
10742   ac_status=$?
10743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10744   (exit $ac_status); }; }; then
10745   ac_header_compiler=yes
10746 else
10747   echo "$as_me: failed program was:" >&5
10748 sed 's/^/| /' conftest.$ac_ext >&5
10749
10750 ac_header_compiler=no
10751 fi
10752 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10753 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10754 echo "${ECHO_T}$ac_header_compiler" >&6
10755
10756 # Is the header present?
10757 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h presence" >&5
10758 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h presence... $ECHO_C" >&6
10759 cat >conftest.$ac_ext <<_ACEOF
10760 /* confdefs.h.  */
10761 _ACEOF
10762 cat confdefs.h >>conftest.$ac_ext
10763 cat >>conftest.$ac_ext <<_ACEOF
10764 /* end confdefs.h.  */
10765 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
10766 _ACEOF
10767 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10768   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10769   ac_status=$?
10770   grep -v '^ *+' conftest.er1 >conftest.err
10771   rm -f conftest.er1
10772   cat conftest.err >&5
10773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10774   (exit $ac_status); } >/dev/null; then
10775   if test -s conftest.err; then
10776     ac_cpp_err=$ac_c_preproc_warn_flag
10777     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10778   else
10779     ac_cpp_err=
10780   fi
10781 else
10782   ac_cpp_err=yes
10783 fi
10784 if test -z "$ac_cpp_err"; then
10785   ac_header_preproc=yes
10786 else
10787   echo "$as_me: failed program was:" >&5
10788 sed 's/^/| /' conftest.$ac_ext >&5
10789
10790   ac_header_preproc=no
10791 fi
10792 rm -f conftest.err conftest.$ac_ext
10793 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10794 echo "${ECHO_T}$ac_header_preproc" >&6
10795
10796 # So?  What about this header?
10797 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10798   yes:no: )
10799     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&5
10800 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10801     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&5
10802 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&2;}
10803     ac_header_preproc=yes
10804     ;;
10805   no:yes:* )
10806     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&5
10807 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&2;}
10808     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&5
10809 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&2;}
10810     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&5
10811 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&2;}
10812     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&5
10813 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10814     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
10815 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;}
10816     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&5
10817 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&2;}
10818     (
10819       cat <<\_ASBOX
10820 ## ---------------------------------------- ##
10821 ## Report this to pgsql-bugs@postgresql.org ##
10822 ## ---------------------------------------- ##
10823 _ASBOX
10824     ) |
10825       sed "s/^/$as_me: WARNING:     /" >&2
10826     ;;
10827 esac
10828 echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
10829 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
10830 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10831   echo $ECHO_N "(cached) $ECHO_C" >&6
10832 else
10833   ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h=$ac_header_preproc
10834 fi
10835 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
10836 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
10837
10838 fi
10839 if test $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h = yes; then
10840   :
10841 else
10842   { { echo "$as_me:$LINENO: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&5
10843 echo "$as_me: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&2;}
10844    { (exit 1); exit 1; }; }
10845 fi
10846
10847
10848 fi
10849
10850
10851 ##
10852 ## Types, structures, compiler characteristics
10853 ##
10854
10855  echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
10856 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
10857 if test "${ac_cv_c_const+set}" = set; then
10858   echo $ECHO_N "(cached) $ECHO_C" >&6
10859 else
10860   cat >conftest.$ac_ext <<_ACEOF
10861 /* confdefs.h.  */
10862 _ACEOF
10863 cat confdefs.h >>conftest.$ac_ext
10864 cat >>conftest.$ac_ext <<_ACEOF
10865 /* end confdefs.h.  */
10866
10867 int
10868 main ()
10869 {
10870 /* FIXME: Include the comments suggested by Paul. */
10871 #ifndef __cplusplus
10872   /* Ultrix mips cc rejects this.  */
10873   typedef int charset[2];
10874   const charset x;
10875   /* SunOS 4.1.1 cc rejects this.  */
10876   char const *const *ccp;
10877   char **p;
10878   /* NEC SVR4.0.2 mips cc rejects this.  */
10879   struct point {int x, y;};
10880   static struct point const zero = {0,0};
10881   /* AIX XL C 1.02.0.0 rejects this.
10882      It does not let you subtract one const X* pointer from another in
10883      an arm of an if-expression whose if-part is not a constant
10884      expression */
10885   const char *g = "string";
10886   ccp = &g + (g ? g-g : 0);
10887   /* HPUX 7.0 cc rejects these. */
10888   ++ccp;
10889   p = (char**) ccp;
10890   ccp = (char const *const *) p;
10891   { /* SCO 3.2v4 cc rejects this.  */
10892     char *t;
10893     char const *s = 0 ? (char *) 0 : (char const *) 0;
10894
10895     *t++ = 0;
10896   }
10897   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
10898     int x[] = {25, 17};
10899     const int *foo = &x[0];
10900     ++foo;
10901   }
10902   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
10903     typedef const int *iptr;
10904     iptr p = 0;
10905     ++p;
10906   }
10907   { /* AIX XL C 1.02.0.0 rejects this saying
10908        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
10909     struct s { int j; const int *ap[3]; };
10910     struct s *b; b->j = 5;
10911   }
10912   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
10913     const int foo = 10;
10914   }
10915 #endif
10916
10917   ;
10918   return 0;
10919 }
10920 _ACEOF
10921 rm -f conftest.$ac_objext
10922 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10923   (eval $ac_compile) 2>conftest.er1
10924   ac_status=$?
10925   grep -v '^ *+' conftest.er1 >conftest.err
10926   rm -f conftest.er1
10927   cat conftest.err >&5
10928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10929   (exit $ac_status); } &&
10930          { ac_try='test -z "$ac_c_werror_flag"
10931                          || test ! -s conftest.err'
10932   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10933   (eval $ac_try) 2>&5
10934   ac_status=$?
10935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10936   (exit $ac_status); }; } &&
10937          { ac_try='test -s conftest.$ac_objext'
10938   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10939   (eval $ac_try) 2>&5
10940   ac_status=$?
10941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10942   (exit $ac_status); }; }; then
10943   ac_cv_c_const=yes
10944 else
10945   echo "$as_me: failed program was:" >&5
10946 sed 's/^/| /' conftest.$ac_ext >&5
10947
10948 ac_cv_c_const=no
10949 fi
10950 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10951 fi
10952 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
10953 echo "${ECHO_T}$ac_cv_c_const" >&6
10954 if test $ac_cv_c_const = no; then
10955
10956 cat >>confdefs.h <<\_ACEOF
10957 #define const
10958 _ACEOF
10959
10960 fi
10961
10962
10963 echo "$as_me:$LINENO: checking for inline" >&5
10964 echo $ECHO_N "checking for inline... $ECHO_C" >&6
10965 if test "${ac_cv_c_inline+set}" = set; then
10966   echo $ECHO_N "(cached) $ECHO_C" >&6
10967 else
10968   ac_cv_c_inline=no
10969 for ac_kw in inline __inline__ __inline; do
10970   cat >conftest.$ac_ext <<_ACEOF
10971 /* confdefs.h.  */
10972 _ACEOF
10973 cat confdefs.h >>conftest.$ac_ext
10974 cat >>conftest.$ac_ext <<_ACEOF
10975 /* end confdefs.h.  */
10976 #ifndef __cplusplus
10977 typedef int foo_t;
10978 static $ac_kw foo_t static_foo () {return 0; }
10979 $ac_kw int foo () {return 0; }
10980 #endif
10981
10982 _ACEOF
10983 rm -f conftest.$ac_objext
10984 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10985   (eval $ac_compile) 2>conftest.er1
10986   ac_status=$?
10987   grep -v '^ *+' conftest.er1 >conftest.err
10988   rm -f conftest.er1
10989   cat conftest.err >&5
10990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10991   (exit $ac_status); } &&
10992          { ac_try='test -z "$ac_c_werror_flag"
10993                          || test ! -s conftest.err'
10994   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10995   (eval $ac_try) 2>&5
10996   ac_status=$?
10997   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10998   (exit $ac_status); }; } &&
10999          { ac_try='test -s conftest.$ac_objext'
11000   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11001   (eval $ac_try) 2>&5
11002   ac_status=$?
11003   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11004   (exit $ac_status); }; }; then
11005   ac_cv_c_inline=$ac_kw; break
11006 else
11007   echo "$as_me: failed program was:" >&5
11008 sed 's/^/| /' conftest.$ac_ext >&5
11009
11010 fi
11011 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11012 done
11013
11014 fi
11015 echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
11016 echo "${ECHO_T}$ac_cv_c_inline" >&6
11017 case $ac_cv_c_inline in
11018   inline | yes) ;;
11019   no)
11020 cat >>confdefs.h <<\_ACEOF
11021 #define inline
11022 _ACEOF
11023  ;;
11024   *)  cat >>confdefs.h <<_ACEOF
11025 #define inline $ac_cv_c_inline
11026 _ACEOF
11027  ;;
11028 esac
11029
11030 echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
11031 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6
11032 if test "${ac_cv_c_stringize+set}" = set; then
11033   echo $ECHO_N "(cached) $ECHO_C" >&6
11034 else
11035   cat >conftest.$ac_ext <<_ACEOF
11036 /* confdefs.h.  */
11037 _ACEOF
11038 cat confdefs.h >>conftest.$ac_ext
11039 cat >>conftest.$ac_ext <<_ACEOF
11040 /* end confdefs.h.  */
11041 #define x(y) #y
11042
11043 char *s = x(teststring);
11044 _ACEOF
11045 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11046   $EGREP "#teststring" >/dev/null 2>&1; then
11047   ac_cv_c_stringize=no
11048 else
11049   ac_cv_c_stringize=yes
11050 fi
11051 rm -f conftest*
11052
11053 fi
11054 echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
11055 echo "${ECHO_T}$ac_cv_c_stringize" >&6
11056 if test $ac_cv_c_stringize = yes; then
11057
11058 cat >>confdefs.h <<\_ACEOF
11059 #define HAVE_STRINGIZE 1
11060 _ACEOF
11061
11062 fi
11063
11064 echo "$as_me:$LINENO: checking for signed types" >&5
11065 echo $ECHO_N "checking for signed types... $ECHO_C" >&6
11066 if test "${pgac_cv_c_signed+set}" = set; then
11067   echo $ECHO_N "(cached) $ECHO_C" >&6
11068 else
11069   cat >conftest.$ac_ext <<_ACEOF
11070 /* confdefs.h.  */
11071 _ACEOF
11072 cat confdefs.h >>conftest.$ac_ext
11073 cat >>conftest.$ac_ext <<_ACEOF
11074 /* end confdefs.h.  */
11075
11076 int
11077 main ()
11078 {
11079 signed char c; signed short s; signed int i;
11080   ;
11081   return 0;
11082 }
11083 _ACEOF
11084 rm -f conftest.$ac_objext
11085 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11086   (eval $ac_compile) 2>conftest.er1
11087   ac_status=$?
11088   grep -v '^ *+' conftest.er1 >conftest.err
11089   rm -f conftest.er1
11090   cat conftest.err >&5
11091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11092   (exit $ac_status); } &&
11093          { ac_try='test -z "$ac_c_werror_flag"
11094                          || test ! -s conftest.err'
11095   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11096   (eval $ac_try) 2>&5
11097   ac_status=$?
11098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11099   (exit $ac_status); }; } &&
11100          { ac_try='test -s conftest.$ac_objext'
11101   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11102   (eval $ac_try) 2>&5
11103   ac_status=$?
11104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11105   (exit $ac_status); }; }; then
11106   pgac_cv_c_signed=yes
11107 else
11108   echo "$as_me: failed program was:" >&5
11109 sed 's/^/| /' conftest.$ac_ext >&5
11110
11111 pgac_cv_c_signed=no
11112 fi
11113 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11114 fi
11115 echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
11116 echo "${ECHO_T}$pgac_cv_c_signed" >&6
11117 if test x"$pgac_cv_c_signed" = xno ; then
11118
11119 cat >>confdefs.h <<\_ACEOF
11120 #define signed
11121 _ACEOF
11122
11123 fi
11124 echo "$as_me:$LINENO: checking for working volatile" >&5
11125 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
11126 if test "${ac_cv_c_volatile+set}" = set; then
11127   echo $ECHO_N "(cached) $ECHO_C" >&6
11128 else
11129   cat >conftest.$ac_ext <<_ACEOF
11130 /* confdefs.h.  */
11131 _ACEOF
11132 cat confdefs.h >>conftest.$ac_ext
11133 cat >>conftest.$ac_ext <<_ACEOF
11134 /* end confdefs.h.  */
11135
11136 int
11137 main ()
11138 {
11139
11140 volatile int x;
11141 int * volatile y;
11142   ;
11143   return 0;
11144 }
11145 _ACEOF
11146 rm -f conftest.$ac_objext
11147 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11148   (eval $ac_compile) 2>conftest.er1
11149   ac_status=$?
11150   grep -v '^ *+' conftest.er1 >conftest.err
11151   rm -f conftest.er1
11152   cat conftest.err >&5
11153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11154   (exit $ac_status); } &&
11155          { ac_try='test -z "$ac_c_werror_flag"
11156                          || test ! -s conftest.err'
11157   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11158   (eval $ac_try) 2>&5
11159   ac_status=$?
11160   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11161   (exit $ac_status); }; } &&
11162          { ac_try='test -s conftest.$ac_objext'
11163   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11164   (eval $ac_try) 2>&5
11165   ac_status=$?
11166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11167   (exit $ac_status); }; }; then
11168   ac_cv_c_volatile=yes
11169 else
11170   echo "$as_me: failed program was:" >&5
11171 sed 's/^/| /' conftest.$ac_ext >&5
11172
11173 ac_cv_c_volatile=no
11174 fi
11175 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11176 fi
11177 echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
11178 echo "${ECHO_T}$ac_cv_c_volatile" >&6
11179 if test $ac_cv_c_volatile = no; then
11180
11181 cat >>confdefs.h <<\_ACEOF
11182 #define volatile
11183 _ACEOF
11184
11185 fi
11186
11187 echo "$as_me:$LINENO: checking for __func__" >&5
11188 echo $ECHO_N "checking for __func__... $ECHO_C" >&6
11189 if test "${pgac_cv_funcname_func_support+set}" = set; then
11190   echo $ECHO_N "(cached) $ECHO_C" >&6
11191 else
11192   cat >conftest.$ac_ext <<_ACEOF
11193 /* confdefs.h.  */
11194 _ACEOF
11195 cat confdefs.h >>conftest.$ac_ext
11196 cat >>conftest.$ac_ext <<_ACEOF
11197 /* end confdefs.h.  */
11198 #include <stdio.h>
11199 int
11200 main ()
11201 {
11202 printf("%s\n", __func__);
11203   ;
11204   return 0;
11205 }
11206 _ACEOF
11207 rm -f conftest.$ac_objext
11208 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11209   (eval $ac_compile) 2>conftest.er1
11210   ac_status=$?
11211   grep -v '^ *+' conftest.er1 >conftest.err
11212   rm -f conftest.er1
11213   cat conftest.err >&5
11214   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11215   (exit $ac_status); } &&
11216          { ac_try='test -z "$ac_c_werror_flag"
11217                          || test ! -s conftest.err'
11218   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11219   (eval $ac_try) 2>&5
11220   ac_status=$?
11221   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11222   (exit $ac_status); }; } &&
11223          { ac_try='test -s conftest.$ac_objext'
11224   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11225   (eval $ac_try) 2>&5
11226   ac_status=$?
11227   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11228   (exit $ac_status); }; }; then
11229   pgac_cv_funcname_func_support=yes
11230 else
11231   echo "$as_me: failed program was:" >&5
11232 sed 's/^/| /' conftest.$ac_ext >&5
11233
11234 pgac_cv_funcname_func_support=no
11235 fi
11236 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11237 fi
11238 echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
11239 echo "${ECHO_T}$pgac_cv_funcname_func_support" >&6
11240 if test x"$pgac_cv_funcname_func_support" = xyes ; then
11241
11242 cat >>confdefs.h <<\_ACEOF
11243 #define HAVE_FUNCNAME__FUNC 1
11244 _ACEOF
11245
11246 else
11247 echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
11248 echo $ECHO_N "checking for __FUNCTION__... $ECHO_C" >&6
11249 if test "${pgac_cv_funcname_function_support+set}" = set; then
11250   echo $ECHO_N "(cached) $ECHO_C" >&6
11251 else
11252   cat >conftest.$ac_ext <<_ACEOF
11253 /* confdefs.h.  */
11254 _ACEOF
11255 cat confdefs.h >>conftest.$ac_ext
11256 cat >>conftest.$ac_ext <<_ACEOF
11257 /* end confdefs.h.  */
11258 #include <stdio.h>
11259 int
11260 main ()
11261 {
11262 printf("%s\n", __FUNCTION__);
11263   ;
11264   return 0;
11265 }
11266 _ACEOF
11267 rm -f conftest.$ac_objext
11268 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11269   (eval $ac_compile) 2>conftest.er1
11270   ac_status=$?
11271   grep -v '^ *+' conftest.er1 >conftest.err
11272   rm -f conftest.er1
11273   cat conftest.err >&5
11274   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11275   (exit $ac_status); } &&
11276          { ac_try='test -z "$ac_c_werror_flag"
11277                          || test ! -s conftest.err'
11278   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11279   (eval $ac_try) 2>&5
11280   ac_status=$?
11281   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11282   (exit $ac_status); }; } &&
11283          { ac_try='test -s conftest.$ac_objext'
11284   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11285   (eval $ac_try) 2>&5
11286   ac_status=$?
11287   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11288   (exit $ac_status); }; }; then
11289   pgac_cv_funcname_function_support=yes
11290 else
11291   echo "$as_me: failed program was:" >&5
11292 sed 's/^/| /' conftest.$ac_ext >&5
11293
11294 pgac_cv_funcname_function_support=no
11295 fi
11296 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11297 fi
11298 echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
11299 echo "${ECHO_T}$pgac_cv_funcname_function_support" >&6
11300 if test x"$pgac_cv_funcname_function_support" = xyes ; then
11301
11302 cat >>confdefs.h <<\_ACEOF
11303 #define HAVE_FUNCNAME__FUNCTION 1
11304 _ACEOF
11305
11306 fi
11307 fi
11308 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
11309 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
11310 if test "${ac_cv_struct_tm+set}" = set; then
11311   echo $ECHO_N "(cached) $ECHO_C" >&6
11312 else
11313   cat >conftest.$ac_ext <<_ACEOF
11314 /* confdefs.h.  */
11315 _ACEOF
11316 cat confdefs.h >>conftest.$ac_ext
11317 cat >>conftest.$ac_ext <<_ACEOF
11318 /* end confdefs.h.  */
11319 #include <sys/types.h>
11320 #include <time.h>
11321
11322 int
11323 main ()
11324 {
11325 struct tm *tp; tp->tm_sec;
11326   ;
11327   return 0;
11328 }
11329 _ACEOF
11330 rm -f conftest.$ac_objext
11331 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11332   (eval $ac_compile) 2>conftest.er1
11333   ac_status=$?
11334   grep -v '^ *+' conftest.er1 >conftest.err
11335   rm -f conftest.er1
11336   cat conftest.err >&5
11337   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11338   (exit $ac_status); } &&
11339          { ac_try='test -z "$ac_c_werror_flag"
11340                          || test ! -s conftest.err'
11341   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11342   (eval $ac_try) 2>&5
11343   ac_status=$?
11344   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11345   (exit $ac_status); }; } &&
11346          { ac_try='test -s conftest.$ac_objext'
11347   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11348   (eval $ac_try) 2>&5
11349   ac_status=$?
11350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11351   (exit $ac_status); }; }; then
11352   ac_cv_struct_tm=time.h
11353 else
11354   echo "$as_me: failed program was:" >&5
11355 sed 's/^/| /' conftest.$ac_ext >&5
11356
11357 ac_cv_struct_tm=sys/time.h
11358 fi
11359 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11360 fi
11361 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
11362 echo "${ECHO_T}$ac_cv_struct_tm" >&6
11363 if test $ac_cv_struct_tm = sys/time.h; then
11364
11365 cat >>confdefs.h <<\_ACEOF
11366 #define TM_IN_SYS_TIME 1
11367 _ACEOF
11368
11369 fi
11370
11371 echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
11372 echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
11373 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
11374   echo $ECHO_N "(cached) $ECHO_C" >&6
11375 else
11376   cat >conftest.$ac_ext <<_ACEOF
11377 /* confdefs.h.  */
11378 _ACEOF
11379 cat confdefs.h >>conftest.$ac_ext
11380 cat >>conftest.$ac_ext <<_ACEOF
11381 /* end confdefs.h.  */
11382 #include <sys/types.h>
11383 #include <$ac_cv_struct_tm>
11384
11385
11386 int
11387 main ()
11388 {
11389 static struct tm ac_aggr;
11390 if (ac_aggr.tm_zone)
11391 return 0;
11392   ;
11393   return 0;
11394 }
11395 _ACEOF
11396 rm -f conftest.$ac_objext
11397 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11398   (eval $ac_compile) 2>conftest.er1
11399   ac_status=$?
11400   grep -v '^ *+' conftest.er1 >conftest.err
11401   rm -f conftest.er1
11402   cat conftest.err >&5
11403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11404   (exit $ac_status); } &&
11405          { ac_try='test -z "$ac_c_werror_flag"
11406                          || test ! -s conftest.err'
11407   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11408   (eval $ac_try) 2>&5
11409   ac_status=$?
11410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11411   (exit $ac_status); }; } &&
11412          { ac_try='test -s conftest.$ac_objext'
11413   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11414   (eval $ac_try) 2>&5
11415   ac_status=$?
11416   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11417   (exit $ac_status); }; }; then
11418   ac_cv_member_struct_tm_tm_zone=yes
11419 else
11420   echo "$as_me: failed program was:" >&5
11421 sed 's/^/| /' conftest.$ac_ext >&5
11422
11423 cat >conftest.$ac_ext <<_ACEOF
11424 /* confdefs.h.  */
11425 _ACEOF
11426 cat confdefs.h >>conftest.$ac_ext
11427 cat >>conftest.$ac_ext <<_ACEOF
11428 /* end confdefs.h.  */
11429 #include <sys/types.h>
11430 #include <$ac_cv_struct_tm>
11431
11432
11433 int
11434 main ()
11435 {
11436 static struct tm ac_aggr;
11437 if (sizeof ac_aggr.tm_zone)
11438 return 0;
11439   ;
11440   return 0;
11441 }
11442 _ACEOF
11443 rm -f conftest.$ac_objext
11444 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11445   (eval $ac_compile) 2>conftest.er1
11446   ac_status=$?
11447   grep -v '^ *+' conftest.er1 >conftest.err
11448   rm -f conftest.er1
11449   cat conftest.err >&5
11450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11451   (exit $ac_status); } &&
11452          { ac_try='test -z "$ac_c_werror_flag"
11453                          || test ! -s conftest.err'
11454   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11455   (eval $ac_try) 2>&5
11456   ac_status=$?
11457   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11458   (exit $ac_status); }; } &&
11459          { ac_try='test -s conftest.$ac_objext'
11460   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11461   (eval $ac_try) 2>&5
11462   ac_status=$?
11463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11464   (exit $ac_status); }; }; then
11465   ac_cv_member_struct_tm_tm_zone=yes
11466 else
11467   echo "$as_me: failed program was:" >&5
11468 sed 's/^/| /' conftest.$ac_ext >&5
11469
11470 ac_cv_member_struct_tm_tm_zone=no
11471 fi
11472 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11473 fi
11474 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11475 fi
11476 echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
11477 echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
11478 if test $ac_cv_member_struct_tm_tm_zone = yes; then
11479
11480 cat >>confdefs.h <<_ACEOF
11481 #define HAVE_STRUCT_TM_TM_ZONE 1
11482 _ACEOF
11483
11484
11485 fi
11486
11487 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
11488
11489 cat >>confdefs.h <<\_ACEOF
11490 #define HAVE_TM_ZONE 1
11491 _ACEOF
11492
11493 fi
11494 echo "$as_me:$LINENO: checking for tzname" >&5
11495 echo $ECHO_N "checking for tzname... $ECHO_C" >&6
11496 if test "${ac_cv_var_tzname+set}" = set; then
11497   echo $ECHO_N "(cached) $ECHO_C" >&6
11498 else
11499   cat >conftest.$ac_ext <<_ACEOF
11500 /* confdefs.h.  */
11501 _ACEOF
11502 cat confdefs.h >>conftest.$ac_ext
11503 cat >>conftest.$ac_ext <<_ACEOF
11504 /* end confdefs.h.  */
11505 #include <time.h>
11506 #ifndef tzname /* For SGI.  */
11507 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
11508 #endif
11509
11510 int
11511 main ()
11512 {
11513 atoi(*tzname);
11514   ;
11515   return 0;
11516 }
11517 _ACEOF
11518 rm -f conftest.$ac_objext conftest$ac_exeext
11519 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11520   (eval $ac_link) 2>conftest.er1
11521   ac_status=$?
11522   grep -v '^ *+' conftest.er1 >conftest.err
11523   rm -f conftest.er1
11524   cat conftest.err >&5
11525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11526   (exit $ac_status); } &&
11527          { ac_try='test -z "$ac_c_werror_flag"
11528                          || test ! -s conftest.err'
11529   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11530   (eval $ac_try) 2>&5
11531   ac_status=$?
11532   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11533   (exit $ac_status); }; } &&
11534          { ac_try='test -s conftest$ac_exeext'
11535   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11536   (eval $ac_try) 2>&5
11537   ac_status=$?
11538   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11539   (exit $ac_status); }; }; then
11540   ac_cv_var_tzname=yes
11541 else
11542   echo "$as_me: failed program was:" >&5
11543 sed 's/^/| /' conftest.$ac_ext >&5
11544
11545 ac_cv_var_tzname=no
11546 fi
11547 rm -f conftest.err conftest.$ac_objext \
11548       conftest$ac_exeext conftest.$ac_ext
11549 fi
11550 echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
11551 echo "${ECHO_T}$ac_cv_var_tzname" >&6
11552 if test $ac_cv_var_tzname = yes; then
11553
11554 cat >>confdefs.h <<\_ACEOF
11555 #define HAVE_TZNAME 1
11556 _ACEOF
11557
11558 fi
11559
11560 echo "$as_me:$LINENO: checking for union semun" >&5
11561 echo $ECHO_N "checking for union semun... $ECHO_C" >&6
11562 if test "${ac_cv_type_union_semun+set}" = set; then
11563   echo $ECHO_N "(cached) $ECHO_C" >&6
11564 else
11565   cat >conftest.$ac_ext <<_ACEOF
11566 /* confdefs.h.  */
11567 _ACEOF
11568 cat confdefs.h >>conftest.$ac_ext
11569 cat >>conftest.$ac_ext <<_ACEOF
11570 /* end confdefs.h.  */
11571 #include <sys/types.h>
11572 #include <sys/ipc.h>
11573 #include <sys/sem.h>
11574
11575 int
11576 main ()
11577 {
11578 if ((union semun *) 0)
11579   return 0;
11580 if (sizeof (union semun))
11581   return 0;
11582   ;
11583   return 0;
11584 }
11585 _ACEOF
11586 rm -f conftest.$ac_objext
11587 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11588   (eval $ac_compile) 2>conftest.er1
11589   ac_status=$?
11590   grep -v '^ *+' conftest.er1 >conftest.err
11591   rm -f conftest.er1
11592   cat conftest.err >&5
11593   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11594   (exit $ac_status); } &&
11595          { ac_try='test -z "$ac_c_werror_flag"
11596                          || test ! -s conftest.err'
11597   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11598   (eval $ac_try) 2>&5
11599   ac_status=$?
11600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11601   (exit $ac_status); }; } &&
11602          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
11608   ac_cv_type_union_semun=yes
11609 else
11610   echo "$as_me: failed program was:" >&5
11611 sed 's/^/| /' conftest.$ac_ext >&5
11612
11613 ac_cv_type_union_semun=no
11614 fi
11615 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11616 fi
11617 echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
11618 echo "${ECHO_T}$ac_cv_type_union_semun" >&6
11619 if test $ac_cv_type_union_semun = yes; then
11620
11621 cat >>confdefs.h <<_ACEOF
11622 #define HAVE_UNION_SEMUN 1
11623 _ACEOF
11624
11625
11626 fi
11627
11628 echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
11629 echo $ECHO_N "checking for struct sockaddr_un... $ECHO_C" >&6
11630 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
11631   echo $ECHO_N "(cached) $ECHO_C" >&6
11632 else
11633   cat >conftest.$ac_ext <<_ACEOF
11634 /* confdefs.h.  */
11635 _ACEOF
11636 cat confdefs.h >>conftest.$ac_ext
11637 cat >>conftest.$ac_ext <<_ACEOF
11638 /* end confdefs.h.  */
11639 #include <sys/types.h>
11640 #ifdef HAVE_SYS_UN_H
11641 #include <sys/un.h>
11642 #endif
11643
11644
11645 int
11646 main ()
11647 {
11648 if ((struct sockaddr_un *) 0)
11649   return 0;
11650 if (sizeof (struct sockaddr_un))
11651   return 0;
11652   ;
11653   return 0;
11654 }
11655 _ACEOF
11656 rm -f conftest.$ac_objext
11657 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11658   (eval $ac_compile) 2>conftest.er1
11659   ac_status=$?
11660   grep -v '^ *+' conftest.er1 >conftest.err
11661   rm -f conftest.er1
11662   cat conftest.err >&5
11663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11664   (exit $ac_status); } &&
11665          { ac_try='test -z "$ac_c_werror_flag"
11666                          || test ! -s conftest.err'
11667   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11668   (eval $ac_try) 2>&5
11669   ac_status=$?
11670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11671   (exit $ac_status); }; } &&
11672          { ac_try='test -s conftest.$ac_objext'
11673   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11674   (eval $ac_try) 2>&5
11675   ac_status=$?
11676   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11677   (exit $ac_status); }; }; then
11678   ac_cv_type_struct_sockaddr_un=yes
11679 else
11680   echo "$as_me: failed program was:" >&5
11681 sed 's/^/| /' conftest.$ac_ext >&5
11682
11683 ac_cv_type_struct_sockaddr_un=no
11684 fi
11685 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11686 fi
11687 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
11688 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_un" >&6
11689 if test $ac_cv_type_struct_sockaddr_un = yes; then
11690
11691 cat >>confdefs.h <<_ACEOF
11692 #define HAVE_STRUCT_SOCKADDR_UN 1
11693 _ACEOF
11694
11695
11696 cat >>confdefs.h <<\_ACEOF
11697 #define HAVE_UNIX_SOCKETS 1
11698 _ACEOF
11699
11700 fi
11701
11702 echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
11703 echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6
11704 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
11705   echo $ECHO_N "(cached) $ECHO_C" >&6
11706 else
11707   cat >conftest.$ac_ext <<_ACEOF
11708 /* confdefs.h.  */
11709 _ACEOF
11710 cat confdefs.h >>conftest.$ac_ext
11711 cat >>conftest.$ac_ext <<_ACEOF
11712 /* end confdefs.h.  */
11713 #include <sys/types.h>
11714 #ifdef HAVE_SYS_SOCKET_H
11715 #include <sys/socket.h>
11716 #endif
11717
11718
11719 int
11720 main ()
11721 {
11722 if ((struct sockaddr_storage *) 0)
11723   return 0;
11724 if (sizeof (struct sockaddr_storage))
11725   return 0;
11726   ;
11727   return 0;
11728 }
11729 _ACEOF
11730 rm -f conftest.$ac_objext
11731 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11732   (eval $ac_compile) 2>conftest.er1
11733   ac_status=$?
11734   grep -v '^ *+' conftest.er1 >conftest.err
11735   rm -f conftest.er1
11736   cat conftest.err >&5
11737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11738   (exit $ac_status); } &&
11739          { ac_try='test -z "$ac_c_werror_flag"
11740                          || test ! -s conftest.err'
11741   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11742   (eval $ac_try) 2>&5
11743   ac_status=$?
11744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11745   (exit $ac_status); }; } &&
11746          { ac_try='test -s conftest.$ac_objext'
11747   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11748   (eval $ac_try) 2>&5
11749   ac_status=$?
11750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11751   (exit $ac_status); }; }; then
11752   ac_cv_type_struct_sockaddr_storage=yes
11753 else
11754   echo "$as_me: failed program was:" >&5
11755 sed 's/^/| /' conftest.$ac_ext >&5
11756
11757 ac_cv_type_struct_sockaddr_storage=no
11758 fi
11759 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11760 fi
11761 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
11762 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_storage" >&6
11763 if test $ac_cv_type_struct_sockaddr_storage = yes; then
11764
11765 cat >>confdefs.h <<_ACEOF
11766 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
11767 _ACEOF
11768
11769
11770 fi
11771
11772 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
11773 echo $ECHO_N "checking for struct sockaddr_storage.ss_family... $ECHO_C" >&6
11774 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
11775   echo $ECHO_N "(cached) $ECHO_C" >&6
11776 else
11777   cat >conftest.$ac_ext <<_ACEOF
11778 /* confdefs.h.  */
11779 _ACEOF
11780 cat confdefs.h >>conftest.$ac_ext
11781 cat >>conftest.$ac_ext <<_ACEOF
11782 /* end confdefs.h.  */
11783 #include <sys/types.h>
11784 #ifdef HAVE_SYS_SOCKET_H
11785 #include <sys/socket.h>
11786 #endif
11787
11788
11789 int
11790 main ()
11791 {
11792 static struct sockaddr_storage ac_aggr;
11793 if (ac_aggr.ss_family)
11794 return 0;
11795   ;
11796   return 0;
11797 }
11798 _ACEOF
11799 rm -f conftest.$ac_objext
11800 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11801   (eval $ac_compile) 2>conftest.er1
11802   ac_status=$?
11803   grep -v '^ *+' conftest.er1 >conftest.err
11804   rm -f conftest.er1
11805   cat conftest.err >&5
11806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11807   (exit $ac_status); } &&
11808          { ac_try='test -z "$ac_c_werror_flag"
11809                          || test ! -s conftest.err'
11810   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11811   (eval $ac_try) 2>&5
11812   ac_status=$?
11813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11814   (exit $ac_status); }; } &&
11815          { ac_try='test -s conftest.$ac_objext'
11816   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11817   (eval $ac_try) 2>&5
11818   ac_status=$?
11819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11820   (exit $ac_status); }; }; then
11821   ac_cv_member_struct_sockaddr_storage_ss_family=yes
11822 else
11823   echo "$as_me: failed program was:" >&5
11824 sed 's/^/| /' conftest.$ac_ext >&5
11825
11826 cat >conftest.$ac_ext <<_ACEOF
11827 /* confdefs.h.  */
11828 _ACEOF
11829 cat confdefs.h >>conftest.$ac_ext
11830 cat >>conftest.$ac_ext <<_ACEOF
11831 /* end confdefs.h.  */
11832 #include <sys/types.h>
11833 #ifdef HAVE_SYS_SOCKET_H
11834 #include <sys/socket.h>
11835 #endif
11836
11837
11838 int
11839 main ()
11840 {
11841 static struct sockaddr_storage ac_aggr;
11842 if (sizeof ac_aggr.ss_family)
11843 return 0;
11844   ;
11845   return 0;
11846 }
11847 _ACEOF
11848 rm -f conftest.$ac_objext
11849 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11850   (eval $ac_compile) 2>conftest.er1
11851   ac_status=$?
11852   grep -v '^ *+' conftest.er1 >conftest.err
11853   rm -f conftest.er1
11854   cat conftest.err >&5
11855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11856   (exit $ac_status); } &&
11857          { ac_try='test -z "$ac_c_werror_flag"
11858                          || test ! -s conftest.err'
11859   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11860   (eval $ac_try) 2>&5
11861   ac_status=$?
11862   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11863   (exit $ac_status); }; } &&
11864          { ac_try='test -s conftest.$ac_objext'
11865   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11866   (eval $ac_try) 2>&5
11867   ac_status=$?
11868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11869   (exit $ac_status); }; }; then
11870   ac_cv_member_struct_sockaddr_storage_ss_family=yes
11871 else
11872   echo "$as_me: failed program was:" >&5
11873 sed 's/^/| /' conftest.$ac_ext >&5
11874
11875 ac_cv_member_struct_sockaddr_storage_ss_family=no
11876 fi
11877 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11878 fi
11879 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11880 fi
11881 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
11882 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_family" >&6
11883 if test $ac_cv_member_struct_sockaddr_storage_ss_family = yes; then
11884
11885 cat >>confdefs.h <<_ACEOF
11886 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
11887 _ACEOF
11888
11889
11890 fi
11891 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
11892 echo $ECHO_N "checking for struct sockaddr_storage.__ss_family... $ECHO_C" >&6
11893 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
11894   echo $ECHO_N "(cached) $ECHO_C" >&6
11895 else
11896   cat >conftest.$ac_ext <<_ACEOF
11897 /* confdefs.h.  */
11898 _ACEOF
11899 cat confdefs.h >>conftest.$ac_ext
11900 cat >>conftest.$ac_ext <<_ACEOF
11901 /* end confdefs.h.  */
11902 #include <sys/types.h>
11903 #ifdef HAVE_SYS_SOCKET_H
11904 #include <sys/socket.h>
11905 #endif
11906
11907
11908 int
11909 main ()
11910 {
11911 static struct sockaddr_storage ac_aggr;
11912 if (ac_aggr.__ss_family)
11913 return 0;
11914   ;
11915   return 0;
11916 }
11917 _ACEOF
11918 rm -f conftest.$ac_objext
11919 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11920   (eval $ac_compile) 2>conftest.er1
11921   ac_status=$?
11922   grep -v '^ *+' conftest.er1 >conftest.err
11923   rm -f conftest.er1
11924   cat conftest.err >&5
11925   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11926   (exit $ac_status); } &&
11927          { ac_try='test -z "$ac_c_werror_flag"
11928                          || test ! -s conftest.err'
11929   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11930   (eval $ac_try) 2>&5
11931   ac_status=$?
11932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11933   (exit $ac_status); }; } &&
11934          { ac_try='test -s conftest.$ac_objext'
11935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11936   (eval $ac_try) 2>&5
11937   ac_status=$?
11938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11939   (exit $ac_status); }; }; then
11940   ac_cv_member_struct_sockaddr_storage___ss_family=yes
11941 else
11942   echo "$as_me: failed program was:" >&5
11943 sed 's/^/| /' conftest.$ac_ext >&5
11944
11945 cat >conftest.$ac_ext <<_ACEOF
11946 /* confdefs.h.  */
11947 _ACEOF
11948 cat confdefs.h >>conftest.$ac_ext
11949 cat >>conftest.$ac_ext <<_ACEOF
11950 /* end confdefs.h.  */
11951 #include <sys/types.h>
11952 #ifdef HAVE_SYS_SOCKET_H
11953 #include <sys/socket.h>
11954 #endif
11955
11956
11957 int
11958 main ()
11959 {
11960 static struct sockaddr_storage ac_aggr;
11961 if (sizeof ac_aggr.__ss_family)
11962 return 0;
11963   ;
11964   return 0;
11965 }
11966 _ACEOF
11967 rm -f conftest.$ac_objext
11968 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11969   (eval $ac_compile) 2>conftest.er1
11970   ac_status=$?
11971   grep -v '^ *+' conftest.er1 >conftest.err
11972   rm -f conftest.er1
11973   cat conftest.err >&5
11974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11975   (exit $ac_status); } &&
11976          { ac_try='test -z "$ac_c_werror_flag"
11977                          || test ! -s conftest.err'
11978   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11979   (eval $ac_try) 2>&5
11980   ac_status=$?
11981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11982   (exit $ac_status); }; } &&
11983          { ac_try='test -s conftest.$ac_objext'
11984   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11985   (eval $ac_try) 2>&5
11986   ac_status=$?
11987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11988   (exit $ac_status); }; }; then
11989   ac_cv_member_struct_sockaddr_storage___ss_family=yes
11990 else
11991   echo "$as_me: failed program was:" >&5
11992 sed 's/^/| /' conftest.$ac_ext >&5
11993
11994 ac_cv_member_struct_sockaddr_storage___ss_family=no
11995 fi
11996 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11997 fi
11998 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11999 fi
12000 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
12001 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_family" >&6
12002 if test $ac_cv_member_struct_sockaddr_storage___ss_family = yes; then
12003
12004 cat >>confdefs.h <<_ACEOF
12005 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
12006 _ACEOF
12007
12008
12009 fi
12010 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
12011 echo $ECHO_N "checking for struct sockaddr_storage.ss_len... $ECHO_C" >&6
12012 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
12013   echo $ECHO_N "(cached) $ECHO_C" >&6
12014 else
12015   cat >conftest.$ac_ext <<_ACEOF
12016 /* confdefs.h.  */
12017 _ACEOF
12018 cat confdefs.h >>conftest.$ac_ext
12019 cat >>conftest.$ac_ext <<_ACEOF
12020 /* end confdefs.h.  */
12021 #include <sys/types.h>
12022 #ifdef HAVE_SYS_SOCKET_H
12023 #include <sys/socket.h>
12024 #endif
12025
12026
12027 int
12028 main ()
12029 {
12030 static struct sockaddr_storage ac_aggr;
12031 if (ac_aggr.ss_len)
12032 return 0;
12033   ;
12034   return 0;
12035 }
12036 _ACEOF
12037 rm -f conftest.$ac_objext
12038 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12039   (eval $ac_compile) 2>conftest.er1
12040   ac_status=$?
12041   grep -v '^ *+' conftest.er1 >conftest.err
12042   rm -f conftest.er1
12043   cat conftest.err >&5
12044   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12045   (exit $ac_status); } &&
12046          { ac_try='test -z "$ac_c_werror_flag"
12047                          || test ! -s conftest.err'
12048   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12049   (eval $ac_try) 2>&5
12050   ac_status=$?
12051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12052   (exit $ac_status); }; } &&
12053          { ac_try='test -s conftest.$ac_objext'
12054   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12055   (eval $ac_try) 2>&5
12056   ac_status=$?
12057   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12058   (exit $ac_status); }; }; then
12059   ac_cv_member_struct_sockaddr_storage_ss_len=yes
12060 else
12061   echo "$as_me: failed program was:" >&5
12062 sed 's/^/| /' conftest.$ac_ext >&5
12063
12064 cat >conftest.$ac_ext <<_ACEOF
12065 /* confdefs.h.  */
12066 _ACEOF
12067 cat confdefs.h >>conftest.$ac_ext
12068 cat >>conftest.$ac_ext <<_ACEOF
12069 /* end confdefs.h.  */
12070 #include <sys/types.h>
12071 #ifdef HAVE_SYS_SOCKET_H
12072 #include <sys/socket.h>
12073 #endif
12074
12075
12076 int
12077 main ()
12078 {
12079 static struct sockaddr_storage ac_aggr;
12080 if (sizeof ac_aggr.ss_len)
12081 return 0;
12082   ;
12083   return 0;
12084 }
12085 _ACEOF
12086 rm -f conftest.$ac_objext
12087 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12088   (eval $ac_compile) 2>conftest.er1
12089   ac_status=$?
12090   grep -v '^ *+' conftest.er1 >conftest.err
12091   rm -f conftest.er1
12092   cat conftest.err >&5
12093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12094   (exit $ac_status); } &&
12095          { ac_try='test -z "$ac_c_werror_flag"
12096                          || test ! -s conftest.err'
12097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12098   (eval $ac_try) 2>&5
12099   ac_status=$?
12100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12101   (exit $ac_status); }; } &&
12102          { ac_try='test -s conftest.$ac_objext'
12103   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12104   (eval $ac_try) 2>&5
12105   ac_status=$?
12106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12107   (exit $ac_status); }; }; then
12108   ac_cv_member_struct_sockaddr_storage_ss_len=yes
12109 else
12110   echo "$as_me: failed program was:" >&5
12111 sed 's/^/| /' conftest.$ac_ext >&5
12112
12113 ac_cv_member_struct_sockaddr_storage_ss_len=no
12114 fi
12115 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12116 fi
12117 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12118 fi
12119 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
12120 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_len" >&6
12121 if test $ac_cv_member_struct_sockaddr_storage_ss_len = yes; then
12122
12123 cat >>confdefs.h <<_ACEOF
12124 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
12125 _ACEOF
12126
12127
12128 fi
12129 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
12130 echo $ECHO_N "checking for struct sockaddr_storage.__ss_len... $ECHO_C" >&6
12131 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+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/types.h>
12141 #ifdef HAVE_SYS_SOCKET_H
12142 #include <sys/socket.h>
12143 #endif
12144
12145
12146 int
12147 main ()
12148 {
12149 static struct sockaddr_storage ac_aggr;
12150 if (ac_aggr.__ss_len)
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_member_struct_sockaddr_storage___ss_len=yes
12179 else
12180   echo "$as_me: failed program was:" >&5
12181 sed 's/^/| /' conftest.$ac_ext >&5
12182
12183 cat >conftest.$ac_ext <<_ACEOF
12184 /* confdefs.h.  */
12185 _ACEOF
12186 cat confdefs.h >>conftest.$ac_ext
12187 cat >>conftest.$ac_ext <<_ACEOF
12188 /* end confdefs.h.  */
12189 #include <sys/types.h>
12190 #ifdef HAVE_SYS_SOCKET_H
12191 #include <sys/socket.h>
12192 #endif
12193
12194
12195 int
12196 main ()
12197 {
12198 static struct sockaddr_storage ac_aggr;
12199 if (sizeof ac_aggr.__ss_len)
12200 return 0;
12201   ;
12202   return 0;
12203 }
12204 _ACEOF
12205 rm -f conftest.$ac_objext
12206 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12207   (eval $ac_compile) 2>conftest.er1
12208   ac_status=$?
12209   grep -v '^ *+' conftest.er1 >conftest.err
12210   rm -f conftest.er1
12211   cat conftest.err >&5
12212   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12213   (exit $ac_status); } &&
12214          { ac_try='test -z "$ac_c_werror_flag"
12215                          || test ! -s conftest.err'
12216   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12217   (eval $ac_try) 2>&5
12218   ac_status=$?
12219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12220   (exit $ac_status); }; } &&
12221          { ac_try='test -s conftest.$ac_objext'
12222   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12223   (eval $ac_try) 2>&5
12224   ac_status=$?
12225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12226   (exit $ac_status); }; }; then
12227   ac_cv_member_struct_sockaddr_storage___ss_len=yes
12228 else
12229   echo "$as_me: failed program was:" >&5
12230 sed 's/^/| /' conftest.$ac_ext >&5
12231
12232 ac_cv_member_struct_sockaddr_storage___ss_len=no
12233 fi
12234 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12235 fi
12236 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12237 fi
12238 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
12239 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_len" >&6
12240 if test $ac_cv_member_struct_sockaddr_storage___ss_len = yes; then
12241
12242 cat >>confdefs.h <<_ACEOF
12243 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
12244 _ACEOF
12245
12246
12247 fi
12248 echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
12249 echo $ECHO_N "checking for struct sockaddr.sa_len... $ECHO_C" >&6
12250 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
12251   echo $ECHO_N "(cached) $ECHO_C" >&6
12252 else
12253   cat >conftest.$ac_ext <<_ACEOF
12254 /* confdefs.h.  */
12255 _ACEOF
12256 cat confdefs.h >>conftest.$ac_ext
12257 cat >>conftest.$ac_ext <<_ACEOF
12258 /* end confdefs.h.  */
12259 #include <sys/types.h>
12260 #ifdef HAVE_SYS_SOCKET_H
12261 #include <sys/socket.h>
12262 #endif
12263
12264
12265 int
12266 main ()
12267 {
12268 static struct sockaddr ac_aggr;
12269 if (ac_aggr.sa_len)
12270 return 0;
12271   ;
12272   return 0;
12273 }
12274 _ACEOF
12275 rm -f conftest.$ac_objext
12276 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12277   (eval $ac_compile) 2>conftest.er1
12278   ac_status=$?
12279   grep -v '^ *+' conftest.er1 >conftest.err
12280   rm -f conftest.er1
12281   cat conftest.err >&5
12282   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12283   (exit $ac_status); } &&
12284          { ac_try='test -z "$ac_c_werror_flag"
12285                          || test ! -s conftest.err'
12286   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12287   (eval $ac_try) 2>&5
12288   ac_status=$?
12289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12290   (exit $ac_status); }; } &&
12291          { ac_try='test -s conftest.$ac_objext'
12292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12293   (eval $ac_try) 2>&5
12294   ac_status=$?
12295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12296   (exit $ac_status); }; }; then
12297   ac_cv_member_struct_sockaddr_sa_len=yes
12298 else
12299   echo "$as_me: failed program was:" >&5
12300 sed 's/^/| /' conftest.$ac_ext >&5
12301
12302 cat >conftest.$ac_ext <<_ACEOF
12303 /* confdefs.h.  */
12304 _ACEOF
12305 cat confdefs.h >>conftest.$ac_ext
12306 cat >>conftest.$ac_ext <<_ACEOF
12307 /* end confdefs.h.  */
12308 #include <sys/types.h>
12309 #ifdef HAVE_SYS_SOCKET_H
12310 #include <sys/socket.h>
12311 #endif
12312
12313
12314 int
12315 main ()
12316 {
12317 static struct sockaddr ac_aggr;
12318 if (sizeof ac_aggr.sa_len)
12319 return 0;
12320   ;
12321   return 0;
12322 }
12323 _ACEOF
12324 rm -f conftest.$ac_objext
12325 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12326   (eval $ac_compile) 2>conftest.er1
12327   ac_status=$?
12328   grep -v '^ *+' conftest.er1 >conftest.err
12329   rm -f conftest.er1
12330   cat conftest.err >&5
12331   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12332   (exit $ac_status); } &&
12333          { ac_try='test -z "$ac_c_werror_flag"
12334                          || test ! -s conftest.err'
12335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12336   (eval $ac_try) 2>&5
12337   ac_status=$?
12338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12339   (exit $ac_status); }; } &&
12340          { ac_try='test -s conftest.$ac_objext'
12341   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12342   (eval $ac_try) 2>&5
12343   ac_status=$?
12344   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12345   (exit $ac_status); }; }; then
12346   ac_cv_member_struct_sockaddr_sa_len=yes
12347 else
12348   echo "$as_me: failed program was:" >&5
12349 sed 's/^/| /' conftest.$ac_ext >&5
12350
12351 ac_cv_member_struct_sockaddr_sa_len=no
12352 fi
12353 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12354 fi
12355 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12356 fi
12357 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
12358 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_sa_len" >&6
12359 if test $ac_cv_member_struct_sockaddr_sa_len = yes; then
12360
12361 cat >>confdefs.h <<_ACEOF
12362 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
12363 _ACEOF
12364
12365
12366 fi
12367
12368 echo "$as_me:$LINENO: checking for struct addrinfo" >&5
12369 echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6
12370 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
12371   echo $ECHO_N "(cached) $ECHO_C" >&6
12372 else
12373   cat >conftest.$ac_ext <<_ACEOF
12374 /* confdefs.h.  */
12375 _ACEOF
12376 cat confdefs.h >>conftest.$ac_ext
12377 cat >>conftest.$ac_ext <<_ACEOF
12378 /* end confdefs.h.  */
12379 #include <sys/types.h>
12380 #include <sys/socket.h>
12381 #include <netdb.h>
12382
12383
12384 int
12385 main ()
12386 {
12387 if ((struct addrinfo *) 0)
12388   return 0;
12389 if (sizeof (struct addrinfo))
12390   return 0;
12391   ;
12392   return 0;
12393 }
12394 _ACEOF
12395 rm -f conftest.$ac_objext
12396 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12397   (eval $ac_compile) 2>conftest.er1
12398   ac_status=$?
12399   grep -v '^ *+' conftest.er1 >conftest.err
12400   rm -f conftest.er1
12401   cat conftest.err >&5
12402   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12403   (exit $ac_status); } &&
12404          { ac_try='test -z "$ac_c_werror_flag"
12405                          || test ! -s conftest.err'
12406   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12407   (eval $ac_try) 2>&5
12408   ac_status=$?
12409   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12410   (exit $ac_status); }; } &&
12411          { ac_try='test -s conftest.$ac_objext'
12412   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12413   (eval $ac_try) 2>&5
12414   ac_status=$?
12415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12416   (exit $ac_status); }; }; then
12417   ac_cv_type_struct_addrinfo=yes
12418 else
12419   echo "$as_me: failed program was:" >&5
12420 sed 's/^/| /' conftest.$ac_ext >&5
12421
12422 ac_cv_type_struct_addrinfo=no
12423 fi
12424 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12425 fi
12426 echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
12427 echo "${ECHO_T}$ac_cv_type_struct_addrinfo" >&6
12428 if test $ac_cv_type_struct_addrinfo = yes; then
12429
12430 cat >>confdefs.h <<_ACEOF
12431 #define HAVE_STRUCT_ADDRINFO 1
12432 _ACEOF
12433
12434
12435 fi
12436
12437
12438 echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
12439 echo $ECHO_N "checking for struct cmsgcred... $ECHO_C" >&6
12440 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
12441   echo $ECHO_N "(cached) $ECHO_C" >&6
12442 else
12443   cat >conftest.$ac_ext <<_ACEOF
12444 /* confdefs.h.  */
12445 _ACEOF
12446 cat confdefs.h >>conftest.$ac_ext
12447 cat >>conftest.$ac_ext <<_ACEOF
12448 /* end confdefs.h.  */
12449 #include <sys/param.h>
12450 #include <sys/types.h>
12451 #include <sys/socket.h>
12452 #include <sys/ucred.h>
12453
12454 int
12455 main ()
12456 {
12457 if ((struct cmsgcred *) 0)
12458   return 0;
12459 if (sizeof (struct cmsgcred))
12460   return 0;
12461   ;
12462   return 0;
12463 }
12464 _ACEOF
12465 rm -f conftest.$ac_objext
12466 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12467   (eval $ac_compile) 2>conftest.er1
12468   ac_status=$?
12469   grep -v '^ *+' conftest.er1 >conftest.err
12470   rm -f conftest.er1
12471   cat conftest.err >&5
12472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12473   (exit $ac_status); } &&
12474          { ac_try='test -z "$ac_c_werror_flag"
12475                          || test ! -s conftest.err'
12476   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12477   (eval $ac_try) 2>&5
12478   ac_status=$?
12479   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12480   (exit $ac_status); }; } &&
12481          { ac_try='test -s conftest.$ac_objext'
12482   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12483   (eval $ac_try) 2>&5
12484   ac_status=$?
12485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12486   (exit $ac_status); }; }; then
12487   ac_cv_type_struct_cmsgcred=yes
12488 else
12489   echo "$as_me: failed program was:" >&5
12490 sed 's/^/| /' conftest.$ac_ext >&5
12491
12492 ac_cv_type_struct_cmsgcred=no
12493 fi
12494 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12495 fi
12496 echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
12497 echo "${ECHO_T}$ac_cv_type_struct_cmsgcred" >&6
12498 if test $ac_cv_type_struct_cmsgcred = yes; then
12499
12500 cat >>confdefs.h <<_ACEOF
12501 #define HAVE_STRUCT_CMSGCRED 1
12502 _ACEOF
12503
12504
12505 fi
12506 echo "$as_me:$LINENO: checking for struct fcred" >&5
12507 echo $ECHO_N "checking for struct fcred... $ECHO_C" >&6
12508 if test "${ac_cv_type_struct_fcred+set}" = set; then
12509   echo $ECHO_N "(cached) $ECHO_C" >&6
12510 else
12511   cat >conftest.$ac_ext <<_ACEOF
12512 /* confdefs.h.  */
12513 _ACEOF
12514 cat confdefs.h >>conftest.$ac_ext
12515 cat >>conftest.$ac_ext <<_ACEOF
12516 /* end confdefs.h.  */
12517 #include <sys/param.h>
12518 #include <sys/types.h>
12519 #include <sys/socket.h>
12520 #include <sys/ucred.h>
12521
12522 int
12523 main ()
12524 {
12525 if ((struct fcred *) 0)
12526   return 0;
12527 if (sizeof (struct fcred))
12528   return 0;
12529   ;
12530   return 0;
12531 }
12532 _ACEOF
12533 rm -f conftest.$ac_objext
12534 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12535   (eval $ac_compile) 2>conftest.er1
12536   ac_status=$?
12537   grep -v '^ *+' conftest.er1 >conftest.err
12538   rm -f conftest.er1
12539   cat conftest.err >&5
12540   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12541   (exit $ac_status); } &&
12542          { ac_try='test -z "$ac_c_werror_flag"
12543                          || test ! -s conftest.err'
12544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12545   (eval $ac_try) 2>&5
12546   ac_status=$?
12547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12548   (exit $ac_status); }; } &&
12549          { ac_try='test -s conftest.$ac_objext'
12550   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12551   (eval $ac_try) 2>&5
12552   ac_status=$?
12553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12554   (exit $ac_status); }; }; then
12555   ac_cv_type_struct_fcred=yes
12556 else
12557   echo "$as_me: failed program was:" >&5
12558 sed 's/^/| /' conftest.$ac_ext >&5
12559
12560 ac_cv_type_struct_fcred=no
12561 fi
12562 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12563 fi
12564 echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
12565 echo "${ECHO_T}$ac_cv_type_struct_fcred" >&6
12566 if test $ac_cv_type_struct_fcred = yes; then
12567
12568 cat >>confdefs.h <<_ACEOF
12569 #define HAVE_STRUCT_FCRED 1
12570 _ACEOF
12571
12572
12573 fi
12574 echo "$as_me:$LINENO: checking for struct sockcred" >&5
12575 echo $ECHO_N "checking for struct sockcred... $ECHO_C" >&6
12576 if test "${ac_cv_type_struct_sockcred+set}" = set; then
12577   echo $ECHO_N "(cached) $ECHO_C" >&6
12578 else
12579   cat >conftest.$ac_ext <<_ACEOF
12580 /* confdefs.h.  */
12581 _ACEOF
12582 cat confdefs.h >>conftest.$ac_ext
12583 cat >>conftest.$ac_ext <<_ACEOF
12584 /* end confdefs.h.  */
12585 #include <sys/param.h>
12586 #include <sys/types.h>
12587 #include <sys/socket.h>
12588 #include <sys/ucred.h>
12589
12590 int
12591 main ()
12592 {
12593 if ((struct sockcred *) 0)
12594   return 0;
12595 if (sizeof (struct sockcred))
12596   return 0;
12597   ;
12598   return 0;
12599 }
12600 _ACEOF
12601 rm -f conftest.$ac_objext
12602 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12603   (eval $ac_compile) 2>conftest.er1
12604   ac_status=$?
12605   grep -v '^ *+' conftest.er1 >conftest.err
12606   rm -f conftest.er1
12607   cat conftest.err >&5
12608   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12609   (exit $ac_status); } &&
12610          { ac_try='test -z "$ac_c_werror_flag"
12611                          || test ! -s conftest.err'
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); }; } &&
12617          { ac_try='test -s conftest.$ac_objext'
12618   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12619   (eval $ac_try) 2>&5
12620   ac_status=$?
12621   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12622   (exit $ac_status); }; }; then
12623   ac_cv_type_struct_sockcred=yes
12624 else
12625   echo "$as_me: failed program was:" >&5
12626 sed 's/^/| /' conftest.$ac_ext >&5
12627
12628 ac_cv_type_struct_sockcred=no
12629 fi
12630 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12631 fi
12632 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
12633 echo "${ECHO_T}$ac_cv_type_struct_sockcred" >&6
12634 if test $ac_cv_type_struct_sockcred = yes; then
12635
12636 cat >>confdefs.h <<_ACEOF
12637 #define HAVE_STRUCT_SOCKCRED 1
12638 _ACEOF
12639
12640
12641 fi
12642
12643
12644 echo "$as_me:$LINENO: checking for struct option" >&5
12645 echo $ECHO_N "checking for struct option... $ECHO_C" >&6
12646 if test "${ac_cv_type_struct_option+set}" = set; then
12647   echo $ECHO_N "(cached) $ECHO_C" >&6
12648 else
12649   cat >conftest.$ac_ext <<_ACEOF
12650 /* confdefs.h.  */
12651 _ACEOF
12652 cat confdefs.h >>conftest.$ac_ext
12653 cat >>conftest.$ac_ext <<_ACEOF
12654 /* end confdefs.h.  */
12655 #ifdef HAVE_GETOPT_H
12656 #include <getopt.h>
12657 #endif
12658
12659 int
12660 main ()
12661 {
12662 if ((struct option *) 0)
12663   return 0;
12664 if (sizeof (struct option))
12665   return 0;
12666   ;
12667   return 0;
12668 }
12669 _ACEOF
12670 rm -f conftest.$ac_objext
12671 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12672   (eval $ac_compile) 2>conftest.er1
12673   ac_status=$?
12674   grep -v '^ *+' conftest.er1 >conftest.err
12675   rm -f conftest.er1
12676   cat conftest.err >&5
12677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12678   (exit $ac_status); } &&
12679          { ac_try='test -z "$ac_c_werror_flag"
12680                          || test ! -s conftest.err'
12681   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12682   (eval $ac_try) 2>&5
12683   ac_status=$?
12684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12685   (exit $ac_status); }; } &&
12686          { ac_try='test -s conftest.$ac_objext'
12687   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12688   (eval $ac_try) 2>&5
12689   ac_status=$?
12690   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12691   (exit $ac_status); }; }; then
12692   ac_cv_type_struct_option=yes
12693 else
12694   echo "$as_me: failed program was:" >&5
12695 sed 's/^/| /' conftest.$ac_ext >&5
12696
12697 ac_cv_type_struct_option=no
12698 fi
12699 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12700 fi
12701 echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
12702 echo "${ECHO_T}$ac_cv_type_struct_option" >&6
12703 if test $ac_cv_type_struct_option = yes; then
12704
12705 cat >>confdefs.h <<_ACEOF
12706 #define HAVE_STRUCT_OPTION 1
12707 _ACEOF
12708
12709
12710 fi
12711
12712
12713 if test "$with_zlib" = yes; then
12714   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
12715   # did not).  While we could work around the lack of z_streamp, it
12716   # seems unwise to encourage people to use such old zlib versions...
12717   echo "$as_me:$LINENO: checking for z_streamp" >&5
12718 echo $ECHO_N "checking for z_streamp... $ECHO_C" >&6
12719 if test "${ac_cv_type_z_streamp+set}" = set; then
12720   echo $ECHO_N "(cached) $ECHO_C" >&6
12721 else
12722   cat >conftest.$ac_ext <<_ACEOF
12723 /* confdefs.h.  */
12724 _ACEOF
12725 cat confdefs.h >>conftest.$ac_ext
12726 cat >>conftest.$ac_ext <<_ACEOF
12727 /* end confdefs.h.  */
12728 #include <zlib.h>
12729
12730 int
12731 main ()
12732 {
12733 if ((z_streamp *) 0)
12734   return 0;
12735 if (sizeof (z_streamp))
12736   return 0;
12737   ;
12738   return 0;
12739 }
12740 _ACEOF
12741 rm -f conftest.$ac_objext
12742 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12743   (eval $ac_compile) 2>conftest.er1
12744   ac_status=$?
12745   grep -v '^ *+' conftest.er1 >conftest.err
12746   rm -f conftest.er1
12747   cat conftest.err >&5
12748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12749   (exit $ac_status); } &&
12750          { ac_try='test -z "$ac_c_werror_flag"
12751                          || test ! -s conftest.err'
12752   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12753   (eval $ac_try) 2>&5
12754   ac_status=$?
12755   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12756   (exit $ac_status); }; } &&
12757          { ac_try='test -s conftest.$ac_objext'
12758   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12759   (eval $ac_try) 2>&5
12760   ac_status=$?
12761   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12762   (exit $ac_status); }; }; then
12763   ac_cv_type_z_streamp=yes
12764 else
12765   echo "$as_me: failed program was:" >&5
12766 sed 's/^/| /' conftest.$ac_ext >&5
12767
12768 ac_cv_type_z_streamp=no
12769 fi
12770 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12771 fi
12772 echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
12773 echo "${ECHO_T}$ac_cv_type_z_streamp" >&6
12774 if test $ac_cv_type_z_streamp = yes; then
12775   :
12776 else
12777   { { echo "$as_me:$LINENO: error: zlib version is too old
12778 Use --without-zlib to disable zlib support." >&5
12779 echo "$as_me: error: zlib version is too old
12780 Use --without-zlib to disable zlib support." >&2;}
12781    { (exit 1); exit 1; }; }
12782 fi
12783
12784 fi
12785
12786 if test "$with_krb5" = yes; then
12787 # Check for differences between MIT and Heimdal (KTH) releases
12788   echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
12789 echo $ECHO_N "checking for krb5_ticket.enc_part2... $ECHO_C" >&6
12790 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
12791   echo $ECHO_N "(cached) $ECHO_C" >&6
12792 else
12793   cat >conftest.$ac_ext <<_ACEOF
12794 /* confdefs.h.  */
12795 _ACEOF
12796 cat confdefs.h >>conftest.$ac_ext
12797 cat >>conftest.$ac_ext <<_ACEOF
12798 /* end confdefs.h.  */
12799 #include <krb5.h>
12800
12801 int
12802 main ()
12803 {
12804 static krb5_ticket ac_aggr;
12805 if (ac_aggr.enc_part2)
12806 return 0;
12807   ;
12808   return 0;
12809 }
12810 _ACEOF
12811 rm -f conftest.$ac_objext
12812 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12813   (eval $ac_compile) 2>conftest.er1
12814   ac_status=$?
12815   grep -v '^ *+' conftest.er1 >conftest.err
12816   rm -f conftest.er1
12817   cat conftest.err >&5
12818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12819   (exit $ac_status); } &&
12820          { ac_try='test -z "$ac_c_werror_flag"
12821                          || test ! -s conftest.err'
12822   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12823   (eval $ac_try) 2>&5
12824   ac_status=$?
12825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12826   (exit $ac_status); }; } &&
12827          { ac_try='test -s conftest.$ac_objext'
12828   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12829   (eval $ac_try) 2>&5
12830   ac_status=$?
12831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12832   (exit $ac_status); }; }; then
12833   ac_cv_member_krb5_ticket_enc_part2=yes
12834 else
12835   echo "$as_me: failed program was:" >&5
12836 sed 's/^/| /' conftest.$ac_ext >&5
12837
12838 cat >conftest.$ac_ext <<_ACEOF
12839 /* confdefs.h.  */
12840 _ACEOF
12841 cat confdefs.h >>conftest.$ac_ext
12842 cat >>conftest.$ac_ext <<_ACEOF
12843 /* end confdefs.h.  */
12844 #include <krb5.h>
12845
12846 int
12847 main ()
12848 {
12849 static krb5_ticket ac_aggr;
12850 if (sizeof ac_aggr.enc_part2)
12851 return 0;
12852   ;
12853   return 0;
12854 }
12855 _ACEOF
12856 rm -f conftest.$ac_objext
12857 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12858   (eval $ac_compile) 2>conftest.er1
12859   ac_status=$?
12860   grep -v '^ *+' conftest.er1 >conftest.err
12861   rm -f conftest.er1
12862   cat conftest.err >&5
12863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12864   (exit $ac_status); } &&
12865          { ac_try='test -z "$ac_c_werror_flag"
12866                          || test ! -s conftest.err'
12867   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12868   (eval $ac_try) 2>&5
12869   ac_status=$?
12870   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12871   (exit $ac_status); }; } &&
12872          { ac_try='test -s conftest.$ac_objext'
12873   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12874   (eval $ac_try) 2>&5
12875   ac_status=$?
12876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12877   (exit $ac_status); }; }; then
12878   ac_cv_member_krb5_ticket_enc_part2=yes
12879 else
12880   echo "$as_me: failed program was:" >&5
12881 sed 's/^/| /' conftest.$ac_ext >&5
12882
12883 ac_cv_member_krb5_ticket_enc_part2=no
12884 fi
12885 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12886 fi
12887 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12888 fi
12889 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
12890 echo "${ECHO_T}$ac_cv_member_krb5_ticket_enc_part2" >&6
12891 if test $ac_cv_member_krb5_ticket_enc_part2 = yes; then
12892
12893 cat >>confdefs.h <<_ACEOF
12894 #define HAVE_KRB5_TICKET_ENC_PART2 1
12895 _ACEOF
12896
12897
12898 else
12899   echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
12900 echo $ECHO_N "checking for krb5_ticket.client... $ECHO_C" >&6
12901 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
12902   echo $ECHO_N "(cached) $ECHO_C" >&6
12903 else
12904   cat >conftest.$ac_ext <<_ACEOF
12905 /* confdefs.h.  */
12906 _ACEOF
12907 cat confdefs.h >>conftest.$ac_ext
12908 cat >>conftest.$ac_ext <<_ACEOF
12909 /* end confdefs.h.  */
12910 #include <krb5.h>
12911
12912 int
12913 main ()
12914 {
12915 static krb5_ticket ac_aggr;
12916 if (ac_aggr.client)
12917 return 0;
12918   ;
12919   return 0;
12920 }
12921 _ACEOF
12922 rm -f conftest.$ac_objext
12923 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12924   (eval $ac_compile) 2>conftest.er1
12925   ac_status=$?
12926   grep -v '^ *+' conftest.er1 >conftest.err
12927   rm -f conftest.er1
12928   cat conftest.err >&5
12929   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12930   (exit $ac_status); } &&
12931          { ac_try='test -z "$ac_c_werror_flag"
12932                          || test ! -s conftest.err'
12933   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12934   (eval $ac_try) 2>&5
12935   ac_status=$?
12936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12937   (exit $ac_status); }; } &&
12938          { ac_try='test -s conftest.$ac_objext'
12939   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12940   (eval $ac_try) 2>&5
12941   ac_status=$?
12942   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12943   (exit $ac_status); }; }; then
12944   ac_cv_member_krb5_ticket_client=yes
12945 else
12946   echo "$as_me: failed program was:" >&5
12947 sed 's/^/| /' conftest.$ac_ext >&5
12948
12949 cat >conftest.$ac_ext <<_ACEOF
12950 /* confdefs.h.  */
12951 _ACEOF
12952 cat confdefs.h >>conftest.$ac_ext
12953 cat >>conftest.$ac_ext <<_ACEOF
12954 /* end confdefs.h.  */
12955 #include <krb5.h>
12956
12957 int
12958 main ()
12959 {
12960 static krb5_ticket ac_aggr;
12961 if (sizeof ac_aggr.client)
12962 return 0;
12963   ;
12964   return 0;
12965 }
12966 _ACEOF
12967 rm -f conftest.$ac_objext
12968 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12969   (eval $ac_compile) 2>conftest.er1
12970   ac_status=$?
12971   grep -v '^ *+' conftest.er1 >conftest.err
12972   rm -f conftest.er1
12973   cat conftest.err >&5
12974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12975   (exit $ac_status); } &&
12976          { ac_try='test -z "$ac_c_werror_flag"
12977                          || test ! -s conftest.err'
12978   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12979   (eval $ac_try) 2>&5
12980   ac_status=$?
12981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12982   (exit $ac_status); }; } &&
12983          { ac_try='test -s conftest.$ac_objext'
12984   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12985   (eval $ac_try) 2>&5
12986   ac_status=$?
12987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12988   (exit $ac_status); }; }; then
12989   ac_cv_member_krb5_ticket_client=yes
12990 else
12991   echo "$as_me: failed program was:" >&5
12992 sed 's/^/| /' conftest.$ac_ext >&5
12993
12994 ac_cv_member_krb5_ticket_client=no
12995 fi
12996 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12997 fi
12998 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12999 fi
13000 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
13001 echo "${ECHO_T}$ac_cv_member_krb5_ticket_client" >&6
13002 if test $ac_cv_member_krb5_ticket_client = yes; then
13003
13004 cat >>confdefs.h <<_ACEOF
13005 #define HAVE_KRB5_TICKET_CLIENT 1
13006 _ACEOF
13007
13008
13009 else
13010   { { echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
13011 echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
13012    { (exit 1); exit 1; }; }
13013 fi
13014
13015 fi
13016
13017   echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
13018 echo $ECHO_N "checking for krb5_error.text.data... $ECHO_C" >&6
13019 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
13020   echo $ECHO_N "(cached) $ECHO_C" >&6
13021 else
13022   cat >conftest.$ac_ext <<_ACEOF
13023 /* confdefs.h.  */
13024 _ACEOF
13025 cat confdefs.h >>conftest.$ac_ext
13026 cat >>conftest.$ac_ext <<_ACEOF
13027 /* end confdefs.h.  */
13028 #include <krb5.h>
13029
13030 int
13031 main ()
13032 {
13033 static krb5_error ac_aggr;
13034 if (ac_aggr.text.data)
13035 return 0;
13036   ;
13037   return 0;
13038 }
13039 _ACEOF
13040 rm -f conftest.$ac_objext
13041 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13042   (eval $ac_compile) 2>conftest.er1
13043   ac_status=$?
13044   grep -v '^ *+' conftest.er1 >conftest.err
13045   rm -f conftest.er1
13046   cat conftest.err >&5
13047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13048   (exit $ac_status); } &&
13049          { ac_try='test -z "$ac_c_werror_flag"
13050                          || test ! -s conftest.err'
13051   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13052   (eval $ac_try) 2>&5
13053   ac_status=$?
13054   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13055   (exit $ac_status); }; } &&
13056          { ac_try='test -s conftest.$ac_objext'
13057   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13058   (eval $ac_try) 2>&5
13059   ac_status=$?
13060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13061   (exit $ac_status); }; }; then
13062   ac_cv_member_krb5_error_text_data=yes
13063 else
13064   echo "$as_me: failed program was:" >&5
13065 sed 's/^/| /' conftest.$ac_ext >&5
13066
13067 cat >conftest.$ac_ext <<_ACEOF
13068 /* confdefs.h.  */
13069 _ACEOF
13070 cat confdefs.h >>conftest.$ac_ext
13071 cat >>conftest.$ac_ext <<_ACEOF
13072 /* end confdefs.h.  */
13073 #include <krb5.h>
13074
13075 int
13076 main ()
13077 {
13078 static krb5_error ac_aggr;
13079 if (sizeof ac_aggr.text.data)
13080 return 0;
13081   ;
13082   return 0;
13083 }
13084 _ACEOF
13085 rm -f conftest.$ac_objext
13086 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13087   (eval $ac_compile) 2>conftest.er1
13088   ac_status=$?
13089   grep -v '^ *+' conftest.er1 >conftest.err
13090   rm -f conftest.er1
13091   cat conftest.err >&5
13092   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13093   (exit $ac_status); } &&
13094          { ac_try='test -z "$ac_c_werror_flag"
13095                          || test ! -s conftest.err'
13096   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13097   (eval $ac_try) 2>&5
13098   ac_status=$?
13099   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13100   (exit $ac_status); }; } &&
13101          { ac_try='test -s conftest.$ac_objext'
13102   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13103   (eval $ac_try) 2>&5
13104   ac_status=$?
13105   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13106   (exit $ac_status); }; }; then
13107   ac_cv_member_krb5_error_text_data=yes
13108 else
13109   echo "$as_me: failed program was:" >&5
13110 sed 's/^/| /' conftest.$ac_ext >&5
13111
13112 ac_cv_member_krb5_error_text_data=no
13113 fi
13114 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13115 fi
13116 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13117 fi
13118 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
13119 echo "${ECHO_T}$ac_cv_member_krb5_error_text_data" >&6
13120 if test $ac_cv_member_krb5_error_text_data = yes; then
13121
13122 cat >>confdefs.h <<_ACEOF
13123 #define HAVE_KRB5_ERROR_TEXT_DATA 1
13124 _ACEOF
13125
13126
13127 else
13128   echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
13129 echo $ECHO_N "checking for krb5_error.e_data... $ECHO_C" >&6
13130 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
13131   echo $ECHO_N "(cached) $ECHO_C" >&6
13132 else
13133   cat >conftest.$ac_ext <<_ACEOF
13134 /* confdefs.h.  */
13135 _ACEOF
13136 cat confdefs.h >>conftest.$ac_ext
13137 cat >>conftest.$ac_ext <<_ACEOF
13138 /* end confdefs.h.  */
13139 #include <krb5.h>
13140
13141 int
13142 main ()
13143 {
13144 static krb5_error ac_aggr;
13145 if (ac_aggr.e_data)
13146 return 0;
13147   ;
13148   return 0;
13149 }
13150 _ACEOF
13151 rm -f conftest.$ac_objext
13152 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13153   (eval $ac_compile) 2>conftest.er1
13154   ac_status=$?
13155   grep -v '^ *+' conftest.er1 >conftest.err
13156   rm -f conftest.er1
13157   cat conftest.err >&5
13158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13159   (exit $ac_status); } &&
13160          { ac_try='test -z "$ac_c_werror_flag"
13161                          || test ! -s conftest.err'
13162   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13163   (eval $ac_try) 2>&5
13164   ac_status=$?
13165   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13166   (exit $ac_status); }; } &&
13167          { ac_try='test -s conftest.$ac_objext'
13168   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13169   (eval $ac_try) 2>&5
13170   ac_status=$?
13171   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13172   (exit $ac_status); }; }; then
13173   ac_cv_member_krb5_error_e_data=yes
13174 else
13175   echo "$as_me: failed program was:" >&5
13176 sed 's/^/| /' conftest.$ac_ext >&5
13177
13178 cat >conftest.$ac_ext <<_ACEOF
13179 /* confdefs.h.  */
13180 _ACEOF
13181 cat confdefs.h >>conftest.$ac_ext
13182 cat >>conftest.$ac_ext <<_ACEOF
13183 /* end confdefs.h.  */
13184 #include <krb5.h>
13185
13186 int
13187 main ()
13188 {
13189 static krb5_error ac_aggr;
13190 if (sizeof ac_aggr.e_data)
13191 return 0;
13192   ;
13193   return 0;
13194 }
13195 _ACEOF
13196 rm -f conftest.$ac_objext
13197 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13198   (eval $ac_compile) 2>conftest.er1
13199   ac_status=$?
13200   grep -v '^ *+' conftest.er1 >conftest.err
13201   rm -f conftest.er1
13202   cat conftest.err >&5
13203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13204   (exit $ac_status); } &&
13205          { ac_try='test -z "$ac_c_werror_flag"
13206                          || test ! -s conftest.err'
13207   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13208   (eval $ac_try) 2>&5
13209   ac_status=$?
13210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13211   (exit $ac_status); }; } &&
13212          { ac_try='test -s conftest.$ac_objext'
13213   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13214   (eval $ac_try) 2>&5
13215   ac_status=$?
13216   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13217   (exit $ac_status); }; }; then
13218   ac_cv_member_krb5_error_e_data=yes
13219 else
13220   echo "$as_me: failed program was:" >&5
13221 sed 's/^/| /' conftest.$ac_ext >&5
13222
13223 ac_cv_member_krb5_error_e_data=no
13224 fi
13225 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13226 fi
13227 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13228 fi
13229 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
13230 echo "${ECHO_T}$ac_cv_member_krb5_error_e_data" >&6
13231 if test $ac_cv_member_krb5_error_e_data = yes; then
13232
13233 cat >>confdefs.h <<_ACEOF
13234 #define HAVE_KRB5_ERROR_E_DATA 1
13235 _ACEOF
13236
13237
13238 else
13239   { { echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
13240 echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
13241    { (exit 1); exit 1; }; }
13242 fi
13243
13244 fi
13245
13246 fi
13247
13248 # This is probably only present on Darwin, but may as well check always
13249 echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
13250 echo $ECHO_N "checking whether F_FULLFSYNC is declared... $ECHO_C" >&6
13251 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
13252   echo $ECHO_N "(cached) $ECHO_C" >&6
13253 else
13254   cat >conftest.$ac_ext <<_ACEOF
13255 /* confdefs.h.  */
13256 _ACEOF
13257 cat confdefs.h >>conftest.$ac_ext
13258 cat >>conftest.$ac_ext <<_ACEOF
13259 /* end confdefs.h.  */
13260 #include <fcntl.h>
13261
13262 int
13263 main ()
13264 {
13265 #ifndef F_FULLFSYNC
13266   char *p = (char *) F_FULLFSYNC;
13267 #endif
13268
13269   ;
13270   return 0;
13271 }
13272 _ACEOF
13273 rm -f conftest.$ac_objext
13274 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13275   (eval $ac_compile) 2>conftest.er1
13276   ac_status=$?
13277   grep -v '^ *+' conftest.er1 >conftest.err
13278   rm -f conftest.er1
13279   cat conftest.err >&5
13280   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13281   (exit $ac_status); } &&
13282          { ac_try='test -z "$ac_c_werror_flag"
13283                          || test ! -s conftest.err'
13284   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13285   (eval $ac_try) 2>&5
13286   ac_status=$?
13287   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13288   (exit $ac_status); }; } &&
13289          { ac_try='test -s conftest.$ac_objext'
13290   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13291   (eval $ac_try) 2>&5
13292   ac_status=$?
13293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13294   (exit $ac_status); }; }; then
13295   ac_cv_have_decl_F_FULLFSYNC=yes
13296 else
13297   echo "$as_me: failed program was:" >&5
13298 sed 's/^/| /' conftest.$ac_ext >&5
13299
13300 ac_cv_have_decl_F_FULLFSYNC=no
13301 fi
13302 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13303 fi
13304 echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
13305 echo "${ECHO_T}$ac_cv_have_decl_F_FULLFSYNC" >&6
13306 if test $ac_cv_have_decl_F_FULLFSYNC = yes; then
13307
13308 cat >>confdefs.h <<_ACEOF
13309 #define HAVE_DECL_F_FULLFSYNC 1
13310 _ACEOF
13311
13312
13313 else
13314   cat >>confdefs.h <<_ACEOF
13315 #define HAVE_DECL_F_FULLFSYNC 0
13316 _ACEOF
13317
13318
13319 fi
13320
13321
13322
13323 ##
13324 ## Functions, global variables
13325 ##
13326
13327 echo "$as_me:$LINENO: checking for int timezone" >&5
13328 echo $ECHO_N "checking for int timezone... $ECHO_C" >&6
13329 if test "${pgac_cv_var_int_timezone+set}" = set; then
13330   echo $ECHO_N "(cached) $ECHO_C" >&6
13331 else
13332   cat >conftest.$ac_ext <<_ACEOF
13333 /* confdefs.h.  */
13334 _ACEOF
13335 cat confdefs.h >>conftest.$ac_ext
13336 cat >>conftest.$ac_ext <<_ACEOF
13337 /* end confdefs.h.  */
13338 #include <time.h>
13339 int res;
13340 int
13341 main ()
13342 {
13343 #ifndef __CYGWIN__
13344 res = timezone / 60;
13345 #else
13346 res = _timezone / 60;
13347 #endif
13348   ;
13349   return 0;
13350 }
13351 _ACEOF
13352 rm -f conftest.$ac_objext conftest$ac_exeext
13353 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13354   (eval $ac_link) 2>conftest.er1
13355   ac_status=$?
13356   grep -v '^ *+' conftest.er1 >conftest.err
13357   rm -f conftest.er1
13358   cat conftest.err >&5
13359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13360   (exit $ac_status); } &&
13361          { ac_try='test -z "$ac_c_werror_flag"
13362                          || test ! -s conftest.err'
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); }; } &&
13368          { ac_try='test -s conftest$ac_exeext'
13369   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13370   (eval $ac_try) 2>&5
13371   ac_status=$?
13372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13373   (exit $ac_status); }; }; then
13374   pgac_cv_var_int_timezone=yes
13375 else
13376   echo "$as_me: failed program was:" >&5
13377 sed 's/^/| /' conftest.$ac_ext >&5
13378
13379 pgac_cv_var_int_timezone=no
13380 fi
13381 rm -f conftest.err conftest.$ac_objext \
13382       conftest$ac_exeext conftest.$ac_ext
13383 fi
13384 echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
13385 echo "${ECHO_T}$pgac_cv_var_int_timezone" >&6
13386 if test x"$pgac_cv_var_int_timezone" = xyes ; then
13387
13388 cat >>confdefs.h <<\_ACEOF
13389 #define HAVE_INT_TIMEZONE
13390 _ACEOF
13391
13392 fi
13393 echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
13394 echo $ECHO_N "checking types of arguments for accept()... $ECHO_C" >&6
13395  if test "${ac_cv_func_accept_return+set}" = set; then
13396   echo $ECHO_N "(cached) $ECHO_C" >&6
13397 else
13398    if test "${ac_cv_func_accept_arg1+set}" = set; then
13399   echo $ECHO_N "(cached) $ECHO_C" >&6
13400 else
13401     if test "${ac_cv_func_accept_arg2+set}" = set; then
13402   echo $ECHO_N "(cached) $ECHO_C" >&6
13403 else
13404      if test "${ac_cv_func_accept_arg3+set}" = set; then
13405   echo $ECHO_N "(cached) $ECHO_C" >&6
13406 else
13407       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
13408       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
13409        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
13410         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
13411          cat >conftest.$ac_ext <<_ACEOF
13412 /* confdefs.h.  */
13413 _ACEOF
13414 cat confdefs.h >>conftest.$ac_ext
13415 cat >>conftest.$ac_ext <<_ACEOF
13416 /* end confdefs.h.  */
13417 #ifdef HAVE_SYS_TYPES_H
13418 #include <sys/types.h>
13419 #endif
13420 #ifdef HAVE_SYS_SOCKET_H
13421 #include <sys/socket.h>
13422 #endif
13423 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
13424 int
13425 main ()
13426 {
13427
13428   ;
13429   return 0;
13430 }
13431 _ACEOF
13432 rm -f conftest.$ac_objext
13433 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13434   (eval $ac_compile) 2>conftest.er1
13435   ac_status=$?
13436   grep -v '^ *+' conftest.er1 >conftest.err
13437   rm -f conftest.er1
13438   cat conftest.err >&5
13439   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13440   (exit $ac_status); } &&
13441          { ac_try='test -z "$ac_c_werror_flag"
13442                          || test ! -s conftest.err'
13443   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13444   (eval $ac_try) 2>&5
13445   ac_status=$?
13446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13447   (exit $ac_status); }; } &&
13448          { ac_try='test -s conftest.$ac_objext'
13449   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13450   (eval $ac_try) 2>&5
13451   ac_status=$?
13452   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13453   (exit $ac_status); }; }; then
13454   ac_not_found=no; break 4
13455 else
13456   echo "$as_me: failed program was:" >&5
13457 sed 's/^/| /' conftest.$ac_ext >&5
13458
13459 ac_not_found=yes
13460 fi
13461 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13462        done
13463       done
13464      done
13465     done
13466     if test "$ac_not_found" = yes; then
13467       { { echo "$as_me:$LINENO: error: could not determine argument types" >&5
13468 echo "$as_me: error: could not determine argument types" >&2;}
13469    { (exit 1); exit 1; }; }
13470     fi
13471     if test "$ac_cv_func_accept_arg3" = "void"; then
13472       ac_cv_func_accept_arg3=int
13473     fi
13474
13475 fi
13476
13477 fi
13478
13479 fi
13480
13481 fi
13482  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
13483 echo "${ECHO_T}$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6
13484
13485 cat >>confdefs.h <<_ACEOF
13486 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
13487 _ACEOF
13488
13489
13490 cat >>confdefs.h <<_ACEOF
13491 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
13492 _ACEOF
13493
13494
13495 cat >>confdefs.h <<_ACEOF
13496 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
13497 _ACEOF
13498
13499
13500 cat >>confdefs.h <<_ACEOF
13501 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
13502 _ACEOF
13503
13504
13505 echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
13506 echo $ECHO_N "checking whether gettimeofday takes only one argument... $ECHO_C" >&6
13507 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
13508   echo $ECHO_N "(cached) $ECHO_C" >&6
13509 else
13510   cat >conftest.$ac_ext <<_ACEOF
13511 /* confdefs.h.  */
13512 _ACEOF
13513 cat confdefs.h >>conftest.$ac_ext
13514 cat >>conftest.$ac_ext <<_ACEOF
13515 /* end confdefs.h.  */
13516 #include <sys/time.h>
13517 int
13518 main ()
13519 {
13520 struct timeval *tp;
13521 struct timezone *tzp;
13522 gettimeofday(tp,tzp);
13523   ;
13524   return 0;
13525 }
13526 _ACEOF
13527 rm -f conftest.$ac_objext
13528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13529   (eval $ac_compile) 2>conftest.er1
13530   ac_status=$?
13531   grep -v '^ *+' conftest.er1 >conftest.err
13532   rm -f conftest.er1
13533   cat conftest.err >&5
13534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13535   (exit $ac_status); } &&
13536          { ac_try='test -z "$ac_c_werror_flag"
13537                          || test ! -s conftest.err'
13538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13539   (eval $ac_try) 2>&5
13540   ac_status=$?
13541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13542   (exit $ac_status); }; } &&
13543          { ac_try='test -s conftest.$ac_objext'
13544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13545   (eval $ac_try) 2>&5
13546   ac_status=$?
13547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13548   (exit $ac_status); }; }; then
13549   pgac_cv_func_gettimeofday_1arg=no
13550 else
13551   echo "$as_me: failed program was:" >&5
13552 sed 's/^/| /' conftest.$ac_ext >&5
13553
13554 pgac_cv_func_gettimeofday_1arg=yes
13555 fi
13556 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13557 fi
13558 echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
13559 echo "${ECHO_T}$pgac_cv_func_gettimeofday_1arg" >&6
13560 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
13561
13562 cat >>confdefs.h <<\_ACEOF
13563 #define GETTIMEOFDAY_1ARG
13564 _ACEOF
13565
13566 fi
13567
13568
13569
13570
13571
13572
13573
13574
13575
13576
13577
13578
13579
13580
13581
13582
13583
13584
13585
13586
13587
13588
13589 for ac_func in cbrt dlopen fcvt fdatasync getpeereid memmove poll pstat readlink setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
13590 do
13591 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13592 echo "$as_me:$LINENO: checking for $ac_func" >&5
13593 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13594 if eval "test \"\${$as_ac_var+set}\" = set"; then
13595   echo $ECHO_N "(cached) $ECHO_C" >&6
13596 else
13597   cat >conftest.$ac_ext <<_ACEOF
13598 /* confdefs.h.  */
13599 _ACEOF
13600 cat confdefs.h >>conftest.$ac_ext
13601 cat >>conftest.$ac_ext <<_ACEOF
13602 /* end confdefs.h.  */
13603 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13604    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13605 #define $ac_func innocuous_$ac_func
13606
13607 /* System header to define __stub macros and hopefully few prototypes,
13608     which can conflict with char $ac_func (); below.
13609     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13610     <limits.h> exists even on freestanding compilers.  */
13611
13612 #ifdef __STDC__
13613 # include <limits.h>
13614 #else
13615 # include <assert.h>
13616 #endif
13617
13618 #undef $ac_func
13619
13620 /* Override any gcc2 internal prototype to avoid an error.  */
13621 #ifdef __cplusplus
13622 extern "C"
13623 {
13624 #endif
13625 /* We use char because int might match the return type of a gcc2
13626    builtin and then its argument prototype would still apply.  */
13627 char $ac_func ();
13628 /* The GNU C library defines this for functions which it implements
13629     to always fail with ENOSYS.  Some functions are actually named
13630     something starting with __ and the normal name is an alias.  */
13631 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13632 choke me
13633 #else
13634 char (*f) () = $ac_func;
13635 #endif
13636 #ifdef __cplusplus
13637 }
13638 #endif
13639
13640 int
13641 main ()
13642 {
13643 return f != $ac_func;
13644   ;
13645   return 0;
13646 }
13647 _ACEOF
13648 rm -f conftest.$ac_objext conftest$ac_exeext
13649 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13650   (eval $ac_link) 2>conftest.er1
13651   ac_status=$?
13652   grep -v '^ *+' conftest.er1 >conftest.err
13653   rm -f conftest.er1
13654   cat conftest.err >&5
13655   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13656   (exit $ac_status); } &&
13657          { ac_try='test -z "$ac_c_werror_flag"
13658                          || test ! -s conftest.err'
13659   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13660   (eval $ac_try) 2>&5
13661   ac_status=$?
13662   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13663   (exit $ac_status); }; } &&
13664          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
13670   eval "$as_ac_var=yes"
13671 else
13672   echo "$as_me: failed program was:" >&5
13673 sed 's/^/| /' conftest.$ac_ext >&5
13674
13675 eval "$as_ac_var=no"
13676 fi
13677 rm -f conftest.err conftest.$ac_objext \
13678       conftest$ac_exeext conftest.$ac_ext
13679 fi
13680 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13681 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13682 if test `eval echo '${'$as_ac_var'}'` = yes; then
13683   cat >>confdefs.h <<_ACEOF
13684 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13685 _ACEOF
13686
13687 fi
13688 done
13689
13690
13691 echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
13692 echo $ECHO_N "checking whether fdatasync is declared... $ECHO_C" >&6
13693 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
13694   echo $ECHO_N "(cached) $ECHO_C" >&6
13695 else
13696   cat >conftest.$ac_ext <<_ACEOF
13697 /* confdefs.h.  */
13698 _ACEOF
13699 cat confdefs.h >>conftest.$ac_ext
13700 cat >>conftest.$ac_ext <<_ACEOF
13701 /* end confdefs.h.  */
13702 #include <unistd.h>
13703
13704 int
13705 main ()
13706 {
13707 #ifndef fdatasync
13708   char *p = (char *) fdatasync;
13709 #endif
13710
13711   ;
13712   return 0;
13713 }
13714 _ACEOF
13715 rm -f conftest.$ac_objext
13716 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13717   (eval $ac_compile) 2>conftest.er1
13718   ac_status=$?
13719   grep -v '^ *+' conftest.er1 >conftest.err
13720   rm -f conftest.er1
13721   cat conftest.err >&5
13722   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13723   (exit $ac_status); } &&
13724          { ac_try='test -z "$ac_c_werror_flag"
13725                          || test ! -s conftest.err'
13726   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13727   (eval $ac_try) 2>&5
13728   ac_status=$?
13729   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13730   (exit $ac_status); }; } &&
13731          { ac_try='test -s conftest.$ac_objext'
13732   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13733   (eval $ac_try) 2>&5
13734   ac_status=$?
13735   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13736   (exit $ac_status); }; }; then
13737   ac_cv_have_decl_fdatasync=yes
13738 else
13739   echo "$as_me: failed program was:" >&5
13740 sed 's/^/| /' conftest.$ac_ext >&5
13741
13742 ac_cv_have_decl_fdatasync=no
13743 fi
13744 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13745 fi
13746 echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
13747 echo "${ECHO_T}$ac_cv_have_decl_fdatasync" >&6
13748 if test $ac_cv_have_decl_fdatasync = yes; then
13749
13750 cat >>confdefs.h <<_ACEOF
13751 #define HAVE_DECL_FDATASYNC 1
13752 _ACEOF
13753
13754
13755 else
13756   cat >>confdefs.h <<_ACEOF
13757 #define HAVE_DECL_FDATASYNC 0
13758 _ACEOF
13759
13760
13761 fi
13762
13763
13764
13765 HAVE_IPV6=no
13766 echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
13767 echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6
13768 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
13769   echo $ECHO_N "(cached) $ECHO_C" >&6
13770 else
13771   cat >conftest.$ac_ext <<_ACEOF
13772 /* confdefs.h.  */
13773 _ACEOF
13774 cat confdefs.h >>conftest.$ac_ext
13775 cat >>conftest.$ac_ext <<_ACEOF
13776 /* end confdefs.h.  */
13777 $ac_includes_default
13778 #include <netinet/in.h>
13779
13780 int
13781 main ()
13782 {
13783 if ((struct sockaddr_in6 *) 0)
13784   return 0;
13785 if (sizeof (struct sockaddr_in6))
13786   return 0;
13787   ;
13788   return 0;
13789 }
13790 _ACEOF
13791 rm -f conftest.$ac_objext
13792 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13793   (eval $ac_compile) 2>conftest.er1
13794   ac_status=$?
13795   grep -v '^ *+' conftest.er1 >conftest.err
13796   rm -f conftest.er1
13797   cat conftest.err >&5
13798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13799   (exit $ac_status); } &&
13800          { ac_try='test -z "$ac_c_werror_flag"
13801                          || test ! -s conftest.err'
13802   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13803   (eval $ac_try) 2>&5
13804   ac_status=$?
13805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13806   (exit $ac_status); }; } &&
13807          { ac_try='test -s conftest.$ac_objext'
13808   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13809   (eval $ac_try) 2>&5
13810   ac_status=$?
13811   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13812   (exit $ac_status); }; }; then
13813   ac_cv_type_struct_sockaddr_in6=yes
13814 else
13815   echo "$as_me: failed program was:" >&5
13816 sed 's/^/| /' conftest.$ac_ext >&5
13817
13818 ac_cv_type_struct_sockaddr_in6=no
13819 fi
13820 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13821 fi
13822 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
13823 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6
13824 if test $ac_cv_type_struct_sockaddr_in6 = yes; then
13825
13826 cat >>confdefs.h <<\_ACEOF
13827 #define HAVE_IPV6 1
13828 _ACEOF
13829
13830          HAVE_IPV6=yes
13831 fi
13832
13833
13834
13835 echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
13836 echo $ECHO_N "checking for PS_STRINGS... $ECHO_C" >&6
13837 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
13838   echo $ECHO_N "(cached) $ECHO_C" >&6
13839 else
13840   cat >conftest.$ac_ext <<_ACEOF
13841 /* confdefs.h.  */
13842 _ACEOF
13843 cat confdefs.h >>conftest.$ac_ext
13844 cat >>conftest.$ac_ext <<_ACEOF
13845 /* end confdefs.h.  */
13846 #include <machine/vmparam.h>
13847 #include <sys/exec.h>
13848
13849 int
13850 main ()
13851 {
13852 PS_STRINGS->ps_nargvstr = 1;
13853 PS_STRINGS->ps_argvstr = "foo";
13854   ;
13855   return 0;
13856 }
13857 _ACEOF
13858 rm -f conftest.$ac_objext conftest$ac_exeext
13859 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13860   (eval $ac_link) 2>conftest.er1
13861   ac_status=$?
13862   grep -v '^ *+' conftest.er1 >conftest.err
13863   rm -f conftest.er1
13864   cat conftest.err >&5
13865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13866   (exit $ac_status); } &&
13867          { ac_try='test -z "$ac_c_werror_flag"
13868                          || test ! -s conftest.err'
13869   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13870   (eval $ac_try) 2>&5
13871   ac_status=$?
13872   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13873   (exit $ac_status); }; } &&
13874          { ac_try='test -s conftest$ac_exeext'
13875   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13876   (eval $ac_try) 2>&5
13877   ac_status=$?
13878   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13879   (exit $ac_status); }; }; then
13880   pgac_cv_var_PS_STRINGS=yes
13881 else
13882   echo "$as_me: failed program was:" >&5
13883 sed 's/^/| /' conftest.$ac_ext >&5
13884
13885 pgac_cv_var_PS_STRINGS=no
13886 fi
13887 rm -f conftest.err conftest.$ac_objext \
13888       conftest$ac_exeext conftest.$ac_ext
13889 fi
13890 echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
13891 echo "${ECHO_T}$pgac_cv_var_PS_STRINGS" >&6
13892 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
13893
13894 cat >>confdefs.h <<\_ACEOF
13895 #define HAVE_PS_STRINGS
13896 _ACEOF
13897
13898 fi
13899
13900
13901 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
13902 # is missing.  Yes, there are machines that have only one.  We may
13903 # also decide to use snprintf.c if snprintf() is present but does not
13904 # have all the features we need --- see below.
13905
13906 if test "$PORTNAME" = "win32"; then
13907   # Win32 gets snprintf.c built unconditionally.
13908   #
13909   # To properly translate all NLS languages strings, we must support the
13910   # *printf() %$ format, which allows *printf() arguments to be selected
13911   # by position in the translated string.
13912   #
13913   # libintl versions < 0.13 use the native *printf() functions, and Win32
13914   # *printf() doesn't understand %$, so we must use our /port versions,
13915   # which do understand %$. libintl versions >= 0.13 include their own
13916   # *printf versions on Win32.  The libintl 0.13 release note text is:
13917   #
13918   #   C format strings with positions, as they arise when a translator
13919   #   needs to reorder a sentence, are now supported on all platforms.
13920   #   On those few platforms (NetBSD and Woe32) for which the native
13921   #   printf()/fprintf()/... functions don't support such format
13922   #   strings, replacements are provided through <libintl.h>.
13923   #
13924   # We could use libintl >= 0.13's *printf() if we were sure that we had
13925   # a litint >= 0.13 at runtime, but seeing that there is no clean way
13926   # to guarantee that, it is best to just use our own, so we are sure to
13927   # get %$ support. In include/port.h we disable the *printf() macros
13928   # that might have been defined by libintl.
13929   #
13930   # We do this unconditionally whether NLS is used or not so we are sure
13931   # that all Win32 libraries and binaries behave the same.
13932   pgac_need_repl_snprintf=yes
13933 else
13934   pgac_need_repl_snprintf=no
13935
13936 for ac_func in snprintf
13937 do
13938 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13939 echo "$as_me:$LINENO: checking for $ac_func" >&5
13940 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13941 if eval "test \"\${$as_ac_var+set}\" = set"; then
13942   echo $ECHO_N "(cached) $ECHO_C" >&6
13943 else
13944   cat >conftest.$ac_ext <<_ACEOF
13945 /* confdefs.h.  */
13946 _ACEOF
13947 cat confdefs.h >>conftest.$ac_ext
13948 cat >>conftest.$ac_ext <<_ACEOF
13949 /* end confdefs.h.  */
13950 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13951    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13952 #define $ac_func innocuous_$ac_func
13953
13954 /* System header to define __stub macros and hopefully few prototypes,
13955     which can conflict with char $ac_func (); below.
13956     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13957     <limits.h> exists even on freestanding compilers.  */
13958
13959 #ifdef __STDC__
13960 # include <limits.h>
13961 #else
13962 # include <assert.h>
13963 #endif
13964
13965 #undef $ac_func
13966
13967 /* Override any gcc2 internal prototype to avoid an error.  */
13968 #ifdef __cplusplus
13969 extern "C"
13970 {
13971 #endif
13972 /* We use char because int might match the return type of a gcc2
13973    builtin and then its argument prototype would still apply.  */
13974 char $ac_func ();
13975 /* The GNU C library defines this for functions which it implements
13976     to always fail with ENOSYS.  Some functions are actually named
13977     something starting with __ and the normal name is an alias.  */
13978 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13979 choke me
13980 #else
13981 char (*f) () = $ac_func;
13982 #endif
13983 #ifdef __cplusplus
13984 }
13985 #endif
13986
13987 int
13988 main ()
13989 {
13990 return f != $ac_func;
13991   ;
13992   return 0;
13993 }
13994 _ACEOF
13995 rm -f conftest.$ac_objext conftest$ac_exeext
13996 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13997   (eval $ac_link) 2>conftest.er1
13998   ac_status=$?
13999   grep -v '^ *+' conftest.er1 >conftest.err
14000   rm -f conftest.er1
14001   cat conftest.err >&5
14002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14003   (exit $ac_status); } &&
14004          { ac_try='test -z "$ac_c_werror_flag"
14005                          || test ! -s conftest.err'
14006   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14007   (eval $ac_try) 2>&5
14008   ac_status=$?
14009   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14010   (exit $ac_status); }; } &&
14011          { ac_try='test -s conftest$ac_exeext'
14012   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14013   (eval $ac_try) 2>&5
14014   ac_status=$?
14015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14016   (exit $ac_status); }; }; then
14017   eval "$as_ac_var=yes"
14018 else
14019   echo "$as_me: failed program was:" >&5
14020 sed 's/^/| /' conftest.$ac_ext >&5
14021
14022 eval "$as_ac_var=no"
14023 fi
14024 rm -f conftest.err conftest.$ac_objext \
14025       conftest$ac_exeext conftest.$ac_ext
14026 fi
14027 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14028 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14029 if test `eval echo '${'$as_ac_var'}'` = yes; then
14030   cat >>confdefs.h <<_ACEOF
14031 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14032 _ACEOF
14033
14034 else
14035   pgac_need_repl_snprintf=yes
14036 fi
14037 done
14038
14039
14040 for ac_func in vsnprintf
14041 do
14042 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14043 echo "$as_me:$LINENO: checking for $ac_func" >&5
14044 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14045 if eval "test \"\${$as_ac_var+set}\" = set"; then
14046   echo $ECHO_N "(cached) $ECHO_C" >&6
14047 else
14048   cat >conftest.$ac_ext <<_ACEOF
14049 /* confdefs.h.  */
14050 _ACEOF
14051 cat confdefs.h >>conftest.$ac_ext
14052 cat >>conftest.$ac_ext <<_ACEOF
14053 /* end confdefs.h.  */
14054 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14055    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14056 #define $ac_func innocuous_$ac_func
14057
14058 /* System header to define __stub macros and hopefully few prototypes,
14059     which can conflict with char $ac_func (); below.
14060     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14061     <limits.h> exists even on freestanding compilers.  */
14062
14063 #ifdef __STDC__
14064 # include <limits.h>
14065 #else
14066 # include <assert.h>
14067 #endif
14068
14069 #undef $ac_func
14070
14071 /* Override any gcc2 internal prototype to avoid an error.  */
14072 #ifdef __cplusplus
14073 extern "C"
14074 {
14075 #endif
14076 /* We use char because int might match the return type of a gcc2
14077    builtin and then its argument prototype would still apply.  */
14078 char $ac_func ();
14079 /* The GNU C library defines this for functions which it implements
14080     to always fail with ENOSYS.  Some functions are actually named
14081     something starting with __ and the normal name is an alias.  */
14082 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14083 choke me
14084 #else
14085 char (*f) () = $ac_func;
14086 #endif
14087 #ifdef __cplusplus
14088 }
14089 #endif
14090
14091 int
14092 main ()
14093 {
14094 return f != $ac_func;
14095   ;
14096   return 0;
14097 }
14098 _ACEOF
14099 rm -f conftest.$ac_objext conftest$ac_exeext
14100 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14101   (eval $ac_link) 2>conftest.er1
14102   ac_status=$?
14103   grep -v '^ *+' conftest.er1 >conftest.err
14104   rm -f conftest.er1
14105   cat conftest.err >&5
14106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14107   (exit $ac_status); } &&
14108          { ac_try='test -z "$ac_c_werror_flag"
14109                          || test ! -s conftest.err'
14110   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14111   (eval $ac_try) 2>&5
14112   ac_status=$?
14113   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14114   (exit $ac_status); }; } &&
14115          { ac_try='test -s conftest$ac_exeext'
14116   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14117   (eval $ac_try) 2>&5
14118   ac_status=$?
14119   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14120   (exit $ac_status); }; }; then
14121   eval "$as_ac_var=yes"
14122 else
14123   echo "$as_me: failed program was:" >&5
14124 sed 's/^/| /' conftest.$ac_ext >&5
14125
14126 eval "$as_ac_var=no"
14127 fi
14128 rm -f conftest.err conftest.$ac_objext \
14129       conftest$ac_exeext conftest.$ac_ext
14130 fi
14131 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14132 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14133 if test `eval echo '${'$as_ac_var'}'` = yes; then
14134   cat >>confdefs.h <<_ACEOF
14135 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14136 _ACEOF
14137
14138 else
14139   pgac_need_repl_snprintf=yes
14140 fi
14141 done
14142
14143 fi
14144
14145
14146 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
14147 # include/c.h will provide declarations.  Note this is a separate test
14148 # from whether the functions exist in the C library --- there are
14149 # systems that have the functions but don't bother to declare them :-(
14150
14151 echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
14152 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6
14153 if test "${ac_cv_have_decl_snprintf+set}" = set; then
14154   echo $ECHO_N "(cached) $ECHO_C" >&6
14155 else
14156   cat >conftest.$ac_ext <<_ACEOF
14157 /* confdefs.h.  */
14158 _ACEOF
14159 cat confdefs.h >>conftest.$ac_ext
14160 cat >>conftest.$ac_ext <<_ACEOF
14161 /* end confdefs.h.  */
14162 $ac_includes_default
14163 int
14164 main ()
14165 {
14166 #ifndef snprintf
14167   char *p = (char *) snprintf;
14168 #endif
14169
14170   ;
14171   return 0;
14172 }
14173 _ACEOF
14174 rm -f conftest.$ac_objext
14175 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14176   (eval $ac_compile) 2>conftest.er1
14177   ac_status=$?
14178   grep -v '^ *+' conftest.er1 >conftest.err
14179   rm -f conftest.er1
14180   cat conftest.err >&5
14181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14182   (exit $ac_status); } &&
14183          { ac_try='test -z "$ac_c_werror_flag"
14184                          || test ! -s conftest.err'
14185   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14186   (eval $ac_try) 2>&5
14187   ac_status=$?
14188   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14189   (exit $ac_status); }; } &&
14190          { ac_try='test -s conftest.$ac_objext'
14191   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14192   (eval $ac_try) 2>&5
14193   ac_status=$?
14194   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14195   (exit $ac_status); }; }; then
14196   ac_cv_have_decl_snprintf=yes
14197 else
14198   echo "$as_me: failed program was:" >&5
14199 sed 's/^/| /' conftest.$ac_ext >&5
14200
14201 ac_cv_have_decl_snprintf=no
14202 fi
14203 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14204 fi
14205 echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
14206 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6
14207 if test $ac_cv_have_decl_snprintf = yes; then
14208
14209 cat >>confdefs.h <<_ACEOF
14210 #define HAVE_DECL_SNPRINTF 1
14211 _ACEOF
14212
14213
14214 else
14215   cat >>confdefs.h <<_ACEOF
14216 #define HAVE_DECL_SNPRINTF 0
14217 _ACEOF
14218
14219
14220 fi
14221 echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
14222 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6
14223 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
14224   echo $ECHO_N "(cached) $ECHO_C" >&6
14225 else
14226   cat >conftest.$ac_ext <<_ACEOF
14227 /* confdefs.h.  */
14228 _ACEOF
14229 cat confdefs.h >>conftest.$ac_ext
14230 cat >>conftest.$ac_ext <<_ACEOF
14231 /* end confdefs.h.  */
14232 $ac_includes_default
14233 int
14234 main ()
14235 {
14236 #ifndef vsnprintf
14237   char *p = (char *) vsnprintf;
14238 #endif
14239
14240   ;
14241   return 0;
14242 }
14243 _ACEOF
14244 rm -f conftest.$ac_objext
14245 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14246   (eval $ac_compile) 2>conftest.er1
14247   ac_status=$?
14248   grep -v '^ *+' conftest.er1 >conftest.err
14249   rm -f conftest.er1
14250   cat conftest.err >&5
14251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14252   (exit $ac_status); } &&
14253          { ac_try='test -z "$ac_c_werror_flag"
14254                          || test ! -s conftest.err'
14255   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14256   (eval $ac_try) 2>&5
14257   ac_status=$?
14258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14259   (exit $ac_status); }; } &&
14260          { ac_try='test -s conftest.$ac_objext'
14261   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14262   (eval $ac_try) 2>&5
14263   ac_status=$?
14264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14265   (exit $ac_status); }; }; then
14266   ac_cv_have_decl_vsnprintf=yes
14267 else
14268   echo "$as_me: failed program was:" >&5
14269 sed 's/^/| /' conftest.$ac_ext >&5
14270
14271 ac_cv_have_decl_vsnprintf=no
14272 fi
14273 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14274 fi
14275 echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
14276 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6
14277 if test $ac_cv_have_decl_vsnprintf = yes; then
14278
14279 cat >>confdefs.h <<_ACEOF
14280 #define HAVE_DECL_VSNPRINTF 1
14281 _ACEOF
14282
14283
14284 else
14285   cat >>confdefs.h <<_ACEOF
14286 #define HAVE_DECL_VSNPRINTF 0
14287 _ACEOF
14288
14289
14290 fi
14291
14292
14293
14294
14295 echo "$as_me:$LINENO: checking for isinf" >&5
14296 echo $ECHO_N "checking for isinf... $ECHO_C" >&6
14297 if test "${ac_cv_func_isinf+set}" = set; then
14298   echo $ECHO_N "(cached) $ECHO_C" >&6
14299 else
14300   cat >conftest.$ac_ext <<_ACEOF
14301 /* confdefs.h.  */
14302 _ACEOF
14303 cat confdefs.h >>conftest.$ac_ext
14304 cat >>conftest.$ac_ext <<_ACEOF
14305 /* end confdefs.h.  */
14306
14307 #include <math.h>
14308 double glob_double;
14309
14310 int
14311 main ()
14312 {
14313 return isinf(glob_double) ? 0 : 1;
14314   ;
14315   return 0;
14316 }
14317 _ACEOF
14318 rm -f conftest.$ac_objext conftest$ac_exeext
14319 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14320   (eval $ac_link) 2>conftest.er1
14321   ac_status=$?
14322   grep -v '^ *+' conftest.er1 >conftest.err
14323   rm -f conftest.er1
14324   cat conftest.err >&5
14325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14326   (exit $ac_status); } &&
14327          { ac_try='test -z "$ac_c_werror_flag"
14328                          || test ! -s conftest.err'
14329   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14330   (eval $ac_try) 2>&5
14331   ac_status=$?
14332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14333   (exit $ac_status); }; } &&
14334          { ac_try='test -s conftest$ac_exeext'
14335   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14336   (eval $ac_try) 2>&5
14337   ac_status=$?
14338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14339   (exit $ac_status); }; }; then
14340   ac_cv_func_isinf=yes
14341 else
14342   echo "$as_me: failed program was:" >&5
14343 sed 's/^/| /' conftest.$ac_ext >&5
14344
14345 ac_cv_func_isinf=no
14346 fi
14347 rm -f conftest.err conftest.$ac_objext \
14348       conftest$ac_exeext conftest.$ac_ext
14349 fi
14350 echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
14351 echo "${ECHO_T}$ac_cv_func_isinf" >&6
14352
14353 if test $ac_cv_func_isinf = yes ; then
14354
14355 cat >>confdefs.h <<\_ACEOF
14356 #define HAVE_ISINF 1
14357 _ACEOF
14358
14359 else
14360   case $LIBOBJS in
14361     "isinf.$ac_objext"   | \
14362   *" isinf.$ac_objext"   | \
14363     "isinf.$ac_objext "* | \
14364   *" isinf.$ac_objext "* ) ;;
14365   *) LIBOBJS="$LIBOBJS isinf.$ac_objext" ;;
14366 esac
14367
14368   # Look for a way to implement a substitute for isinf()
14369
14370
14371
14372
14373 for ac_func in fpclass fp_class fp_class_d class
14374 do
14375 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14376 echo "$as_me:$LINENO: checking for $ac_func" >&5
14377 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14378 if eval "test \"\${$as_ac_var+set}\" = set"; then
14379   echo $ECHO_N "(cached) $ECHO_C" >&6
14380 else
14381   cat >conftest.$ac_ext <<_ACEOF
14382 /* confdefs.h.  */
14383 _ACEOF
14384 cat confdefs.h >>conftest.$ac_ext
14385 cat >>conftest.$ac_ext <<_ACEOF
14386 /* end confdefs.h.  */
14387 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14388    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14389 #define $ac_func innocuous_$ac_func
14390
14391 /* System header to define __stub macros and hopefully few prototypes,
14392     which can conflict with char $ac_func (); below.
14393     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14394     <limits.h> exists even on freestanding compilers.  */
14395
14396 #ifdef __STDC__
14397 # include <limits.h>
14398 #else
14399 # include <assert.h>
14400 #endif
14401
14402 #undef $ac_func
14403
14404 /* Override any gcc2 internal prototype to avoid an error.  */
14405 #ifdef __cplusplus
14406 extern "C"
14407 {
14408 #endif
14409 /* We use char because int might match the return type of a gcc2
14410    builtin and then its argument prototype would still apply.  */
14411 char $ac_func ();
14412 /* The GNU C library defines this for functions which it implements
14413     to always fail with ENOSYS.  Some functions are actually named
14414     something starting with __ and the normal name is an alias.  */
14415 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14416 choke me
14417 #else
14418 char (*f) () = $ac_func;
14419 #endif
14420 #ifdef __cplusplus
14421 }
14422 #endif
14423
14424 int
14425 main ()
14426 {
14427 return f != $ac_func;
14428   ;
14429   return 0;
14430 }
14431 _ACEOF
14432 rm -f conftest.$ac_objext conftest$ac_exeext
14433 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14434   (eval $ac_link) 2>conftest.er1
14435   ac_status=$?
14436   grep -v '^ *+' conftest.er1 >conftest.err
14437   rm -f conftest.er1
14438   cat conftest.err >&5
14439   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14440   (exit $ac_status); } &&
14441          { ac_try='test -z "$ac_c_werror_flag"
14442                          || test ! -s conftest.err'
14443   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14444   (eval $ac_try) 2>&5
14445   ac_status=$?
14446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14447   (exit $ac_status); }; } &&
14448          { ac_try='test -s conftest$ac_exeext'
14449   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14450   (eval $ac_try) 2>&5
14451   ac_status=$?
14452   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14453   (exit $ac_status); }; }; then
14454   eval "$as_ac_var=yes"
14455 else
14456   echo "$as_me: failed program was:" >&5
14457 sed 's/^/| /' conftest.$ac_ext >&5
14458
14459 eval "$as_ac_var=no"
14460 fi
14461 rm -f conftest.err conftest.$ac_objext \
14462       conftest$ac_exeext conftest.$ac_ext
14463 fi
14464 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14465 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14466 if test `eval echo '${'$as_ac_var'}'` = yes; then
14467   cat >>confdefs.h <<_ACEOF
14468 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14469 _ACEOF
14470  break
14471 fi
14472 done
14473
14474 fi
14475
14476
14477
14478
14479
14480
14481
14482
14483
14484
14485
14486
14487
14488
14489 for ac_func in crypt fseeko getopt getrusage inet_aton random rint srandom strdup strerror strtol strtoul unsetenv
14490 do
14491 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14492 echo "$as_me:$LINENO: checking for $ac_func" >&5
14493 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14494 if eval "test \"\${$as_ac_var+set}\" = set"; then
14495   echo $ECHO_N "(cached) $ECHO_C" >&6
14496 else
14497   cat >conftest.$ac_ext <<_ACEOF
14498 /* confdefs.h.  */
14499 _ACEOF
14500 cat confdefs.h >>conftest.$ac_ext
14501 cat >>conftest.$ac_ext <<_ACEOF
14502 /* end confdefs.h.  */
14503 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14504    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14505 #define $ac_func innocuous_$ac_func
14506
14507 /* System header to define __stub macros and hopefully few prototypes,
14508     which can conflict with char $ac_func (); below.
14509     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14510     <limits.h> exists even on freestanding compilers.  */
14511
14512 #ifdef __STDC__
14513 # include <limits.h>
14514 #else
14515 # include <assert.h>
14516 #endif
14517
14518 #undef $ac_func
14519
14520 /* Override any gcc2 internal prototype to avoid an error.  */
14521 #ifdef __cplusplus
14522 extern "C"
14523 {
14524 #endif
14525 /* We use char because int might match the return type of a gcc2
14526    builtin and then its argument prototype would still apply.  */
14527 char $ac_func ();
14528 /* The GNU C library defines this for functions which it implements
14529     to always fail with ENOSYS.  Some functions are actually named
14530     something starting with __ and the normal name is an alias.  */
14531 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14532 choke me
14533 #else
14534 char (*f) () = $ac_func;
14535 #endif
14536 #ifdef __cplusplus
14537 }
14538 #endif
14539
14540 int
14541 main ()
14542 {
14543 return f != $ac_func;
14544   ;
14545   return 0;
14546 }
14547 _ACEOF
14548 rm -f conftest.$ac_objext conftest$ac_exeext
14549 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14550   (eval $ac_link) 2>conftest.er1
14551   ac_status=$?
14552   grep -v '^ *+' conftest.er1 >conftest.err
14553   rm -f conftest.er1
14554   cat conftest.err >&5
14555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14556   (exit $ac_status); } &&
14557          { ac_try='test -z "$ac_c_werror_flag"
14558                          || test ! -s conftest.err'
14559   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14560   (eval $ac_try) 2>&5
14561   ac_status=$?
14562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14563   (exit $ac_status); }; } &&
14564          { ac_try='test -s conftest$ac_exeext'
14565   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14566   (eval $ac_try) 2>&5
14567   ac_status=$?
14568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14569   (exit $ac_status); }; }; then
14570   eval "$as_ac_var=yes"
14571 else
14572   echo "$as_me: failed program was:" >&5
14573 sed 's/^/| /' conftest.$ac_ext >&5
14574
14575 eval "$as_ac_var=no"
14576 fi
14577 rm -f conftest.err conftest.$ac_objext \
14578       conftest$ac_exeext conftest.$ac_ext
14579 fi
14580 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14581 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14582 if test `eval echo '${'$as_ac_var'}'` = yes; then
14583   cat >>confdefs.h <<_ACEOF
14584 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14585 _ACEOF
14586
14587 else
14588   case $LIBOBJS in
14589     "$ac_func.$ac_objext"   | \
14590   *" $ac_func.$ac_objext"   | \
14591     "$ac_func.$ac_objext "* | \
14592   *" $ac_func.$ac_objext "* ) ;;
14593   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14594 esac
14595
14596 fi
14597 done
14598
14599
14600
14601 # System's version of getaddrinfo(), if any, may be used only if we found
14602 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
14603 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
14604 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
14605 # because we want to use our own getaddrinfo.c on Windows anyway.)
14606 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
14607
14608 for ac_func in getaddrinfo
14609 do
14610 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14611 echo "$as_me:$LINENO: checking for $ac_func" >&5
14612 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14613 if eval "test \"\${$as_ac_var+set}\" = set"; then
14614   echo $ECHO_N "(cached) $ECHO_C" >&6
14615 else
14616   cat >conftest.$ac_ext <<_ACEOF
14617 /* confdefs.h.  */
14618 _ACEOF
14619 cat confdefs.h >>conftest.$ac_ext
14620 cat >>conftest.$ac_ext <<_ACEOF
14621 /* end confdefs.h.  */
14622 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14623    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14624 #define $ac_func innocuous_$ac_func
14625
14626 /* System header to define __stub macros and hopefully few prototypes,
14627     which can conflict with char $ac_func (); below.
14628     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14629     <limits.h> exists even on freestanding compilers.  */
14630
14631 #ifdef __STDC__
14632 # include <limits.h>
14633 #else
14634 # include <assert.h>
14635 #endif
14636
14637 #undef $ac_func
14638
14639 /* Override any gcc2 internal prototype to avoid an error.  */
14640 #ifdef __cplusplus
14641 extern "C"
14642 {
14643 #endif
14644 /* We use char because int might match the return type of a gcc2
14645    builtin and then its argument prototype would still apply.  */
14646 char $ac_func ();
14647 /* The GNU C library defines this for functions which it implements
14648     to always fail with ENOSYS.  Some functions are actually named
14649     something starting with __ and the normal name is an alias.  */
14650 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14651 choke me
14652 #else
14653 char (*f) () = $ac_func;
14654 #endif
14655 #ifdef __cplusplus
14656 }
14657 #endif
14658
14659 int
14660 main ()
14661 {
14662 return f != $ac_func;
14663   ;
14664   return 0;
14665 }
14666 _ACEOF
14667 rm -f conftest.$ac_objext conftest$ac_exeext
14668 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14669   (eval $ac_link) 2>conftest.er1
14670   ac_status=$?
14671   grep -v '^ *+' conftest.er1 >conftest.err
14672   rm -f conftest.er1
14673   cat conftest.err >&5
14674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14675   (exit $ac_status); } &&
14676          { ac_try='test -z "$ac_c_werror_flag"
14677                          || test ! -s conftest.err'
14678   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14679   (eval $ac_try) 2>&5
14680   ac_status=$?
14681   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14682   (exit $ac_status); }; } &&
14683          { ac_try='test -s conftest$ac_exeext'
14684   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14685   (eval $ac_try) 2>&5
14686   ac_status=$?
14687   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14688   (exit $ac_status); }; }; then
14689   eval "$as_ac_var=yes"
14690 else
14691   echo "$as_me: failed program was:" >&5
14692 sed 's/^/| /' conftest.$ac_ext >&5
14693
14694 eval "$as_ac_var=no"
14695 fi
14696 rm -f conftest.err conftest.$ac_objext \
14697       conftest$ac_exeext conftest.$ac_ext
14698 fi
14699 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14700 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14701 if test `eval echo '${'$as_ac_var'}'` = yes; then
14702   cat >>confdefs.h <<_ACEOF
14703 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14704 _ACEOF
14705
14706 else
14707   case $LIBOBJS in
14708     "$ac_func.$ac_objext"   | \
14709   *" $ac_func.$ac_objext"   | \
14710     "$ac_func.$ac_objext "* | \
14711   *" $ac_func.$ac_objext "* ) ;;
14712   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14713 esac
14714
14715 fi
14716 done
14717
14718
14719 else
14720   case $LIBOBJS in
14721     "getaddrinfo.$ac_objext"   | \
14722   *" getaddrinfo.$ac_objext"   | \
14723     "getaddrinfo.$ac_objext "* | \
14724   *" getaddrinfo.$ac_objext "* ) ;;
14725   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext" ;;
14726 esac
14727
14728 fi
14729
14730 # similarly, use system's getopt_long() only if system provides struct option.
14731 if test x"$ac_cv_type_struct_option" = xyes ; then
14732
14733 for ac_func in getopt_long
14734 do
14735 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14736 echo "$as_me:$LINENO: checking for $ac_func" >&5
14737 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14738 if eval "test \"\${$as_ac_var+set}\" = set"; then
14739   echo $ECHO_N "(cached) $ECHO_C" >&6
14740 else
14741   cat >conftest.$ac_ext <<_ACEOF
14742 /* confdefs.h.  */
14743 _ACEOF
14744 cat confdefs.h >>conftest.$ac_ext
14745 cat >>conftest.$ac_ext <<_ACEOF
14746 /* end confdefs.h.  */
14747 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14748    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14749 #define $ac_func innocuous_$ac_func
14750
14751 /* System header to define __stub macros and hopefully few prototypes,
14752     which can conflict with char $ac_func (); below.
14753     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14754     <limits.h> exists even on freestanding compilers.  */
14755
14756 #ifdef __STDC__
14757 # include <limits.h>
14758 #else
14759 # include <assert.h>
14760 #endif
14761
14762 #undef $ac_func
14763
14764 /* Override any gcc2 internal prototype to avoid an error.  */
14765 #ifdef __cplusplus
14766 extern "C"
14767 {
14768 #endif
14769 /* We use char because int might match the return type of a gcc2
14770    builtin and then its argument prototype would still apply.  */
14771 char $ac_func ();
14772 /* The GNU C library defines this for functions which it implements
14773     to always fail with ENOSYS.  Some functions are actually named
14774     something starting with __ and the normal name is an alias.  */
14775 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14776 choke me
14777 #else
14778 char (*f) () = $ac_func;
14779 #endif
14780 #ifdef __cplusplus
14781 }
14782 #endif
14783
14784 int
14785 main ()
14786 {
14787 return f != $ac_func;
14788   ;
14789   return 0;
14790 }
14791 _ACEOF
14792 rm -f conftest.$ac_objext conftest$ac_exeext
14793 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14794   (eval $ac_link) 2>conftest.er1
14795   ac_status=$?
14796   grep -v '^ *+' conftest.er1 >conftest.err
14797   rm -f conftest.er1
14798   cat conftest.err >&5
14799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14800   (exit $ac_status); } &&
14801          { ac_try='test -z "$ac_c_werror_flag"
14802                          || test ! -s conftest.err'
14803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14804   (eval $ac_try) 2>&5
14805   ac_status=$?
14806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14807   (exit $ac_status); }; } &&
14808          { ac_try='test -s conftest$ac_exeext'
14809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14810   (eval $ac_try) 2>&5
14811   ac_status=$?
14812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14813   (exit $ac_status); }; }; then
14814   eval "$as_ac_var=yes"
14815 else
14816   echo "$as_me: failed program was:" >&5
14817 sed 's/^/| /' conftest.$ac_ext >&5
14818
14819 eval "$as_ac_var=no"
14820 fi
14821 rm -f conftest.err conftest.$ac_objext \
14822       conftest$ac_exeext conftest.$ac_ext
14823 fi
14824 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14825 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14826 if test `eval echo '${'$as_ac_var'}'` = yes; then
14827   cat >>confdefs.h <<_ACEOF
14828 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14829 _ACEOF
14830
14831 else
14832   case $LIBOBJS in
14833     "$ac_func.$ac_objext"   | \
14834   *" $ac_func.$ac_objext"   | \
14835     "$ac_func.$ac_objext "* | \
14836   *" $ac_func.$ac_objext "* ) ;;
14837   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14838 esac
14839
14840 fi
14841 done
14842
14843
14844 else
14845   case $LIBOBJS in
14846     "getopt_long.$ac_objext"   | \
14847   *" getopt_long.$ac_objext"   | \
14848     "getopt_long.$ac_objext "* | \
14849   *" getopt_long.$ac_objext "* ) ;;
14850   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext" ;;
14851 esac
14852
14853 fi
14854
14855 # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
14856 # We override the previous test that said fseeko/ftello didn't exist
14857 # OS tests are also done in include/c.h and port/fseeko.c
14858 case $host_os in bsdi*|netbsd*)
14859 ac_cv_func_fseeko=yes
14860 esac
14861
14862 # Solaris has a very slow qsort in certain cases, so we replace it:
14863 #   http://forum.sun.com/thread.jspa?forumID=4&threadID=7231
14864 # Supposedly it is fixed in Solaris, but not sure which version, and
14865 # no confirmed testing.  2005-12-16
14866 if test "$PORTNAME" = "solaris"; then
14867 case $LIBOBJS in
14868     "qsort.$ac_objext"   | \
14869   *" qsort.$ac_objext"   | \
14870     "qsort.$ac_objext "* | \
14871   *" qsort.$ac_objext "* ) ;;
14872   *) LIBOBJS="$LIBOBJS qsort.$ac_objext" ;;
14873 esac
14874
14875 fi
14876
14877 # Win32 support
14878 if test "$PORTNAME" = "win32"; then
14879 case $LIBOBJS in
14880     "gettimeofday.$ac_objext"   | \
14881   *" gettimeofday.$ac_objext"   | \
14882     "gettimeofday.$ac_objext "* | \
14883   *" gettimeofday.$ac_objext "* ) ;;
14884   *) LIBOBJS="$LIBOBJS gettimeofday.$ac_objext" ;;
14885 esac
14886
14887 case $LIBOBJS in
14888     "kill.$ac_objext"   | \
14889   *" kill.$ac_objext"   | \
14890     "kill.$ac_objext "* | \
14891   *" kill.$ac_objext "* ) ;;
14892   *) LIBOBJS="$LIBOBJS kill.$ac_objext" ;;
14893 esac
14894
14895 case $LIBOBJS in
14896     "open.$ac_objext"   | \
14897   *" open.$ac_objext"   | \
14898     "open.$ac_objext "* | \
14899   *" open.$ac_objext "* ) ;;
14900   *) LIBOBJS="$LIBOBJS open.$ac_objext" ;;
14901 esac
14902
14903 case $LIBOBJS in
14904     "rand.$ac_objext"   | \
14905   *" rand.$ac_objext"   | \
14906     "rand.$ac_objext "* | \
14907   *" rand.$ac_objext "* ) ;;
14908   *) LIBOBJS="$LIBOBJS rand.$ac_objext" ;;
14909 esac
14910
14911
14912 cat >>confdefs.h <<\_ACEOF
14913 #define HAVE_SYMLINK 1
14914 _ACEOF
14915
14916 fi
14917
14918 if test "$with_readline" = yes; then
14919   echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
14920 echo $ECHO_N "checking for rl_completion_append_character... $ECHO_C" >&6
14921 cat >conftest.$ac_ext <<_ACEOF
14922 /* confdefs.h.  */
14923 _ACEOF
14924 cat confdefs.h >>conftest.$ac_ext
14925 cat >>conftest.$ac_ext <<_ACEOF
14926 /* end confdefs.h.  */
14927 #include <stdio.h>
14928 #ifdef HAVE_READLINE_READLINE_H
14929 # include <readline/readline.h>
14930 #elif defined(HAVE_READLINE_H)
14931 # include <readline.h>
14932 #endif
14933
14934 int
14935 main ()
14936 {
14937 rl_completion_append_character = 'x';
14938   ;
14939   return 0;
14940 }
14941 _ACEOF
14942 rm -f conftest.$ac_objext conftest$ac_exeext
14943 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14944   (eval $ac_link) 2>conftest.er1
14945   ac_status=$?
14946   grep -v '^ *+' conftest.er1 >conftest.err
14947   rm -f conftest.er1
14948   cat conftest.err >&5
14949   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14950   (exit $ac_status); } &&
14951          { ac_try='test -z "$ac_c_werror_flag"
14952                          || test ! -s conftest.err'
14953   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14954   (eval $ac_try) 2>&5
14955   ac_status=$?
14956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14957   (exit $ac_status); }; } &&
14958          { ac_try='test -s conftest$ac_exeext'
14959   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14960   (eval $ac_try) 2>&5
14961   ac_status=$?
14962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14963   (exit $ac_status); }; }; then
14964   echo "$as_me:$LINENO: result: yes" >&5
14965 echo "${ECHO_T}yes" >&6
14966
14967 cat >>confdefs.h <<\_ACEOF
14968 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
14969 _ACEOF
14970
14971 else
14972   echo "$as_me: failed program was:" >&5
14973 sed 's/^/| /' conftest.$ac_ext >&5
14974
14975 echo "$as_me:$LINENO: result: no" >&5
14976 echo "${ECHO_T}no" >&6
14977 fi
14978 rm -f conftest.err conftest.$ac_objext \
14979       conftest$ac_exeext conftest.$ac_ext
14980
14981
14982 for ac_func in rl_completion_matches rl_filename_completion_function
14983 do
14984 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14985 echo "$as_me:$LINENO: checking for $ac_func" >&5
14986 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14987 if eval "test \"\${$as_ac_var+set}\" = set"; then
14988   echo $ECHO_N "(cached) $ECHO_C" >&6
14989 else
14990   cat >conftest.$ac_ext <<_ACEOF
14991 /* confdefs.h.  */
14992 _ACEOF
14993 cat confdefs.h >>conftest.$ac_ext
14994 cat >>conftest.$ac_ext <<_ACEOF
14995 /* end confdefs.h.  */
14996 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14997    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14998 #define $ac_func innocuous_$ac_func
14999
15000 /* System header to define __stub macros and hopefully few prototypes,
15001     which can conflict with char $ac_func (); below.
15002     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15003     <limits.h> exists even on freestanding compilers.  */
15004
15005 #ifdef __STDC__
15006 # include <limits.h>
15007 #else
15008 # include <assert.h>
15009 #endif
15010
15011 #undef $ac_func
15012
15013 /* Override any gcc2 internal prototype to avoid an error.  */
15014 #ifdef __cplusplus
15015 extern "C"
15016 {
15017 #endif
15018 /* We use char because int might match the return type of a gcc2
15019    builtin and then its argument prototype would still apply.  */
15020 char $ac_func ();
15021 /* The GNU C library defines this for functions which it implements
15022     to always fail with ENOSYS.  Some functions are actually named
15023     something starting with __ and the normal name is an alias.  */
15024 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15025 choke me
15026 #else
15027 char (*f) () = $ac_func;
15028 #endif
15029 #ifdef __cplusplus
15030 }
15031 #endif
15032
15033 int
15034 main ()
15035 {
15036 return f != $ac_func;
15037   ;
15038   return 0;
15039 }
15040 _ACEOF
15041 rm -f conftest.$ac_objext conftest$ac_exeext
15042 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15043   (eval $ac_link) 2>conftest.er1
15044   ac_status=$?
15045   grep -v '^ *+' conftest.er1 >conftest.err
15046   rm -f conftest.er1
15047   cat conftest.err >&5
15048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15049   (exit $ac_status); } &&
15050          { ac_try='test -z "$ac_c_werror_flag"
15051                          || test ! -s conftest.err'
15052   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15053   (eval $ac_try) 2>&5
15054   ac_status=$?
15055   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15056   (exit $ac_status); }; } &&
15057          { ac_try='test -s conftest$ac_exeext'
15058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15059   (eval $ac_try) 2>&5
15060   ac_status=$?
15061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15062   (exit $ac_status); }; }; then
15063   eval "$as_ac_var=yes"
15064 else
15065   echo "$as_me: failed program was:" >&5
15066 sed 's/^/| /' conftest.$ac_ext >&5
15067
15068 eval "$as_ac_var=no"
15069 fi
15070 rm -f conftest.err conftest.$ac_objext \
15071       conftest$ac_exeext conftest.$ac_ext
15072 fi
15073 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15074 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15075 if test `eval echo '${'$as_ac_var'}'` = yes; then
15076   cat >>confdefs.h <<_ACEOF
15077 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15078 _ACEOF
15079
15080 fi
15081 done
15082
15083
15084 for ac_func in replace_history_entry
15085 do
15086 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15087 echo "$as_me:$LINENO: checking for $ac_func" >&5
15088 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15089 if eval "test \"\${$as_ac_var+set}\" = set"; then
15090   echo $ECHO_N "(cached) $ECHO_C" >&6
15091 else
15092   cat >conftest.$ac_ext <<_ACEOF
15093 /* confdefs.h.  */
15094 _ACEOF
15095 cat confdefs.h >>conftest.$ac_ext
15096 cat >>conftest.$ac_ext <<_ACEOF
15097 /* end confdefs.h.  */
15098 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15099    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15100 #define $ac_func innocuous_$ac_func
15101
15102 /* System header to define __stub macros and hopefully few prototypes,
15103     which can conflict with char $ac_func (); below.
15104     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15105     <limits.h> exists even on freestanding compilers.  */
15106
15107 #ifdef __STDC__
15108 # include <limits.h>
15109 #else
15110 # include <assert.h>
15111 #endif
15112
15113 #undef $ac_func
15114
15115 /* Override any gcc2 internal prototype to avoid an error.  */
15116 #ifdef __cplusplus
15117 extern "C"
15118 {
15119 #endif
15120 /* We use char because int might match the return type of a gcc2
15121    builtin and then its argument prototype would still apply.  */
15122 char $ac_func ();
15123 /* The GNU C library defines this for functions which it implements
15124     to always fail with ENOSYS.  Some functions are actually named
15125     something starting with __ and the normal name is an alias.  */
15126 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15127 choke me
15128 #else
15129 char (*f) () = $ac_func;
15130 #endif
15131 #ifdef __cplusplus
15132 }
15133 #endif
15134
15135 int
15136 main ()
15137 {
15138 return f != $ac_func;
15139   ;
15140   return 0;
15141 }
15142 _ACEOF
15143 rm -f conftest.$ac_objext conftest$ac_exeext
15144 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15145   (eval $ac_link) 2>conftest.er1
15146   ac_status=$?
15147   grep -v '^ *+' conftest.er1 >conftest.err
15148   rm -f conftest.er1
15149   cat conftest.err >&5
15150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15151   (exit $ac_status); } &&
15152          { ac_try='test -z "$ac_c_werror_flag"
15153                          || test ! -s conftest.err'
15154   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15155   (eval $ac_try) 2>&5
15156   ac_status=$?
15157   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15158   (exit $ac_status); }; } &&
15159          { ac_try='test -s conftest$ac_exeext'
15160   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15161   (eval $ac_try) 2>&5
15162   ac_status=$?
15163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15164   (exit $ac_status); }; }; then
15165   eval "$as_ac_var=yes"
15166 else
15167   echo "$as_me: failed program was:" >&5
15168 sed 's/^/| /' conftest.$ac_ext >&5
15169
15170 eval "$as_ac_var=no"
15171 fi
15172 rm -f conftest.err conftest.$ac_objext \
15173       conftest$ac_exeext conftest.$ac_ext
15174 fi
15175 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15176 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15177 if test `eval echo '${'$as_ac_var'}'` = yes; then
15178   cat >>confdefs.h <<_ACEOF
15179 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15180 _ACEOF
15181
15182 fi
15183 done
15184
15185 fi
15186
15187
15188 echo "$as_me:$LINENO: checking for finite" >&5
15189 echo $ECHO_N "checking for finite... $ECHO_C" >&6
15190 cat >conftest.$ac_ext <<_ACEOF
15191 /* confdefs.h.  */
15192 _ACEOF
15193 cat confdefs.h >>conftest.$ac_ext
15194 cat >>conftest.$ac_ext <<_ACEOF
15195 /* end confdefs.h.  */
15196
15197 #include <math.h>
15198 double glob_double;
15199
15200 int
15201 main ()
15202 {
15203 return finite(glob_double) ? 0 : 1;
15204   ;
15205   return 0;
15206 }
15207 _ACEOF
15208 rm -f conftest.$ac_objext conftest$ac_exeext
15209 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15210   (eval $ac_link) 2>conftest.er1
15211   ac_status=$?
15212   grep -v '^ *+' conftest.er1 >conftest.err
15213   rm -f conftest.er1
15214   cat conftest.err >&5
15215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15216   (exit $ac_status); } &&
15217          { ac_try='test -z "$ac_c_werror_flag"
15218                          || test ! -s conftest.err'
15219   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15220   (eval $ac_try) 2>&5
15221   ac_status=$?
15222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15223   (exit $ac_status); }; } &&
15224          { ac_try='test -s conftest$ac_exeext'
15225   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15226   (eval $ac_try) 2>&5
15227   ac_status=$?
15228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15229   (exit $ac_status); }; }; then
15230
15231 cat >>confdefs.h <<\_ACEOF
15232 #define HAVE_FINITE 1
15233 _ACEOF
15234
15235 echo "$as_me:$LINENO: result: yes" >&5
15236 echo "${ECHO_T}yes" >&6
15237 else
15238   echo "$as_me: failed program was:" >&5
15239 sed 's/^/| /' conftest.$ac_ext >&5
15240
15241 echo "$as_me:$LINENO: result: no" >&5
15242 echo "${ECHO_T}no" >&6
15243 fi
15244 rm -f conftest.err conftest.$ac_objext \
15245       conftest$ac_exeext conftest.$ac_ext
15246
15247 echo "$as_me:$LINENO: checking for sigsetjmp" >&5
15248 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6
15249 cat >conftest.$ac_ext <<_ACEOF
15250 /* confdefs.h.  */
15251 _ACEOF
15252 cat confdefs.h >>conftest.$ac_ext
15253 cat >>conftest.$ac_ext <<_ACEOF
15254 /* end confdefs.h.  */
15255 #include <setjmp.h>
15256 int
15257 main ()
15258 {
15259 sigjmp_buf x; sigsetjmp(x, 1);
15260   ;
15261   return 0;
15262 }
15263 _ACEOF
15264 rm -f conftest.$ac_objext conftest$ac_exeext
15265 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15266   (eval $ac_link) 2>conftest.er1
15267   ac_status=$?
15268   grep -v '^ *+' conftest.er1 >conftest.err
15269   rm -f conftest.er1
15270   cat conftest.err >&5
15271   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15272   (exit $ac_status); } &&
15273          { ac_try='test -z "$ac_c_werror_flag"
15274                          || test ! -s conftest.err'
15275   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15276   (eval $ac_try) 2>&5
15277   ac_status=$?
15278   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15279   (exit $ac_status); }; } &&
15280          { ac_try='test -s conftest$ac_exeext'
15281   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15282   (eval $ac_try) 2>&5
15283   ac_status=$?
15284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15285   (exit $ac_status); }; }; then
15286
15287 cat >>confdefs.h <<\_ACEOF
15288 #define HAVE_SIGSETJMP 1
15289 _ACEOF
15290
15291 echo "$as_me:$LINENO: result: yes" >&5
15292 echo "${ECHO_T}yes" >&6
15293 else
15294   echo "$as_me: failed program was:" >&5
15295 sed 's/^/| /' conftest.$ac_ext >&5
15296
15297 echo "$as_me:$LINENO: result: no" >&5
15298 echo "${ECHO_T}no" >&6
15299 fi
15300 rm -f conftest.err conftest.$ac_objext \
15301       conftest$ac_exeext conftest.$ac_ext
15302
15303 echo "$as_me:$LINENO: checking for syslog" >&5
15304 echo $ECHO_N "checking for syslog... $ECHO_C" >&6
15305 if test "${ac_cv_func_syslog+set}" = set; then
15306   echo $ECHO_N "(cached) $ECHO_C" >&6
15307 else
15308   cat >conftest.$ac_ext <<_ACEOF
15309 /* confdefs.h.  */
15310 _ACEOF
15311 cat confdefs.h >>conftest.$ac_ext
15312 cat >>conftest.$ac_ext <<_ACEOF
15313 /* end confdefs.h.  */
15314 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
15315    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15316 #define syslog innocuous_syslog
15317
15318 /* System header to define __stub macros and hopefully few prototypes,
15319     which can conflict with char syslog (); below.
15320     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15321     <limits.h> exists even on freestanding compilers.  */
15322
15323 #ifdef __STDC__
15324 # include <limits.h>
15325 #else
15326 # include <assert.h>
15327 #endif
15328
15329 #undef syslog
15330
15331 /* Override any gcc2 internal prototype to avoid an error.  */
15332 #ifdef __cplusplus
15333 extern "C"
15334 {
15335 #endif
15336 /* We use char because int might match the return type of a gcc2
15337    builtin and then its argument prototype would still apply.  */
15338 char syslog ();
15339 /* The GNU C library defines this for functions which it implements
15340     to always fail with ENOSYS.  Some functions are actually named
15341     something starting with __ and the normal name is an alias.  */
15342 #if defined (__stub_syslog) || defined (__stub___syslog)
15343 choke me
15344 #else
15345 char (*f) () = syslog;
15346 #endif
15347 #ifdef __cplusplus
15348 }
15349 #endif
15350
15351 int
15352 main ()
15353 {
15354 return f != syslog;
15355   ;
15356   return 0;
15357 }
15358 _ACEOF
15359 rm -f conftest.$ac_objext conftest$ac_exeext
15360 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15361   (eval $ac_link) 2>conftest.er1
15362   ac_status=$?
15363   grep -v '^ *+' conftest.er1 >conftest.err
15364   rm -f conftest.er1
15365   cat conftest.err >&5
15366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15367   (exit $ac_status); } &&
15368          { ac_try='test -z "$ac_c_werror_flag"
15369                          || test ! -s conftest.err'
15370   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15371   (eval $ac_try) 2>&5
15372   ac_status=$?
15373   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15374   (exit $ac_status); }; } &&
15375          { ac_try='test -s conftest$ac_exeext'
15376   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15377   (eval $ac_try) 2>&5
15378   ac_status=$?
15379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15380   (exit $ac_status); }; }; then
15381   ac_cv_func_syslog=yes
15382 else
15383   echo "$as_me: failed program was:" >&5
15384 sed 's/^/| /' conftest.$ac_ext >&5
15385
15386 ac_cv_func_syslog=no
15387 fi
15388 rm -f conftest.err conftest.$ac_objext \
15389       conftest$ac_exeext conftest.$ac_ext
15390 fi
15391 echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
15392 echo "${ECHO_T}$ac_cv_func_syslog" >&6
15393 if test $ac_cv_func_syslog = yes; then
15394   if test "${ac_cv_header_syslog_h+set}" = set; then
15395   echo "$as_me:$LINENO: checking for syslog.h" >&5
15396 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
15397 if test "${ac_cv_header_syslog_h+set}" = set; then
15398   echo $ECHO_N "(cached) $ECHO_C" >&6
15399 fi
15400 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
15401 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
15402 else
15403   # Is the header compilable?
15404 echo "$as_me:$LINENO: checking syslog.h usability" >&5
15405 echo $ECHO_N "checking syslog.h usability... $ECHO_C" >&6
15406 cat >conftest.$ac_ext <<_ACEOF
15407 /* confdefs.h.  */
15408 _ACEOF
15409 cat confdefs.h >>conftest.$ac_ext
15410 cat >>conftest.$ac_ext <<_ACEOF
15411 /* end confdefs.h.  */
15412 $ac_includes_default
15413 #include <syslog.h>
15414 _ACEOF
15415 rm -f conftest.$ac_objext
15416 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15417   (eval $ac_compile) 2>conftest.er1
15418   ac_status=$?
15419   grep -v '^ *+' conftest.er1 >conftest.err
15420   rm -f conftest.er1
15421   cat conftest.err >&5
15422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15423   (exit $ac_status); } &&
15424          { ac_try='test -z "$ac_c_werror_flag"
15425                          || test ! -s conftest.err'
15426   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15427   (eval $ac_try) 2>&5
15428   ac_status=$?
15429   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15430   (exit $ac_status); }; } &&
15431          { ac_try='test -s conftest.$ac_objext'
15432   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15433   (eval $ac_try) 2>&5
15434   ac_status=$?
15435   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15436   (exit $ac_status); }; }; then
15437   ac_header_compiler=yes
15438 else
15439   echo "$as_me: failed program was:" >&5
15440 sed 's/^/| /' conftest.$ac_ext >&5
15441
15442 ac_header_compiler=no
15443 fi
15444 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15445 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15446 echo "${ECHO_T}$ac_header_compiler" >&6
15447
15448 # Is the header present?
15449 echo "$as_me:$LINENO: checking syslog.h presence" >&5
15450 echo $ECHO_N "checking syslog.h presence... $ECHO_C" >&6
15451 cat >conftest.$ac_ext <<_ACEOF
15452 /* confdefs.h.  */
15453 _ACEOF
15454 cat confdefs.h >>conftest.$ac_ext
15455 cat >>conftest.$ac_ext <<_ACEOF
15456 /* end confdefs.h.  */
15457 #include <syslog.h>
15458 _ACEOF
15459 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15460   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15461   ac_status=$?
15462   grep -v '^ *+' conftest.er1 >conftest.err
15463   rm -f conftest.er1
15464   cat conftest.err >&5
15465   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15466   (exit $ac_status); } >/dev/null; then
15467   if test -s conftest.err; then
15468     ac_cpp_err=$ac_c_preproc_warn_flag
15469     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15470   else
15471     ac_cpp_err=
15472   fi
15473 else
15474   ac_cpp_err=yes
15475 fi
15476 if test -z "$ac_cpp_err"; then
15477   ac_header_preproc=yes
15478 else
15479   echo "$as_me: failed program was:" >&5
15480 sed 's/^/| /' conftest.$ac_ext >&5
15481
15482   ac_header_preproc=no
15483 fi
15484 rm -f conftest.err conftest.$ac_ext
15485 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15486 echo "${ECHO_T}$ac_header_preproc" >&6
15487
15488 # So?  What about this header?
15489 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15490   yes:no: )
15491     { echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
15492 echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15493     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
15494 echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
15495     ac_header_preproc=yes
15496     ;;
15497   no:yes:* )
15498     { echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
15499 echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
15500     { echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
15501 echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
15502     { echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
15503 echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
15504     { echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
15505 echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
15506     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
15507 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
15508     { echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
15509 echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
15510     (
15511       cat <<\_ASBOX
15512 ## ---------------------------------------- ##
15513 ## Report this to pgsql-bugs@postgresql.org ##
15514 ## ---------------------------------------- ##
15515 _ASBOX
15516     ) |
15517       sed "s/^/$as_me: WARNING:     /" >&2
15518     ;;
15519 esac
15520 echo "$as_me:$LINENO: checking for syslog.h" >&5
15521 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
15522 if test "${ac_cv_header_syslog_h+set}" = set; then
15523   echo $ECHO_N "(cached) $ECHO_C" >&6
15524 else
15525   ac_cv_header_syslog_h=$ac_header_preproc
15526 fi
15527 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
15528 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
15529
15530 fi
15531 if test $ac_cv_header_syslog_h = yes; then
15532
15533 cat >>confdefs.h <<\_ACEOF
15534 #define HAVE_SYSLOG 1
15535 _ACEOF
15536
15537 fi
15538
15539
15540 fi
15541
15542
15543 echo "$as_me:$LINENO: checking for optreset" >&5
15544 echo $ECHO_N "checking for optreset... $ECHO_C" >&6
15545 if test "${pgac_cv_var_int_optreset+set}" = set; then
15546   echo $ECHO_N "(cached) $ECHO_C" >&6
15547 else
15548   cat >conftest.$ac_ext <<_ACEOF
15549 /* confdefs.h.  */
15550 _ACEOF
15551 cat confdefs.h >>conftest.$ac_ext
15552 cat >>conftest.$ac_ext <<_ACEOF
15553 /* end confdefs.h.  */
15554 #include <unistd.h>
15555 int
15556 main ()
15557 {
15558 extern int optreset; optreset = 1;
15559   ;
15560   return 0;
15561 }
15562 _ACEOF
15563 rm -f conftest.$ac_objext conftest$ac_exeext
15564 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15565   (eval $ac_link) 2>conftest.er1
15566   ac_status=$?
15567   grep -v '^ *+' conftest.er1 >conftest.err
15568   rm -f conftest.er1
15569   cat conftest.err >&5
15570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15571   (exit $ac_status); } &&
15572          { ac_try='test -z "$ac_c_werror_flag"
15573                          || test ! -s conftest.err'
15574   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15575   (eval $ac_try) 2>&5
15576   ac_status=$?
15577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15578   (exit $ac_status); }; } &&
15579          { ac_try='test -s conftest$ac_exeext'
15580   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15581   (eval $ac_try) 2>&5
15582   ac_status=$?
15583   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15584   (exit $ac_status); }; }; then
15585   pgac_cv_var_int_optreset=yes
15586 else
15587   echo "$as_me: failed program was:" >&5
15588 sed 's/^/| /' conftest.$ac_ext >&5
15589
15590 pgac_cv_var_int_optreset=no
15591 fi
15592 rm -f conftest.err conftest.$ac_objext \
15593       conftest$ac_exeext conftest.$ac_ext
15594 fi
15595 echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
15596 echo "${ECHO_T}$pgac_cv_var_int_optreset" >&6
15597 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
15598
15599 cat >>confdefs.h <<\_ACEOF
15600 #define HAVE_INT_OPTRESET 1
15601 _ACEOF
15602
15603 fi
15604
15605
15606
15607 for ac_func in strtoll strtoq
15608 do
15609 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15610 echo "$as_me:$LINENO: checking for $ac_func" >&5
15611 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15612 if eval "test \"\${$as_ac_var+set}\" = set"; then
15613   echo $ECHO_N "(cached) $ECHO_C" >&6
15614 else
15615   cat >conftest.$ac_ext <<_ACEOF
15616 /* confdefs.h.  */
15617 _ACEOF
15618 cat confdefs.h >>conftest.$ac_ext
15619 cat >>conftest.$ac_ext <<_ACEOF
15620 /* end confdefs.h.  */
15621 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15622    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15623 #define $ac_func innocuous_$ac_func
15624
15625 /* System header to define __stub macros and hopefully few prototypes,
15626     which can conflict with char $ac_func (); below.
15627     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15628     <limits.h> exists even on freestanding compilers.  */
15629
15630 #ifdef __STDC__
15631 # include <limits.h>
15632 #else
15633 # include <assert.h>
15634 #endif
15635
15636 #undef $ac_func
15637
15638 /* Override any gcc2 internal prototype to avoid an error.  */
15639 #ifdef __cplusplus
15640 extern "C"
15641 {
15642 #endif
15643 /* We use char because int might match the return type of a gcc2
15644    builtin and then its argument prototype would still apply.  */
15645 char $ac_func ();
15646 /* The GNU C library defines this for functions which it implements
15647     to always fail with ENOSYS.  Some functions are actually named
15648     something starting with __ and the normal name is an alias.  */
15649 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15650 choke me
15651 #else
15652 char (*f) () = $ac_func;
15653 #endif
15654 #ifdef __cplusplus
15655 }
15656 #endif
15657
15658 int
15659 main ()
15660 {
15661 return f != $ac_func;
15662   ;
15663   return 0;
15664 }
15665 _ACEOF
15666 rm -f conftest.$ac_objext conftest$ac_exeext
15667 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15668   (eval $ac_link) 2>conftest.er1
15669   ac_status=$?
15670   grep -v '^ *+' conftest.er1 >conftest.err
15671   rm -f conftest.er1
15672   cat conftest.err >&5
15673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15674   (exit $ac_status); } &&
15675          { ac_try='test -z "$ac_c_werror_flag"
15676                          || test ! -s conftest.err'
15677   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15678   (eval $ac_try) 2>&5
15679   ac_status=$?
15680   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15681   (exit $ac_status); }; } &&
15682          { ac_try='test -s conftest$ac_exeext'
15683   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15684   (eval $ac_try) 2>&5
15685   ac_status=$?
15686   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15687   (exit $ac_status); }; }; then
15688   eval "$as_ac_var=yes"
15689 else
15690   echo "$as_me: failed program was:" >&5
15691 sed 's/^/| /' conftest.$ac_ext >&5
15692
15693 eval "$as_ac_var=no"
15694 fi
15695 rm -f conftest.err conftest.$ac_objext \
15696       conftest$ac_exeext conftest.$ac_ext
15697 fi
15698 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15699 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15700 if test `eval echo '${'$as_ac_var'}'` = yes; then
15701   cat >>confdefs.h <<_ACEOF
15702 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15703 _ACEOF
15704  break
15705 fi
15706 done
15707
15708
15709
15710 for ac_func in strtoull strtouq
15711 do
15712 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15713 echo "$as_me:$LINENO: checking for $ac_func" >&5
15714 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15715 if eval "test \"\${$as_ac_var+set}\" = set"; then
15716   echo $ECHO_N "(cached) $ECHO_C" >&6
15717 else
15718   cat >conftest.$ac_ext <<_ACEOF
15719 /* confdefs.h.  */
15720 _ACEOF
15721 cat confdefs.h >>conftest.$ac_ext
15722 cat >>conftest.$ac_ext <<_ACEOF
15723 /* end confdefs.h.  */
15724 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15725    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15726 #define $ac_func innocuous_$ac_func
15727
15728 /* System header to define __stub macros and hopefully few prototypes,
15729     which can conflict with char $ac_func (); below.
15730     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15731     <limits.h> exists even on freestanding compilers.  */
15732
15733 #ifdef __STDC__
15734 # include <limits.h>
15735 #else
15736 # include <assert.h>
15737 #endif
15738
15739 #undef $ac_func
15740
15741 /* Override any gcc2 internal prototype to avoid an error.  */
15742 #ifdef __cplusplus
15743 extern "C"
15744 {
15745 #endif
15746 /* We use char because int might match the return type of a gcc2
15747    builtin and then its argument prototype would still apply.  */
15748 char $ac_func ();
15749 /* The GNU C library defines this for functions which it implements
15750     to always fail with ENOSYS.  Some functions are actually named
15751     something starting with __ and the normal name is an alias.  */
15752 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15753 choke me
15754 #else
15755 char (*f) () = $ac_func;
15756 #endif
15757 #ifdef __cplusplus
15758 }
15759 #endif
15760
15761 int
15762 main ()
15763 {
15764 return f != $ac_func;
15765   ;
15766   return 0;
15767 }
15768 _ACEOF
15769 rm -f conftest.$ac_objext conftest$ac_exeext
15770 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15771   (eval $ac_link) 2>conftest.er1
15772   ac_status=$?
15773   grep -v '^ *+' conftest.er1 >conftest.err
15774   rm -f conftest.er1
15775   cat conftest.err >&5
15776   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15777   (exit $ac_status); } &&
15778          { ac_try='test -z "$ac_c_werror_flag"
15779                          || test ! -s conftest.err'
15780   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15781   (eval $ac_try) 2>&5
15782   ac_status=$?
15783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15784   (exit $ac_status); }; } &&
15785          { ac_try='test -s conftest$ac_exeext'
15786   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15787   (eval $ac_try) 2>&5
15788   ac_status=$?
15789   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15790   (exit $ac_status); }; }; then
15791   eval "$as_ac_var=yes"
15792 else
15793   echo "$as_me: failed program was:" >&5
15794 sed 's/^/| /' conftest.$ac_ext >&5
15795
15796 eval "$as_ac_var=no"
15797 fi
15798 rm -f conftest.err conftest.$ac_objext \
15799       conftest$ac_exeext conftest.$ac_ext
15800 fi
15801 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15802 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15803 if test `eval echo '${'$as_ac_var'}'` = yes; then
15804   cat >>confdefs.h <<_ACEOF
15805 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15806 _ACEOF
15807  break
15808 fi
15809 done
15810
15811
15812 # Check for one of atexit() or on_exit()
15813
15814 for ac_func in atexit
15815 do
15816 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15817 echo "$as_me:$LINENO: checking for $ac_func" >&5
15818 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15819 if eval "test \"\${$as_ac_var+set}\" = set"; then
15820   echo $ECHO_N "(cached) $ECHO_C" >&6
15821 else
15822   cat >conftest.$ac_ext <<_ACEOF
15823 /* confdefs.h.  */
15824 _ACEOF
15825 cat confdefs.h >>conftest.$ac_ext
15826 cat >>conftest.$ac_ext <<_ACEOF
15827 /* end confdefs.h.  */
15828 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15829    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15830 #define $ac_func innocuous_$ac_func
15831
15832 /* System header to define __stub macros and hopefully few prototypes,
15833     which can conflict with char $ac_func (); below.
15834     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15835     <limits.h> exists even on freestanding compilers.  */
15836
15837 #ifdef __STDC__
15838 # include <limits.h>
15839 #else
15840 # include <assert.h>
15841 #endif
15842
15843 #undef $ac_func
15844
15845 /* Override any gcc2 internal prototype to avoid an error.  */
15846 #ifdef __cplusplus
15847 extern "C"
15848 {
15849 #endif
15850 /* We use char because int might match the return type of a gcc2
15851    builtin and then its argument prototype would still apply.  */
15852 char $ac_func ();
15853 /* The GNU C library defines this for functions which it implements
15854     to always fail with ENOSYS.  Some functions are actually named
15855     something starting with __ and the normal name is an alias.  */
15856 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15857 choke me
15858 #else
15859 char (*f) () = $ac_func;
15860 #endif
15861 #ifdef __cplusplus
15862 }
15863 #endif
15864
15865 int
15866 main ()
15867 {
15868 return f != $ac_func;
15869   ;
15870   return 0;
15871 }
15872 _ACEOF
15873 rm -f conftest.$ac_objext conftest$ac_exeext
15874 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15875   (eval $ac_link) 2>conftest.er1
15876   ac_status=$?
15877   grep -v '^ *+' conftest.er1 >conftest.err
15878   rm -f conftest.er1
15879   cat conftest.err >&5
15880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15881   (exit $ac_status); } &&
15882          { ac_try='test -z "$ac_c_werror_flag"
15883                          || test ! -s conftest.err'
15884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15885   (eval $ac_try) 2>&5
15886   ac_status=$?
15887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15888   (exit $ac_status); }; } &&
15889          { ac_try='test -s conftest$ac_exeext'
15890   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15891   (eval $ac_try) 2>&5
15892   ac_status=$?
15893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15894   (exit $ac_status); }; }; then
15895   eval "$as_ac_var=yes"
15896 else
15897   echo "$as_me: failed program was:" >&5
15898 sed 's/^/| /' conftest.$ac_ext >&5
15899
15900 eval "$as_ac_var=no"
15901 fi
15902 rm -f conftest.err conftest.$ac_objext \
15903       conftest$ac_exeext conftest.$ac_ext
15904 fi
15905 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15906 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15907 if test `eval echo '${'$as_ac_var'}'` = yes; then
15908   cat >>confdefs.h <<_ACEOF
15909 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15910 _ACEOF
15911
15912 else
15913
15914 for ac_func in on_exit
15915 do
15916 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15917 echo "$as_me:$LINENO: checking for $ac_func" >&5
15918 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15919 if eval "test \"\${$as_ac_var+set}\" = set"; then
15920   echo $ECHO_N "(cached) $ECHO_C" >&6
15921 else
15922   cat >conftest.$ac_ext <<_ACEOF
15923 /* confdefs.h.  */
15924 _ACEOF
15925 cat confdefs.h >>conftest.$ac_ext
15926 cat >>conftest.$ac_ext <<_ACEOF
15927 /* end confdefs.h.  */
15928 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15929    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15930 #define $ac_func innocuous_$ac_func
15931
15932 /* System header to define __stub macros and hopefully few prototypes,
15933     which can conflict with char $ac_func (); below.
15934     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15935     <limits.h> exists even on freestanding compilers.  */
15936
15937 #ifdef __STDC__
15938 # include <limits.h>
15939 #else
15940 # include <assert.h>
15941 #endif
15942
15943 #undef $ac_func
15944
15945 /* Override any gcc2 internal prototype to avoid an error.  */
15946 #ifdef __cplusplus
15947 extern "C"
15948 {
15949 #endif
15950 /* We use char because int might match the return type of a gcc2
15951    builtin and then its argument prototype would still apply.  */
15952 char $ac_func ();
15953 /* The GNU C library defines this for functions which it implements
15954     to always fail with ENOSYS.  Some functions are actually named
15955     something starting with __ and the normal name is an alias.  */
15956 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15957 choke me
15958 #else
15959 char (*f) () = $ac_func;
15960 #endif
15961 #ifdef __cplusplus
15962 }
15963 #endif
15964
15965 int
15966 main ()
15967 {
15968 return f != $ac_func;
15969   ;
15970   return 0;
15971 }
15972 _ACEOF
15973 rm -f conftest.$ac_objext conftest$ac_exeext
15974 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15975   (eval $ac_link) 2>conftest.er1
15976   ac_status=$?
15977   grep -v '^ *+' conftest.er1 >conftest.err
15978   rm -f conftest.er1
15979   cat conftest.err >&5
15980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15981   (exit $ac_status); } &&
15982          { ac_try='test -z "$ac_c_werror_flag"
15983                          || test ! -s conftest.err'
15984   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15985   (eval $ac_try) 2>&5
15986   ac_status=$?
15987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15988   (exit $ac_status); }; } &&
15989          { ac_try='test -s conftest$ac_exeext'
15990   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15991   (eval $ac_try) 2>&5
15992   ac_status=$?
15993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15994   (exit $ac_status); }; }; then
15995   eval "$as_ac_var=yes"
15996 else
15997   echo "$as_me: failed program was:" >&5
15998 sed 's/^/| /' conftest.$ac_ext >&5
15999
16000 eval "$as_ac_var=no"
16001 fi
16002 rm -f conftest.err conftest.$ac_objext \
16003       conftest$ac_exeext conftest.$ac_ext
16004 fi
16005 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16006 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16007 if test `eval echo '${'$as_ac_var'}'` = yes; then
16008   cat >>confdefs.h <<_ACEOF
16009 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16010 _ACEOF
16011
16012 else
16013   { { echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
16014 echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
16015    { (exit 1); exit 1; }; }
16016 fi
16017 done
16018
16019 fi
16020 done
16021
16022
16023 echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
16024 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
16025 if test "${ac_cv_sys_largefile_source+set}" = set; then
16026   echo $ECHO_N "(cached) $ECHO_C" >&6
16027 else
16028   while :; do
16029   ac_cv_sys_largefile_source=no
16030   cat >conftest.$ac_ext <<_ACEOF
16031 /* confdefs.h.  */
16032 _ACEOF
16033 cat confdefs.h >>conftest.$ac_ext
16034 cat >>conftest.$ac_ext <<_ACEOF
16035 /* end confdefs.h.  */
16036 #include <stdio.h>
16037 int
16038 main ()
16039 {
16040 return !fseeko;
16041   ;
16042   return 0;
16043 }
16044 _ACEOF
16045 rm -f conftest.$ac_objext
16046 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16047   (eval $ac_compile) 2>conftest.er1
16048   ac_status=$?
16049   grep -v '^ *+' conftest.er1 >conftest.err
16050   rm -f conftest.er1
16051   cat conftest.err >&5
16052   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16053   (exit $ac_status); } &&
16054          { ac_try='test -z "$ac_c_werror_flag"
16055                          || test ! -s conftest.err'
16056   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16057   (eval $ac_try) 2>&5
16058   ac_status=$?
16059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16060   (exit $ac_status); }; } &&
16061          { ac_try='test -s conftest.$ac_objext'
16062   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16063   (eval $ac_try) 2>&5
16064   ac_status=$?
16065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16066   (exit $ac_status); }; }; then
16067   break
16068 else
16069   echo "$as_me: failed program was:" >&5
16070 sed 's/^/| /' conftest.$ac_ext >&5
16071
16072 fi
16073 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16074   cat >conftest.$ac_ext <<_ACEOF
16075 /* confdefs.h.  */
16076 _ACEOF
16077 cat confdefs.h >>conftest.$ac_ext
16078 cat >>conftest.$ac_ext <<_ACEOF
16079 /* end confdefs.h.  */
16080 #define _LARGEFILE_SOURCE 1
16081 #include <stdio.h>
16082 int
16083 main ()
16084 {
16085 return !fseeko;
16086   ;
16087   return 0;
16088 }
16089 _ACEOF
16090 rm -f conftest.$ac_objext
16091 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16092   (eval $ac_compile) 2>conftest.er1
16093   ac_status=$?
16094   grep -v '^ *+' conftest.er1 >conftest.err
16095   rm -f conftest.er1
16096   cat conftest.err >&5
16097   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16098   (exit $ac_status); } &&
16099          { ac_try='test -z "$ac_c_werror_flag"
16100                          || test ! -s conftest.err'
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); }; } &&
16106          { ac_try='test -s conftest.$ac_objext'
16107   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16108   (eval $ac_try) 2>&5
16109   ac_status=$?
16110   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16111   (exit $ac_status); }; }; then
16112   ac_cv_sys_largefile_source=1; break
16113 else
16114   echo "$as_me: failed program was:" >&5
16115 sed 's/^/| /' conftest.$ac_ext >&5
16116
16117 fi
16118 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16119   break
16120 done
16121 fi
16122 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
16123 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
16124 if test "$ac_cv_sys_largefile_source" != no; then
16125
16126 cat >>confdefs.h <<_ACEOF
16127 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
16128 _ACEOF
16129
16130 fi
16131 rm -f conftest*
16132
16133 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
16134 # in glibc 2.1.3, but that breaks too many other things.
16135 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
16136 echo "$as_me:$LINENO: checking for fseeko" >&5
16137 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
16138 if test "${ac_cv_func_fseeko+set}" = set; then
16139   echo $ECHO_N "(cached) $ECHO_C" >&6
16140 else
16141   cat >conftest.$ac_ext <<_ACEOF
16142 /* confdefs.h.  */
16143 _ACEOF
16144 cat confdefs.h >>conftest.$ac_ext
16145 cat >>conftest.$ac_ext <<_ACEOF
16146 /* end confdefs.h.  */
16147 #include <stdio.h>
16148 int
16149 main ()
16150 {
16151 return fseeko && fseeko (stdin, 0, 0);
16152   ;
16153   return 0;
16154 }
16155 _ACEOF
16156 rm -f conftest.$ac_objext conftest$ac_exeext
16157 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16158   (eval $ac_link) 2>conftest.er1
16159   ac_status=$?
16160   grep -v '^ *+' conftest.er1 >conftest.err
16161   rm -f conftest.er1
16162   cat conftest.err >&5
16163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16164   (exit $ac_status); } &&
16165          { ac_try='test -z "$ac_c_werror_flag"
16166                          || test ! -s conftest.err'
16167   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16168   (eval $ac_try) 2>&5
16169   ac_status=$?
16170   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16171   (exit $ac_status); }; } &&
16172          { ac_try='test -s conftest$ac_exeext'
16173   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16174   (eval $ac_try) 2>&5
16175   ac_status=$?
16176   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16177   (exit $ac_status); }; }; then
16178   ac_cv_func_fseeko=yes
16179 else
16180   echo "$as_me: failed program was:" >&5
16181 sed 's/^/| /' conftest.$ac_ext >&5
16182
16183 ac_cv_func_fseeko=no
16184 fi
16185 rm -f conftest.err conftest.$ac_objext \
16186       conftest$ac_exeext conftest.$ac_ext
16187 fi
16188 echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
16189 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
16190 if test $ac_cv_func_fseeko = yes; then
16191
16192 cat >>confdefs.h <<\_ACEOF
16193 #define HAVE_FSEEKO 1
16194 _ACEOF
16195
16196 fi
16197
16198
16199 #
16200 # Pthreads
16201 #
16202 # For each platform, we need to know about any special compile and link
16203 # libraries, and whether the normal C function names are thread-safe.
16204 # See the comment at the top of src/port/thread.c for more information.
16205 #
16206 if test "$enable_thread_safety" = yes; then
16207
16208
16209
16210
16211 ac_ext=c
16212 ac_cpp='$CPP $CPPFLAGS'
16213 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16214 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16215 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16216
16217 acx_pthread_ok=no
16218
16219 # We used to check for pthread.h first, but this fails if pthread.h
16220 # requires special compiler flags (e.g. on True64 or Sequent).
16221 # It gets checked for in the link test anyway.
16222
16223 # First of all, check if the user has set any of the PTHREAD_LIBS,
16224 # etcetera environment variables, and if threads linking works using
16225 # them:
16226 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
16227         save_CFLAGS="$CFLAGS"
16228         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16229         save_LIBS="$LIBS"
16230         LIBS="$PTHREAD_LIBS $LIBS"
16231         echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
16232 echo $ECHO_N "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... $ECHO_C" >&6
16233         cat >conftest.$ac_ext <<_ACEOF
16234 /* confdefs.h.  */
16235 _ACEOF
16236 cat confdefs.h >>conftest.$ac_ext
16237 cat >>conftest.$ac_ext <<_ACEOF
16238 /* end confdefs.h.  */
16239
16240 /* Override any gcc2 internal prototype to avoid an error.  */
16241 #ifdef __cplusplus
16242 extern "C"
16243 #endif
16244 /* We use char because int might match the return type of a gcc2
16245    builtin and then its argument prototype would still apply.  */
16246 char pthread_join ();
16247 int
16248 main ()
16249 {
16250 pthread_join ();
16251   ;
16252   return 0;
16253 }
16254 _ACEOF
16255 rm -f conftest.$ac_objext conftest$ac_exeext
16256 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16257   (eval $ac_link) 2>conftest.er1
16258   ac_status=$?
16259   grep -v '^ *+' conftest.er1 >conftest.err
16260   rm -f conftest.er1
16261   cat conftest.err >&5
16262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16263   (exit $ac_status); } &&
16264          { ac_try='test -z "$ac_c_werror_flag"
16265                          || test ! -s conftest.err'
16266   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16267   (eval $ac_try) 2>&5
16268   ac_status=$?
16269   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16270   (exit $ac_status); }; } &&
16271          { ac_try='test -s conftest$ac_exeext'
16272   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16273   (eval $ac_try) 2>&5
16274   ac_status=$?
16275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16276   (exit $ac_status); }; }; then
16277   acx_pthread_ok=yes
16278 else
16279   echo "$as_me: failed program was:" >&5
16280 sed 's/^/| /' conftest.$ac_ext >&5
16281
16282 fi
16283 rm -f conftest.err conftest.$ac_objext \
16284       conftest$ac_exeext conftest.$ac_ext
16285         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
16286 echo "${ECHO_T}$acx_pthread_ok" >&6
16287         if test x"$acx_pthread_ok" = xno; then
16288                 PTHREAD_LIBS=""
16289                 PTHREAD_CFLAGS=""
16290         fi
16291         LIBS="$save_LIBS"
16292         CFLAGS="$save_CFLAGS"
16293 fi
16294
16295 # We must check for the threads library under a number of different
16296 # names; the ordering is very important because some systems
16297 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
16298 # libraries is broken (non-POSIX).
16299
16300 # Create a list of thread flags to try.  Items starting with a "-" are
16301 # C compiler flags, and other items are library names, except for "none"
16302 # which indicates that we try without any flags at all, and "pthread-config"
16303 # which is a program returning the flags for the Pth emulation library.
16304
16305 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
16306
16307 # The ordering *is* (sometimes) important.  Some notes on the
16308 # individual items follow:
16309
16310 # pthreads: AIX (must check this before -lpthread)
16311 # none: in case threads are in libc; should be tried before -Kthread and
16312 #       other compiler flags to prevent continual compiler warnings
16313 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
16314 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
16315 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
16316 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
16317 # -pthreads: Solaris/gcc
16318 # -mthreads: Mingw32/gcc, Lynx/gcc
16319 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
16320 #      doesn't hurt to check since this sometimes defines pthreads too;
16321 #      also defines -D_REENTRANT)
16322 # pthread: Linux, etcetera
16323 # --thread-safe: KAI C++
16324 # pthread-config: use pthread-config program (for GNU Pth library)
16325
16326 case "${host_cpu}-${host_os}" in
16327         *solaris*)
16328
16329         # On Solaris (at least, for some versions), libc contains stubbed
16330         # (non-functional) versions of the pthreads routines, so link-based
16331         # tests will erroneously succeed.  (We need to link with -pthread or
16332         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
16333         # a function called by this macro, so we could check for that, but
16334         # who knows whether they'll stub that too in a future libc.)  So,
16335         # we'll just look for -pthreads and -lpthread first:
16336
16337         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
16338         ;;
16339 esac
16340
16341 if test x"$acx_pthread_ok" = xno; then
16342 for flag in $acx_pthread_flags; do
16343
16344         tryPTHREAD_CFLAGS=""
16345         tryPTHREAD_LIBS=""
16346         case $flag in
16347                 none)
16348                 echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
16349 echo $ECHO_N "checking whether pthreads work without any flags... $ECHO_C" >&6
16350                 ;;
16351
16352                 -*)
16353                 echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
16354 echo $ECHO_N "checking whether pthreads work with $flag... $ECHO_C" >&6
16355                 tryPTHREAD_CFLAGS="$flag"
16356                 ;;
16357
16358                 pthread-config)
16359                 # skip this if we already have flags defined, for PostgreSQL
16360                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
16361                 # Extract the first word of "pthread-config", so it can be a program name with args.
16362 set dummy pthread-config; ac_word=$2
16363 echo "$as_me:$LINENO: checking for $ac_word" >&5
16364 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16365 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
16366   echo $ECHO_N "(cached) $ECHO_C" >&6
16367 else
16368   if test -n "$acx_pthread_config"; then
16369   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
16370 else
16371 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16372 for as_dir in $PATH
16373 do
16374   IFS=$as_save_IFS
16375   test -z "$as_dir" && as_dir=.
16376   for ac_exec_ext in '' $ac_executable_extensions; do
16377   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16378     ac_cv_prog_acx_pthread_config="yes"
16379     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16380     break 2
16381   fi
16382 done
16383 done
16384
16385   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
16386 fi
16387 fi
16388 acx_pthread_config=$ac_cv_prog_acx_pthread_config
16389 if test -n "$acx_pthread_config"; then
16390   echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
16391 echo "${ECHO_T}$acx_pthread_config" >&6
16392 else
16393   echo "$as_me:$LINENO: result: no" >&5
16394 echo "${ECHO_T}no" >&6
16395 fi
16396
16397                 if test x"$acx_pthread_config" = xno; then continue; fi
16398                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
16399                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
16400                 ;;
16401
16402                 *)
16403                 echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
16404 echo $ECHO_N "checking for the pthreads library -l$flag... $ECHO_C" >&6
16405                 tryPTHREAD_LIBS="-l$flag"
16406                 ;;
16407         esac
16408
16409         save_LIBS="$LIBS"
16410         save_CFLAGS="$CFLAGS"
16411         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
16412         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
16413
16414         # Check for various functions.  We must include pthread.h,
16415         # since some functions may be macros.  (On the Sequent, we
16416         # need a special flag -Kthread to make this header compile.)
16417         # We check for pthread_join because it is in -lpthread on IRIX
16418         # while pthread_create is in libc.  We check for pthread_attr_init
16419         # due to DEC craziness with -lpthreads.  We check for
16420         # pthread_cleanup_push because it is one of the few pthread
16421         # functions on Solaris that doesn't have a non-functional libc stub.
16422         # We try pthread_create on general principles.
16423         cat >conftest.$ac_ext <<_ACEOF
16424 /* confdefs.h.  */
16425 _ACEOF
16426 cat confdefs.h >>conftest.$ac_ext
16427 cat >>conftest.$ac_ext <<_ACEOF
16428 /* end confdefs.h.  */
16429 #include <pthread.h>
16430 int
16431 main ()
16432 {
16433 pthread_t th; pthread_join(th, 0);
16434                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
16435                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
16436   ;
16437   return 0;
16438 }
16439 _ACEOF
16440 rm -f conftest.$ac_objext conftest$ac_exeext
16441 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16442   (eval $ac_link) 2>conftest.er1
16443   ac_status=$?
16444   grep -v '^ *+' conftest.er1 >conftest.err
16445   rm -f conftest.er1
16446   cat conftest.err >&5
16447   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16448   (exit $ac_status); } &&
16449          { ac_try='test -z "$ac_c_werror_flag"
16450                          || test ! -s conftest.err'
16451   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16452   (eval $ac_try) 2>&5
16453   ac_status=$?
16454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16455   (exit $ac_status); }; } &&
16456          { ac_try='test -s conftest$ac_exeext'
16457   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16458   (eval $ac_try) 2>&5
16459   ac_status=$?
16460   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16461   (exit $ac_status); }; }; then
16462   acx_pthread_ok=yes
16463 else
16464   echo "$as_me: failed program was:" >&5
16465 sed 's/^/| /' conftest.$ac_ext >&5
16466
16467 acx_pthread_ok=no
16468 fi
16469 rm -f conftest.err conftest.$ac_objext \
16470       conftest$ac_exeext conftest.$ac_ext
16471
16472         if test "x$acx_pthread_ok" = xyes; then
16473             # Don't use options that are ignored by the compiler.
16474             # We find them by checking stderror.
16475             cat >conftest.$ac_ext <<_ACEOF
16476 int
16477 main (int argc, char **argv)
16478 {
16479   (void) argc;
16480   (void) argv;
16481   return 0;
16482 }
16483 _ACEOF
16484             rm -f conftest.$ac_objext conftest$ac_exeext
16485             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
16486                 # we continue with more flags because Linux needs -lpthread
16487                 # for libpq builds on PostgreSQL.  The test above only
16488                 # tests for building binaries, not shared libraries.
16489                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
16490                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
16491             else   acx_pthread_ok=no
16492             fi
16493         fi
16494
16495         LIBS="$save_LIBS"
16496         CFLAGS="$save_CFLAGS"
16497
16498         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
16499 echo "${ECHO_T}$acx_pthread_ok" >&6
16500 done
16501 fi
16502
16503 # Various other checks:
16504 if test "x$acx_pthread_ok" = xyes; then
16505         save_LIBS="$LIBS"
16506         LIBS="$PTHREAD_LIBS $LIBS"
16507         save_CFLAGS="$CFLAGS"
16508         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16509
16510         # Detect AIX lossage: threads are created detached by default
16511         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
16512         echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
16513 echo $ECHO_N "checking for joinable pthread attribute... $ECHO_C" >&6
16514         cat >conftest.$ac_ext <<_ACEOF
16515 /* confdefs.h.  */
16516 _ACEOF
16517 cat confdefs.h >>conftest.$ac_ext
16518 cat >>conftest.$ac_ext <<_ACEOF
16519 /* end confdefs.h.  */
16520 #include <pthread.h>
16521 int
16522 main ()
16523 {
16524 int attr=PTHREAD_CREATE_JOINABLE;
16525   ;
16526   return 0;
16527 }
16528 _ACEOF
16529 rm -f conftest.$ac_objext conftest$ac_exeext
16530 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16531   (eval $ac_link) 2>conftest.er1
16532   ac_status=$?
16533   grep -v '^ *+' conftest.er1 >conftest.err
16534   rm -f conftest.er1
16535   cat conftest.err >&5
16536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16537   (exit $ac_status); } &&
16538          { ac_try='test -z "$ac_c_werror_flag"
16539                          || test ! -s conftest.err'
16540   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16541   (eval $ac_try) 2>&5
16542   ac_status=$?
16543   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16544   (exit $ac_status); }; } &&
16545          { ac_try='test -s conftest$ac_exeext'
16546   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16547   (eval $ac_try) 2>&5
16548   ac_status=$?
16549   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16550   (exit $ac_status); }; }; then
16551   ok=PTHREAD_CREATE_JOINABLE
16552 else
16553   echo "$as_me: failed program was:" >&5
16554 sed 's/^/| /' conftest.$ac_ext >&5
16555
16556 ok=unknown
16557 fi
16558 rm -f conftest.err conftest.$ac_objext \
16559       conftest$ac_exeext conftest.$ac_ext
16560         if test x"$ok" = xunknown; then
16561                 cat >conftest.$ac_ext <<_ACEOF
16562 /* confdefs.h.  */
16563 _ACEOF
16564 cat confdefs.h >>conftest.$ac_ext
16565 cat >>conftest.$ac_ext <<_ACEOF
16566 /* end confdefs.h.  */
16567 #include <pthread.h>
16568 int
16569 main ()
16570 {
16571 int attr=PTHREAD_CREATE_UNDETACHED;
16572   ;
16573   return 0;
16574 }
16575 _ACEOF
16576 rm -f conftest.$ac_objext conftest$ac_exeext
16577 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16578   (eval $ac_link) 2>conftest.er1
16579   ac_status=$?
16580   grep -v '^ *+' conftest.er1 >conftest.err
16581   rm -f conftest.er1
16582   cat conftest.err >&5
16583   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16584   (exit $ac_status); } &&
16585          { ac_try='test -z "$ac_c_werror_flag"
16586                          || test ! -s conftest.err'
16587   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16588   (eval $ac_try) 2>&5
16589   ac_status=$?
16590   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16591   (exit $ac_status); }; } &&
16592          { ac_try='test -s conftest$ac_exeext'
16593   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16594   (eval $ac_try) 2>&5
16595   ac_status=$?
16596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16597   (exit $ac_status); }; }; then
16598   ok=PTHREAD_CREATE_UNDETACHED
16599 else
16600   echo "$as_me: failed program was:" >&5
16601 sed 's/^/| /' conftest.$ac_ext >&5
16602
16603 ok=unknown
16604 fi
16605 rm -f conftest.err conftest.$ac_objext \
16606       conftest$ac_exeext conftest.$ac_ext
16607         fi
16608         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
16609
16610 cat >>confdefs.h <<\_ACEOF
16611 #define PTHREAD_CREATE_JOINABLE $ok
16612 _ACEOF
16613
16614         fi
16615         echo "$as_me:$LINENO: result: ${ok}" >&5
16616 echo "${ECHO_T}${ok}" >&6
16617         if test x"$ok" = xunknown; then
16618                 { echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
16619 echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
16620         fi
16621
16622         echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
16623 echo $ECHO_N "checking if more special flags are required for pthreads... $ECHO_C" >&6
16624         flag=no
16625 # We always add these in PostgreSQL
16626 #       case "${host_cpu}-${host_os}" in
16627 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
16628 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
16629 #       esac
16630         echo "$as_me:$LINENO: result: ${flag}" >&5
16631 echo "${ECHO_T}${flag}" >&6
16632         if test "x$flag" != xno; then
16633                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
16634         fi
16635
16636         LIBS="$save_LIBS"
16637         CFLAGS="$save_CFLAGS"
16638
16639 # Supporting cc_r would require a special CC in all places that
16640 # use libpq, and that is ugly, so we don't do it.  Users can still
16641 # define their compiler as cc_r to do thread builds of everything.
16642         # More AIX lossage: must compile with cc_r
16643         # Extract the first word of "cc_r", so it can be a program name with args.
16644 set dummy cc_r; ac_word=$2
16645 echo "$as_me:$LINENO: checking for $ac_word" >&5
16646 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16647 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
16648   echo $ECHO_N "(cached) $ECHO_C" >&6
16649 else
16650   if test -n "$PTHREAD_CC"; then
16651   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
16652 else
16653 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16654 for as_dir in $PATH
16655 do
16656   IFS=$as_save_IFS
16657   test -z "$as_dir" && as_dir=.
16658   for ac_exec_ext in '' $ac_executable_extensions; do
16659   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16660     ac_cv_prog_PTHREAD_CC="cc_r"
16661     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16662     break 2
16663   fi
16664 done
16665 done
16666
16667   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
16668 fi
16669 fi
16670 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
16671 if test -n "$PTHREAD_CC"; then
16672   echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
16673 echo "${ECHO_T}$PTHREAD_CC" >&6
16674 else
16675   echo "$as_me:$LINENO: result: no" >&5
16676 echo "${ECHO_T}no" >&6
16677 fi
16678
16679 else
16680         PTHREAD_CC="$CC"
16681 fi
16682
16683
16684
16685
16686
16687 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
16688 if test x"$acx_pthread_ok" = xyes; then
16689
16690 cat >>confdefs.h <<\_ACEOF
16691 #define HAVE_PTHREAD 1
16692 _ACEOF
16693
16694         :
16695 else
16696         acx_pthread_ok=no
16697
16698 fi
16699 ac_ext=c
16700 ac_cpp='$CPP $CPPFLAGS'
16701 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16702 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16703 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16704
16705         # set thread flags
16706
16707 # Some platforms use these, so just defineed them.  They can't hurt if they
16708 # are not supported.
16709 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
16710
16711
16712 # At this point, we don't want to muck with the compiler name for threading.
16713 # Let's see who fails, perhaps AIX.  2004-04-23
16714 if test "$PTHREAD_CC" != "$CC"; then
16715 { { echo "$as_me:$LINENO: error:
16716 PostgreSQL does not support platforms that require a special
16717 compiler binary for thread-safety.
16718 " >&5
16719 echo "$as_me: error:
16720 PostgreSQL does not support platforms that require a special
16721 compiler binary for thread-safety.
16722 " >&2;}
16723    { (exit 1); exit 1; }; }
16724 fi
16725
16726 if test "$THREAD_SUPPORT" = no; then
16727 { { echo "$as_me:$LINENO: error:
16728 Cannot enable threads on your platform.
16729 Your platform is known to not support thread-safe programs.
16730 For details, compile and run src/bin/pg_thread_test.
16731 " >&5
16732 echo "$as_me: error:
16733 Cannot enable threads on your platform.
16734 Your platform is known to not support thread-safe programs.
16735 For details, compile and run src/bin/pg_thread_test.
16736 " >&2;}
16737    { (exit 1); exit 1; }; }
16738 fi
16739
16740 # Check for *_r functions
16741 _CFLAGS="$CFLAGS"
16742 _LIBS="$LIBS"
16743 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16744 LIBS="$LIBS $PTHREAD_LIBS"
16745
16746 if test "${ac_cv_header_pthread_h+set}" = set; then
16747   echo "$as_me:$LINENO: checking for pthread.h" >&5
16748 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
16749 if test "${ac_cv_header_pthread_h+set}" = set; then
16750   echo $ECHO_N "(cached) $ECHO_C" >&6
16751 fi
16752 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
16753 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
16754 else
16755   # Is the header compilable?
16756 echo "$as_me:$LINENO: checking pthread.h usability" >&5
16757 echo $ECHO_N "checking pthread.h usability... $ECHO_C" >&6
16758 cat >conftest.$ac_ext <<_ACEOF
16759 /* confdefs.h.  */
16760 _ACEOF
16761 cat confdefs.h >>conftest.$ac_ext
16762 cat >>conftest.$ac_ext <<_ACEOF
16763 /* end confdefs.h.  */
16764 $ac_includes_default
16765 #include <pthread.h>
16766 _ACEOF
16767 rm -f conftest.$ac_objext
16768 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16769   (eval $ac_compile) 2>conftest.er1
16770   ac_status=$?
16771   grep -v '^ *+' conftest.er1 >conftest.err
16772   rm -f conftest.er1
16773   cat conftest.err >&5
16774   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16775   (exit $ac_status); } &&
16776          { ac_try='test -z "$ac_c_werror_flag"
16777                          || test ! -s conftest.err'
16778   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16779   (eval $ac_try) 2>&5
16780   ac_status=$?
16781   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16782   (exit $ac_status); }; } &&
16783          { ac_try='test -s conftest.$ac_objext'
16784   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16785   (eval $ac_try) 2>&5
16786   ac_status=$?
16787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16788   (exit $ac_status); }; }; then
16789   ac_header_compiler=yes
16790 else
16791   echo "$as_me: failed program was:" >&5
16792 sed 's/^/| /' conftest.$ac_ext >&5
16793
16794 ac_header_compiler=no
16795 fi
16796 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16797 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16798 echo "${ECHO_T}$ac_header_compiler" >&6
16799
16800 # Is the header present?
16801 echo "$as_me:$LINENO: checking pthread.h presence" >&5
16802 echo $ECHO_N "checking pthread.h presence... $ECHO_C" >&6
16803 cat >conftest.$ac_ext <<_ACEOF
16804 /* confdefs.h.  */
16805 _ACEOF
16806 cat confdefs.h >>conftest.$ac_ext
16807 cat >>conftest.$ac_ext <<_ACEOF
16808 /* end confdefs.h.  */
16809 #include <pthread.h>
16810 _ACEOF
16811 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16812   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16813   ac_status=$?
16814   grep -v '^ *+' conftest.er1 >conftest.err
16815   rm -f conftest.er1
16816   cat conftest.err >&5
16817   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16818   (exit $ac_status); } >/dev/null; then
16819   if test -s conftest.err; then
16820     ac_cpp_err=$ac_c_preproc_warn_flag
16821     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16822   else
16823     ac_cpp_err=
16824   fi
16825 else
16826   ac_cpp_err=yes
16827 fi
16828 if test -z "$ac_cpp_err"; then
16829   ac_header_preproc=yes
16830 else
16831   echo "$as_me: failed program was:" >&5
16832 sed 's/^/| /' conftest.$ac_ext >&5
16833
16834   ac_header_preproc=no
16835 fi
16836 rm -f conftest.err conftest.$ac_ext
16837 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16838 echo "${ECHO_T}$ac_header_preproc" >&6
16839
16840 # So?  What about this header?
16841 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16842   yes:no: )
16843     { echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
16844 echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
16845     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
16846 echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
16847     ac_header_preproc=yes
16848     ;;
16849   no:yes:* )
16850     { echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
16851 echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
16852     { echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
16853 echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
16854     { echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
16855 echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
16856     { echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
16857 echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
16858     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
16859 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
16860     { echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
16861 echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
16862     (
16863       cat <<\_ASBOX
16864 ## ---------------------------------------- ##
16865 ## Report this to pgsql-bugs@postgresql.org ##
16866 ## ---------------------------------------- ##
16867 _ASBOX
16868     ) |
16869       sed "s/^/$as_me: WARNING:     /" >&2
16870     ;;
16871 esac
16872 echo "$as_me:$LINENO: checking for pthread.h" >&5
16873 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
16874 if test "${ac_cv_header_pthread_h+set}" = set; then
16875   echo $ECHO_N "(cached) $ECHO_C" >&6
16876 else
16877   ac_cv_header_pthread_h=$ac_header_preproc
16878 fi
16879 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
16880 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
16881
16882 fi
16883 if test $ac_cv_header_pthread_h = yes; then
16884   :
16885 else
16886   { { echo "$as_me:$LINENO: error: pthread.h not found, required for --enable-thread-safety" >&5
16887 echo "$as_me: error: pthread.h not found, required for --enable-thread-safety" >&2;}
16888    { (exit 1); exit 1; }; }
16889 fi
16890
16891
16892
16893
16894
16895
16896 for ac_func in strerror_r getpwuid_r gethostbyname_r
16897 do
16898 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16899 echo "$as_me:$LINENO: checking for $ac_func" >&5
16900 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16901 if eval "test \"\${$as_ac_var+set}\" = set"; then
16902   echo $ECHO_N "(cached) $ECHO_C" >&6
16903 else
16904   cat >conftest.$ac_ext <<_ACEOF
16905 /* confdefs.h.  */
16906 _ACEOF
16907 cat confdefs.h >>conftest.$ac_ext
16908 cat >>conftest.$ac_ext <<_ACEOF
16909 /* end confdefs.h.  */
16910 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16911    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16912 #define $ac_func innocuous_$ac_func
16913
16914 /* System header to define __stub macros and hopefully few prototypes,
16915     which can conflict with char $ac_func (); below.
16916     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16917     <limits.h> exists even on freestanding compilers.  */
16918
16919 #ifdef __STDC__
16920 # include <limits.h>
16921 #else
16922 # include <assert.h>
16923 #endif
16924
16925 #undef $ac_func
16926
16927 /* Override any gcc2 internal prototype to avoid an error.  */
16928 #ifdef __cplusplus
16929 extern "C"
16930 {
16931 #endif
16932 /* We use char because int might match the return type of a gcc2
16933    builtin and then its argument prototype would still apply.  */
16934 char $ac_func ();
16935 /* The GNU C library defines this for functions which it implements
16936     to always fail with ENOSYS.  Some functions are actually named
16937     something starting with __ and the normal name is an alias.  */
16938 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16939 choke me
16940 #else
16941 char (*f) () = $ac_func;
16942 #endif
16943 #ifdef __cplusplus
16944 }
16945 #endif
16946
16947 int
16948 main ()
16949 {
16950 return f != $ac_func;
16951   ;
16952   return 0;
16953 }
16954 _ACEOF
16955 rm -f conftest.$ac_objext conftest$ac_exeext
16956 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16957   (eval $ac_link) 2>conftest.er1
16958   ac_status=$?
16959   grep -v '^ *+' conftest.er1 >conftest.err
16960   rm -f conftest.er1
16961   cat conftest.err >&5
16962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16963   (exit $ac_status); } &&
16964          { ac_try='test -z "$ac_c_werror_flag"
16965                          || test ! -s conftest.err'
16966   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16967   (eval $ac_try) 2>&5
16968   ac_status=$?
16969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16970   (exit $ac_status); }; } &&
16971          { ac_try='test -s conftest$ac_exeext'
16972   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16973   (eval $ac_try) 2>&5
16974   ac_status=$?
16975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16976   (exit $ac_status); }; }; then
16977   eval "$as_ac_var=yes"
16978 else
16979   echo "$as_me: failed program was:" >&5
16980 sed 's/^/| /' conftest.$ac_ext >&5
16981
16982 eval "$as_ac_var=no"
16983 fi
16984 rm -f conftest.err conftest.$ac_objext \
16985       conftest$ac_exeext conftest.$ac_ext
16986 fi
16987 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16988 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16989 if test `eval echo '${'$as_ac_var'}'` = yes; then
16990   cat >>confdefs.h <<_ACEOF
16991 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16992 _ACEOF
16993
16994 fi
16995 done
16996
16997
16998 # Do test here with the proper thread flags
16999 echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
17000 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6
17001 if test "${pgac_func_getpwuid_r_5arg+set}" = set; then
17002   echo $ECHO_N "(cached) $ECHO_C" >&6
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 #include <sys/types.h>
17011 #include <pwd.h>
17012 int
17013 main ()
17014 {
17015 uid_t uid;
17016 struct passwd *space;
17017 char *buf;
17018 size_t bufsize;
17019 struct passwd **result;
17020 getpwuid_r(uid, space, buf, bufsize, result);
17021   ;
17022   return 0;
17023 }
17024 _ACEOF
17025 rm -f conftest.$ac_objext
17026 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17027   (eval $ac_compile) 2>conftest.er1
17028   ac_status=$?
17029   grep -v '^ *+' conftest.er1 >conftest.err
17030   rm -f conftest.er1
17031   cat conftest.err >&5
17032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17033   (exit $ac_status); } &&
17034          { ac_try='test -z "$ac_c_werror_flag"
17035                          || test ! -s conftest.err'
17036   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17037   (eval $ac_try) 2>&5
17038   ac_status=$?
17039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17040   (exit $ac_status); }; } &&
17041          { ac_try='test -s conftest.$ac_objext'
17042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17043   (eval $ac_try) 2>&5
17044   ac_status=$?
17045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17046   (exit $ac_status); }; }; then
17047   pgac_func_getpwuid_r_5arg=yes
17048 else
17049   echo "$as_me: failed program was:" >&5
17050 sed 's/^/| /' conftest.$ac_ext >&5
17051
17052 pgac_func_getpwuid_r_5arg=no
17053 fi
17054 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17055 fi
17056 echo "$as_me:$LINENO: result: $pgac_func_getpwuid_r_5arg" >&5
17057 echo "${ECHO_T}$pgac_func_getpwuid_r_5arg" >&6
17058 if test x"$pgac_func_getpwuid_r_5arg" = xyes ; then
17059
17060 cat >>confdefs.h <<\_ACEOF
17061 #define GETPWUID_R_5ARG
17062 _ACEOF
17063
17064 fi
17065
17066 echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
17067 echo $ECHO_N "checking whether strerror_r returns int... $ECHO_C" >&6
17068 if test "${pgac_func_strerror_r_int+set}" = set; then
17069   echo $ECHO_N "(cached) $ECHO_C" >&6
17070 else
17071   cat >conftest.$ac_ext <<_ACEOF
17072 /* confdefs.h.  */
17073 _ACEOF
17074 cat confdefs.h >>conftest.$ac_ext
17075 cat >>conftest.$ac_ext <<_ACEOF
17076 /* end confdefs.h.  */
17077 #include <string.h>
17078 int
17079 main ()
17080 {
17081 #ifndef _AIX
17082 int strerror_r(int, char *, size_t);
17083 #else
17084 /* Older AIX has 'int' for the third argument so we don't test the args. */
17085 int strerror_r();
17086 #endif
17087   ;
17088   return 0;
17089 }
17090 _ACEOF
17091 rm -f conftest.$ac_objext
17092 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17093   (eval $ac_compile) 2>conftest.er1
17094   ac_status=$?
17095   grep -v '^ *+' conftest.er1 >conftest.err
17096   rm -f conftest.er1
17097   cat conftest.err >&5
17098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17099   (exit $ac_status); } &&
17100          { ac_try='test -z "$ac_c_werror_flag"
17101                          || test ! -s conftest.err'
17102   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17103   (eval $ac_try) 2>&5
17104   ac_status=$?
17105   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17106   (exit $ac_status); }; } &&
17107          { ac_try='test -s conftest.$ac_objext'
17108   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17109   (eval $ac_try) 2>&5
17110   ac_status=$?
17111   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17112   (exit $ac_status); }; }; then
17113   pgac_func_strerror_r_int=yes
17114 else
17115   echo "$as_me: failed program was:" >&5
17116 sed 's/^/| /' conftest.$ac_ext >&5
17117
17118 pgac_func_strerror_r_int=no
17119 fi
17120 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17121 fi
17122 echo "$as_me:$LINENO: result: $pgac_func_strerror_r_int" >&5
17123 echo "${ECHO_T}$pgac_func_strerror_r_int" >&6
17124 if test x"$pgac_func_strerror_r_int" = xyes ; then
17125
17126 cat >>confdefs.h <<\_ACEOF
17127 #define STRERROR_R_INT
17128 _ACEOF
17129
17130 fi
17131
17132
17133 CFLAGS="$_CFLAGS"
17134 LIBS="$_LIBS"
17135
17136 else
17137 # do not use values from template file
17138 PTHREAD_CFLAGS=
17139 PTHREAD_LIBS=
17140 fi
17141
17142
17143
17144
17145
17146 # This test makes sure that run tests work at all.  Sometimes a shared
17147 # library is found by the linker, but the runtime linker can't find it.
17148 # This check should come after all modifications of compiler or linker
17149 # variables, and before any other run tests.
17150 echo "$as_me:$LINENO: checking test program" >&5
17151 echo $ECHO_N "checking test program... $ECHO_C" >&6
17152 if test "$cross_compiling" = yes; then
17153   echo "$as_me:$LINENO: result: cross-compiling" >&5
17154 echo "${ECHO_T}cross-compiling" >&6
17155 else
17156   cat >conftest.$ac_ext <<_ACEOF
17157 /* confdefs.h.  */
17158 _ACEOF
17159 cat confdefs.h >>conftest.$ac_ext
17160 cat >>conftest.$ac_ext <<_ACEOF
17161 /* end confdefs.h.  */
17162 int main() { return 0; }
17163 _ACEOF
17164 rm -f conftest$ac_exeext
17165 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17166   (eval $ac_link) 2>&5
17167   ac_status=$?
17168   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17169   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17170   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17171   (eval $ac_try) 2>&5
17172   ac_status=$?
17173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17174   (exit $ac_status); }; }; then
17175   echo "$as_me:$LINENO: result: ok" >&5
17176 echo "${ECHO_T}ok" >&6
17177 else
17178   echo "$as_me: program exited with status $ac_status" >&5
17179 echo "$as_me: failed program was:" >&5
17180 sed 's/^/| /' conftest.$ac_ext >&5
17181
17182 ( exit $ac_status )
17183 echo "$as_me:$LINENO: result: failed" >&5
17184 echo "${ECHO_T}failed" >&6
17185 { { echo "$as_me:$LINENO: error:
17186 *** Could not execute a simple test program.  This may be a problem
17187 *** related to locating shared libraries.  Check the file 'config.log'
17188 *** for the exact reason." >&5
17189 echo "$as_me: error:
17190 *** Could not execute a simple test program.  This may be a problem
17191 *** related to locating shared libraries.  Check the file 'config.log'
17192 *** for the exact reason." >&2;}
17193    { (exit 1); exit 1; }; }
17194 fi
17195 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17196 fi
17197
17198 # --------------------
17199 # Run tests below here
17200 # --------------------
17201
17202 # Force use of our snprintf if system's doesn't do arg control
17203 # See comment above at snprintf test for details.
17204 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
17205   echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
17206 echo $ECHO_N "checking whether printf supports argument control... $ECHO_C" >&6
17207 if test "${pgac_cv_printf_arg_control+set}" = set; then
17208   echo $ECHO_N "(cached) $ECHO_C" >&6
17209 else
17210   if test "$cross_compiling" = yes; then
17211   pgac_cv_printf_arg_control=cross
17212 else
17213   cat >conftest.$ac_ext <<_ACEOF
17214 /* confdefs.h.  */
17215 _ACEOF
17216 cat confdefs.h >>conftest.$ac_ext
17217 cat >>conftest.$ac_ext <<_ACEOF
17218 /* end confdefs.h.  */
17219 #include <stdio.h>
17220 #include <string.h>
17221
17222 int main()
17223 {
17224   char buf[100];
17225
17226   /* can it swap arguments? */
17227   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
17228   if (strcmp(buf, "4 3") != 0)
17229     return 1;
17230   return 0;
17231 }
17232 _ACEOF
17233 rm -f conftest$ac_exeext
17234 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17235   (eval $ac_link) 2>&5
17236   ac_status=$?
17237   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17238   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17239   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17240   (eval $ac_try) 2>&5
17241   ac_status=$?
17242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17243   (exit $ac_status); }; }; then
17244   pgac_cv_printf_arg_control=yes
17245 else
17246   echo "$as_me: program exited with status $ac_status" >&5
17247 echo "$as_me: failed program was:" >&5
17248 sed 's/^/| /' conftest.$ac_ext >&5
17249
17250 ( exit $ac_status )
17251 pgac_cv_printf_arg_control=no
17252 fi
17253 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17254 fi
17255
17256 fi
17257 echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
17258 echo "${ECHO_T}$pgac_cv_printf_arg_control" >&6
17259
17260   if test $pgac_cv_printf_arg_control != yes ; then
17261     pgac_need_repl_snprintf=yes
17262   fi
17263 fi
17264
17265
17266
17267 echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
17268 echo $ECHO_N "checking whether long int is 64 bits... $ECHO_C" >&6
17269 if test "${pgac_cv_type_long_int_64+set}" = set; then
17270   echo $ECHO_N "(cached) $ECHO_C" >&6
17271 else
17272   if test "$cross_compiling" = yes; then
17273   # If cross-compiling, check the size reported by the compiler and
17274 # trust that the arithmetic works.
17275 cat >conftest.$ac_ext <<_ACEOF
17276 /* confdefs.h.  */
17277 _ACEOF
17278 cat confdefs.h >>conftest.$ac_ext
17279 cat >>conftest.$ac_ext <<_ACEOF
17280 /* end confdefs.h.  */
17281
17282 int
17283 main ()
17284 {
17285 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
17286 test_array [0] = 0
17287
17288   ;
17289   return 0;
17290 }
17291 _ACEOF
17292 rm -f conftest.$ac_objext
17293 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17294   (eval $ac_compile) 2>conftest.er1
17295   ac_status=$?
17296   grep -v '^ *+' conftest.er1 >conftest.err
17297   rm -f conftest.er1
17298   cat conftest.err >&5
17299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17300   (exit $ac_status); } &&
17301          { ac_try='test -z "$ac_c_werror_flag"
17302                          || test ! -s conftest.err'
17303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17304   (eval $ac_try) 2>&5
17305   ac_status=$?
17306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17307   (exit $ac_status); }; } &&
17308          { ac_try='test -s conftest.$ac_objext'
17309   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17310   (eval $ac_try) 2>&5
17311   ac_status=$?
17312   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17313   (exit $ac_status); }; }; then
17314   pgac_cv_type_long_int_64=yes
17315 else
17316   echo "$as_me: failed program was:" >&5
17317 sed 's/^/| /' conftest.$ac_ext >&5
17318
17319 pgac_cv_type_long_int_64=no
17320 fi
17321 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17322 else
17323   cat >conftest.$ac_ext <<_ACEOF
17324 /* confdefs.h.  */
17325 _ACEOF
17326 cat confdefs.h >>conftest.$ac_ext
17327 cat >>conftest.$ac_ext <<_ACEOF
17328 /* end confdefs.h.  */
17329 typedef long int ac_int64;
17330
17331 /*
17332  * These are globals to discourage the compiler from folding all the
17333  * arithmetic tests down to compile-time constants.
17334  */
17335 ac_int64 a = 20000001;
17336 ac_int64 b = 40000005;
17337
17338 int does_int64_work()
17339 {
17340   ac_int64 c,d;
17341
17342   if (sizeof(ac_int64) != 8)
17343     return 0;                   /* definitely not the right size */
17344
17345   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
17346   c = a * b;
17347   d = (c + b) / b;
17348   if (d != a+1)
17349     return 0;
17350   return 1;
17351 }
17352 main() {
17353   exit(! does_int64_work());
17354 }
17355 _ACEOF
17356 rm -f conftest$ac_exeext
17357 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17358   (eval $ac_link) 2>&5
17359   ac_status=$?
17360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17361   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17362   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17363   (eval $ac_try) 2>&5
17364   ac_status=$?
17365   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17366   (exit $ac_status); }; }; then
17367   pgac_cv_type_long_int_64=yes
17368 else
17369   echo "$as_me: program exited with status $ac_status" >&5
17370 echo "$as_me: failed program was:" >&5
17371 sed 's/^/| /' conftest.$ac_ext >&5
17372
17373 ( exit $ac_status )
17374 pgac_cv_type_long_int_64=no
17375 fi
17376 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17377 fi
17378 fi
17379 echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
17380 echo "${ECHO_T}$pgac_cv_type_long_int_64" >&6
17381
17382 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
17383 if test x"$pgac_cv_type_long_int_64" = xyes ; then
17384
17385 cat >>confdefs.h <<\_ACEOF
17386 #define HAVE_LONG_INT_64
17387 _ACEOF
17388
17389 fi
17390
17391
17392 if test x"$HAVE_LONG_INT_64" = x"no" ; then
17393   echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
17394 echo $ECHO_N "checking whether long long int is 64 bits... $ECHO_C" >&6
17395 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
17396   echo $ECHO_N "(cached) $ECHO_C" >&6
17397 else
17398   if test "$cross_compiling" = yes; then
17399   # If cross-compiling, check the size reported by the compiler and
17400 # trust that the arithmetic works.
17401 cat >conftest.$ac_ext <<_ACEOF
17402 /* confdefs.h.  */
17403 _ACEOF
17404 cat confdefs.h >>conftest.$ac_ext
17405 cat >>conftest.$ac_ext <<_ACEOF
17406 /* end confdefs.h.  */
17407
17408 int
17409 main ()
17410 {
17411 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
17412 test_array [0] = 0
17413
17414   ;
17415   return 0;
17416 }
17417 _ACEOF
17418 rm -f conftest.$ac_objext
17419 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17420   (eval $ac_compile) 2>conftest.er1
17421   ac_status=$?
17422   grep -v '^ *+' conftest.er1 >conftest.err
17423   rm -f conftest.er1
17424   cat conftest.err >&5
17425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17426   (exit $ac_status); } &&
17427          { ac_try='test -z "$ac_c_werror_flag"
17428                          || test ! -s conftest.err'
17429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17430   (eval $ac_try) 2>&5
17431   ac_status=$?
17432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17433   (exit $ac_status); }; } &&
17434          { ac_try='test -s conftest.$ac_objext'
17435   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17436   (eval $ac_try) 2>&5
17437   ac_status=$?
17438   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17439   (exit $ac_status); }; }; then
17440   pgac_cv_type_long_long_int_64=yes
17441 else
17442   echo "$as_me: failed program was:" >&5
17443 sed 's/^/| /' conftest.$ac_ext >&5
17444
17445 pgac_cv_type_long_long_int_64=no
17446 fi
17447 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17448 else
17449   cat >conftest.$ac_ext <<_ACEOF
17450 /* confdefs.h.  */
17451 _ACEOF
17452 cat confdefs.h >>conftest.$ac_ext
17453 cat >>conftest.$ac_ext <<_ACEOF
17454 /* end confdefs.h.  */
17455 typedef long long int ac_int64;
17456
17457 /*
17458  * These are globals to discourage the compiler from folding all the
17459  * arithmetic tests down to compile-time constants.
17460  */
17461 ac_int64 a = 20000001;
17462 ac_int64 b = 40000005;
17463
17464 int does_int64_work()
17465 {
17466   ac_int64 c,d;
17467
17468   if (sizeof(ac_int64) != 8)
17469     return 0;                   /* definitely not the right size */
17470
17471   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
17472   c = a * b;
17473   d = (c + b) / b;
17474   if (d != a+1)
17475     return 0;
17476   return 1;
17477 }
17478 main() {
17479   exit(! does_int64_work());
17480 }
17481 _ACEOF
17482 rm -f conftest$ac_exeext
17483 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17484   (eval $ac_link) 2>&5
17485   ac_status=$?
17486   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17487   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17488   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17489   (eval $ac_try) 2>&5
17490   ac_status=$?
17491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17492   (exit $ac_status); }; }; then
17493   pgac_cv_type_long_long_int_64=yes
17494 else
17495   echo "$as_me: program exited with status $ac_status" >&5
17496 echo "$as_me: failed program was:" >&5
17497 sed 's/^/| /' conftest.$ac_ext >&5
17498
17499 ( exit $ac_status )
17500 pgac_cv_type_long_long_int_64=no
17501 fi
17502 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17503 fi
17504 fi
17505 echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
17506 echo "${ECHO_T}$pgac_cv_type_long_long_int_64" >&6
17507
17508 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
17509 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
17510
17511 cat >>confdefs.h <<\_ACEOF
17512 #define HAVE_LONG_LONG_INT_64
17513 _ACEOF
17514
17515 fi
17516
17517 fi
17518
17519
17520
17521 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
17522   cat >conftest.$ac_ext <<_ACEOF
17523 /* confdefs.h.  */
17524 _ACEOF
17525 cat confdefs.h >>conftest.$ac_ext
17526 cat >>conftest.$ac_ext <<_ACEOF
17527 /* end confdefs.h.  */
17528
17529 #define INT64CONST(x)  x##LL
17530 long long int foo = INT64CONST(0x1234567890123456);
17531
17532 int
17533 main ()
17534 {
17535
17536   ;
17537   return 0;
17538 }
17539 _ACEOF
17540 rm -f conftest.$ac_objext
17541 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17542   (eval $ac_compile) 2>conftest.er1
17543   ac_status=$?
17544   grep -v '^ *+' conftest.er1 >conftest.err
17545   rm -f conftest.er1
17546   cat conftest.err >&5
17547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17548   (exit $ac_status); } &&
17549          { ac_try='test -z "$ac_c_werror_flag"
17550                          || test ! -s conftest.err'
17551   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17552   (eval $ac_try) 2>&5
17553   ac_status=$?
17554   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17555   (exit $ac_status); }; } &&
17556          { ac_try='test -s conftest.$ac_objext'
17557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17558   (eval $ac_try) 2>&5
17559   ac_status=$?
17560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17561   (exit $ac_status); }; }; then
17562
17563 cat >>confdefs.h <<\_ACEOF
17564 #define HAVE_LL_CONSTANTS 1
17565 _ACEOF
17566
17567 else
17568   echo "$as_me: failed program was:" >&5
17569 sed 's/^/| /' conftest.$ac_ext >&5
17570
17571 fi
17572 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17573 fi
17574
17575
17576 # If we found "long int" is 64 bits, assume snprintf handles it.  If
17577 # we found we need to use "long long int", better check.  We cope with
17578 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
17579 # work, fall back to our own snprintf emulation (which we know uses %lld).
17580
17581 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
17582   if test $pgac_need_repl_snprintf = no; then
17583     echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
17584 echo $ECHO_N "checking snprintf format for long long int... $ECHO_C" >&6
17585 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
17586   echo $ECHO_N "(cached) $ECHO_C" >&6
17587 else
17588   for pgac_format in '%lld' '%qd' '%I64d'; do
17589 if test "$cross_compiling" = yes; then
17590   pgac_cv_snprintf_long_long_int_format=cross; break
17591 else
17592   cat >conftest.$ac_ext <<_ACEOF
17593 /* confdefs.h.  */
17594 _ACEOF
17595 cat confdefs.h >>conftest.$ac_ext
17596 cat >>conftest.$ac_ext <<_ACEOF
17597 /* end confdefs.h.  */
17598 #include <stdio.h>
17599 typedef long long int ac_int64;
17600 #define INT64_FORMAT "$pgac_format"
17601
17602 ac_int64 a = 20000001;
17603 ac_int64 b = 40000005;
17604
17605 int does_int64_snprintf_work()
17606 {
17607   ac_int64 c;
17608   char buf[100];
17609
17610   if (sizeof(ac_int64) != 8)
17611     return 0;                   /* doesn't look like the right size */
17612
17613   c = a * b;
17614   snprintf(buf, 100, INT64_FORMAT, c);
17615   if (strcmp(buf, "800000140000005") != 0)
17616     return 0;                   /* either multiply or snprintf is busted */
17617   return 1;
17618 }
17619 main() {
17620   exit(! does_int64_snprintf_work());
17621 }
17622 _ACEOF
17623 rm -f conftest$ac_exeext
17624 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17625   (eval $ac_link) 2>&5
17626   ac_status=$?
17627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17628   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17629   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17630   (eval $ac_try) 2>&5
17631   ac_status=$?
17632   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17633   (exit $ac_status); }; }; then
17634   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
17635 else
17636   echo "$as_me: program exited with status $ac_status" >&5
17637 echo "$as_me: failed program was:" >&5
17638 sed 's/^/| /' conftest.$ac_ext >&5
17639
17640 fi
17641 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17642 fi
17643 done
17644 fi
17645
17646 LONG_LONG_INT_FORMAT=''
17647
17648 case $pgac_cv_snprintf_long_long_int_format in
17649   cross) echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
17650 echo "${ECHO_T}cannot test (not on host machine)" >&6;;
17651   ?*)    echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
17652 echo "${ECHO_T}$pgac_cv_snprintf_long_long_int_format" >&6
17653          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
17654   *)     echo "$as_me:$LINENO: result: none" >&5
17655 echo "${ECHO_T}none" >&6;;
17656 esac
17657     if test "$LONG_LONG_INT_FORMAT" = ""; then
17658       # Force usage of our own snprintf, since system snprintf is broken
17659       pgac_need_repl_snprintf=yes
17660       LONG_LONG_INT_FORMAT='%lld'
17661     fi
17662   else
17663     # Here if we previously decided we needed to use our own snprintf
17664     LONG_LONG_INT_FORMAT='%lld'
17665   fi
17666   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
17667   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
17668   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
17669 else
17670   # Here if we are not using 'long long int' at all
17671   INT64_FORMAT='"%ld"'
17672   UINT64_FORMAT='"%lu"'
17673 fi
17674
17675
17676 cat >>confdefs.h <<_ACEOF
17677 #define INT64_FORMAT $INT64_FORMAT
17678 _ACEOF
17679
17680
17681
17682 cat >>confdefs.h <<_ACEOF
17683 #define UINT64_FORMAT $UINT64_FORMAT
17684 _ACEOF
17685
17686
17687 # Now we have checked all the reasons to replace snprintf
17688 if test $pgac_need_repl_snprintf = yes; then
17689
17690 cat >>confdefs.h <<\_ACEOF
17691 #define USE_REPL_SNPRINTF 1
17692 _ACEOF
17693
17694   case $LIBOBJS in
17695     "snprintf.$ac_objext"   | \
17696   *" snprintf.$ac_objext"   | \
17697     "snprintf.$ac_objext "* | \
17698   *" snprintf.$ac_objext "* ) ;;
17699   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" ;;
17700 esac
17701
17702 fi
17703
17704 # Need a #define for the size of Datum (unsigned long)
17705 echo "$as_me:$LINENO: checking for unsigned long" >&5
17706 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6
17707 if test "${ac_cv_type_unsigned_long+set}" = set; then
17708   echo $ECHO_N "(cached) $ECHO_C" >&6
17709 else
17710   cat >conftest.$ac_ext <<_ACEOF
17711 /* confdefs.h.  */
17712 _ACEOF
17713 cat confdefs.h >>conftest.$ac_ext
17714 cat >>conftest.$ac_ext <<_ACEOF
17715 /* end confdefs.h.  */
17716 $ac_includes_default
17717 int
17718 main ()
17719 {
17720 if ((unsigned long *) 0)
17721   return 0;
17722 if (sizeof (unsigned long))
17723   return 0;
17724   ;
17725   return 0;
17726 }
17727 _ACEOF
17728 rm -f conftest.$ac_objext
17729 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17730   (eval $ac_compile) 2>conftest.er1
17731   ac_status=$?
17732   grep -v '^ *+' conftest.er1 >conftest.err
17733   rm -f conftest.er1
17734   cat conftest.err >&5
17735   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17736   (exit $ac_status); } &&
17737          { ac_try='test -z "$ac_c_werror_flag"
17738                          || test ! -s conftest.err'
17739   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17740   (eval $ac_try) 2>&5
17741   ac_status=$?
17742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17743   (exit $ac_status); }; } &&
17744          { ac_try='test -s conftest.$ac_objext'
17745   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17746   (eval $ac_try) 2>&5
17747   ac_status=$?
17748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17749   (exit $ac_status); }; }; then
17750   ac_cv_type_unsigned_long=yes
17751 else
17752   echo "$as_me: failed program was:" >&5
17753 sed 's/^/| /' conftest.$ac_ext >&5
17754
17755 ac_cv_type_unsigned_long=no
17756 fi
17757 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17758 fi
17759 echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
17760 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6
17761
17762 echo "$as_me:$LINENO: checking size of unsigned long" >&5
17763 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6
17764 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
17765   echo $ECHO_N "(cached) $ECHO_C" >&6
17766 else
17767   if test "$ac_cv_type_unsigned_long" = yes; then
17768   # The cast to unsigned long works around a bug in the HP C Compiler
17769   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17770   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
17771   # This bug is HP SR number 8606223364.
17772   if test "$cross_compiling" = yes; then
17773   # Depending upon the size, compute the lo and hi bounds.
17774 cat >conftest.$ac_ext <<_ACEOF
17775 /* confdefs.h.  */
17776 _ACEOF
17777 cat confdefs.h >>conftest.$ac_ext
17778 cat >>conftest.$ac_ext <<_ACEOF
17779 /* end confdefs.h.  */
17780 $ac_includes_default
17781 int
17782 main ()
17783 {
17784 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= 0)];
17785 test_array [0] = 0
17786
17787   ;
17788   return 0;
17789 }
17790 _ACEOF
17791 rm -f conftest.$ac_objext
17792 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17793   (eval $ac_compile) 2>conftest.er1
17794   ac_status=$?
17795   grep -v '^ *+' conftest.er1 >conftest.err
17796   rm -f conftest.er1
17797   cat conftest.err >&5
17798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17799   (exit $ac_status); } &&
17800          { ac_try='test -z "$ac_c_werror_flag"
17801                          || test ! -s conftest.err'
17802   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17803   (eval $ac_try) 2>&5
17804   ac_status=$?
17805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17806   (exit $ac_status); }; } &&
17807          { ac_try='test -s conftest.$ac_objext'
17808   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17809   (eval $ac_try) 2>&5
17810   ac_status=$?
17811   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17812   (exit $ac_status); }; }; then
17813   ac_lo=0 ac_mid=0
17814   while :; do
17815     cat >conftest.$ac_ext <<_ACEOF
17816 /* confdefs.h.  */
17817 _ACEOF
17818 cat confdefs.h >>conftest.$ac_ext
17819 cat >>conftest.$ac_ext <<_ACEOF
17820 /* end confdefs.h.  */
17821 $ac_includes_default
17822 int
17823 main ()
17824 {
17825 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
17826 test_array [0] = 0
17827
17828   ;
17829   return 0;
17830 }
17831 _ACEOF
17832 rm -f conftest.$ac_objext
17833 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17834   (eval $ac_compile) 2>conftest.er1
17835   ac_status=$?
17836   grep -v '^ *+' conftest.er1 >conftest.err
17837   rm -f conftest.er1
17838   cat conftest.err >&5
17839   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17840   (exit $ac_status); } &&
17841          { ac_try='test -z "$ac_c_werror_flag"
17842                          || test ! -s conftest.err'
17843   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17844   (eval $ac_try) 2>&5
17845   ac_status=$?
17846   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17847   (exit $ac_status); }; } &&
17848          { ac_try='test -s conftest.$ac_objext'
17849   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17850   (eval $ac_try) 2>&5
17851   ac_status=$?
17852   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17853   (exit $ac_status); }; }; then
17854   ac_hi=$ac_mid; break
17855 else
17856   echo "$as_me: failed program was:" >&5
17857 sed 's/^/| /' conftest.$ac_ext >&5
17858
17859 ac_lo=`expr $ac_mid + 1`
17860                     if test $ac_lo -le $ac_mid; then
17861                       ac_lo= ac_hi=
17862                       break
17863                     fi
17864                     ac_mid=`expr 2 '*' $ac_mid + 1`
17865 fi
17866 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17867   done
17868 else
17869   echo "$as_me: failed program was:" >&5
17870 sed 's/^/| /' conftest.$ac_ext >&5
17871
17872 cat >conftest.$ac_ext <<_ACEOF
17873 /* confdefs.h.  */
17874 _ACEOF
17875 cat confdefs.h >>conftest.$ac_ext
17876 cat >>conftest.$ac_ext <<_ACEOF
17877 /* end confdefs.h.  */
17878 $ac_includes_default
17879 int
17880 main ()
17881 {
17882 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) < 0)];
17883 test_array [0] = 0
17884
17885   ;
17886   return 0;
17887 }
17888 _ACEOF
17889 rm -f conftest.$ac_objext
17890 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17891   (eval $ac_compile) 2>conftest.er1
17892   ac_status=$?
17893   grep -v '^ *+' conftest.er1 >conftest.err
17894   rm -f conftest.er1
17895   cat conftest.err >&5
17896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17897   (exit $ac_status); } &&
17898          { ac_try='test -z "$ac_c_werror_flag"
17899                          || test ! -s conftest.err'
17900   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17901   (eval $ac_try) 2>&5
17902   ac_status=$?
17903   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17904   (exit $ac_status); }; } &&
17905          { ac_try='test -s conftest.$ac_objext'
17906   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17907   (eval $ac_try) 2>&5
17908   ac_status=$?
17909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17910   (exit $ac_status); }; }; then
17911   ac_hi=-1 ac_mid=-1
17912   while :; do
17913     cat >conftest.$ac_ext <<_ACEOF
17914 /* confdefs.h.  */
17915 _ACEOF
17916 cat confdefs.h >>conftest.$ac_ext
17917 cat >>conftest.$ac_ext <<_ACEOF
17918 /* end confdefs.h.  */
17919 $ac_includes_default
17920 int
17921 main ()
17922 {
17923 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= $ac_mid)];
17924 test_array [0] = 0
17925
17926   ;
17927   return 0;
17928 }
17929 _ACEOF
17930 rm -f conftest.$ac_objext
17931 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17932   (eval $ac_compile) 2>conftest.er1
17933   ac_status=$?
17934   grep -v '^ *+' conftest.er1 >conftest.err
17935   rm -f conftest.er1
17936   cat conftest.err >&5
17937   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17938   (exit $ac_status); } &&
17939          { ac_try='test -z "$ac_c_werror_flag"
17940                          || test ! -s conftest.err'
17941   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17942   (eval $ac_try) 2>&5
17943   ac_status=$?
17944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17945   (exit $ac_status); }; } &&
17946          { ac_try='test -s conftest.$ac_objext'
17947   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17948   (eval $ac_try) 2>&5
17949   ac_status=$?
17950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17951   (exit $ac_status); }; }; then
17952   ac_lo=$ac_mid; break
17953 else
17954   echo "$as_me: failed program was:" >&5
17955 sed 's/^/| /' conftest.$ac_ext >&5
17956
17957 ac_hi=`expr '(' $ac_mid ')' - 1`
17958                        if test $ac_mid -le $ac_hi; then
17959                          ac_lo= ac_hi=
17960                          break
17961                        fi
17962                        ac_mid=`expr 2 '*' $ac_mid`
17963 fi
17964 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17965   done
17966 else
17967   echo "$as_me: failed program was:" >&5
17968 sed 's/^/| /' conftest.$ac_ext >&5
17969
17970 ac_lo= ac_hi=
17971 fi
17972 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17973 fi
17974 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17975 # Binary search between lo and hi bounds.
17976 while test "x$ac_lo" != "x$ac_hi"; do
17977   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
17978   cat >conftest.$ac_ext <<_ACEOF
17979 /* confdefs.h.  */
17980 _ACEOF
17981 cat confdefs.h >>conftest.$ac_ext
17982 cat >>conftest.$ac_ext <<_ACEOF
17983 /* end confdefs.h.  */
17984 $ac_includes_default
17985 int
17986 main ()
17987 {
17988 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
17989 test_array [0] = 0
17990
17991   ;
17992   return 0;
17993 }
17994 _ACEOF
17995 rm -f conftest.$ac_objext
17996 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17997   (eval $ac_compile) 2>conftest.er1
17998   ac_status=$?
17999   grep -v '^ *+' conftest.er1 >conftest.err
18000   rm -f conftest.er1
18001   cat conftest.err >&5
18002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18003   (exit $ac_status); } &&
18004          { ac_try='test -z "$ac_c_werror_flag"
18005                          || test ! -s conftest.err'
18006   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18007   (eval $ac_try) 2>&5
18008   ac_status=$?
18009   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18010   (exit $ac_status); }; } &&
18011          { ac_try='test -s conftest.$ac_objext'
18012   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18013   (eval $ac_try) 2>&5
18014   ac_status=$?
18015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18016   (exit $ac_status); }; }; then
18017   ac_hi=$ac_mid
18018 else
18019   echo "$as_me: failed program was:" >&5
18020 sed 's/^/| /' conftest.$ac_ext >&5
18021
18022 ac_lo=`expr '(' $ac_mid ')' + 1`
18023 fi
18024 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18025 done
18026 case $ac_lo in
18027 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
18028 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77
18029 See \`config.log' for more details." >&5
18030 echo "$as_me: error: cannot compute sizeof (unsigned long), 77
18031 See \`config.log' for more details." >&2;}
18032    { (exit 1); exit 1; }; } ;;
18033 esac
18034 else
18035   if test "$cross_compiling" = yes; then
18036   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18037 See \`config.log' for more details." >&5
18038 echo "$as_me: error: cannot run test program while cross compiling
18039 See \`config.log' for more details." >&2;}
18040    { (exit 1); exit 1; }; }
18041 else
18042   cat >conftest.$ac_ext <<_ACEOF
18043 /* confdefs.h.  */
18044 _ACEOF
18045 cat confdefs.h >>conftest.$ac_ext
18046 cat >>conftest.$ac_ext <<_ACEOF
18047 /* end confdefs.h.  */
18048 $ac_includes_default
18049 long longval () { return (long) (sizeof (unsigned long)); }
18050 unsigned long ulongval () { return (long) (sizeof (unsigned long)); }
18051 #include <stdio.h>
18052 #include <stdlib.h>
18053 int
18054 main ()
18055 {
18056
18057   FILE *f = fopen ("conftest.val", "w");
18058   if (! f)
18059     exit (1);
18060   if (((long) (sizeof (unsigned long))) < 0)
18061     {
18062       long i = longval ();
18063       if (i != ((long) (sizeof (unsigned long))))
18064         exit (1);
18065       fprintf (f, "%ld\n", i);
18066     }
18067   else
18068     {
18069       unsigned long i = ulongval ();
18070       if (i != ((long) (sizeof (unsigned long))))
18071         exit (1);
18072       fprintf (f, "%lu\n", i);
18073     }
18074   exit (ferror (f) || fclose (f) != 0);
18075
18076   ;
18077   return 0;
18078 }
18079 _ACEOF
18080 rm -f conftest$ac_exeext
18081 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18082   (eval $ac_link) 2>&5
18083   ac_status=$?
18084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18085   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18086   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18087   (eval $ac_try) 2>&5
18088   ac_status=$?
18089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18090   (exit $ac_status); }; }; then
18091   ac_cv_sizeof_unsigned_long=`cat conftest.val`
18092 else
18093   echo "$as_me: program exited with status $ac_status" >&5
18094 echo "$as_me: failed program was:" >&5
18095 sed 's/^/| /' conftest.$ac_ext >&5
18096
18097 ( exit $ac_status )
18098 { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77
18099 See \`config.log' for more details." >&5
18100 echo "$as_me: error: cannot compute sizeof (unsigned long), 77
18101 See \`config.log' for more details." >&2;}
18102    { (exit 1); exit 1; }; }
18103 fi
18104 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18105 fi
18106 fi
18107 rm -f conftest.val
18108 else
18109   ac_cv_sizeof_unsigned_long=0
18110 fi
18111 fi
18112 echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
18113 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6
18114 cat >>confdefs.h <<_ACEOF
18115 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
18116 _ACEOF
18117
18118
18119
18120 # And one for the size of size_t (enables tweaks for > 32bit address space)
18121 echo "$as_me:$LINENO: checking for size_t" >&5
18122 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
18123 if test "${ac_cv_type_size_t+set}" = set; then
18124   echo $ECHO_N "(cached) $ECHO_C" >&6
18125 else
18126   cat >conftest.$ac_ext <<_ACEOF
18127 /* confdefs.h.  */
18128 _ACEOF
18129 cat confdefs.h >>conftest.$ac_ext
18130 cat >>conftest.$ac_ext <<_ACEOF
18131 /* end confdefs.h.  */
18132 $ac_includes_default
18133 int
18134 main ()
18135 {
18136 if ((size_t *) 0)
18137   return 0;
18138 if (sizeof (size_t))
18139   return 0;
18140   ;
18141   return 0;
18142 }
18143 _ACEOF
18144 rm -f conftest.$ac_objext
18145 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18146   (eval $ac_compile) 2>conftest.er1
18147   ac_status=$?
18148   grep -v '^ *+' conftest.er1 >conftest.err
18149   rm -f conftest.er1
18150   cat conftest.err >&5
18151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18152   (exit $ac_status); } &&
18153          { ac_try='test -z "$ac_c_werror_flag"
18154                          || test ! -s conftest.err'
18155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18156   (eval $ac_try) 2>&5
18157   ac_status=$?
18158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18159   (exit $ac_status); }; } &&
18160          { ac_try='test -s conftest.$ac_objext'
18161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18162   (eval $ac_try) 2>&5
18163   ac_status=$?
18164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18165   (exit $ac_status); }; }; then
18166   ac_cv_type_size_t=yes
18167 else
18168   echo "$as_me: failed program was:" >&5
18169 sed 's/^/| /' conftest.$ac_ext >&5
18170
18171 ac_cv_type_size_t=no
18172 fi
18173 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18174 fi
18175 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
18176 echo "${ECHO_T}$ac_cv_type_size_t" >&6
18177
18178 echo "$as_me:$LINENO: checking size of size_t" >&5
18179 echo $ECHO_N "checking size of size_t... $ECHO_C" >&6
18180 if test "${ac_cv_sizeof_size_t+set}" = set; then
18181   echo $ECHO_N "(cached) $ECHO_C" >&6
18182 else
18183   if test "$ac_cv_type_size_t" = yes; then
18184   # The cast to unsigned long works around a bug in the HP C Compiler
18185   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18186   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18187   # This bug is HP SR number 8606223364.
18188   if test "$cross_compiling" = yes; then
18189   # Depending upon the size, compute the lo and hi bounds.
18190 cat >conftest.$ac_ext <<_ACEOF
18191 /* confdefs.h.  */
18192 _ACEOF
18193 cat confdefs.h >>conftest.$ac_ext
18194 cat >>conftest.$ac_ext <<_ACEOF
18195 /* end confdefs.h.  */
18196 $ac_includes_default
18197 int
18198 main ()
18199 {
18200 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) >= 0)];
18201 test_array [0] = 0
18202
18203   ;
18204   return 0;
18205 }
18206 _ACEOF
18207 rm -f conftest.$ac_objext
18208 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18209   (eval $ac_compile) 2>conftest.er1
18210   ac_status=$?
18211   grep -v '^ *+' conftest.er1 >conftest.err
18212   rm -f conftest.er1
18213   cat conftest.err >&5
18214   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18215   (exit $ac_status); } &&
18216          { ac_try='test -z "$ac_c_werror_flag"
18217                          || test ! -s conftest.err'
18218   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18219   (eval $ac_try) 2>&5
18220   ac_status=$?
18221   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18222   (exit $ac_status); }; } &&
18223          { ac_try='test -s conftest.$ac_objext'
18224   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18225   (eval $ac_try) 2>&5
18226   ac_status=$?
18227   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18228   (exit $ac_status); }; }; then
18229   ac_lo=0 ac_mid=0
18230   while :; do
18231     cat >conftest.$ac_ext <<_ACEOF
18232 /* confdefs.h.  */
18233 _ACEOF
18234 cat confdefs.h >>conftest.$ac_ext
18235 cat >>conftest.$ac_ext <<_ACEOF
18236 /* end confdefs.h.  */
18237 $ac_includes_default
18238 int
18239 main ()
18240 {
18241 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) <= $ac_mid)];
18242 test_array [0] = 0
18243
18244   ;
18245   return 0;
18246 }
18247 _ACEOF
18248 rm -f conftest.$ac_objext
18249 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18250   (eval $ac_compile) 2>conftest.er1
18251   ac_status=$?
18252   grep -v '^ *+' conftest.er1 >conftest.err
18253   rm -f conftest.er1
18254   cat conftest.err >&5
18255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18256   (exit $ac_status); } &&
18257          { ac_try='test -z "$ac_c_werror_flag"
18258                          || test ! -s conftest.err'
18259   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18260   (eval $ac_try) 2>&5
18261   ac_status=$?
18262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18263   (exit $ac_status); }; } &&
18264          { ac_try='test -s conftest.$ac_objext'
18265   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18266   (eval $ac_try) 2>&5
18267   ac_status=$?
18268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18269   (exit $ac_status); }; }; then
18270   ac_hi=$ac_mid; break
18271 else
18272   echo "$as_me: failed program was:" >&5
18273 sed 's/^/| /' conftest.$ac_ext >&5
18274
18275 ac_lo=`expr $ac_mid + 1`
18276                     if test $ac_lo -le $ac_mid; then
18277                       ac_lo= ac_hi=
18278                       break
18279                     fi
18280                     ac_mid=`expr 2 '*' $ac_mid + 1`
18281 fi
18282 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18283   done
18284 else
18285   echo "$as_me: failed program was:" >&5
18286 sed 's/^/| /' conftest.$ac_ext >&5
18287
18288 cat >conftest.$ac_ext <<_ACEOF
18289 /* confdefs.h.  */
18290 _ACEOF
18291 cat confdefs.h >>conftest.$ac_ext
18292 cat >>conftest.$ac_ext <<_ACEOF
18293 /* end confdefs.h.  */
18294 $ac_includes_default
18295 int
18296 main ()
18297 {
18298 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) < 0)];
18299 test_array [0] = 0
18300
18301   ;
18302   return 0;
18303 }
18304 _ACEOF
18305 rm -f conftest.$ac_objext
18306 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18307   (eval $ac_compile) 2>conftest.er1
18308   ac_status=$?
18309   grep -v '^ *+' conftest.er1 >conftest.err
18310   rm -f conftest.er1
18311   cat conftest.err >&5
18312   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18313   (exit $ac_status); } &&
18314          { ac_try='test -z "$ac_c_werror_flag"
18315                          || test ! -s conftest.err'
18316   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18317   (eval $ac_try) 2>&5
18318   ac_status=$?
18319   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18320   (exit $ac_status); }; } &&
18321          { ac_try='test -s conftest.$ac_objext'
18322   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18323   (eval $ac_try) 2>&5
18324   ac_status=$?
18325   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18326   (exit $ac_status); }; }; then
18327   ac_hi=-1 ac_mid=-1
18328   while :; do
18329     cat >conftest.$ac_ext <<_ACEOF
18330 /* confdefs.h.  */
18331 _ACEOF
18332 cat confdefs.h >>conftest.$ac_ext
18333 cat >>conftest.$ac_ext <<_ACEOF
18334 /* end confdefs.h.  */
18335 $ac_includes_default
18336 int
18337 main ()
18338 {
18339 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) >= $ac_mid)];
18340 test_array [0] = 0
18341
18342   ;
18343   return 0;
18344 }
18345 _ACEOF
18346 rm -f conftest.$ac_objext
18347 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18348   (eval $ac_compile) 2>conftest.er1
18349   ac_status=$?
18350   grep -v '^ *+' conftest.er1 >conftest.err
18351   rm -f conftest.er1
18352   cat conftest.err >&5
18353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18354   (exit $ac_status); } &&
18355          { ac_try='test -z "$ac_c_werror_flag"
18356                          || test ! -s conftest.err'
18357   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18358   (eval $ac_try) 2>&5
18359   ac_status=$?
18360   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18361   (exit $ac_status); }; } &&
18362          { ac_try='test -s conftest.$ac_objext'
18363   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18364   (eval $ac_try) 2>&5
18365   ac_status=$?
18366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18367   (exit $ac_status); }; }; then
18368   ac_lo=$ac_mid; break
18369 else
18370   echo "$as_me: failed program was:" >&5
18371 sed 's/^/| /' conftest.$ac_ext >&5
18372
18373 ac_hi=`expr '(' $ac_mid ')' - 1`
18374                        if test $ac_mid -le $ac_hi; then
18375                          ac_lo= ac_hi=
18376                          break
18377                        fi
18378                        ac_mid=`expr 2 '*' $ac_mid`
18379 fi
18380 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18381   done
18382 else
18383   echo "$as_me: failed program was:" >&5
18384 sed 's/^/| /' conftest.$ac_ext >&5
18385
18386 ac_lo= ac_hi=
18387 fi
18388 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18389 fi
18390 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18391 # Binary search between lo and hi bounds.
18392 while test "x$ac_lo" != "x$ac_hi"; do
18393   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18394   cat >conftest.$ac_ext <<_ACEOF
18395 /* confdefs.h.  */
18396 _ACEOF
18397 cat confdefs.h >>conftest.$ac_ext
18398 cat >>conftest.$ac_ext <<_ACEOF
18399 /* end confdefs.h.  */
18400 $ac_includes_default
18401 int
18402 main ()
18403 {
18404 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) <= $ac_mid)];
18405 test_array [0] = 0
18406
18407   ;
18408   return 0;
18409 }
18410 _ACEOF
18411 rm -f conftest.$ac_objext
18412 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18413   (eval $ac_compile) 2>conftest.er1
18414   ac_status=$?
18415   grep -v '^ *+' conftest.er1 >conftest.err
18416   rm -f conftest.er1
18417   cat conftest.err >&5
18418   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18419   (exit $ac_status); } &&
18420          { ac_try='test -z "$ac_c_werror_flag"
18421                          || test ! -s conftest.err'
18422   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18423   (eval $ac_try) 2>&5
18424   ac_status=$?
18425   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18426   (exit $ac_status); }; } &&
18427          { ac_try='test -s conftest.$ac_objext'
18428   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18429   (eval $ac_try) 2>&5
18430   ac_status=$?
18431   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18432   (exit $ac_status); }; }; then
18433   ac_hi=$ac_mid
18434 else
18435   echo "$as_me: failed program was:" >&5
18436 sed 's/^/| /' conftest.$ac_ext >&5
18437
18438 ac_lo=`expr '(' $ac_mid ')' + 1`
18439 fi
18440 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18441 done
18442 case $ac_lo in
18443 ?*) ac_cv_sizeof_size_t=$ac_lo;;
18444 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t), 77
18445 See \`config.log' for more details." >&5
18446 echo "$as_me: error: cannot compute sizeof (size_t), 77
18447 See \`config.log' for more details." >&2;}
18448    { (exit 1); exit 1; }; } ;;
18449 esac
18450 else
18451   if test "$cross_compiling" = yes; then
18452   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18453 See \`config.log' for more details." >&5
18454 echo "$as_me: error: cannot run test program while cross compiling
18455 See \`config.log' for more details." >&2;}
18456    { (exit 1); exit 1; }; }
18457 else
18458   cat >conftest.$ac_ext <<_ACEOF
18459 /* confdefs.h.  */
18460 _ACEOF
18461 cat confdefs.h >>conftest.$ac_ext
18462 cat >>conftest.$ac_ext <<_ACEOF
18463 /* end confdefs.h.  */
18464 $ac_includes_default
18465 long longval () { return (long) (sizeof (size_t)); }
18466 unsigned long ulongval () { return (long) (sizeof (size_t)); }
18467 #include <stdio.h>
18468 #include <stdlib.h>
18469 int
18470 main ()
18471 {
18472
18473   FILE *f = fopen ("conftest.val", "w");
18474   if (! f)
18475     exit (1);
18476   if (((long) (sizeof (size_t))) < 0)
18477     {
18478       long i = longval ();
18479       if (i != ((long) (sizeof (size_t))))
18480         exit (1);
18481       fprintf (f, "%ld\n", i);
18482     }
18483   else
18484     {
18485       unsigned long i = ulongval ();
18486       if (i != ((long) (sizeof (size_t))))
18487         exit (1);
18488       fprintf (f, "%lu\n", i);
18489     }
18490   exit (ferror (f) || fclose (f) != 0);
18491
18492   ;
18493   return 0;
18494 }
18495 _ACEOF
18496 rm -f conftest$ac_exeext
18497 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18498   (eval $ac_link) 2>&5
18499   ac_status=$?
18500   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18501   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18502   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18503   (eval $ac_try) 2>&5
18504   ac_status=$?
18505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18506   (exit $ac_status); }; }; then
18507   ac_cv_sizeof_size_t=`cat conftest.val`
18508 else
18509   echo "$as_me: program exited with status $ac_status" >&5
18510 echo "$as_me: failed program was:" >&5
18511 sed 's/^/| /' conftest.$ac_ext >&5
18512
18513 ( exit $ac_status )
18514 { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t), 77
18515 See \`config.log' for more details." >&5
18516 echo "$as_me: error: cannot compute sizeof (size_t), 77
18517 See \`config.log' for more details." >&2;}
18518    { (exit 1); exit 1; }; }
18519 fi
18520 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18521 fi
18522 fi
18523 rm -f conftest.val
18524 else
18525   ac_cv_sizeof_size_t=0
18526 fi
18527 fi
18528 echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
18529 echo "${ECHO_T}$ac_cv_sizeof_size_t" >&6
18530 cat >>confdefs.h <<_ACEOF
18531 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
18532 _ACEOF
18533
18534
18535
18536 # Determine memory alignment requirements for the basic C data types.
18537
18538 echo "$as_me:$LINENO: checking for short" >&5
18539 echo $ECHO_N "checking for short... $ECHO_C" >&6
18540 if test "${ac_cv_type_short+set}" = set; then
18541   echo $ECHO_N "(cached) $ECHO_C" >&6
18542 else
18543   cat >conftest.$ac_ext <<_ACEOF
18544 /* confdefs.h.  */
18545 _ACEOF
18546 cat confdefs.h >>conftest.$ac_ext
18547 cat >>conftest.$ac_ext <<_ACEOF
18548 /* end confdefs.h.  */
18549 $ac_includes_default
18550 int
18551 main ()
18552 {
18553 if ((short *) 0)
18554   return 0;
18555 if (sizeof (short))
18556   return 0;
18557   ;
18558   return 0;
18559 }
18560 _ACEOF
18561 rm -f conftest.$ac_objext
18562 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18563   (eval $ac_compile) 2>conftest.er1
18564   ac_status=$?
18565   grep -v '^ *+' conftest.er1 >conftest.err
18566   rm -f conftest.er1
18567   cat conftest.err >&5
18568   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18569   (exit $ac_status); } &&
18570          { ac_try='test -z "$ac_c_werror_flag"
18571                          || test ! -s conftest.err'
18572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18573   (eval $ac_try) 2>&5
18574   ac_status=$?
18575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18576   (exit $ac_status); }; } &&
18577          { ac_try='test -s conftest.$ac_objext'
18578   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18579   (eval $ac_try) 2>&5
18580   ac_status=$?
18581   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18582   (exit $ac_status); }; }; then
18583   ac_cv_type_short=yes
18584 else
18585   echo "$as_me: failed program was:" >&5
18586 sed 's/^/| /' conftest.$ac_ext >&5
18587
18588 ac_cv_type_short=no
18589 fi
18590 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18591 fi
18592 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
18593 echo "${ECHO_T}$ac_cv_type_short" >&6
18594
18595 echo "$as_me:$LINENO: checking alignment of short" >&5
18596 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6
18597 if test "${pgac_cv_alignof_short+set}" = set; then
18598   echo $ECHO_N "(cached) $ECHO_C" >&6
18599 else
18600   if test "$ac_cv_type_short" = yes; then
18601   if test "$cross_compiling" = yes; then
18602   # Depending upon the size, compute the lo and hi bounds.
18603 cat >conftest.$ac_ext <<_ACEOF
18604 /* confdefs.h.  */
18605 _ACEOF
18606 cat confdefs.h >>conftest.$ac_ext
18607 cat >>conftest.$ac_ext <<_ACEOF
18608 /* end confdefs.h.  */
18609 $ac_includes_default
18610 struct { char filler; short field; } pgac_struct;
18611 int
18612 main ()
18613 {
18614 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
18615 test_array [0] = 0
18616
18617   ;
18618   return 0;
18619 }
18620 _ACEOF
18621 rm -f conftest.$ac_objext
18622 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18623   (eval $ac_compile) 2>conftest.er1
18624   ac_status=$?
18625   grep -v '^ *+' conftest.er1 >conftest.err
18626   rm -f conftest.er1
18627   cat conftest.err >&5
18628   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18629   (exit $ac_status); } &&
18630          { ac_try='test -z "$ac_c_werror_flag"
18631                          || test ! -s conftest.err'
18632   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18633   (eval $ac_try) 2>&5
18634   ac_status=$?
18635   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18636   (exit $ac_status); }; } &&
18637          { ac_try='test -s conftest.$ac_objext'
18638   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18639   (eval $ac_try) 2>&5
18640   ac_status=$?
18641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18642   (exit $ac_status); }; }; then
18643   ac_lo=0 ac_mid=0
18644   while :; do
18645     cat >conftest.$ac_ext <<_ACEOF
18646 /* confdefs.h.  */
18647 _ACEOF
18648 cat confdefs.h >>conftest.$ac_ext
18649 cat >>conftest.$ac_ext <<_ACEOF
18650 /* end confdefs.h.  */
18651 $ac_includes_default
18652 struct { char filler; short field; } pgac_struct;
18653 int
18654 main ()
18655 {
18656 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18657 test_array [0] = 0
18658
18659   ;
18660   return 0;
18661 }
18662 _ACEOF
18663 rm -f conftest.$ac_objext
18664 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18665   (eval $ac_compile) 2>conftest.er1
18666   ac_status=$?
18667   grep -v '^ *+' conftest.er1 >conftest.err
18668   rm -f conftest.er1
18669   cat conftest.err >&5
18670   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18671   (exit $ac_status); } &&
18672          { ac_try='test -z "$ac_c_werror_flag"
18673                          || test ! -s conftest.err'
18674   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18675   (eval $ac_try) 2>&5
18676   ac_status=$?
18677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18678   (exit $ac_status); }; } &&
18679          { ac_try='test -s conftest.$ac_objext'
18680   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18681   (eval $ac_try) 2>&5
18682   ac_status=$?
18683   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18684   (exit $ac_status); }; }; then
18685   ac_hi=$ac_mid; break
18686 else
18687   echo "$as_me: failed program was:" >&5
18688 sed 's/^/| /' conftest.$ac_ext >&5
18689
18690 ac_lo=`expr $ac_mid + 1`
18691                     if test $ac_lo -le $ac_mid; then
18692                       ac_lo= ac_hi=
18693                       break
18694                     fi
18695                     ac_mid=`expr 2 '*' $ac_mid + 1`
18696 fi
18697 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18698   done
18699 else
18700   echo "$as_me: failed program was:" >&5
18701 sed 's/^/| /' conftest.$ac_ext >&5
18702
18703 cat >conftest.$ac_ext <<_ACEOF
18704 /* confdefs.h.  */
18705 _ACEOF
18706 cat confdefs.h >>conftest.$ac_ext
18707 cat >>conftest.$ac_ext <<_ACEOF
18708 /* end confdefs.h.  */
18709 $ac_includes_default
18710 struct { char filler; short field; } pgac_struct;
18711 int
18712 main ()
18713 {
18714 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
18715 test_array [0] = 0
18716
18717   ;
18718   return 0;
18719 }
18720 _ACEOF
18721 rm -f conftest.$ac_objext
18722 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18723   (eval $ac_compile) 2>conftest.er1
18724   ac_status=$?
18725   grep -v '^ *+' conftest.er1 >conftest.err
18726   rm -f conftest.er1
18727   cat conftest.err >&5
18728   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18729   (exit $ac_status); } &&
18730          { ac_try='test -z "$ac_c_werror_flag"
18731                          || test ! -s conftest.err'
18732   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18733   (eval $ac_try) 2>&5
18734   ac_status=$?
18735   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18736   (exit $ac_status); }; } &&
18737          { ac_try='test -s conftest.$ac_objext'
18738   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18739   (eval $ac_try) 2>&5
18740   ac_status=$?
18741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18742   (exit $ac_status); }; }; then
18743   ac_hi=-1 ac_mid=-1
18744   while :; do
18745     cat >conftest.$ac_ext <<_ACEOF
18746 /* confdefs.h.  */
18747 _ACEOF
18748 cat confdefs.h >>conftest.$ac_ext
18749 cat >>conftest.$ac_ext <<_ACEOF
18750 /* end confdefs.h.  */
18751 $ac_includes_default
18752 struct { char filler; short field; } pgac_struct;
18753 int
18754 main ()
18755 {
18756 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
18757 test_array [0] = 0
18758
18759   ;
18760   return 0;
18761 }
18762 _ACEOF
18763 rm -f conftest.$ac_objext
18764 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18765   (eval $ac_compile) 2>conftest.er1
18766   ac_status=$?
18767   grep -v '^ *+' conftest.er1 >conftest.err
18768   rm -f conftest.er1
18769   cat conftest.err >&5
18770   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18771   (exit $ac_status); } &&
18772          { ac_try='test -z "$ac_c_werror_flag"
18773                          || test ! -s conftest.err'
18774   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18775   (eval $ac_try) 2>&5
18776   ac_status=$?
18777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18778   (exit $ac_status); }; } &&
18779          { ac_try='test -s conftest.$ac_objext'
18780   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18781   (eval $ac_try) 2>&5
18782   ac_status=$?
18783   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18784   (exit $ac_status); }; }; then
18785   ac_lo=$ac_mid; break
18786 else
18787   echo "$as_me: failed program was:" >&5
18788 sed 's/^/| /' conftest.$ac_ext >&5
18789
18790 ac_hi=`expr '(' $ac_mid ')' - 1`
18791                        if test $ac_mid -le $ac_hi; then
18792                          ac_lo= ac_hi=
18793                          break
18794                        fi
18795                        ac_mid=`expr 2 '*' $ac_mid`
18796 fi
18797 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18798   done
18799 else
18800   echo "$as_me: failed program was:" >&5
18801 sed 's/^/| /' conftest.$ac_ext >&5
18802
18803 ac_lo= ac_hi=
18804 fi
18805 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18806 fi
18807 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18808 # Binary search between lo and hi bounds.
18809 while test "x$ac_lo" != "x$ac_hi"; do
18810   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18811   cat >conftest.$ac_ext <<_ACEOF
18812 /* confdefs.h.  */
18813 _ACEOF
18814 cat confdefs.h >>conftest.$ac_ext
18815 cat >>conftest.$ac_ext <<_ACEOF
18816 /* end confdefs.h.  */
18817 $ac_includes_default
18818 struct { char filler; short field; } pgac_struct;
18819 int
18820 main ()
18821 {
18822 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18823 test_array [0] = 0
18824
18825   ;
18826   return 0;
18827 }
18828 _ACEOF
18829 rm -f conftest.$ac_objext
18830 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18831   (eval $ac_compile) 2>conftest.er1
18832   ac_status=$?
18833   grep -v '^ *+' conftest.er1 >conftest.err
18834   rm -f conftest.er1
18835   cat conftest.err >&5
18836   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18837   (exit $ac_status); } &&
18838          { ac_try='test -z "$ac_c_werror_flag"
18839                          || test ! -s conftest.err'
18840   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18841   (eval $ac_try) 2>&5
18842   ac_status=$?
18843   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18844   (exit $ac_status); }; } &&
18845          { ac_try='test -s conftest.$ac_objext'
18846   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18847   (eval $ac_try) 2>&5
18848   ac_status=$?
18849   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18850   (exit $ac_status); }; }; then
18851   ac_hi=$ac_mid
18852 else
18853   echo "$as_me: failed program was:" >&5
18854 sed 's/^/| /' conftest.$ac_ext >&5
18855
18856 ac_lo=`expr '(' $ac_mid ')' + 1`
18857 fi
18858 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18859 done
18860 case $ac_lo in
18861 ?*) pgac_cv_alignof_short=$ac_lo;;
18862 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
18863 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
18864    { (exit 1); exit 1; }; } ;;
18865 esac
18866 else
18867   if test "$cross_compiling" = yes; then
18868   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18869 See \`config.log' for more details." >&5
18870 echo "$as_me: error: cannot run test program while cross compiling
18871 See \`config.log' for more details." >&2;}
18872    { (exit 1); exit 1; }; }
18873 else
18874   cat >conftest.$ac_ext <<_ACEOF
18875 /* confdefs.h.  */
18876 _ACEOF
18877 cat confdefs.h >>conftest.$ac_ext
18878 cat >>conftest.$ac_ext <<_ACEOF
18879 /* end confdefs.h.  */
18880 $ac_includes_default
18881 struct { char filler; short field; } pgac_struct;
18882 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18883 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
18884 #include <stdio.h>
18885 #include <stdlib.h>
18886 int
18887 main ()
18888 {
18889
18890   FILE *f = fopen ("conftest.val", "w");
18891   if (! f)
18892     exit (1);
18893   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
18894     {
18895       long i = longval ();
18896       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18897         exit (1);
18898       fprintf (f, "%ld\n", i);
18899     }
18900   else
18901     {
18902       unsigned long i = ulongval ();
18903       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
18904         exit (1);
18905       fprintf (f, "%lu\n", i);
18906     }
18907   exit (ferror (f) || fclose (f) != 0);
18908
18909   ;
18910   return 0;
18911 }
18912 _ACEOF
18913 rm -f conftest$ac_exeext
18914 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18915   (eval $ac_link) 2>&5
18916   ac_status=$?
18917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18918   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18919   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18920   (eval $ac_try) 2>&5
18921   ac_status=$?
18922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18923   (exit $ac_status); }; }; then
18924   pgac_cv_alignof_short=`cat conftest.val`
18925 else
18926   echo "$as_me: program exited with status $ac_status" >&5
18927 echo "$as_me: failed program was:" >&5
18928 sed 's/^/| /' conftest.$ac_ext >&5
18929
18930 ( exit $ac_status )
18931 { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
18932 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
18933    { (exit 1); exit 1; }; }
18934 fi
18935 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18936 fi
18937 fi
18938 rm -f conftest.val
18939 else
18940   pgac_cv_alignof_short=0
18941 fi
18942 fi
18943 echo "$as_me:$LINENO: result: $pgac_cv_alignof_short" >&5
18944 echo "${ECHO_T}$pgac_cv_alignof_short" >&6
18945 cat >>confdefs.h <<_ACEOF
18946 #define ALIGNOF_SHORT $pgac_cv_alignof_short
18947 _ACEOF
18948
18949
18950 echo "$as_me:$LINENO: checking for int" >&5
18951 echo $ECHO_N "checking for int... $ECHO_C" >&6
18952 if test "${ac_cv_type_int+set}" = set; then
18953   echo $ECHO_N "(cached) $ECHO_C" >&6
18954 else
18955   cat >conftest.$ac_ext <<_ACEOF
18956 /* confdefs.h.  */
18957 _ACEOF
18958 cat confdefs.h >>conftest.$ac_ext
18959 cat >>conftest.$ac_ext <<_ACEOF
18960 /* end confdefs.h.  */
18961 $ac_includes_default
18962 int
18963 main ()
18964 {
18965 if ((int *) 0)
18966   return 0;
18967 if (sizeof (int))
18968   return 0;
18969   ;
18970   return 0;
18971 }
18972 _ACEOF
18973 rm -f conftest.$ac_objext
18974 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18975   (eval $ac_compile) 2>conftest.er1
18976   ac_status=$?
18977   grep -v '^ *+' conftest.er1 >conftest.err
18978   rm -f conftest.er1
18979   cat conftest.err >&5
18980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18981   (exit $ac_status); } &&
18982          { ac_try='test -z "$ac_c_werror_flag"
18983                          || test ! -s conftest.err'
18984   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18985   (eval $ac_try) 2>&5
18986   ac_status=$?
18987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18988   (exit $ac_status); }; } &&
18989          { ac_try='test -s conftest.$ac_objext'
18990   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18991   (eval $ac_try) 2>&5
18992   ac_status=$?
18993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18994   (exit $ac_status); }; }; then
18995   ac_cv_type_int=yes
18996 else
18997   echo "$as_me: failed program was:" >&5
18998 sed 's/^/| /' conftest.$ac_ext >&5
18999
19000 ac_cv_type_int=no
19001 fi
19002 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19003 fi
19004 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
19005 echo "${ECHO_T}$ac_cv_type_int" >&6
19006
19007 echo "$as_me:$LINENO: checking alignment of int" >&5
19008 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6
19009 if test "${pgac_cv_alignof_int+set}" = set; then
19010   echo $ECHO_N "(cached) $ECHO_C" >&6
19011 else
19012   if test "$ac_cv_type_int" = yes; then
19013   if test "$cross_compiling" = yes; then
19014   # Depending upon the size, compute the lo and hi bounds.
19015 cat >conftest.$ac_ext <<_ACEOF
19016 /* confdefs.h.  */
19017 _ACEOF
19018 cat confdefs.h >>conftest.$ac_ext
19019 cat >>conftest.$ac_ext <<_ACEOF
19020 /* end confdefs.h.  */
19021 $ac_includes_default
19022 struct { char filler; int field; } pgac_struct;
19023 int
19024 main ()
19025 {
19026 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
19027 test_array [0] = 0
19028
19029   ;
19030   return 0;
19031 }
19032 _ACEOF
19033 rm -f conftest.$ac_objext
19034 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19035   (eval $ac_compile) 2>conftest.er1
19036   ac_status=$?
19037   grep -v '^ *+' conftest.er1 >conftest.err
19038   rm -f conftest.er1
19039   cat conftest.err >&5
19040   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19041   (exit $ac_status); } &&
19042          { ac_try='test -z "$ac_c_werror_flag"
19043                          || test ! -s conftest.err'
19044   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19045   (eval $ac_try) 2>&5
19046   ac_status=$?
19047   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19048   (exit $ac_status); }; } &&
19049          { ac_try='test -s conftest.$ac_objext'
19050   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19051   (eval $ac_try) 2>&5
19052   ac_status=$?
19053   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19054   (exit $ac_status); }; }; then
19055   ac_lo=0 ac_mid=0
19056   while :; do
19057     cat >conftest.$ac_ext <<_ACEOF
19058 /* confdefs.h.  */
19059 _ACEOF
19060 cat confdefs.h >>conftest.$ac_ext
19061 cat >>conftest.$ac_ext <<_ACEOF
19062 /* end confdefs.h.  */
19063 $ac_includes_default
19064 struct { char filler; int field; } pgac_struct;
19065 int
19066 main ()
19067 {
19068 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19069 test_array [0] = 0
19070
19071   ;
19072   return 0;
19073 }
19074 _ACEOF
19075 rm -f conftest.$ac_objext
19076 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19077   (eval $ac_compile) 2>conftest.er1
19078   ac_status=$?
19079   grep -v '^ *+' conftest.er1 >conftest.err
19080   rm -f conftest.er1
19081   cat conftest.err >&5
19082   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19083   (exit $ac_status); } &&
19084          { ac_try='test -z "$ac_c_werror_flag"
19085                          || test ! -s conftest.err'
19086   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19087   (eval $ac_try) 2>&5
19088   ac_status=$?
19089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19090   (exit $ac_status); }; } &&
19091          { ac_try='test -s conftest.$ac_objext'
19092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19093   (eval $ac_try) 2>&5
19094   ac_status=$?
19095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19096   (exit $ac_status); }; }; then
19097   ac_hi=$ac_mid; break
19098 else
19099   echo "$as_me: failed program was:" >&5
19100 sed 's/^/| /' conftest.$ac_ext >&5
19101
19102 ac_lo=`expr $ac_mid + 1`
19103                     if test $ac_lo -le $ac_mid; then
19104                       ac_lo= ac_hi=
19105                       break
19106                     fi
19107                     ac_mid=`expr 2 '*' $ac_mid + 1`
19108 fi
19109 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19110   done
19111 else
19112   echo "$as_me: failed program was:" >&5
19113 sed 's/^/| /' conftest.$ac_ext >&5
19114
19115 cat >conftest.$ac_ext <<_ACEOF
19116 /* confdefs.h.  */
19117 _ACEOF
19118 cat confdefs.h >>conftest.$ac_ext
19119 cat >>conftest.$ac_ext <<_ACEOF
19120 /* end confdefs.h.  */
19121 $ac_includes_default
19122 struct { char filler; int field; } pgac_struct;
19123 int
19124 main ()
19125 {
19126 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19127 test_array [0] = 0
19128
19129   ;
19130   return 0;
19131 }
19132 _ACEOF
19133 rm -f conftest.$ac_objext
19134 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19135   (eval $ac_compile) 2>conftest.er1
19136   ac_status=$?
19137   grep -v '^ *+' conftest.er1 >conftest.err
19138   rm -f conftest.er1
19139   cat conftest.err >&5
19140   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19141   (exit $ac_status); } &&
19142          { ac_try='test -z "$ac_c_werror_flag"
19143                          || test ! -s conftest.err'
19144   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19145   (eval $ac_try) 2>&5
19146   ac_status=$?
19147   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19148   (exit $ac_status); }; } &&
19149          { ac_try='test -s conftest.$ac_objext'
19150   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19151   (eval $ac_try) 2>&5
19152   ac_status=$?
19153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19154   (exit $ac_status); }; }; then
19155   ac_hi=-1 ac_mid=-1
19156   while :; do
19157     cat >conftest.$ac_ext <<_ACEOF
19158 /* confdefs.h.  */
19159 _ACEOF
19160 cat confdefs.h >>conftest.$ac_ext
19161 cat >>conftest.$ac_ext <<_ACEOF
19162 /* end confdefs.h.  */
19163 $ac_includes_default
19164 struct { char filler; int field; } pgac_struct;
19165 int
19166 main ()
19167 {
19168 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19169 test_array [0] = 0
19170
19171   ;
19172   return 0;
19173 }
19174 _ACEOF
19175 rm -f conftest.$ac_objext
19176 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19177   (eval $ac_compile) 2>conftest.er1
19178   ac_status=$?
19179   grep -v '^ *+' conftest.er1 >conftest.err
19180   rm -f conftest.er1
19181   cat conftest.err >&5
19182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19183   (exit $ac_status); } &&
19184          { ac_try='test -z "$ac_c_werror_flag"
19185                          || test ! -s conftest.err'
19186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19187   (eval $ac_try) 2>&5
19188   ac_status=$?
19189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19190   (exit $ac_status); }; } &&
19191          { ac_try='test -s conftest.$ac_objext'
19192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19193   (eval $ac_try) 2>&5
19194   ac_status=$?
19195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19196   (exit $ac_status); }; }; then
19197   ac_lo=$ac_mid; break
19198 else
19199   echo "$as_me: failed program was:" >&5
19200 sed 's/^/| /' conftest.$ac_ext >&5
19201
19202 ac_hi=`expr '(' $ac_mid ')' - 1`
19203                        if test $ac_mid -le $ac_hi; then
19204                          ac_lo= ac_hi=
19205                          break
19206                        fi
19207                        ac_mid=`expr 2 '*' $ac_mid`
19208 fi
19209 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19210   done
19211 else
19212   echo "$as_me: failed program was:" >&5
19213 sed 's/^/| /' conftest.$ac_ext >&5
19214
19215 ac_lo= ac_hi=
19216 fi
19217 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19218 fi
19219 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19220 # Binary search between lo and hi bounds.
19221 while test "x$ac_lo" != "x$ac_hi"; do
19222   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19223   cat >conftest.$ac_ext <<_ACEOF
19224 /* confdefs.h.  */
19225 _ACEOF
19226 cat confdefs.h >>conftest.$ac_ext
19227 cat >>conftest.$ac_ext <<_ACEOF
19228 /* end confdefs.h.  */
19229 $ac_includes_default
19230 struct { char filler; int field; } pgac_struct;
19231 int
19232 main ()
19233 {
19234 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19235 test_array [0] = 0
19236
19237   ;
19238   return 0;
19239 }
19240 _ACEOF
19241 rm -f conftest.$ac_objext
19242 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19243   (eval $ac_compile) 2>conftest.er1
19244   ac_status=$?
19245   grep -v '^ *+' conftest.er1 >conftest.err
19246   rm -f conftest.er1
19247   cat conftest.err >&5
19248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19249   (exit $ac_status); } &&
19250          { ac_try='test -z "$ac_c_werror_flag"
19251                          || test ! -s conftest.err'
19252   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19253   (eval $ac_try) 2>&5
19254   ac_status=$?
19255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19256   (exit $ac_status); }; } &&
19257          { ac_try='test -s conftest.$ac_objext'
19258   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19259   (eval $ac_try) 2>&5
19260   ac_status=$?
19261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19262   (exit $ac_status); }; }; then
19263   ac_hi=$ac_mid
19264 else
19265   echo "$as_me: failed program was:" >&5
19266 sed 's/^/| /' conftest.$ac_ext >&5
19267
19268 ac_lo=`expr '(' $ac_mid ')' + 1`
19269 fi
19270 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19271 done
19272 case $ac_lo in
19273 ?*) pgac_cv_alignof_int=$ac_lo;;
19274 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
19275 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
19276    { (exit 1); exit 1; }; } ;;
19277 esac
19278 else
19279   if test "$cross_compiling" = yes; then
19280   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19281 See \`config.log' for more details." >&5
19282 echo "$as_me: error: cannot run test program while cross compiling
19283 See \`config.log' for more details." >&2;}
19284    { (exit 1); exit 1; }; }
19285 else
19286   cat >conftest.$ac_ext <<_ACEOF
19287 /* confdefs.h.  */
19288 _ACEOF
19289 cat confdefs.h >>conftest.$ac_ext
19290 cat >>conftest.$ac_ext <<_ACEOF
19291 /* end confdefs.h.  */
19292 $ac_includes_default
19293 struct { char filler; int field; } pgac_struct;
19294 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19295 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19296 #include <stdio.h>
19297 #include <stdlib.h>
19298 int
19299 main ()
19300 {
19301
19302   FILE *f = fopen ("conftest.val", "w");
19303   if (! f)
19304     exit (1);
19305   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
19306     {
19307       long i = longval ();
19308       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19309         exit (1);
19310       fprintf (f, "%ld\n", i);
19311     }
19312   else
19313     {
19314       unsigned long i = ulongval ();
19315       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19316         exit (1);
19317       fprintf (f, "%lu\n", i);
19318     }
19319   exit (ferror (f) || fclose (f) != 0);
19320
19321   ;
19322   return 0;
19323 }
19324 _ACEOF
19325 rm -f conftest$ac_exeext
19326 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19327   (eval $ac_link) 2>&5
19328   ac_status=$?
19329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19330   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19331   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19332   (eval $ac_try) 2>&5
19333   ac_status=$?
19334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19335   (exit $ac_status); }; }; then
19336   pgac_cv_alignof_int=`cat conftest.val`
19337 else
19338   echo "$as_me: program exited with status $ac_status" >&5
19339 echo "$as_me: failed program was:" >&5
19340 sed 's/^/| /' conftest.$ac_ext >&5
19341
19342 ( exit $ac_status )
19343 { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
19344 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
19345    { (exit 1); exit 1; }; }
19346 fi
19347 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19348 fi
19349 fi
19350 rm -f conftest.val
19351 else
19352   pgac_cv_alignof_int=0
19353 fi
19354 fi
19355 echo "$as_me:$LINENO: result: $pgac_cv_alignof_int" >&5
19356 echo "${ECHO_T}$pgac_cv_alignof_int" >&6
19357 cat >>confdefs.h <<_ACEOF
19358 #define ALIGNOF_INT $pgac_cv_alignof_int
19359 _ACEOF
19360
19361
19362 echo "$as_me:$LINENO: checking for long" >&5
19363 echo $ECHO_N "checking for long... $ECHO_C" >&6
19364 if test "${ac_cv_type_long+set}" = set; then
19365   echo $ECHO_N "(cached) $ECHO_C" >&6
19366 else
19367   cat >conftest.$ac_ext <<_ACEOF
19368 /* confdefs.h.  */
19369 _ACEOF
19370 cat confdefs.h >>conftest.$ac_ext
19371 cat >>conftest.$ac_ext <<_ACEOF
19372 /* end confdefs.h.  */
19373 $ac_includes_default
19374 int
19375 main ()
19376 {
19377 if ((long *) 0)
19378   return 0;
19379 if (sizeof (long))
19380   return 0;
19381   ;
19382   return 0;
19383 }
19384 _ACEOF
19385 rm -f conftest.$ac_objext
19386 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19387   (eval $ac_compile) 2>conftest.er1
19388   ac_status=$?
19389   grep -v '^ *+' conftest.er1 >conftest.err
19390   rm -f conftest.er1
19391   cat conftest.err >&5
19392   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19393   (exit $ac_status); } &&
19394          { ac_try='test -z "$ac_c_werror_flag"
19395                          || test ! -s conftest.err'
19396   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19397   (eval $ac_try) 2>&5
19398   ac_status=$?
19399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19400   (exit $ac_status); }; } &&
19401          { ac_try='test -s conftest.$ac_objext'
19402   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19403   (eval $ac_try) 2>&5
19404   ac_status=$?
19405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19406   (exit $ac_status); }; }; then
19407   ac_cv_type_long=yes
19408 else
19409   echo "$as_me: failed program was:" >&5
19410 sed 's/^/| /' conftest.$ac_ext >&5
19411
19412 ac_cv_type_long=no
19413 fi
19414 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19415 fi
19416 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
19417 echo "${ECHO_T}$ac_cv_type_long" >&6
19418
19419 echo "$as_me:$LINENO: checking alignment of long" >&5
19420 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6
19421 if test "${pgac_cv_alignof_long+set}" = set; then
19422   echo $ECHO_N "(cached) $ECHO_C" >&6
19423 else
19424   if test "$ac_cv_type_long" = yes; then
19425   if test "$cross_compiling" = yes; then
19426   # Depending upon the size, compute the lo and hi bounds.
19427 cat >conftest.$ac_ext <<_ACEOF
19428 /* confdefs.h.  */
19429 _ACEOF
19430 cat confdefs.h >>conftest.$ac_ext
19431 cat >>conftest.$ac_ext <<_ACEOF
19432 /* end confdefs.h.  */
19433 $ac_includes_default
19434 struct { char filler; long field; } pgac_struct;
19435 int
19436 main ()
19437 {
19438 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
19439 test_array [0] = 0
19440
19441   ;
19442   return 0;
19443 }
19444 _ACEOF
19445 rm -f conftest.$ac_objext
19446 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19447   (eval $ac_compile) 2>conftest.er1
19448   ac_status=$?
19449   grep -v '^ *+' conftest.er1 >conftest.err
19450   rm -f conftest.er1
19451   cat conftest.err >&5
19452   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19453   (exit $ac_status); } &&
19454          { ac_try='test -z "$ac_c_werror_flag"
19455                          || test ! -s conftest.err'
19456   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19457   (eval $ac_try) 2>&5
19458   ac_status=$?
19459   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19460   (exit $ac_status); }; } &&
19461          { ac_try='test -s conftest.$ac_objext'
19462   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19463   (eval $ac_try) 2>&5
19464   ac_status=$?
19465   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19466   (exit $ac_status); }; }; then
19467   ac_lo=0 ac_mid=0
19468   while :; do
19469     cat >conftest.$ac_ext <<_ACEOF
19470 /* confdefs.h.  */
19471 _ACEOF
19472 cat confdefs.h >>conftest.$ac_ext
19473 cat >>conftest.$ac_ext <<_ACEOF
19474 /* end confdefs.h.  */
19475 $ac_includes_default
19476 struct { char filler; long field; } pgac_struct;
19477 int
19478 main ()
19479 {
19480 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19481 test_array [0] = 0
19482
19483   ;
19484   return 0;
19485 }
19486 _ACEOF
19487 rm -f conftest.$ac_objext
19488 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19489   (eval $ac_compile) 2>conftest.er1
19490   ac_status=$?
19491   grep -v '^ *+' conftest.er1 >conftest.err
19492   rm -f conftest.er1
19493   cat conftest.err >&5
19494   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19495   (exit $ac_status); } &&
19496          { ac_try='test -z "$ac_c_werror_flag"
19497                          || test ! -s conftest.err'
19498   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19499   (eval $ac_try) 2>&5
19500   ac_status=$?
19501   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19502   (exit $ac_status); }; } &&
19503          { ac_try='test -s conftest.$ac_objext'
19504   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19505   (eval $ac_try) 2>&5
19506   ac_status=$?
19507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19508   (exit $ac_status); }; }; then
19509   ac_hi=$ac_mid; break
19510 else
19511   echo "$as_me: failed program was:" >&5
19512 sed 's/^/| /' conftest.$ac_ext >&5
19513
19514 ac_lo=`expr $ac_mid + 1`
19515                     if test $ac_lo -le $ac_mid; then
19516                       ac_lo= ac_hi=
19517                       break
19518                     fi
19519                     ac_mid=`expr 2 '*' $ac_mid + 1`
19520 fi
19521 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19522   done
19523 else
19524   echo "$as_me: failed program was:" >&5
19525 sed 's/^/| /' conftest.$ac_ext >&5
19526
19527 cat >conftest.$ac_ext <<_ACEOF
19528 /* confdefs.h.  */
19529 _ACEOF
19530 cat confdefs.h >>conftest.$ac_ext
19531 cat >>conftest.$ac_ext <<_ACEOF
19532 /* end confdefs.h.  */
19533 $ac_includes_default
19534 struct { char filler; long field; } pgac_struct;
19535 int
19536 main ()
19537 {
19538 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19539 test_array [0] = 0
19540
19541   ;
19542   return 0;
19543 }
19544 _ACEOF
19545 rm -f conftest.$ac_objext
19546 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19547   (eval $ac_compile) 2>conftest.er1
19548   ac_status=$?
19549   grep -v '^ *+' conftest.er1 >conftest.err
19550   rm -f conftest.er1
19551   cat conftest.err >&5
19552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19553   (exit $ac_status); } &&
19554          { ac_try='test -z "$ac_c_werror_flag"
19555                          || test ! -s conftest.err'
19556   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19557   (eval $ac_try) 2>&5
19558   ac_status=$?
19559   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19560   (exit $ac_status); }; } &&
19561          { ac_try='test -s conftest.$ac_objext'
19562   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19563   (eval $ac_try) 2>&5
19564   ac_status=$?
19565   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19566   (exit $ac_status); }; }; then
19567   ac_hi=-1 ac_mid=-1
19568   while :; do
19569     cat >conftest.$ac_ext <<_ACEOF
19570 /* confdefs.h.  */
19571 _ACEOF
19572 cat confdefs.h >>conftest.$ac_ext
19573 cat >>conftest.$ac_ext <<_ACEOF
19574 /* end confdefs.h.  */
19575 $ac_includes_default
19576 struct { char filler; long field; } pgac_struct;
19577 int
19578 main ()
19579 {
19580 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19581 test_array [0] = 0
19582
19583   ;
19584   return 0;
19585 }
19586 _ACEOF
19587 rm -f conftest.$ac_objext
19588 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19589   (eval $ac_compile) 2>conftest.er1
19590   ac_status=$?
19591   grep -v '^ *+' conftest.er1 >conftest.err
19592   rm -f conftest.er1
19593   cat conftest.err >&5
19594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19595   (exit $ac_status); } &&
19596          { ac_try='test -z "$ac_c_werror_flag"
19597                          || test ! -s conftest.err'
19598   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19599   (eval $ac_try) 2>&5
19600   ac_status=$?
19601   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19602   (exit $ac_status); }; } &&
19603          { ac_try='test -s conftest.$ac_objext'
19604   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19605   (eval $ac_try) 2>&5
19606   ac_status=$?
19607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19608   (exit $ac_status); }; }; then
19609   ac_lo=$ac_mid; break
19610 else
19611   echo "$as_me: failed program was:" >&5
19612 sed 's/^/| /' conftest.$ac_ext >&5
19613
19614 ac_hi=`expr '(' $ac_mid ')' - 1`
19615                        if test $ac_mid -le $ac_hi; then
19616                          ac_lo= ac_hi=
19617                          break
19618                        fi
19619                        ac_mid=`expr 2 '*' $ac_mid`
19620 fi
19621 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19622   done
19623 else
19624   echo "$as_me: failed program was:" >&5
19625 sed 's/^/| /' conftest.$ac_ext >&5
19626
19627 ac_lo= ac_hi=
19628 fi
19629 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19630 fi
19631 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19632 # Binary search between lo and hi bounds.
19633 while test "x$ac_lo" != "x$ac_hi"; do
19634   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19635   cat >conftest.$ac_ext <<_ACEOF
19636 /* confdefs.h.  */
19637 _ACEOF
19638 cat confdefs.h >>conftest.$ac_ext
19639 cat >>conftest.$ac_ext <<_ACEOF
19640 /* end confdefs.h.  */
19641 $ac_includes_default
19642 struct { char filler; long field; } pgac_struct;
19643 int
19644 main ()
19645 {
19646 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19647 test_array [0] = 0
19648
19649   ;
19650   return 0;
19651 }
19652 _ACEOF
19653 rm -f conftest.$ac_objext
19654 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19655   (eval $ac_compile) 2>conftest.er1
19656   ac_status=$?
19657   grep -v '^ *+' conftest.er1 >conftest.err
19658   rm -f conftest.er1
19659   cat conftest.err >&5
19660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19661   (exit $ac_status); } &&
19662          { ac_try='test -z "$ac_c_werror_flag"
19663                          || test ! -s conftest.err'
19664   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19665   (eval $ac_try) 2>&5
19666   ac_status=$?
19667   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19668   (exit $ac_status); }; } &&
19669          { ac_try='test -s conftest.$ac_objext'
19670   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19671   (eval $ac_try) 2>&5
19672   ac_status=$?
19673   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19674   (exit $ac_status); }; }; then
19675   ac_hi=$ac_mid
19676 else
19677   echo "$as_me: failed program was:" >&5
19678 sed 's/^/| /' conftest.$ac_ext >&5
19679
19680 ac_lo=`expr '(' $ac_mid ')' + 1`
19681 fi
19682 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19683 done
19684 case $ac_lo in
19685 ?*) pgac_cv_alignof_long=$ac_lo;;
19686 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
19687 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
19688    { (exit 1); exit 1; }; } ;;
19689 esac
19690 else
19691   if test "$cross_compiling" = yes; then
19692   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19693 See \`config.log' for more details." >&5
19694 echo "$as_me: error: cannot run test program while cross compiling
19695 See \`config.log' for more details." >&2;}
19696    { (exit 1); exit 1; }; }
19697 else
19698   cat >conftest.$ac_ext <<_ACEOF
19699 /* confdefs.h.  */
19700 _ACEOF
19701 cat confdefs.h >>conftest.$ac_ext
19702 cat >>conftest.$ac_ext <<_ACEOF
19703 /* end confdefs.h.  */
19704 $ac_includes_default
19705 struct { char filler; long field; } pgac_struct;
19706 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19707 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19708 #include <stdio.h>
19709 #include <stdlib.h>
19710 int
19711 main ()
19712 {
19713
19714   FILE *f = fopen ("conftest.val", "w");
19715   if (! f)
19716     exit (1);
19717   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
19718     {
19719       long i = longval ();
19720       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19721         exit (1);
19722       fprintf (f, "%ld\n", i);
19723     }
19724   else
19725     {
19726       unsigned long i = ulongval ();
19727       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19728         exit (1);
19729       fprintf (f, "%lu\n", i);
19730     }
19731   exit (ferror (f) || fclose (f) != 0);
19732
19733   ;
19734   return 0;
19735 }
19736 _ACEOF
19737 rm -f conftest$ac_exeext
19738 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19739   (eval $ac_link) 2>&5
19740   ac_status=$?
19741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19742   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19743   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19744   (eval $ac_try) 2>&5
19745   ac_status=$?
19746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19747   (exit $ac_status); }; }; then
19748   pgac_cv_alignof_long=`cat conftest.val`
19749 else
19750   echo "$as_me: program exited with status $ac_status" >&5
19751 echo "$as_me: failed program was:" >&5
19752 sed 's/^/| /' conftest.$ac_ext >&5
19753
19754 ( exit $ac_status )
19755 { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
19756 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
19757    { (exit 1); exit 1; }; }
19758 fi
19759 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19760 fi
19761 fi
19762 rm -f conftest.val
19763 else
19764   pgac_cv_alignof_long=0
19765 fi
19766 fi
19767 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long" >&5
19768 echo "${ECHO_T}$pgac_cv_alignof_long" >&6
19769 cat >>confdefs.h <<_ACEOF
19770 #define ALIGNOF_LONG $pgac_cv_alignof_long
19771 _ACEOF
19772
19773
19774 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
19775   echo "$as_me:$LINENO: checking for long long int" >&5
19776 echo $ECHO_N "checking for long long int... $ECHO_C" >&6
19777 if test "${ac_cv_type_long_long_int+set}" = set; then
19778   echo $ECHO_N "(cached) $ECHO_C" >&6
19779 else
19780   cat >conftest.$ac_ext <<_ACEOF
19781 /* confdefs.h.  */
19782 _ACEOF
19783 cat confdefs.h >>conftest.$ac_ext
19784 cat >>conftest.$ac_ext <<_ACEOF
19785 /* end confdefs.h.  */
19786 $ac_includes_default
19787 int
19788 main ()
19789 {
19790 if ((long long int *) 0)
19791   return 0;
19792 if (sizeof (long long int))
19793   return 0;
19794   ;
19795   return 0;
19796 }
19797 _ACEOF
19798 rm -f conftest.$ac_objext
19799 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19800   (eval $ac_compile) 2>conftest.er1
19801   ac_status=$?
19802   grep -v '^ *+' conftest.er1 >conftest.err
19803   rm -f conftest.er1
19804   cat conftest.err >&5
19805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19806   (exit $ac_status); } &&
19807          { ac_try='test -z "$ac_c_werror_flag"
19808                          || test ! -s conftest.err'
19809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19810   (eval $ac_try) 2>&5
19811   ac_status=$?
19812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19813   (exit $ac_status); }; } &&
19814          { ac_try='test -s conftest.$ac_objext'
19815   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19816   (eval $ac_try) 2>&5
19817   ac_status=$?
19818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19819   (exit $ac_status); }; }; then
19820   ac_cv_type_long_long_int=yes
19821 else
19822   echo "$as_me: failed program was:" >&5
19823 sed 's/^/| /' conftest.$ac_ext >&5
19824
19825 ac_cv_type_long_long_int=no
19826 fi
19827 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19828 fi
19829 echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
19830 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6
19831
19832 echo "$as_me:$LINENO: checking alignment of long long int" >&5
19833 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6
19834 if test "${pgac_cv_alignof_long_long_int+set}" = set; then
19835   echo $ECHO_N "(cached) $ECHO_C" >&6
19836 else
19837   if test "$ac_cv_type_long_long_int" = yes; then
19838   if test "$cross_compiling" = yes; then
19839   # Depending upon the size, compute the lo and hi bounds.
19840 cat >conftest.$ac_ext <<_ACEOF
19841 /* confdefs.h.  */
19842 _ACEOF
19843 cat confdefs.h >>conftest.$ac_ext
19844 cat >>conftest.$ac_ext <<_ACEOF
19845 /* end confdefs.h.  */
19846 $ac_includes_default
19847 struct { char filler; long long int field; } pgac_struct;
19848 int
19849 main ()
19850 {
19851 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
19852 test_array [0] = 0
19853
19854   ;
19855   return 0;
19856 }
19857 _ACEOF
19858 rm -f conftest.$ac_objext
19859 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19860   (eval $ac_compile) 2>conftest.er1
19861   ac_status=$?
19862   grep -v '^ *+' conftest.er1 >conftest.err
19863   rm -f conftest.er1
19864   cat conftest.err >&5
19865   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19866   (exit $ac_status); } &&
19867          { ac_try='test -z "$ac_c_werror_flag"
19868                          || test ! -s conftest.err'
19869   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19870   (eval $ac_try) 2>&5
19871   ac_status=$?
19872   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19873   (exit $ac_status); }; } &&
19874          { ac_try='test -s conftest.$ac_objext'
19875   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19876   (eval $ac_try) 2>&5
19877   ac_status=$?
19878   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19879   (exit $ac_status); }; }; then
19880   ac_lo=0 ac_mid=0
19881   while :; do
19882     cat >conftest.$ac_ext <<_ACEOF
19883 /* confdefs.h.  */
19884 _ACEOF
19885 cat confdefs.h >>conftest.$ac_ext
19886 cat >>conftest.$ac_ext <<_ACEOF
19887 /* end confdefs.h.  */
19888 $ac_includes_default
19889 struct { char filler; long long int field; } pgac_struct;
19890 int
19891 main ()
19892 {
19893 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19894 test_array [0] = 0
19895
19896   ;
19897   return 0;
19898 }
19899 _ACEOF
19900 rm -f conftest.$ac_objext
19901 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19902   (eval $ac_compile) 2>conftest.er1
19903   ac_status=$?
19904   grep -v '^ *+' conftest.er1 >conftest.err
19905   rm -f conftest.er1
19906   cat conftest.err >&5
19907   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19908   (exit $ac_status); } &&
19909          { ac_try='test -z "$ac_c_werror_flag"
19910                          || test ! -s conftest.err'
19911   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19912   (eval $ac_try) 2>&5
19913   ac_status=$?
19914   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19915   (exit $ac_status); }; } &&
19916          { ac_try='test -s conftest.$ac_objext'
19917   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19918   (eval $ac_try) 2>&5
19919   ac_status=$?
19920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19921   (exit $ac_status); }; }; then
19922   ac_hi=$ac_mid; break
19923 else
19924   echo "$as_me: failed program was:" >&5
19925 sed 's/^/| /' conftest.$ac_ext >&5
19926
19927 ac_lo=`expr $ac_mid + 1`
19928                     if test $ac_lo -le $ac_mid; then
19929                       ac_lo= ac_hi=
19930                       break
19931                     fi
19932                     ac_mid=`expr 2 '*' $ac_mid + 1`
19933 fi
19934 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19935   done
19936 else
19937   echo "$as_me: failed program was:" >&5
19938 sed 's/^/| /' conftest.$ac_ext >&5
19939
19940 cat >conftest.$ac_ext <<_ACEOF
19941 /* confdefs.h.  */
19942 _ACEOF
19943 cat confdefs.h >>conftest.$ac_ext
19944 cat >>conftest.$ac_ext <<_ACEOF
19945 /* end confdefs.h.  */
19946 $ac_includes_default
19947 struct { char filler; long long int field; } pgac_struct;
19948 int
19949 main ()
19950 {
19951 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19952 test_array [0] = 0
19953
19954   ;
19955   return 0;
19956 }
19957 _ACEOF
19958 rm -f conftest.$ac_objext
19959 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19960   (eval $ac_compile) 2>conftest.er1
19961   ac_status=$?
19962   grep -v '^ *+' conftest.er1 >conftest.err
19963   rm -f conftest.er1
19964   cat conftest.err >&5
19965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19966   (exit $ac_status); } &&
19967          { ac_try='test -z "$ac_c_werror_flag"
19968                          || test ! -s conftest.err'
19969   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19970   (eval $ac_try) 2>&5
19971   ac_status=$?
19972   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19973   (exit $ac_status); }; } &&
19974          { ac_try='test -s conftest.$ac_objext'
19975   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19976   (eval $ac_try) 2>&5
19977   ac_status=$?
19978   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19979   (exit $ac_status); }; }; then
19980   ac_hi=-1 ac_mid=-1
19981   while :; do
19982     cat >conftest.$ac_ext <<_ACEOF
19983 /* confdefs.h.  */
19984 _ACEOF
19985 cat confdefs.h >>conftest.$ac_ext
19986 cat >>conftest.$ac_ext <<_ACEOF
19987 /* end confdefs.h.  */
19988 $ac_includes_default
19989 struct { char filler; long long int field; } pgac_struct;
19990 int
19991 main ()
19992 {
19993 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19994 test_array [0] = 0
19995
19996   ;
19997   return 0;
19998 }
19999 _ACEOF
20000 rm -f conftest.$ac_objext
20001 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20002   (eval $ac_compile) 2>conftest.er1
20003   ac_status=$?
20004   grep -v '^ *+' conftest.er1 >conftest.err
20005   rm -f conftest.er1
20006   cat conftest.err >&5
20007   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20008   (exit $ac_status); } &&
20009          { ac_try='test -z "$ac_c_werror_flag"
20010                          || test ! -s conftest.err'
20011   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20012   (eval $ac_try) 2>&5
20013   ac_status=$?
20014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20015   (exit $ac_status); }; } &&
20016          { ac_try='test -s conftest.$ac_objext'
20017   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20018   (eval $ac_try) 2>&5
20019   ac_status=$?
20020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20021   (exit $ac_status); }; }; then
20022   ac_lo=$ac_mid; break
20023 else
20024   echo "$as_me: failed program was:" >&5
20025 sed 's/^/| /' conftest.$ac_ext >&5
20026
20027 ac_hi=`expr '(' $ac_mid ')' - 1`
20028                        if test $ac_mid -le $ac_hi; then
20029                          ac_lo= ac_hi=
20030                          break
20031                        fi
20032                        ac_mid=`expr 2 '*' $ac_mid`
20033 fi
20034 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20035   done
20036 else
20037   echo "$as_me: failed program was:" >&5
20038 sed 's/^/| /' conftest.$ac_ext >&5
20039
20040 ac_lo= ac_hi=
20041 fi
20042 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20043 fi
20044 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20045 # Binary search between lo and hi bounds.
20046 while test "x$ac_lo" != "x$ac_hi"; do
20047   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20048   cat >conftest.$ac_ext <<_ACEOF
20049 /* confdefs.h.  */
20050 _ACEOF
20051 cat confdefs.h >>conftest.$ac_ext
20052 cat >>conftest.$ac_ext <<_ACEOF
20053 /* end confdefs.h.  */
20054 $ac_includes_default
20055 struct { char filler; long long int field; } pgac_struct;
20056 int
20057 main ()
20058 {
20059 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
20060 test_array [0] = 0
20061
20062   ;
20063   return 0;
20064 }
20065 _ACEOF
20066 rm -f conftest.$ac_objext
20067 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20068   (eval $ac_compile) 2>conftest.er1
20069   ac_status=$?
20070   grep -v '^ *+' conftest.er1 >conftest.err
20071   rm -f conftest.er1
20072   cat conftest.err >&5
20073   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20074   (exit $ac_status); } &&
20075          { ac_try='test -z "$ac_c_werror_flag"
20076                          || test ! -s conftest.err'
20077   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20078   (eval $ac_try) 2>&5
20079   ac_status=$?
20080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20081   (exit $ac_status); }; } &&
20082          { ac_try='test -s conftest.$ac_objext'
20083   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20084   (eval $ac_try) 2>&5
20085   ac_status=$?
20086   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20087   (exit $ac_status); }; }; then
20088   ac_hi=$ac_mid
20089 else
20090   echo "$as_me: failed program was:" >&5
20091 sed 's/^/| /' conftest.$ac_ext >&5
20092
20093 ac_lo=`expr '(' $ac_mid ')' + 1`
20094 fi
20095 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20096 done
20097 case $ac_lo in
20098 ?*) pgac_cv_alignof_long_long_int=$ac_lo;;
20099 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
20100 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
20101    { (exit 1); exit 1; }; } ;;
20102 esac
20103 else
20104   if test "$cross_compiling" = yes; then
20105   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
20106 See \`config.log' for more details." >&5
20107 echo "$as_me: error: cannot run test program while cross compiling
20108 See \`config.log' for more details." >&2;}
20109    { (exit 1); exit 1; }; }
20110 else
20111   cat >conftest.$ac_ext <<_ACEOF
20112 /* confdefs.h.  */
20113 _ACEOF
20114 cat confdefs.h >>conftest.$ac_ext
20115 cat >>conftest.$ac_ext <<_ACEOF
20116 /* end confdefs.h.  */
20117 $ac_includes_default
20118 struct { char filler; long long int field; } pgac_struct;
20119 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20120 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20121 #include <stdio.h>
20122 #include <stdlib.h>
20123 int
20124 main ()
20125 {
20126
20127   FILE *f = fopen ("conftest.val", "w");
20128   if (! f)
20129     exit (1);
20130   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
20131     {
20132       long i = longval ();
20133       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20134         exit (1);
20135       fprintf (f, "%ld\n", i);
20136     }
20137   else
20138     {
20139       unsigned long i = ulongval ();
20140       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20141         exit (1);
20142       fprintf (f, "%lu\n", i);
20143     }
20144   exit (ferror (f) || fclose (f) != 0);
20145
20146   ;
20147   return 0;
20148 }
20149 _ACEOF
20150 rm -f conftest$ac_exeext
20151 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20152   (eval $ac_link) 2>&5
20153   ac_status=$?
20154   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20155   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20156   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20157   (eval $ac_try) 2>&5
20158   ac_status=$?
20159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20160   (exit $ac_status); }; }; then
20161   pgac_cv_alignof_long_long_int=`cat conftest.val`
20162 else
20163   echo "$as_me: program exited with status $ac_status" >&5
20164 echo "$as_me: failed program was:" >&5
20165 sed 's/^/| /' conftest.$ac_ext >&5
20166
20167 ( exit $ac_status )
20168 { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
20169 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
20170    { (exit 1); exit 1; }; }
20171 fi
20172 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20173 fi
20174 fi
20175 rm -f conftest.val
20176 else
20177   pgac_cv_alignof_long_long_int=0
20178 fi
20179 fi
20180 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long_long_int" >&5
20181 echo "${ECHO_T}$pgac_cv_alignof_long_long_int" >&6
20182 cat >>confdefs.h <<_ACEOF
20183 #define ALIGNOF_LONG_LONG_INT $pgac_cv_alignof_long_long_int
20184 _ACEOF
20185
20186
20187 fi
20188 echo "$as_me:$LINENO: checking for double" >&5
20189 echo $ECHO_N "checking for double... $ECHO_C" >&6
20190 if test "${ac_cv_type_double+set}" = set; then
20191   echo $ECHO_N "(cached) $ECHO_C" >&6
20192 else
20193   cat >conftest.$ac_ext <<_ACEOF
20194 /* confdefs.h.  */
20195 _ACEOF
20196 cat confdefs.h >>conftest.$ac_ext
20197 cat >>conftest.$ac_ext <<_ACEOF
20198 /* end confdefs.h.  */
20199 $ac_includes_default
20200 int
20201 main ()
20202 {
20203 if ((double *) 0)
20204   return 0;
20205 if (sizeof (double))
20206   return 0;
20207   ;
20208   return 0;
20209 }
20210 _ACEOF
20211 rm -f conftest.$ac_objext
20212 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20213   (eval $ac_compile) 2>conftest.er1
20214   ac_status=$?
20215   grep -v '^ *+' conftest.er1 >conftest.err
20216   rm -f conftest.er1
20217   cat conftest.err >&5
20218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20219   (exit $ac_status); } &&
20220          { ac_try='test -z "$ac_c_werror_flag"
20221                          || test ! -s conftest.err'
20222   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20223   (eval $ac_try) 2>&5
20224   ac_status=$?
20225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20226   (exit $ac_status); }; } &&
20227          { ac_try='test -s conftest.$ac_objext'
20228   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20229   (eval $ac_try) 2>&5
20230   ac_status=$?
20231   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20232   (exit $ac_status); }; }; then
20233   ac_cv_type_double=yes
20234 else
20235   echo "$as_me: failed program was:" >&5
20236 sed 's/^/| /' conftest.$ac_ext >&5
20237
20238 ac_cv_type_double=no
20239 fi
20240 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20241 fi
20242 echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
20243 echo "${ECHO_T}$ac_cv_type_double" >&6
20244
20245 echo "$as_me:$LINENO: checking alignment of double" >&5
20246 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6
20247 if test "${pgac_cv_alignof_double+set}" = set; then
20248   echo $ECHO_N "(cached) $ECHO_C" >&6
20249 else
20250   if test "$ac_cv_type_double" = yes; then
20251   if test "$cross_compiling" = yes; then
20252   # Depending upon the size, compute the lo and hi bounds.
20253 cat >conftest.$ac_ext <<_ACEOF
20254 /* confdefs.h.  */
20255 _ACEOF
20256 cat confdefs.h >>conftest.$ac_ext
20257 cat >>conftest.$ac_ext <<_ACEOF
20258 /* end confdefs.h.  */
20259 $ac_includes_default
20260 struct { char filler; double field; } pgac_struct;
20261 int
20262 main ()
20263 {
20264 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
20265 test_array [0] = 0
20266
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_lo=0 ac_mid=0
20294   while :; do
20295     cat >conftest.$ac_ext <<_ACEOF
20296 /* confdefs.h.  */
20297 _ACEOF
20298 cat confdefs.h >>conftest.$ac_ext
20299 cat >>conftest.$ac_ext <<_ACEOF
20300 /* end confdefs.h.  */
20301 $ac_includes_default
20302 struct { char filler; double field; } pgac_struct;
20303 int
20304 main ()
20305 {
20306 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
20307 test_array [0] = 0
20308
20309   ;
20310   return 0;
20311 }
20312 _ACEOF
20313 rm -f conftest.$ac_objext
20314 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20315   (eval $ac_compile) 2>conftest.er1
20316   ac_status=$?
20317   grep -v '^ *+' conftest.er1 >conftest.err
20318   rm -f conftest.er1
20319   cat conftest.err >&5
20320   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20321   (exit $ac_status); } &&
20322          { ac_try='test -z "$ac_c_werror_flag"
20323                          || test ! -s conftest.err'
20324   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20325   (eval $ac_try) 2>&5
20326   ac_status=$?
20327   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20328   (exit $ac_status); }; } &&
20329          { ac_try='test -s conftest.$ac_objext'
20330   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20331   (eval $ac_try) 2>&5
20332   ac_status=$?
20333   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20334   (exit $ac_status); }; }; then
20335   ac_hi=$ac_mid; break
20336 else
20337   echo "$as_me: failed program was:" >&5
20338 sed 's/^/| /' conftest.$ac_ext >&5
20339
20340 ac_lo=`expr $ac_mid + 1`
20341                     if test $ac_lo -le $ac_mid; then
20342                       ac_lo= ac_hi=
20343                       break
20344                     fi
20345                     ac_mid=`expr 2 '*' $ac_mid + 1`
20346 fi
20347 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20348   done
20349 else
20350   echo "$as_me: failed program was:" >&5
20351 sed 's/^/| /' conftest.$ac_ext >&5
20352
20353 cat >conftest.$ac_ext <<_ACEOF
20354 /* confdefs.h.  */
20355 _ACEOF
20356 cat confdefs.h >>conftest.$ac_ext
20357 cat >>conftest.$ac_ext <<_ACEOF
20358 /* end confdefs.h.  */
20359 $ac_includes_default
20360 struct { char filler; double field; } pgac_struct;
20361 int
20362 main ()
20363 {
20364 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
20365 test_array [0] = 0
20366
20367   ;
20368   return 0;
20369 }
20370 _ACEOF
20371 rm -f conftest.$ac_objext
20372 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20373   (eval $ac_compile) 2>conftest.er1
20374   ac_status=$?
20375   grep -v '^ *+' conftest.er1 >conftest.err
20376   rm -f conftest.er1
20377   cat conftest.err >&5
20378   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20379   (exit $ac_status); } &&
20380          { ac_try='test -z "$ac_c_werror_flag"
20381                          || test ! -s conftest.err'
20382   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20383   (eval $ac_try) 2>&5
20384   ac_status=$?
20385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20386   (exit $ac_status); }; } &&
20387          { ac_try='test -s conftest.$ac_objext'
20388   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20389   (eval $ac_try) 2>&5
20390   ac_status=$?
20391   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20392   (exit $ac_status); }; }; then
20393   ac_hi=-1 ac_mid=-1
20394   while :; do
20395     cat >conftest.$ac_ext <<_ACEOF
20396 /* confdefs.h.  */
20397 _ACEOF
20398 cat confdefs.h >>conftest.$ac_ext
20399 cat >>conftest.$ac_ext <<_ACEOF
20400 /* end confdefs.h.  */
20401 $ac_includes_default
20402 struct { char filler; double field; } pgac_struct;
20403 int
20404 main ()
20405 {
20406 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
20407 test_array [0] = 0
20408
20409   ;
20410   return 0;
20411 }
20412 _ACEOF
20413 rm -f conftest.$ac_objext
20414 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20415   (eval $ac_compile) 2>conftest.er1
20416   ac_status=$?
20417   grep -v '^ *+' conftest.er1 >conftest.err
20418   rm -f conftest.er1
20419   cat conftest.err >&5
20420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20421   (exit $ac_status); } &&
20422          { ac_try='test -z "$ac_c_werror_flag"
20423                          || test ! -s conftest.err'
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); }; } &&
20429          { ac_try='test -s conftest.$ac_objext'
20430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20431   (eval $ac_try) 2>&5
20432   ac_status=$?
20433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20434   (exit $ac_status); }; }; then
20435   ac_lo=$ac_mid; break
20436 else
20437   echo "$as_me: failed program was:" >&5
20438 sed 's/^/| /' conftest.$ac_ext >&5
20439
20440 ac_hi=`expr '(' $ac_mid ')' - 1`
20441                        if test $ac_mid -le $ac_hi; then
20442                          ac_lo= ac_hi=
20443                          break
20444                        fi
20445                        ac_mid=`expr 2 '*' $ac_mid`
20446 fi
20447 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20448   done
20449 else
20450   echo "$as_me: failed program was:" >&5
20451 sed 's/^/| /' conftest.$ac_ext >&5
20452
20453 ac_lo= ac_hi=
20454 fi
20455 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20456 fi
20457 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20458 # Binary search between lo and hi bounds.
20459 while test "x$ac_lo" != "x$ac_hi"; do
20460   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20461   cat >conftest.$ac_ext <<_ACEOF
20462 /* confdefs.h.  */
20463 _ACEOF
20464 cat confdefs.h >>conftest.$ac_ext
20465 cat >>conftest.$ac_ext <<_ACEOF
20466 /* end confdefs.h.  */
20467 $ac_includes_default
20468 struct { char filler; double field; } pgac_struct;
20469 int
20470 main ()
20471 {
20472 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
20473 test_array [0] = 0
20474
20475   ;
20476   return 0;
20477 }
20478 _ACEOF
20479 rm -f conftest.$ac_objext
20480 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20481   (eval $ac_compile) 2>conftest.er1
20482   ac_status=$?
20483   grep -v '^ *+' conftest.er1 >conftest.err
20484   rm -f conftest.er1
20485   cat conftest.err >&5
20486   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20487   (exit $ac_status); } &&
20488          { ac_try='test -z "$ac_c_werror_flag"
20489                          || test ! -s conftest.err'
20490   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20491   (eval $ac_try) 2>&5
20492   ac_status=$?
20493   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20494   (exit $ac_status); }; } &&
20495          { ac_try='test -s conftest.$ac_objext'
20496   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20497   (eval $ac_try) 2>&5
20498   ac_status=$?
20499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20500   (exit $ac_status); }; }; then
20501   ac_hi=$ac_mid
20502 else
20503   echo "$as_me: failed program was:" >&5
20504 sed 's/^/| /' conftest.$ac_ext >&5
20505
20506 ac_lo=`expr '(' $ac_mid ')' + 1`
20507 fi
20508 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20509 done
20510 case $ac_lo in
20511 ?*) pgac_cv_alignof_double=$ac_lo;;
20512 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
20513 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
20514    { (exit 1); exit 1; }; } ;;
20515 esac
20516 else
20517   if test "$cross_compiling" = yes; then
20518   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
20519 See \`config.log' for more details." >&5
20520 echo "$as_me: error: cannot run test program while cross compiling
20521 See \`config.log' for more details." >&2;}
20522    { (exit 1); exit 1; }; }
20523 else
20524   cat >conftest.$ac_ext <<_ACEOF
20525 /* confdefs.h.  */
20526 _ACEOF
20527 cat confdefs.h >>conftest.$ac_ext
20528 cat >>conftest.$ac_ext <<_ACEOF
20529 /* end confdefs.h.  */
20530 $ac_includes_default
20531 struct { char filler; double field; } pgac_struct;
20532 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20533 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20534 #include <stdio.h>
20535 #include <stdlib.h>
20536 int
20537 main ()
20538 {
20539
20540   FILE *f = fopen ("conftest.val", "w");
20541   if (! f)
20542     exit (1);
20543   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
20544     {
20545       long i = longval ();
20546       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20547         exit (1);
20548       fprintf (f, "%ld\n", i);
20549     }
20550   else
20551     {
20552       unsigned long i = ulongval ();
20553       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20554         exit (1);
20555       fprintf (f, "%lu\n", i);
20556     }
20557   exit (ferror (f) || fclose (f) != 0);
20558
20559   ;
20560   return 0;
20561 }
20562 _ACEOF
20563 rm -f conftest$ac_exeext
20564 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20565   (eval $ac_link) 2>&5
20566   ac_status=$?
20567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20568   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20569   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20570   (eval $ac_try) 2>&5
20571   ac_status=$?
20572   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20573   (exit $ac_status); }; }; then
20574   pgac_cv_alignof_double=`cat conftest.val`
20575 else
20576   echo "$as_me: program exited with status $ac_status" >&5
20577 echo "$as_me: failed program was:" >&5
20578 sed 's/^/| /' conftest.$ac_ext >&5
20579
20580 ( exit $ac_status )
20581 { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
20582 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
20583    { (exit 1); exit 1; }; }
20584 fi
20585 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20586 fi
20587 fi
20588 rm -f conftest.val
20589 else
20590   pgac_cv_alignof_double=0
20591 fi
20592 fi
20593 echo "$as_me:$LINENO: result: $pgac_cv_alignof_double" >&5
20594 echo "${ECHO_T}$pgac_cv_alignof_double" >&6
20595 cat >>confdefs.h <<_ACEOF
20596 #define ALIGNOF_DOUBLE $pgac_cv_alignof_double
20597 _ACEOF
20598
20599
20600
20601 # Compute maximum alignment of any basic type.
20602 # We assume long's alignment is at least as strong as char, short, or int;
20603 # but we must check long long (if it exists) and double.
20604
20605 MAX_ALIGNOF=$pgac_cv_alignof_long
20606 if test $MAX_ALIGNOF -lt $pgac_cv_alignof_double ; then
20607   MAX_ALIGNOF=$pgac_cv_alignof_double
20608 fi
20609 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $pgac_cv_alignof_long_long_int ; then
20610   MAX_ALIGNOF="$pgac_cv_alignof_long_long_int"
20611 fi
20612
20613 cat >>confdefs.h <<_ACEOF
20614 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
20615 _ACEOF
20616
20617
20618
20619 # Some platforms predefine the types int8, int16, etc.  Only check
20620 # a (hopefully) representative subset.
20621 echo "$as_me:$LINENO: checking for int8" >&5
20622 echo $ECHO_N "checking for int8... $ECHO_C" >&6
20623 if test "${ac_cv_type_int8+set}" = set; then
20624   echo $ECHO_N "(cached) $ECHO_C" >&6
20625 else
20626   cat >conftest.$ac_ext <<_ACEOF
20627 /* confdefs.h.  */
20628 _ACEOF
20629 cat confdefs.h >>conftest.$ac_ext
20630 cat >>conftest.$ac_ext <<_ACEOF
20631 /* end confdefs.h.  */
20632 #include <stdio.h>
20633 #ifdef HAVE_SUPPORTDEFS_H
20634 #include <SupportDefs.h>
20635 #endif
20636
20637 int
20638 main ()
20639 {
20640 if ((int8 *) 0)
20641   return 0;
20642 if (sizeof (int8))
20643   return 0;
20644   ;
20645   return 0;
20646 }
20647 _ACEOF
20648 rm -f conftest.$ac_objext
20649 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20650   (eval $ac_compile) 2>conftest.er1
20651   ac_status=$?
20652   grep -v '^ *+' conftest.er1 >conftest.err
20653   rm -f conftest.er1
20654   cat conftest.err >&5
20655   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20656   (exit $ac_status); } &&
20657          { ac_try='test -z "$ac_c_werror_flag"
20658                          || test ! -s conftest.err'
20659   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20660   (eval $ac_try) 2>&5
20661   ac_status=$?
20662   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20663   (exit $ac_status); }; } &&
20664          { ac_try='test -s conftest.$ac_objext'
20665   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20666   (eval $ac_try) 2>&5
20667   ac_status=$?
20668   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20669   (exit $ac_status); }; }; then
20670   ac_cv_type_int8=yes
20671 else
20672   echo "$as_me: failed program was:" >&5
20673 sed 's/^/| /' conftest.$ac_ext >&5
20674
20675 ac_cv_type_int8=no
20676 fi
20677 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20678 fi
20679 echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
20680 echo "${ECHO_T}$ac_cv_type_int8" >&6
20681 if test $ac_cv_type_int8 = yes; then
20682
20683 cat >>confdefs.h <<_ACEOF
20684 #define HAVE_INT8 1
20685 _ACEOF
20686
20687
20688 fi
20689 echo "$as_me:$LINENO: checking for uint8" >&5
20690 echo $ECHO_N "checking for uint8... $ECHO_C" >&6
20691 if test "${ac_cv_type_uint8+set}" = set; then
20692   echo $ECHO_N "(cached) $ECHO_C" >&6
20693 else
20694   cat >conftest.$ac_ext <<_ACEOF
20695 /* confdefs.h.  */
20696 _ACEOF
20697 cat confdefs.h >>conftest.$ac_ext
20698 cat >>conftest.$ac_ext <<_ACEOF
20699 /* end confdefs.h.  */
20700 #include <stdio.h>
20701 #ifdef HAVE_SUPPORTDEFS_H
20702 #include <SupportDefs.h>
20703 #endif
20704
20705 int
20706 main ()
20707 {
20708 if ((uint8 *) 0)
20709   return 0;
20710 if (sizeof (uint8))
20711   return 0;
20712   ;
20713   return 0;
20714 }
20715 _ACEOF
20716 rm -f conftest.$ac_objext
20717 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20718   (eval $ac_compile) 2>conftest.er1
20719   ac_status=$?
20720   grep -v '^ *+' conftest.er1 >conftest.err
20721   rm -f conftest.er1
20722   cat conftest.err >&5
20723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20724   (exit $ac_status); } &&
20725          { ac_try='test -z "$ac_c_werror_flag"
20726                          || test ! -s conftest.err'
20727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20728   (eval $ac_try) 2>&5
20729   ac_status=$?
20730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20731   (exit $ac_status); }; } &&
20732          { ac_try='test -s conftest.$ac_objext'
20733   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20734   (eval $ac_try) 2>&5
20735   ac_status=$?
20736   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20737   (exit $ac_status); }; }; then
20738   ac_cv_type_uint8=yes
20739 else
20740   echo "$as_me: failed program was:" >&5
20741 sed 's/^/| /' conftest.$ac_ext >&5
20742
20743 ac_cv_type_uint8=no
20744 fi
20745 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20746 fi
20747 echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
20748 echo "${ECHO_T}$ac_cv_type_uint8" >&6
20749 if test $ac_cv_type_uint8 = yes; then
20750
20751 cat >>confdefs.h <<_ACEOF
20752 #define HAVE_UINT8 1
20753 _ACEOF
20754
20755
20756 fi
20757 echo "$as_me:$LINENO: checking for int64" >&5
20758 echo $ECHO_N "checking for int64... $ECHO_C" >&6
20759 if test "${ac_cv_type_int64+set}" = set; then
20760   echo $ECHO_N "(cached) $ECHO_C" >&6
20761 else
20762   cat >conftest.$ac_ext <<_ACEOF
20763 /* confdefs.h.  */
20764 _ACEOF
20765 cat confdefs.h >>conftest.$ac_ext
20766 cat >>conftest.$ac_ext <<_ACEOF
20767 /* end confdefs.h.  */
20768 #include <stdio.h>
20769 #ifdef HAVE_SUPPORTDEFS_H
20770 #include <SupportDefs.h>
20771 #endif
20772
20773 int
20774 main ()
20775 {
20776 if ((int64 *) 0)
20777   return 0;
20778 if (sizeof (int64))
20779   return 0;
20780   ;
20781   return 0;
20782 }
20783 _ACEOF
20784 rm -f conftest.$ac_objext
20785 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20786   (eval $ac_compile) 2>conftest.er1
20787   ac_status=$?
20788   grep -v '^ *+' conftest.er1 >conftest.err
20789   rm -f conftest.er1
20790   cat conftest.err >&5
20791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20792   (exit $ac_status); } &&
20793          { ac_try='test -z "$ac_c_werror_flag"
20794                          || test ! -s conftest.err'
20795   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20796   (eval $ac_try) 2>&5
20797   ac_status=$?
20798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20799   (exit $ac_status); }; } &&
20800          { ac_try='test -s conftest.$ac_objext'
20801   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20802   (eval $ac_try) 2>&5
20803   ac_status=$?
20804   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20805   (exit $ac_status); }; }; then
20806   ac_cv_type_int64=yes
20807 else
20808   echo "$as_me: failed program was:" >&5
20809 sed 's/^/| /' conftest.$ac_ext >&5
20810
20811 ac_cv_type_int64=no
20812 fi
20813 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20814 fi
20815 echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
20816 echo "${ECHO_T}$ac_cv_type_int64" >&6
20817 if test $ac_cv_type_int64 = yes; then
20818
20819 cat >>confdefs.h <<_ACEOF
20820 #define HAVE_INT64 1
20821 _ACEOF
20822
20823
20824 fi
20825 echo "$as_me:$LINENO: checking for uint64" >&5
20826 echo $ECHO_N "checking for uint64... $ECHO_C" >&6
20827 if test "${ac_cv_type_uint64+set}" = set; then
20828   echo $ECHO_N "(cached) $ECHO_C" >&6
20829 else
20830   cat >conftest.$ac_ext <<_ACEOF
20831 /* confdefs.h.  */
20832 _ACEOF
20833 cat confdefs.h >>conftest.$ac_ext
20834 cat >>conftest.$ac_ext <<_ACEOF
20835 /* end confdefs.h.  */
20836 #include <stdio.h>
20837 #ifdef HAVE_SUPPORTDEFS_H
20838 #include <SupportDefs.h>
20839 #endif
20840
20841 int
20842 main ()
20843 {
20844 if ((uint64 *) 0)
20845   return 0;
20846 if (sizeof (uint64))
20847   return 0;
20848   ;
20849   return 0;
20850 }
20851 _ACEOF
20852 rm -f conftest.$ac_objext
20853 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20854   (eval $ac_compile) 2>conftest.er1
20855   ac_status=$?
20856   grep -v '^ *+' conftest.er1 >conftest.err
20857   rm -f conftest.er1
20858   cat conftest.err >&5
20859   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20860   (exit $ac_status); } &&
20861          { ac_try='test -z "$ac_c_werror_flag"
20862                          || test ! -s conftest.err'
20863   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20864   (eval $ac_try) 2>&5
20865   ac_status=$?
20866   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20867   (exit $ac_status); }; } &&
20868          { ac_try='test -s conftest.$ac_objext'
20869   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20870   (eval $ac_try) 2>&5
20871   ac_status=$?
20872   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20873   (exit $ac_status); }; }; then
20874   ac_cv_type_uint64=yes
20875 else
20876   echo "$as_me: failed program was:" >&5
20877 sed 's/^/| /' conftest.$ac_ext >&5
20878
20879 ac_cv_type_uint64=no
20880 fi
20881 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20882 fi
20883 echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
20884 echo "${ECHO_T}$ac_cv_type_uint64" >&6
20885 if test $ac_cv_type_uint64 = yes; then
20886
20887 cat >>confdefs.h <<_ACEOF
20888 #define HAVE_UINT64 1
20889 _ACEOF
20890
20891
20892 fi
20893
20894
20895 # We also check for sig_atomic_t, which *should* be defined per ANSI
20896 # C, but is missing on some old platforms.
20897 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
20898 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
20899 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
20900   echo $ECHO_N "(cached) $ECHO_C" >&6
20901 else
20902   cat >conftest.$ac_ext <<_ACEOF
20903 /* confdefs.h.  */
20904 _ACEOF
20905 cat confdefs.h >>conftest.$ac_ext
20906 cat >>conftest.$ac_ext <<_ACEOF
20907 /* end confdefs.h.  */
20908 #include <signal.h>
20909
20910 int
20911 main ()
20912 {
20913 if ((sig_atomic_t *) 0)
20914   return 0;
20915 if (sizeof (sig_atomic_t))
20916   return 0;
20917   ;
20918   return 0;
20919 }
20920 _ACEOF
20921 rm -f conftest.$ac_objext
20922 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20923   (eval $ac_compile) 2>conftest.er1
20924   ac_status=$?
20925   grep -v '^ *+' conftest.er1 >conftest.err
20926   rm -f conftest.er1
20927   cat conftest.err >&5
20928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20929   (exit $ac_status); } &&
20930          { ac_try='test -z "$ac_c_werror_flag"
20931                          || test ! -s conftest.err'
20932   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20933   (eval $ac_try) 2>&5
20934   ac_status=$?
20935   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20936   (exit $ac_status); }; } &&
20937          { ac_try='test -s conftest.$ac_objext'
20938   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20939   (eval $ac_try) 2>&5
20940   ac_status=$?
20941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20942   (exit $ac_status); }; }; then
20943   ac_cv_type_sig_atomic_t=yes
20944 else
20945   echo "$as_me: failed program was:" >&5
20946 sed 's/^/| /' conftest.$ac_ext >&5
20947
20948 ac_cv_type_sig_atomic_t=no
20949 fi
20950 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20951 fi
20952 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
20953 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
20954 if test $ac_cv_type_sig_atomic_t = yes; then
20955
20956 cat >>confdefs.h <<_ACEOF
20957 #define HAVE_SIG_ATOMIC_T 1
20958 _ACEOF
20959
20960
20961 fi
20962
20963
20964
20965 if test x"$template" != x"win32"
20966 then
20967 echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
20968 echo $ECHO_N "checking for POSIX signal interface... $ECHO_C" >&6
20969 if test "${pgac_cv_func_posix_signals+set}" = set; then
20970   echo $ECHO_N "(cached) $ECHO_C" >&6
20971 else
20972   cat >conftest.$ac_ext <<_ACEOF
20973 /* confdefs.h.  */
20974 _ACEOF
20975 cat confdefs.h >>conftest.$ac_ext
20976 cat >>conftest.$ac_ext <<_ACEOF
20977 /* end confdefs.h.  */
20978 #include <signal.h>
20979
20980 int
20981 main ()
20982 {
20983 struct sigaction act, oact;
20984 sigemptyset(&act.sa_mask);
20985 act.sa_flags = SA_RESTART;
20986 sigaction(0, &act, &oact);
20987   ;
20988   return 0;
20989 }
20990 _ACEOF
20991 rm -f conftest.$ac_objext conftest$ac_exeext
20992 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20993   (eval $ac_link) 2>conftest.er1
20994   ac_status=$?
20995   grep -v '^ *+' conftest.er1 >conftest.err
20996   rm -f conftest.er1
20997   cat conftest.err >&5
20998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20999   (exit $ac_status); } &&
21000          { ac_try='test -z "$ac_c_werror_flag"
21001                          || test ! -s conftest.err'
21002   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21003   (eval $ac_try) 2>&5
21004   ac_status=$?
21005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21006   (exit $ac_status); }; } &&
21007          { ac_try='test -s conftest$ac_exeext'
21008   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21009   (eval $ac_try) 2>&5
21010   ac_status=$?
21011   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21012   (exit $ac_status); }; }; then
21013   pgac_cv_func_posix_signals=yes
21014 else
21015   echo "$as_me: failed program was:" >&5
21016 sed 's/^/| /' conftest.$ac_ext >&5
21017
21018 pgac_cv_func_posix_signals=no
21019 fi
21020 rm -f conftest.err conftest.$ac_objext \
21021       conftest$ac_exeext conftest.$ac_ext
21022 fi
21023 echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
21024 echo "${ECHO_T}$pgac_cv_func_posix_signals" >&6
21025 if test x"$pgac_cv_func_posix_signals" = xyes ; then
21026
21027 cat >>confdefs.h <<\_ACEOF
21028 #define HAVE_POSIX_SIGNALS
21029 _ACEOF
21030
21031 fi
21032 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
21033
21034 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
21035   { { echo "$as_me:$LINENO: error:
21036 *** Thread-safety requires POSIX signals, which are not supported by your
21037 *** operating system.
21038 " >&5
21039 echo "$as_me: error:
21040 *** Thread-safety requires POSIX signals, which are not supported by your
21041 *** operating system.
21042 " >&2;}
21043    { (exit 1); exit 1; }; }
21044 fi
21045 fi
21046
21047 if test $ac_cv_func_fseeko = yes; then
21048 # Check whether --enable-largefile or --disable-largefile was given.
21049 if test "${enable_largefile+set}" = set; then
21050   enableval="$enable_largefile"
21051
21052 fi;
21053 if test "$enable_largefile" != no; then
21054
21055   echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
21056 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
21057 if test "${ac_cv_sys_largefile_CC+set}" = set; then
21058   echo $ECHO_N "(cached) $ECHO_C" >&6
21059 else
21060   ac_cv_sys_largefile_CC=no
21061      if test "$GCC" != yes; then
21062        ac_save_CC=$CC
21063        while :; do
21064          # IRIX 6.2 and later do not support large files by default,
21065          # so use the C compiler's -n32 option if that helps.
21066          cat >conftest.$ac_ext <<_ACEOF
21067 /* confdefs.h.  */
21068 _ACEOF
21069 cat confdefs.h >>conftest.$ac_ext
21070 cat >>conftest.$ac_ext <<_ACEOF
21071 /* end confdefs.h.  */
21072 #include <sys/types.h>
21073  /* Check that off_t can represent 2**63 - 1 correctly.
21074     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21075     since some C++ compilers masquerading as C compilers
21076     incorrectly reject 9223372036854775807.  */
21077 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21078   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21079                        && LARGE_OFF_T % 2147483647 == 1)
21080                       ? 1 : -1];
21081 int
21082 main ()
21083 {
21084
21085   ;
21086   return 0;
21087 }
21088 _ACEOF
21089          rm -f conftest.$ac_objext
21090 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21091   (eval $ac_compile) 2>conftest.er1
21092   ac_status=$?
21093   grep -v '^ *+' conftest.er1 >conftest.err
21094   rm -f conftest.er1
21095   cat conftest.err >&5
21096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21097   (exit $ac_status); } &&
21098          { ac_try='test -z "$ac_c_werror_flag"
21099                          || test ! -s conftest.err'
21100   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21101   (eval $ac_try) 2>&5
21102   ac_status=$?
21103   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21104   (exit $ac_status); }; } &&
21105          { ac_try='test -s conftest.$ac_objext'
21106   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21107   (eval $ac_try) 2>&5
21108   ac_status=$?
21109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21110   (exit $ac_status); }; }; then
21111   break
21112 else
21113   echo "$as_me: failed program was:" >&5
21114 sed 's/^/| /' conftest.$ac_ext >&5
21115
21116 fi
21117 rm -f conftest.err conftest.$ac_objext
21118          CC="$CC -n32"
21119          rm -f conftest.$ac_objext
21120 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21121   (eval $ac_compile) 2>conftest.er1
21122   ac_status=$?
21123   grep -v '^ *+' conftest.er1 >conftest.err
21124   rm -f conftest.er1
21125   cat conftest.err >&5
21126   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21127   (exit $ac_status); } &&
21128          { ac_try='test -z "$ac_c_werror_flag"
21129                          || test ! -s conftest.err'
21130   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21131   (eval $ac_try) 2>&5
21132   ac_status=$?
21133   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21134   (exit $ac_status); }; } &&
21135          { ac_try='test -s conftest.$ac_objext'
21136   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21137   (eval $ac_try) 2>&5
21138   ac_status=$?
21139   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21140   (exit $ac_status); }; }; then
21141   ac_cv_sys_largefile_CC=' -n32'; break
21142 else
21143   echo "$as_me: failed program was:" >&5
21144 sed 's/^/| /' conftest.$ac_ext >&5
21145
21146 fi
21147 rm -f conftest.err conftest.$ac_objext
21148          break
21149        done
21150        CC=$ac_save_CC
21151        rm -f conftest.$ac_ext
21152     fi
21153 fi
21154 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
21155 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
21156   if test "$ac_cv_sys_largefile_CC" != no; then
21157     CC=$CC$ac_cv_sys_largefile_CC
21158   fi
21159
21160   echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
21161 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
21162 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
21163   echo $ECHO_N "(cached) $ECHO_C" >&6
21164 else
21165   while :; do
21166   ac_cv_sys_file_offset_bits=no
21167   cat >conftest.$ac_ext <<_ACEOF
21168 /* confdefs.h.  */
21169 _ACEOF
21170 cat confdefs.h >>conftest.$ac_ext
21171 cat >>conftest.$ac_ext <<_ACEOF
21172 /* end confdefs.h.  */
21173 #include <sys/types.h>
21174  /* Check that off_t can represent 2**63 - 1 correctly.
21175     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21176     since some C++ compilers masquerading as C compilers
21177     incorrectly reject 9223372036854775807.  */
21178 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21179   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21180                        && LARGE_OFF_T % 2147483647 == 1)
21181                       ? 1 : -1];
21182 int
21183 main ()
21184 {
21185
21186   ;
21187   return 0;
21188 }
21189 _ACEOF
21190 rm -f conftest.$ac_objext
21191 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21192   (eval $ac_compile) 2>conftest.er1
21193   ac_status=$?
21194   grep -v '^ *+' conftest.er1 >conftest.err
21195   rm -f conftest.er1
21196   cat conftest.err >&5
21197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21198   (exit $ac_status); } &&
21199          { ac_try='test -z "$ac_c_werror_flag"
21200                          || test ! -s conftest.err'
21201   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21202   (eval $ac_try) 2>&5
21203   ac_status=$?
21204   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21205   (exit $ac_status); }; } &&
21206          { ac_try='test -s conftest.$ac_objext'
21207   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21208   (eval $ac_try) 2>&5
21209   ac_status=$?
21210   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21211   (exit $ac_status); }; }; then
21212   break
21213 else
21214   echo "$as_me: failed program was:" >&5
21215 sed 's/^/| /' conftest.$ac_ext >&5
21216
21217 fi
21218 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21219   cat >conftest.$ac_ext <<_ACEOF
21220 /* confdefs.h.  */
21221 _ACEOF
21222 cat confdefs.h >>conftest.$ac_ext
21223 cat >>conftest.$ac_ext <<_ACEOF
21224 /* end confdefs.h.  */
21225 #define _FILE_OFFSET_BITS 64
21226 #include <sys/types.h>
21227  /* Check that off_t can represent 2**63 - 1 correctly.
21228     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21229     since some C++ compilers masquerading as C compilers
21230     incorrectly reject 9223372036854775807.  */
21231 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21232   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21233                        && LARGE_OFF_T % 2147483647 == 1)
21234                       ? 1 : -1];
21235 int
21236 main ()
21237 {
21238
21239   ;
21240   return 0;
21241 }
21242 _ACEOF
21243 rm -f conftest.$ac_objext
21244 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21245   (eval $ac_compile) 2>conftest.er1
21246   ac_status=$?
21247   grep -v '^ *+' conftest.er1 >conftest.err
21248   rm -f conftest.er1
21249   cat conftest.err >&5
21250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21251   (exit $ac_status); } &&
21252          { ac_try='test -z "$ac_c_werror_flag"
21253                          || test ! -s conftest.err'
21254   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21255   (eval $ac_try) 2>&5
21256   ac_status=$?
21257   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21258   (exit $ac_status); }; } &&
21259          { ac_try='test -s conftest.$ac_objext'
21260   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21261   (eval $ac_try) 2>&5
21262   ac_status=$?
21263   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21264   (exit $ac_status); }; }; then
21265   ac_cv_sys_file_offset_bits=64; break
21266 else
21267   echo "$as_me: failed program was:" >&5
21268 sed 's/^/| /' conftest.$ac_ext >&5
21269
21270 fi
21271 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21272   break
21273 done
21274 fi
21275 echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
21276 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
21277 if test "$ac_cv_sys_file_offset_bits" != no; then
21278
21279 cat >>confdefs.h <<_ACEOF
21280 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
21281 _ACEOF
21282
21283 fi
21284 rm -f conftest*
21285   echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
21286 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
21287 if test "${ac_cv_sys_large_files+set}" = set; then
21288   echo $ECHO_N "(cached) $ECHO_C" >&6
21289 else
21290   while :; do
21291   ac_cv_sys_large_files=no
21292   cat >conftest.$ac_ext <<_ACEOF
21293 /* confdefs.h.  */
21294 _ACEOF
21295 cat confdefs.h >>conftest.$ac_ext
21296 cat >>conftest.$ac_ext <<_ACEOF
21297 /* end confdefs.h.  */
21298 #include <sys/types.h>
21299  /* Check that off_t can represent 2**63 - 1 correctly.
21300     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21301     since some C++ compilers masquerading as C compilers
21302     incorrectly reject 9223372036854775807.  */
21303 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21304   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21305                        && LARGE_OFF_T % 2147483647 == 1)
21306                       ? 1 : -1];
21307 int
21308 main ()
21309 {
21310
21311   ;
21312   return 0;
21313 }
21314 _ACEOF
21315 rm -f conftest.$ac_objext
21316 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21317   (eval $ac_compile) 2>conftest.er1
21318   ac_status=$?
21319   grep -v '^ *+' conftest.er1 >conftest.err
21320   rm -f conftest.er1
21321   cat conftest.err >&5
21322   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21323   (exit $ac_status); } &&
21324          { ac_try='test -z "$ac_c_werror_flag"
21325                          || test ! -s conftest.err'
21326   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21327   (eval $ac_try) 2>&5
21328   ac_status=$?
21329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21330   (exit $ac_status); }; } &&
21331          { ac_try='test -s conftest.$ac_objext'
21332   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21333   (eval $ac_try) 2>&5
21334   ac_status=$?
21335   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21336   (exit $ac_status); }; }; then
21337   break
21338 else
21339   echo "$as_me: failed program was:" >&5
21340 sed 's/^/| /' conftest.$ac_ext >&5
21341
21342 fi
21343 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21344   cat >conftest.$ac_ext <<_ACEOF
21345 /* confdefs.h.  */
21346 _ACEOF
21347 cat confdefs.h >>conftest.$ac_ext
21348 cat >>conftest.$ac_ext <<_ACEOF
21349 /* end confdefs.h.  */
21350 #define _LARGE_FILES 1
21351 #include <sys/types.h>
21352  /* Check that off_t can represent 2**63 - 1 correctly.
21353     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21354     since some C++ compilers masquerading as C compilers
21355     incorrectly reject 9223372036854775807.  */
21356 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21357   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21358                        && LARGE_OFF_T % 2147483647 == 1)
21359                       ? 1 : -1];
21360 int
21361 main ()
21362 {
21363
21364   ;
21365   return 0;
21366 }
21367 _ACEOF
21368 rm -f conftest.$ac_objext
21369 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21370   (eval $ac_compile) 2>conftest.er1
21371   ac_status=$?
21372   grep -v '^ *+' conftest.er1 >conftest.err
21373   rm -f conftest.er1
21374   cat conftest.err >&5
21375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21376   (exit $ac_status); } &&
21377          { ac_try='test -z "$ac_c_werror_flag"
21378                          || test ! -s conftest.err'
21379   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21380   (eval $ac_try) 2>&5
21381   ac_status=$?
21382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21383   (exit $ac_status); }; } &&
21384          { ac_try='test -s conftest.$ac_objext'
21385   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21386   (eval $ac_try) 2>&5
21387   ac_status=$?
21388   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21389   (exit $ac_status); }; }; then
21390   ac_cv_sys_large_files=1; break
21391 else
21392   echo "$as_me: failed program was:" >&5
21393 sed 's/^/| /' conftest.$ac_ext >&5
21394
21395 fi
21396 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21397   break
21398 done
21399 fi
21400 echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
21401 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
21402 if test "$ac_cv_sys_large_files" != no; then
21403
21404 cat >>confdefs.h <<_ACEOF
21405 #define _LARGE_FILES $ac_cv_sys_large_files
21406 _ACEOF
21407
21408 fi
21409 rm -f conftest*
21410 fi
21411
21412 fi
21413
21414 # SunOS doesn't handle negative byte comparisons properly with +/- return
21415 echo "$as_me:$LINENO: checking for working memcmp" >&5
21416 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
21417 if test "${ac_cv_func_memcmp_working+set}" = set; then
21418   echo $ECHO_N "(cached) $ECHO_C" >&6
21419 else
21420   if test "$cross_compiling" = yes; then
21421   ac_cv_func_memcmp_working=no
21422 else
21423   cat >conftest.$ac_ext <<_ACEOF
21424 /* confdefs.h.  */
21425 _ACEOF
21426 cat confdefs.h >>conftest.$ac_ext
21427 cat >>conftest.$ac_ext <<_ACEOF
21428 /* end confdefs.h.  */
21429 $ac_includes_default
21430 int
21431 main ()
21432 {
21433
21434   /* Some versions of memcmp are not 8-bit clean.  */
21435   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
21436   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
21437     exit (1);
21438
21439   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
21440      or more and with at least one buffer not starting on a 4-byte boundary.
21441      William Lewis provided this test program.   */
21442   {
21443     char foo[21];
21444     char bar[21];
21445     int i;
21446     for (i = 0; i < 4; i++)
21447       {
21448         char *a = foo + i;
21449         char *b = bar + i;
21450         strcpy (a, "--------01111111");
21451         strcpy (b, "--------10000000");
21452         if (memcmp (a, b, 16) >= 0)
21453           exit (1);
21454       }
21455     exit (0);
21456   }
21457
21458   ;
21459   return 0;
21460 }
21461 _ACEOF
21462 rm -f conftest$ac_exeext
21463 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21464   (eval $ac_link) 2>&5
21465   ac_status=$?
21466   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21467   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21468   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21469   (eval $ac_try) 2>&5
21470   ac_status=$?
21471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21472   (exit $ac_status); }; }; then
21473   ac_cv_func_memcmp_working=yes
21474 else
21475   echo "$as_me: program exited with status $ac_status" >&5
21476 echo "$as_me: failed program was:" >&5
21477 sed 's/^/| /' conftest.$ac_ext >&5
21478
21479 ( exit $ac_status )
21480 ac_cv_func_memcmp_working=no
21481 fi
21482 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21483 fi
21484 fi
21485 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
21486 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
21487 test $ac_cv_func_memcmp_working = no && case $LIBOBJS in
21488     "memcmp.$ac_objext"   | \
21489   *" memcmp.$ac_objext"   | \
21490     "memcmp.$ac_objext "* | \
21491   *" memcmp.$ac_objext "* ) ;;
21492   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" ;;
21493 esac
21494
21495
21496
21497
21498 # Select semaphore implementation type.
21499 if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
21500
21501 cat >>confdefs.h <<\_ACEOF
21502 #define USE_NAMED_POSIX_SEMAPHORES 1
21503 _ACEOF
21504
21505   SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21506 else
21507   if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
21508
21509 cat >>confdefs.h <<\_ACEOF
21510 #define USE_UNNAMED_POSIX_SEMAPHORES 1
21511 _ACEOF
21512
21513     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21514   else
21515
21516 cat >>confdefs.h <<\_ACEOF
21517 #define USE_SYSV_SEMAPHORES 1
21518 _ACEOF
21519
21520     SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
21521   fi
21522 fi
21523
21524
21525 # Select shared-memory implementation type.
21526
21527 cat >>confdefs.h <<\_ACEOF
21528 #define USE_SYSV_SHARED_MEMORY 1
21529 _ACEOF
21530
21531 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
21532
21533
21534 # If not set in template file, set bytes to use libc memset()
21535 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
21536   MEMSET_LOOP_LIMIT=1024
21537 fi
21538
21539 cat >>confdefs.h <<_ACEOF
21540 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
21541 _ACEOF
21542
21543
21544
21545 if test "$enable_nls" = yes ; then
21546
21547   echo "$as_me:$LINENO: checking for library containing gettext" >&5
21548 echo $ECHO_N "checking for library containing gettext... $ECHO_C" >&6
21549 if test "${ac_cv_search_gettext+set}" = set; then
21550   echo $ECHO_N "(cached) $ECHO_C" >&6
21551 else
21552   ac_func_search_save_LIBS=$LIBS
21553 ac_cv_search_gettext=no
21554 cat >conftest.$ac_ext <<_ACEOF
21555 /* confdefs.h.  */
21556 _ACEOF
21557 cat confdefs.h >>conftest.$ac_ext
21558 cat >>conftest.$ac_ext <<_ACEOF
21559 /* end confdefs.h.  */
21560
21561 /* Override any gcc2 internal prototype to avoid an error.  */
21562 #ifdef __cplusplus
21563 extern "C"
21564 #endif
21565 /* We use char because int might match the return type of a gcc2
21566    builtin and then its argument prototype would still apply.  */
21567 char gettext ();
21568 int
21569 main ()
21570 {
21571 gettext ();
21572   ;
21573   return 0;
21574 }
21575 _ACEOF
21576 rm -f conftest.$ac_objext conftest$ac_exeext
21577 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21578   (eval $ac_link) 2>conftest.er1
21579   ac_status=$?
21580   grep -v '^ *+' conftest.er1 >conftest.err
21581   rm -f conftest.er1
21582   cat conftest.err >&5
21583   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21584   (exit $ac_status); } &&
21585          { ac_try='test -z "$ac_c_werror_flag"
21586                          || test ! -s conftest.err'
21587   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21588   (eval $ac_try) 2>&5
21589   ac_status=$?
21590   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21591   (exit $ac_status); }; } &&
21592          { ac_try='test -s conftest$ac_exeext'
21593   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21594   (eval $ac_try) 2>&5
21595   ac_status=$?
21596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21597   (exit $ac_status); }; }; then
21598   ac_cv_search_gettext="none required"
21599 else
21600   echo "$as_me: failed program was:" >&5
21601 sed 's/^/| /' conftest.$ac_ext >&5
21602
21603 fi
21604 rm -f conftest.err conftest.$ac_objext \
21605       conftest$ac_exeext conftest.$ac_ext
21606 if test "$ac_cv_search_gettext" = no; then
21607   for ac_lib in intl; do
21608     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21609     cat >conftest.$ac_ext <<_ACEOF
21610 /* confdefs.h.  */
21611 _ACEOF
21612 cat confdefs.h >>conftest.$ac_ext
21613 cat >>conftest.$ac_ext <<_ACEOF
21614 /* end confdefs.h.  */
21615
21616 /* Override any gcc2 internal prototype to avoid an error.  */
21617 #ifdef __cplusplus
21618 extern "C"
21619 #endif
21620 /* We use char because int might match the return type of a gcc2
21621    builtin and then its argument prototype would still apply.  */
21622 char gettext ();
21623 int
21624 main ()
21625 {
21626 gettext ();
21627   ;
21628   return 0;
21629 }
21630 _ACEOF
21631 rm -f conftest.$ac_objext conftest$ac_exeext
21632 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21633   (eval $ac_link) 2>conftest.er1
21634   ac_status=$?
21635   grep -v '^ *+' conftest.er1 >conftest.err
21636   rm -f conftest.er1
21637   cat conftest.err >&5
21638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21639   (exit $ac_status); } &&
21640          { ac_try='test -z "$ac_c_werror_flag"
21641                          || test ! -s conftest.err'
21642   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21643   (eval $ac_try) 2>&5
21644   ac_status=$?
21645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21646   (exit $ac_status); }; } &&
21647          { ac_try='test -s conftest$ac_exeext'
21648   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21649   (eval $ac_try) 2>&5
21650   ac_status=$?
21651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21652   (exit $ac_status); }; }; then
21653   ac_cv_search_gettext="-l$ac_lib"
21654 break
21655 else
21656   echo "$as_me: failed program was:" >&5
21657 sed 's/^/| /' conftest.$ac_ext >&5
21658
21659 fi
21660 rm -f conftest.err conftest.$ac_objext \
21661       conftest$ac_exeext conftest.$ac_ext
21662   done
21663 fi
21664 LIBS=$ac_func_search_save_LIBS
21665 fi
21666 echo "$as_me:$LINENO: result: $ac_cv_search_gettext" >&5
21667 echo "${ECHO_T}$ac_cv_search_gettext" >&6
21668 if test "$ac_cv_search_gettext" != no; then
21669   test "$ac_cv_search_gettext" = "none required" || LIBS="$ac_cv_search_gettext $LIBS"
21670
21671 else
21672   { { echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
21673 echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
21674    { (exit 1); exit 1; }; }
21675 fi
21676
21677   if test "${ac_cv_header_libintl_h+set}" = set; then
21678   echo "$as_me:$LINENO: checking for libintl.h" >&5
21679 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
21680 if test "${ac_cv_header_libintl_h+set}" = set; then
21681   echo $ECHO_N "(cached) $ECHO_C" >&6
21682 fi
21683 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
21684 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
21685 else
21686   # Is the header compilable?
21687 echo "$as_me:$LINENO: checking libintl.h usability" >&5
21688 echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6
21689 cat >conftest.$ac_ext <<_ACEOF
21690 /* confdefs.h.  */
21691 _ACEOF
21692 cat confdefs.h >>conftest.$ac_ext
21693 cat >>conftest.$ac_ext <<_ACEOF
21694 /* end confdefs.h.  */
21695 $ac_includes_default
21696 #include <libintl.h>
21697 _ACEOF
21698 rm -f conftest.$ac_objext
21699 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21700   (eval $ac_compile) 2>conftest.er1
21701   ac_status=$?
21702   grep -v '^ *+' conftest.er1 >conftest.err
21703   rm -f conftest.er1
21704   cat conftest.err >&5
21705   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21706   (exit $ac_status); } &&
21707          { ac_try='test -z "$ac_c_werror_flag"
21708                          || test ! -s conftest.err'
21709   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21710   (eval $ac_try) 2>&5
21711   ac_status=$?
21712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21713   (exit $ac_status); }; } &&
21714          { ac_try='test -s conftest.$ac_objext'
21715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21716   (eval $ac_try) 2>&5
21717   ac_status=$?
21718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21719   (exit $ac_status); }; }; then
21720   ac_header_compiler=yes
21721 else
21722   echo "$as_me: failed program was:" >&5
21723 sed 's/^/| /' conftest.$ac_ext >&5
21724
21725 ac_header_compiler=no
21726 fi
21727 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21728 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21729 echo "${ECHO_T}$ac_header_compiler" >&6
21730
21731 # Is the header present?
21732 echo "$as_me:$LINENO: checking libintl.h presence" >&5
21733 echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6
21734 cat >conftest.$ac_ext <<_ACEOF
21735 /* confdefs.h.  */
21736 _ACEOF
21737 cat confdefs.h >>conftest.$ac_ext
21738 cat >>conftest.$ac_ext <<_ACEOF
21739 /* end confdefs.h.  */
21740 #include <libintl.h>
21741 _ACEOF
21742 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
21743   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
21744   ac_status=$?
21745   grep -v '^ *+' conftest.er1 >conftest.err
21746   rm -f conftest.er1
21747   cat conftest.err >&5
21748   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21749   (exit $ac_status); } >/dev/null; then
21750   if test -s conftest.err; then
21751     ac_cpp_err=$ac_c_preproc_warn_flag
21752     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
21753   else
21754     ac_cpp_err=
21755   fi
21756 else
21757   ac_cpp_err=yes
21758 fi
21759 if test -z "$ac_cpp_err"; then
21760   ac_header_preproc=yes
21761 else
21762   echo "$as_me: failed program was:" >&5
21763 sed 's/^/| /' conftest.$ac_ext >&5
21764
21765   ac_header_preproc=no
21766 fi
21767 rm -f conftest.err conftest.$ac_ext
21768 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21769 echo "${ECHO_T}$ac_header_preproc" >&6
21770
21771 # So?  What about this header?
21772 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21773   yes:no: )
21774     { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
21775 echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21776     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
21777 echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
21778     ac_header_preproc=yes
21779     ;;
21780   no:yes:* )
21781     { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
21782 echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
21783     { echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
21784 echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
21785     { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
21786 echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
21787     { echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
21788 echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21789     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
21790 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
21791     { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
21792 echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
21793     (
21794       cat <<\_ASBOX
21795 ## ---------------------------------------- ##
21796 ## Report this to pgsql-bugs@postgresql.org ##
21797 ## ---------------------------------------- ##
21798 _ASBOX
21799     ) |
21800       sed "s/^/$as_me: WARNING:     /" >&2
21801     ;;
21802 esac
21803 echo "$as_me:$LINENO: checking for libintl.h" >&5
21804 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
21805 if test "${ac_cv_header_libintl_h+set}" = set; then
21806   echo $ECHO_N "(cached) $ECHO_C" >&6
21807 else
21808   ac_cv_header_libintl_h=$ac_header_preproc
21809 fi
21810 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
21811 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
21812
21813 fi
21814 if test $ac_cv_header_libintl_h = yes; then
21815   :
21816 else
21817   { { echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
21818 echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
21819    { (exit 1); exit 1; }; }
21820 fi
21821
21822
21823   for ac_prog in msgfmt
21824 do
21825   # Extract the first word of "$ac_prog", so it can be a program name with args.
21826 set dummy $ac_prog; ac_word=$2
21827 echo "$as_me:$LINENO: checking for $ac_word" >&5
21828 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21829 if test "${ac_cv_prog_MSGFMT+set}" = set; then
21830   echo $ECHO_N "(cached) $ECHO_C" >&6
21831 else
21832   if test -n "$MSGFMT"; then
21833   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
21834 else
21835 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21836 for as_dir in $PATH
21837 do
21838   IFS=$as_save_IFS
21839   test -z "$as_dir" && as_dir=.
21840   for ac_exec_ext in '' $ac_executable_extensions; do
21841   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21842     ac_cv_prog_MSGFMT="$ac_prog"
21843     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21844     break 2
21845   fi
21846 done
21847 done
21848
21849 fi
21850 fi
21851 MSGFMT=$ac_cv_prog_MSGFMT
21852 if test -n "$MSGFMT"; then
21853   echo "$as_me:$LINENO: result: $MSGFMT" >&5
21854 echo "${ECHO_T}$MSGFMT" >&6
21855 else
21856   echo "$as_me:$LINENO: result: no" >&5
21857 echo "${ECHO_T}no" >&6
21858 fi
21859
21860   test -n "$MSGFMT" && break
21861 done
21862
21863   if test -z "$MSGFMT"; then
21864     { { echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
21865 echo "$as_me: error: msgfmt is required for NLS" >&2;}
21866    { (exit 1); exit 1; }; }
21867   fi
21868   for ac_prog in msgmerge
21869 do
21870   # Extract the first word of "$ac_prog", so it can be a program name with args.
21871 set dummy $ac_prog; ac_word=$2
21872 echo "$as_me:$LINENO: checking for $ac_word" >&5
21873 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21874 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
21875   echo $ECHO_N "(cached) $ECHO_C" >&6
21876 else
21877   if test -n "$MSGMERGE"; then
21878   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
21879 else
21880 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21881 for as_dir in $PATH
21882 do
21883   IFS=$as_save_IFS
21884   test -z "$as_dir" && as_dir=.
21885   for ac_exec_ext in '' $ac_executable_extensions; do
21886   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21887     ac_cv_prog_MSGMERGE="$ac_prog"
21888     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21889     break 2
21890   fi
21891 done
21892 done
21893
21894 fi
21895 fi
21896 MSGMERGE=$ac_cv_prog_MSGMERGE
21897 if test -n "$MSGMERGE"; then
21898   echo "$as_me:$LINENO: result: $MSGMERGE" >&5
21899 echo "${ECHO_T}$MSGMERGE" >&6
21900 else
21901   echo "$as_me:$LINENO: result: no" >&5
21902 echo "${ECHO_T}no" >&6
21903 fi
21904
21905   test -n "$MSGMERGE" && break
21906 done
21907
21908   for ac_prog in xgettext
21909 do
21910   # Extract the first word of "$ac_prog", so it can be a program name with args.
21911 set dummy $ac_prog; ac_word=$2
21912 echo "$as_me:$LINENO: checking for $ac_word" >&5
21913 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21914 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
21915   echo $ECHO_N "(cached) $ECHO_C" >&6
21916 else
21917   if test -n "$XGETTEXT"; then
21918   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
21919 else
21920 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21921 for as_dir in $PATH
21922 do
21923   IFS=$as_save_IFS
21924   test -z "$as_dir" && as_dir=.
21925   for ac_exec_ext in '' $ac_executable_extensions; do
21926   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21927     ac_cv_prog_XGETTEXT="$ac_prog"
21928     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21929     break 2
21930   fi
21931 done
21932 done
21933
21934 fi
21935 fi
21936 XGETTEXT=$ac_cv_prog_XGETTEXT
21937 if test -n "$XGETTEXT"; then
21938   echo "$as_me:$LINENO: result: $XGETTEXT" >&5
21939 echo "${ECHO_T}$XGETTEXT" >&6
21940 else
21941   echo "$as_me:$LINENO: result: no" >&5
21942 echo "${ECHO_T}no" >&6
21943 fi
21944
21945   test -n "$XGETTEXT" && break
21946 done
21947
21948
21949   # Note: share/locale is always the default, independent of $datadir
21950   localedir='${prefix}/share/locale'
21951   if test x"$prefix" = x"NONE"; then
21952     exp_localedir="$ac_default_prefix/share/locale"
21953   else
21954     exp_localedir="$prefix/share/locale"
21955   fi
21956
21957
21958
21959 cat >>confdefs.h <<_ACEOF
21960 #define LOCALEDIR "$exp_localedir"
21961 _ACEOF
21962
21963
21964 fi
21965
21966 # Check for Tcl configuration script tclConfig.sh
21967 if test "$with_tcl" = yes; then
21968     for ac_prog in tclsh tcl
21969 do
21970   # Extract the first word of "$ac_prog", so it can be a program name with args.
21971 set dummy $ac_prog; ac_word=$2
21972 echo "$as_me:$LINENO: checking for $ac_word" >&5
21973 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
21974 if test "${ac_cv_path_TCLSH+set}" = set; then
21975   echo $ECHO_N "(cached) $ECHO_C" >&6
21976 else
21977   case $TCLSH in
21978   [\\/]* | ?:[\\/]*)
21979   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
21980   ;;
21981   *)
21982   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21983 for as_dir in $PATH
21984 do
21985   IFS=$as_save_IFS
21986   test -z "$as_dir" && as_dir=.
21987   for ac_exec_ext in '' $ac_executable_extensions; do
21988   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
21989     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
21990     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
21991     break 2
21992   fi
21993 done
21994 done
21995
21996   ;;
21997 esac
21998 fi
21999 TCLSH=$ac_cv_path_TCLSH
22000
22001 if test -n "$TCLSH"; then
22002   echo "$as_me:$LINENO: result: $TCLSH" >&5
22003 echo "${ECHO_T}$TCLSH" >&6
22004 else
22005   echo "$as_me:$LINENO: result: no" >&5
22006 echo "${ECHO_T}no" >&6
22007 fi
22008
22009   test -n "$TCLSH" && break
22010 done
22011
22012 echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
22013 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6
22014 # Let user override test
22015 if test -z "$TCL_CONFIG_SH"; then
22016     pgac_test_dirs="$with_tclconfig"
22017
22018     set X $pgac_test_dirs; shift
22019     if test $# -eq 0; then
22020         test -z "$TCLSH" && { { echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
22021 echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
22022    { (exit 1); exit 1; }; }
22023         set X `echo 'puts $auto_path' | $TCLSH`; shift
22024     fi
22025
22026     for pgac_dir do
22027         if test -r "$pgac_dir/tclConfig.sh"; then
22028             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
22029             break
22030         fi
22031     done
22032 fi
22033
22034 if test -z "$TCL_CONFIG_SH"; then
22035     echo "$as_me:$LINENO: result: no" >&5
22036 echo "${ECHO_T}no" >&6
22037     { { echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
22038 echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
22039    { (exit 1); exit 1; }; }
22040 else
22041     echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
22042 echo "${ECHO_T}$TCL_CONFIG_SH" >&6
22043 fi
22044
22045
22046
22047     . "$TCL_CONFIG_SH"
22048 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
22049 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
22050 eval TCL_LIBS=\"$TCL_LIBS\"
22051 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
22052 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
22053
22054         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
22055     ac_save_CPPFLAGS=$CPPFLAGS
22056     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
22057     if test "${ac_cv_header_tcl_h+set}" = set; then
22058   echo "$as_me:$LINENO: checking for tcl.h" >&5
22059 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
22060 if test "${ac_cv_header_tcl_h+set}" = set; then
22061   echo $ECHO_N "(cached) $ECHO_C" >&6
22062 fi
22063 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
22064 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
22065 else
22066   # Is the header compilable?
22067 echo "$as_me:$LINENO: checking tcl.h usability" >&5
22068 echo $ECHO_N "checking tcl.h usability... $ECHO_C" >&6
22069 cat >conftest.$ac_ext <<_ACEOF
22070 /* confdefs.h.  */
22071 _ACEOF
22072 cat confdefs.h >>conftest.$ac_ext
22073 cat >>conftest.$ac_ext <<_ACEOF
22074 /* end confdefs.h.  */
22075 $ac_includes_default
22076 #include <tcl.h>
22077 _ACEOF
22078 rm -f conftest.$ac_objext
22079 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22080   (eval $ac_compile) 2>conftest.er1
22081   ac_status=$?
22082   grep -v '^ *+' conftest.er1 >conftest.err
22083   rm -f conftest.er1
22084   cat conftest.err >&5
22085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22086   (exit $ac_status); } &&
22087          { ac_try='test -z "$ac_c_werror_flag"
22088                          || test ! -s conftest.err'
22089   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22090   (eval $ac_try) 2>&5
22091   ac_status=$?
22092   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22093   (exit $ac_status); }; } &&
22094          { ac_try='test -s conftest.$ac_objext'
22095   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22096   (eval $ac_try) 2>&5
22097   ac_status=$?
22098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22099   (exit $ac_status); }; }; then
22100   ac_header_compiler=yes
22101 else
22102   echo "$as_me: failed program was:" >&5
22103 sed 's/^/| /' conftest.$ac_ext >&5
22104
22105 ac_header_compiler=no
22106 fi
22107 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
22108 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22109 echo "${ECHO_T}$ac_header_compiler" >&6
22110
22111 # Is the header present?
22112 echo "$as_me:$LINENO: checking tcl.h presence" >&5
22113 echo $ECHO_N "checking tcl.h presence... $ECHO_C" >&6
22114 cat >conftest.$ac_ext <<_ACEOF
22115 /* confdefs.h.  */
22116 _ACEOF
22117 cat confdefs.h >>conftest.$ac_ext
22118 cat >>conftest.$ac_ext <<_ACEOF
22119 /* end confdefs.h.  */
22120 #include <tcl.h>
22121 _ACEOF
22122 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
22123   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22124   ac_status=$?
22125   grep -v '^ *+' conftest.er1 >conftest.err
22126   rm -f conftest.er1
22127   cat conftest.err >&5
22128   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22129   (exit $ac_status); } >/dev/null; then
22130   if test -s conftest.err; then
22131     ac_cpp_err=$ac_c_preproc_warn_flag
22132     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
22133   else
22134     ac_cpp_err=
22135   fi
22136 else
22137   ac_cpp_err=yes
22138 fi
22139 if test -z "$ac_cpp_err"; then
22140   ac_header_preproc=yes
22141 else
22142   echo "$as_me: failed program was:" >&5
22143 sed 's/^/| /' conftest.$ac_ext >&5
22144
22145   ac_header_preproc=no
22146 fi
22147 rm -f conftest.err conftest.$ac_ext
22148 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22149 echo "${ECHO_T}$ac_header_preproc" >&6
22150
22151 # So?  What about this header?
22152 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22153   yes:no: )
22154     { echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
22155 echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
22156     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
22157 echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
22158     ac_header_preproc=yes
22159     ;;
22160   no:yes:* )
22161     { echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
22162 echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
22163     { echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
22164 echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
22165     { echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
22166 echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
22167     { echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
22168 echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
22169     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
22170 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
22171     { echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
22172 echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
22173     (
22174       cat <<\_ASBOX
22175 ## ---------------------------------------- ##
22176 ## Report this to pgsql-bugs@postgresql.org ##
22177 ## ---------------------------------------- ##
22178 _ASBOX
22179     ) |
22180       sed "s/^/$as_me: WARNING:     /" >&2
22181     ;;
22182 esac
22183 echo "$as_me:$LINENO: checking for tcl.h" >&5
22184 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
22185 if test "${ac_cv_header_tcl_h+set}" = set; then
22186   echo $ECHO_N "(cached) $ECHO_C" >&6
22187 else
22188   ac_cv_header_tcl_h=$ac_header_preproc
22189 fi
22190 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
22191 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
22192
22193 fi
22194 if test $ac_cv_header_tcl_h = yes; then
22195   :
22196 else
22197   { { echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
22198 echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
22199    { (exit 1); exit 1; }; }
22200 fi
22201
22202
22203     CPPFLAGS=$ac_save_CPPFLAGS
22204 fi
22205
22206 #
22207 # Check for DocBook and tools
22208 #
22209 for ac_prog in onsgmls nsgmls
22210 do
22211   # Extract the first word of "$ac_prog", so it can be a program name with args.
22212 set dummy $ac_prog; ac_word=$2
22213 echo "$as_me:$LINENO: checking for $ac_word" >&5
22214 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22215 if test "${ac_cv_prog_NSGMLS+set}" = set; then
22216   echo $ECHO_N "(cached) $ECHO_C" >&6
22217 else
22218   if test -n "$NSGMLS"; then
22219   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
22220 else
22221 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22222 for as_dir in $PATH
22223 do
22224   IFS=$as_save_IFS
22225   test -z "$as_dir" && as_dir=.
22226   for ac_exec_ext in '' $ac_executable_extensions; do
22227   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22228     ac_cv_prog_NSGMLS="$ac_prog"
22229     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22230     break 2
22231   fi
22232 done
22233 done
22234
22235 fi
22236 fi
22237 NSGMLS=$ac_cv_prog_NSGMLS
22238 if test -n "$NSGMLS"; then
22239   echo "$as_me:$LINENO: result: $NSGMLS" >&5
22240 echo "${ECHO_T}$NSGMLS" >&6
22241 else
22242   echo "$as_me:$LINENO: result: no" >&5
22243 echo "${ECHO_T}no" >&6
22244 fi
22245
22246   test -n "$NSGMLS" && break
22247 done
22248
22249 for ac_prog in openjade jade
22250 do
22251   # Extract the first word of "$ac_prog", so it can be a program name with args.
22252 set dummy $ac_prog; ac_word=$2
22253 echo "$as_me:$LINENO: checking for $ac_word" >&5
22254 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22255 if test "${ac_cv_prog_JADE+set}" = set; then
22256   echo $ECHO_N "(cached) $ECHO_C" >&6
22257 else
22258   if test -n "$JADE"; then
22259   ac_cv_prog_JADE="$JADE" # Let the user override the test.
22260 else
22261 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22262 for as_dir in $PATH
22263 do
22264   IFS=$as_save_IFS
22265   test -z "$as_dir" && as_dir=.
22266   for ac_exec_ext in '' $ac_executable_extensions; do
22267   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22268     ac_cv_prog_JADE="$ac_prog"
22269     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22270     break 2
22271   fi
22272 done
22273 done
22274
22275 fi
22276 fi
22277 JADE=$ac_cv_prog_JADE
22278 if test -n "$JADE"; then
22279   echo "$as_me:$LINENO: result: $JADE" >&5
22280 echo "${ECHO_T}$JADE" >&6
22281 else
22282   echo "$as_me:$LINENO: result: no" >&5
22283 echo "${ECHO_T}no" >&6
22284 fi
22285
22286   test -n "$JADE" && break
22287 done
22288
22289
22290 echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
22291 echo $ECHO_N "checking for DocBook V4.2... $ECHO_C" >&6
22292 if test "${pgac_cv_check_docbook+set}" = set; then
22293   echo $ECHO_N "(cached) $ECHO_C" >&6
22294 else
22295   cat >conftest.sgml <<EOF
22296 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
22297 <book>
22298  <title>test</title>
22299  <chapter>
22300   <title>random</title>
22301    <sect1>
22302     <title>testsect</title>
22303     <para>text</para>
22304   </sect1>
22305  </chapter>
22306 </book>
22307 EOF
22308
22309 pgac_cv_check_docbook=no
22310
22311 if test -n "$NSGMLS"; then
22312   $NSGMLS -s conftest.sgml 1>&5 2>&1
22313   if test $? -eq 0; then
22314     pgac_cv_check_docbook=yes
22315   fi
22316 fi
22317 rm -f conftest.sgml
22318 fi
22319 echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
22320 echo "${ECHO_T}$pgac_cv_check_docbook" >&6
22321
22322 have_docbook=$pgac_cv_check_docbook
22323
22324
22325 echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
22326 echo $ECHO_N "checking for DocBook stylesheets... $ECHO_C" >&6
22327 if test "${pgac_cv_path_stylesheets+set}" = set; then
22328   echo $ECHO_N "(cached) $ECHO_C" >&6
22329 else
22330   if test -n "$DOCBOOKSTYLE"; then
22331   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
22332 else
22333   for pgac_prefix in /usr /usr/local /opt; do
22334     for pgac_infix in share lib; do
22335       for pgac_postfix in \
22336         sgml/stylesheets/nwalsh-modular \
22337         sgml/stylesheets/docbook \
22338                 sgml/docbook-dsssl \
22339         sgml/docbook/dsssl/modular \
22340         sgml/docbook/stylesheet/dsssl/modular \
22341         sgml/docbook/dsssl-stylesheets
22342       do
22343         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
22344         if test -r "$pgac_candidate/html/docbook.dsl" \
22345            && test -r "$pgac_candidate/print/docbook.dsl"
22346         then
22347           pgac_cv_path_stylesheets=$pgac_candidate
22348           break 3
22349         fi
22350       done
22351     done
22352   done
22353 fi
22354 fi
22355
22356 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
22357
22358 if test -n "$DOCBOOKSTYLE"; then
22359   echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
22360 echo "${ECHO_T}$DOCBOOKSTYLE" >&6
22361 else
22362   echo "$as_me:$LINENO: result: no" >&5
22363 echo "${ECHO_T}no" >&6
22364 fi
22365 if test -n "$DOCBOOKSTYLE"; then
22366   for ac_prog in collateindex.pl
22367 do
22368   # Extract the first word of "$ac_prog", so it can be a program name with args.
22369 set dummy $ac_prog; ac_word=$2
22370 echo "$as_me:$LINENO: checking for $ac_word" >&5
22371 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22372 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
22373   echo $ECHO_N "(cached) $ECHO_C" >&6
22374 else
22375   case $COLLATEINDEX in
22376   [\\/]* | ?:[\\/]*)
22377   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
22378   ;;
22379   *)
22380   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22381 for as_dir in $DOCBOOKSTYLE/bin $PATH
22382 do
22383   IFS=$as_save_IFS
22384   test -z "$as_dir" && as_dir=.
22385   for ac_exec_ext in '' $ac_executable_extensions; do
22386   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22387     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
22388     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22389     break 2
22390   fi
22391 done
22392 done
22393
22394   ;;
22395 esac
22396 fi
22397 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
22398
22399 if test -n "$COLLATEINDEX"; then
22400   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
22401 echo "${ECHO_T}$COLLATEINDEX" >&6
22402 else
22403   echo "$as_me:$LINENO: result: no" >&5
22404 echo "${ECHO_T}no" >&6
22405 fi
22406
22407   test -n "$COLLATEINDEX" && break
22408 done
22409
22410 else
22411   for ac_prog in collateindex.pl
22412 do
22413   # Extract the first word of "$ac_prog", so it can be a program name with args.
22414 set dummy $ac_prog; ac_word=$2
22415 echo "$as_me:$LINENO: checking for $ac_word" >&5
22416 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22417 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
22418   echo $ECHO_N "(cached) $ECHO_C" >&6
22419 else
22420   case $COLLATEINDEX in
22421   [\\/]* | ?:[\\/]*)
22422   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
22423   ;;
22424   *)
22425   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22426 for as_dir in $PATH
22427 do
22428   IFS=$as_save_IFS
22429   test -z "$as_dir" && as_dir=.
22430   for ac_exec_ext in '' $ac_executable_extensions; do
22431   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22432     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
22433     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22434     break 2
22435   fi
22436 done
22437 done
22438
22439   ;;
22440 esac
22441 fi
22442 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
22443
22444 if test -n "$COLLATEINDEX"; then
22445   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
22446 echo "${ECHO_T}$COLLATEINDEX" >&6
22447 else
22448   echo "$as_me:$LINENO: result: no" >&5
22449 echo "${ECHO_T}no" >&6
22450 fi
22451
22452   test -n "$COLLATEINDEX" && break
22453 done
22454
22455 fi
22456 for ac_prog in sgmlspl
22457 do
22458   # Extract the first word of "$ac_prog", so it can be a program name with args.
22459 set dummy $ac_prog; ac_word=$2
22460 echo "$as_me:$LINENO: checking for $ac_word" >&5
22461 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22462 if test "${ac_cv_prog_SGMLSPL+set}" = set; then
22463   echo $ECHO_N "(cached) $ECHO_C" >&6
22464 else
22465   if test -n "$SGMLSPL"; then
22466   ac_cv_prog_SGMLSPL="$SGMLSPL" # Let the user override the test.
22467 else
22468 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22469 for as_dir in $PATH
22470 do
22471   IFS=$as_save_IFS
22472   test -z "$as_dir" && as_dir=.
22473   for ac_exec_ext in '' $ac_executable_extensions; do
22474   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22475     ac_cv_prog_SGMLSPL="$ac_prog"
22476     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22477     break 2
22478   fi
22479 done
22480 done
22481
22482 fi
22483 fi
22484 SGMLSPL=$ac_cv_prog_SGMLSPL
22485 if test -n "$SGMLSPL"; then
22486   echo "$as_me:$LINENO: result: $SGMLSPL" >&5
22487 echo "${ECHO_T}$SGMLSPL" >&6
22488 else
22489   echo "$as_me:$LINENO: result: no" >&5
22490 echo "${ECHO_T}no" >&6
22491 fi
22492
22493   test -n "$SGMLSPL" && break
22494 done
22495
22496
22497 # Thread testing
22498
22499 # We have to run the thread test near the end so we have all our symbols
22500 # defined.  Cross compiling throws a warning.
22501 #
22502 if test "$enable_thread_safety_force" = yes; then
22503 if test x"$template" != x"win32"
22504 then
22505   { echo "$as_me:$LINENO: WARNING:
22506 *** Skipping thread test program.  --enable-thread-safety-force was used.
22507 *** Run the program in src/test/thread on the your machine and add
22508 proper locking function calls to your applications to guarantee thread
22509 safety.
22510 " >&5
22511 echo "$as_me: WARNING:
22512 *** Skipping thread test program.  --enable-thread-safety-force was used.
22513 *** Run the program in src/test/thread on the your machine and add
22514 proper locking function calls to your applications to guarantee thread
22515 safety.
22516 " >&2;}
22517 else
22518 { echo "$as_me:$LINENO: WARNING: *** Skipping thread test on Win32" >&5
22519 echo "$as_me: WARNING: *** Skipping thread test on Win32" >&2;}
22520 fi
22521 elif test "$enable_thread_safety" = yes; then
22522 if test x"$template" != x"win32"
22523 then
22524 echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
22525 echo $ECHO_N "checking thread safety of required library functions... $ECHO_C" >&6
22526
22527 _CFLAGS="$CFLAGS"
22528 _LIBS="$LIBS"
22529 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
22530 LIBS="$LIBS $PTHREAD_LIBS"
22531 if test "$cross_compiling" = yes; then
22532   echo "$as_me:$LINENO: result: maybe" >&5
22533 echo "${ECHO_T}maybe" >&6
22534   { echo "$as_me:$LINENO: WARNING:
22535 *** Skipping thread test program because of cross-compile build.
22536 *** Run the program in src/test/thread on the target machine.
22537 " >&5
22538 echo "$as_me: WARNING:
22539 *** Skipping thread test program because of cross-compile build.
22540 *** Run the program in src/test/thread on the target machine.
22541 " >&2;}
22542 else
22543   cat >conftest.$ac_ext <<_ACEOF
22544 /* confdefs.h.  */
22545 _ACEOF
22546 cat confdefs.h >>conftest.$ac_ext
22547 cat >>conftest.$ac_ext <<_ACEOF
22548 /* end confdefs.h.  */
22549 #include "$srcdir/src/test/thread/thread_test.c"
22550 _ACEOF
22551 rm -f conftest$ac_exeext
22552 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22553   (eval $ac_link) 2>&5
22554   ac_status=$?
22555   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22556   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22558   (eval $ac_try) 2>&5
22559   ac_status=$?
22560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22561   (exit $ac_status); }; }; then
22562   echo "$as_me:$LINENO: result: yes" >&5
22563 echo "${ECHO_T}yes" >&6
22564 else
22565   echo "$as_me: program exited with status $ac_status" >&5
22566 echo "$as_me: failed program was:" >&5
22567 sed 's/^/| /' conftest.$ac_ext >&5
22568
22569 ( exit $ac_status )
22570 echo "$as_me:$LINENO: result: no" >&5
22571 echo "${ECHO_T}no" >&6
22572   { { echo "$as_me:$LINENO: error:
22573 *** Thread test program failed.  Your platform is not thread-safe.
22574 *** Check the file 'config.log'for the exact reason.
22575 ***
22576 *** You can use the configure option --enable-thread-safety-force
22577 *** to force threads to be enabled.  However, you must then run
22578 *** the program in src/test/thread and add locking function calls
22579 *** to your applications to guarantee thread safety.
22580 " >&5
22581 echo "$as_me: error:
22582 *** Thread test program failed.  Your platform is not thread-safe.
22583 *** Check the file 'config.log'for the exact reason.
22584 ***
22585 *** You can use the configure option --enable-thread-safety-force
22586 *** to force threads to be enabled.  However, you must then run
22587 *** the program in src/test/thread and add locking function calls
22588 *** to your applications to guarantee thread safety.
22589 " >&2;}
22590    { (exit 1); exit 1; }; }
22591 fi
22592 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22593 fi
22594 CFLAGS="$_CFLAGS"
22595 LIBS="$_LIBS"
22596 else
22597 { echo "$as_me:$LINENO: WARNING: *** Skipping thread test on Win32" >&5
22598 echo "$as_me: WARNING: *** Skipping thread test on Win32" >&2;}
22599 fi
22600 fi
22601
22602 # prepare build tree if outside source tree
22603 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
22604 # Note 2: /bin/pwd might be better than shell's built-in at getting
22605 #         a symlink-free name.
22606 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
22607   vpath_build=no
22608 else
22609   vpath_build=yes
22610   if test "$no_create" != yes; then
22611     echo $ECHO_N "preparing build tree... $ECHO_C" >&6
22612     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
22613     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
22614       || { { echo "$as_me:$LINENO: error: failed" >&5
22615 echo "$as_me: error: failed" >&2;}
22616    { (exit 1); exit 1; }; }
22617     echo "$as_me:$LINENO: result: done" >&5
22618 echo "${ECHO_T}done" >&6
22619   fi
22620 fi
22621
22622
22623
22624                     ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
22625
22626
22627                                                             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}"
22628
22629
22630 if test "$PORTNAME" = "win32"; then
22631           ac_config_commands="$ac_config_commands check_win32_symlinks"
22632
22633 fi
22634
22635           ac_config_headers="$ac_config_headers src/include/pg_config.h"
22636
22637
22638 cat >confcache <<\_ACEOF
22639 # This file is a shell script that caches the results of configure
22640 # tests run on this system so they can be shared between configure
22641 # scripts and configure runs, see configure's option --config-cache.
22642 # It is not useful on other systems.  If it contains results you don't
22643 # want to keep, you may remove or edit it.
22644 #
22645 # config.status only pays attention to the cache file if you give it
22646 # the --recheck option to rerun configure.
22647 #
22648 # `ac_cv_env_foo' variables (set or unset) will be overridden when
22649 # loading this file, other *unset* `ac_cv_foo' will be assigned the
22650 # following values.
22651
22652 _ACEOF
22653
22654 # The following way of writing the cache mishandles newlines in values,
22655 # but we know of no workaround that is simple, portable, and efficient.
22656 # So, don't put newlines in cache variables' values.
22657 # Ultrix sh set writes to stderr and can't be redirected directly,
22658 # and sets the high bit in the cache file unless we assign to the vars.
22659 {
22660   (set) 2>&1 |
22661     case `(ac_space=' '; set | grep ac_space) 2>&1` in
22662     *ac_space=\ *)
22663       # `set' does not quote correctly, so add quotes (double-quote
22664       # substitution turns \\\\ into \\, and sed turns \\ into \).
22665       sed -n \
22666         "s/'/'\\\\''/g;
22667           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22668       ;;
22669     *)
22670       # `set' quotes correctly as required by POSIX, so do not add quotes.
22671       sed -n \
22672         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
22673       ;;
22674     esac;
22675 } |
22676   sed '
22677      t clear
22678      : clear
22679      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22680      t end
22681      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22682      : end' >>confcache
22683 if diff $cache_file confcache >/dev/null 2>&1; then :; else
22684   if test -w $cache_file; then
22685     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
22686     cat confcache >$cache_file
22687   else
22688     echo "not updating unwritable cache $cache_file"
22689   fi
22690 fi
22691 rm -f confcache
22692
22693 test "x$prefix" = xNONE && prefix=$ac_default_prefix
22694 # Let make expand exec_prefix.
22695 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22696
22697 # VPATH may cause trouble with some makes, so we remove $(srcdir),
22698 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
22699 # trailing colons and then remove the whole line if VPATH becomes empty
22700 # (actually we leave an empty line to preserve line numbers).
22701 if test "x$srcdir" = x.; then
22702   ac_vpsub='/^[  ]*VPATH[        ]*=/{
22703 s/:*\$(srcdir):*/:/;
22704 s/:*\${srcdir}:*/:/;
22705 s/:*@srcdir@:*/:/;
22706 s/^\([^=]*=[     ]*\):*/\1/;
22707 s/:*$//;
22708 s/^[^=]*=[       ]*$//;
22709 }'
22710 fi
22711
22712 DEFS=-DHAVE_CONFIG_H
22713
22714 ac_libobjs=
22715 ac_ltlibobjs=
22716 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
22717   # 1. Remove the extension, and $U if already installed.
22718   ac_i=`echo "$ac_i" |
22719          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
22720   # 2. Add them.
22721   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
22722   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
22723 done
22724 LIBOBJS=$ac_libobjs
22725
22726 LTLIBOBJS=$ac_ltlibobjs
22727
22728
22729
22730 : ${CONFIG_STATUS=./config.status}
22731 ac_clean_files_save=$ac_clean_files
22732 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
22733 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
22734 echo "$as_me: creating $CONFIG_STATUS" >&6;}
22735 cat >$CONFIG_STATUS <<_ACEOF
22736 #! $SHELL
22737 # Generated by $as_me.
22738 # Run this file to recreate the current configuration.
22739 # Compiler output produced by configure, useful for debugging
22740 # configure, is in config.log if it exists.
22741
22742 debug=false
22743 ac_cs_recheck=false
22744 ac_cs_silent=false
22745 SHELL=\${CONFIG_SHELL-$SHELL}
22746 _ACEOF
22747
22748 cat >>$CONFIG_STATUS <<\_ACEOF
22749 ## --------------------- ##
22750 ## M4sh Initialization.  ##
22751 ## --------------------- ##
22752
22753 # Be Bourne compatible
22754 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
22755   emulate sh
22756   NULLCMD=:
22757   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
22758   # is contrary to our usage.  Disable this feature.
22759   alias -g '${1+"$@"}'='"$@"'
22760 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
22761   set -o posix
22762 fi
22763 DUALCASE=1; export DUALCASE # for MKS sh
22764
22765 # Support unset when possible.
22766 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
22767   as_unset=unset
22768 else
22769   as_unset=false
22770 fi
22771
22772
22773 # Work around bugs in pre-3.0 UWIN ksh.
22774 $as_unset ENV MAIL MAILPATH
22775 PS1='$ '
22776 PS2='> '
22777 PS4='+ '
22778
22779 # NLS nuisances.
22780 for as_var in \
22781   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
22782   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
22783   LC_TELEPHONE LC_TIME
22784 do
22785   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
22786     eval $as_var=C; export $as_var
22787   else
22788     $as_unset $as_var
22789   fi
22790 done
22791
22792 # Required to use basename.
22793 if expr a : '\(a\)' >/dev/null 2>&1; then
22794   as_expr=expr
22795 else
22796   as_expr=false
22797 fi
22798
22799 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
22800   as_basename=basename
22801 else
22802   as_basename=false
22803 fi
22804
22805
22806 # Name of the executable.
22807 as_me=`$as_basename "$0" ||
22808 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
22809          X"$0" : 'X\(//\)$' \| \
22810          X"$0" : 'X\(/\)$' \| \
22811          .     : '\(.\)' 2>/dev/null ||
22812 echo X/"$0" |
22813     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
22814           /^X\/\(\/\/\)$/{ s//\1/; q; }
22815           /^X\/\(\/\).*/{ s//\1/; q; }
22816           s/.*/./; q'`
22817
22818
22819 # PATH needs CR, and LINENO needs CR and PATH.
22820 # Avoid depending upon Character Ranges.
22821 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
22822 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
22823 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
22824 as_cr_digits='0123456789'
22825 as_cr_alnum=$as_cr_Letters$as_cr_digits
22826
22827 # The user is always right.
22828 if test "${PATH_SEPARATOR+set}" != set; then
22829   echo "#! /bin/sh" >conf$$.sh
22830   echo  "exit 0"   >>conf$$.sh
22831   chmod +x conf$$.sh
22832   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
22833     PATH_SEPARATOR=';'
22834   else
22835     PATH_SEPARATOR=:
22836   fi
22837   rm -f conf$$.sh
22838 fi
22839
22840
22841   as_lineno_1=$LINENO
22842   as_lineno_2=$LINENO
22843   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
22844   test "x$as_lineno_1" != "x$as_lineno_2" &&
22845   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
22846   # Find who we are.  Look in the path if we contain no path at all
22847   # relative or not.
22848   case $0 in
22849     *[\\/]* ) as_myself=$0 ;;
22850     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22851 for as_dir in $PATH
22852 do
22853   IFS=$as_save_IFS
22854   test -z "$as_dir" && as_dir=.
22855   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
22856 done
22857
22858        ;;
22859   esac
22860   # We did not find ourselves, most probably we were run as `sh COMMAND'
22861   # in which case we are not to be found in the path.
22862   if test "x$as_myself" = x; then
22863     as_myself=$0
22864   fi
22865   if test ! -f "$as_myself"; then
22866     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
22867 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
22868    { (exit 1); exit 1; }; }
22869   fi
22870   case $CONFIG_SHELL in
22871   '')
22872     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22873 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
22874 do
22875   IFS=$as_save_IFS
22876   test -z "$as_dir" && as_dir=.
22877   for as_base in sh bash ksh sh5; do
22878          case $as_dir in
22879          /*)
22880            if ("$as_dir/$as_base" -c '
22881   as_lineno_1=$LINENO
22882   as_lineno_2=$LINENO
22883   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
22884   test "x$as_lineno_1" != "x$as_lineno_2" &&
22885   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
22886              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
22887              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
22888              CONFIG_SHELL=$as_dir/$as_base
22889              export CONFIG_SHELL
22890              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
22891            fi;;
22892          esac
22893        done
22894 done
22895 ;;
22896   esac
22897
22898   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
22899   # uniformly replaced by the line number.  The first 'sed' inserts a
22900   # line-number line before each line; the second 'sed' does the real
22901   # work.  The second script uses 'N' to pair each line-number line
22902   # with the numbered line, and appends trailing '-' during
22903   # substitution so that $LINENO is not a special case at line end.
22904   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
22905   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
22906   sed '=' <$as_myself |
22907     sed '
22908       N
22909       s,$,-,
22910       : loop
22911       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
22912       t loop
22913       s,-$,,
22914       s,^['$as_cr_digits']*\n,,
22915     ' >$as_me.lineno &&
22916   chmod +x $as_me.lineno ||
22917     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
22918 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
22919    { (exit 1); exit 1; }; }
22920
22921   # Don't try to exec as it changes $[0], causing all sort of problems
22922   # (the dirname of $[0] is not the place where we might find the
22923   # original and so on.  Autoconf is especially sensible to this).
22924   . ./$as_me.lineno
22925   # Exit status is that of the last command.
22926   exit
22927 }
22928
22929
22930 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
22931   *c*,-n*) ECHO_N= ECHO_C='
22932 ' ECHO_T='      ' ;;
22933   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
22934   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
22935 esac
22936
22937 if expr a : '\(a\)' >/dev/null 2>&1; then
22938   as_expr=expr
22939 else
22940   as_expr=false
22941 fi
22942
22943 rm -f conf$$ conf$$.exe conf$$.file
22944 echo >conf$$.file
22945 if ln -s conf$$.file conf$$ 2>/dev/null; then
22946   # We could just check for DJGPP; but this test a) works b) is more generic
22947   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
22948   if test -f conf$$.exe; then
22949     # Don't use ln at all; we don't have any links
22950     as_ln_s='cp -p'
22951   else
22952     as_ln_s='ln -s'
22953   fi
22954 elif ln conf$$.file conf$$ 2>/dev/null; then
22955   as_ln_s=ln
22956 else
22957   as_ln_s='cp -p'
22958 fi
22959 rm -f conf$$ conf$$.exe conf$$.file
22960
22961 if mkdir -p . 2>/dev/null; then
22962   as_mkdir_p=:
22963 else
22964   test -d ./-p && rmdir ./-p
22965   as_mkdir_p=false
22966 fi
22967
22968 as_executable_p="test -f"
22969
22970 # Sed expression to map a string onto a valid CPP name.
22971 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
22972
22973 # Sed expression to map a string onto a valid variable name.
22974 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
22975
22976
22977 # IFS
22978 # We need space, tab and new line, in precisely that order.
22979 as_nl='
22980 '
22981 IFS="   $as_nl"
22982
22983 # CDPATH.
22984 $as_unset CDPATH
22985
22986 exec 6>&1
22987
22988 # Open the log real soon, to keep \$[0] and so on meaningful, and to
22989 # report actual input values of CONFIG_FILES etc. instead of their
22990 # values after options handling.  Logging --version etc. is OK.
22991 exec 5>>config.log
22992 {
22993   echo
22994   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
22995 ## Running $as_me. ##
22996 _ASBOX
22997 } >&5
22998 cat >&5 <<_CSEOF
22999
23000 This file was extended by PostgreSQL $as_me 8.2devel, which was
23001 generated by GNU Autoconf 2.59.  Invocation command line was
23002
23003   CONFIG_FILES    = $CONFIG_FILES
23004   CONFIG_HEADERS  = $CONFIG_HEADERS
23005   CONFIG_LINKS    = $CONFIG_LINKS
23006   CONFIG_COMMANDS = $CONFIG_COMMANDS
23007   $ $0 $@
23008
23009 _CSEOF
23010 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
23011 echo >&5
23012 _ACEOF
23013
23014 # Files that config.status was made for.
23015 if test -n "$ac_config_files"; then
23016   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
23017 fi
23018
23019 if test -n "$ac_config_headers"; then
23020   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
23021 fi
23022
23023 if test -n "$ac_config_links"; then
23024   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
23025 fi
23026
23027 if test -n "$ac_config_commands"; then
23028   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
23029 fi
23030
23031 cat >>$CONFIG_STATUS <<\_ACEOF
23032
23033 ac_cs_usage="\
23034 \`$as_me' instantiates files from templates according to the
23035 current configuration.
23036
23037 Usage: $0 [OPTIONS] [FILE]...
23038
23039   -h, --help       print this help, then exit
23040   -V, --version    print version number, then exit
23041   -q, --quiet      do not print progress messages
23042   -d, --debug      don't remove temporary files
23043       --recheck    update $as_me by reconfiguring in the same conditions
23044   --file=FILE[:TEMPLATE]
23045                    instantiate the configuration file FILE
23046   --header=FILE[:TEMPLATE]
23047                    instantiate the configuration header FILE
23048
23049 Configuration files:
23050 $config_files
23051
23052 Configuration headers:
23053 $config_headers
23054
23055 Configuration links:
23056 $config_links
23057
23058 Configuration commands:
23059 $config_commands
23060
23061 Report bugs to <bug-autoconf@gnu.org>."
23062 _ACEOF
23063
23064 cat >>$CONFIG_STATUS <<_ACEOF
23065 ac_cs_version="\\
23066 PostgreSQL config.status 8.2devel
23067 configured by $0, generated by GNU Autoconf 2.59,
23068   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
23069
23070 Copyright (C) 2003 Free Software Foundation, Inc.
23071 This config.status script is free software; the Free Software Foundation
23072 gives unlimited permission to copy, distribute and modify it."
23073 srcdir=$srcdir
23074 _ACEOF
23075
23076 cat >>$CONFIG_STATUS <<\_ACEOF
23077 # If no file are specified by the user, then we need to provide default
23078 # value.  By we need to know if files were specified by the user.
23079 ac_need_defaults=:
23080 while test $# != 0
23081 do
23082   case $1 in
23083   --*=*)
23084     ac_option=`expr "x$1" : 'x\([^=]*\)='`
23085     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
23086     ac_shift=:
23087     ;;
23088   -*)
23089     ac_option=$1
23090     ac_optarg=$2
23091     ac_shift=shift
23092     ;;
23093   *) # This is not an option, so the user has probably given explicit
23094      # arguments.
23095      ac_option=$1
23096      ac_need_defaults=false;;
23097   esac
23098
23099   case $ac_option in
23100   # Handling of the options.
23101 _ACEOF
23102 cat >>$CONFIG_STATUS <<\_ACEOF
23103   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
23104     ac_cs_recheck=: ;;
23105   --version | --vers* | -V )
23106     echo "$ac_cs_version"; exit 0 ;;
23107   --he | --h)
23108     # Conflict between --help and --header
23109     { { echo "$as_me:$LINENO: error: ambiguous option: $1
23110 Try \`$0 --help' for more information." >&5
23111 echo "$as_me: error: ambiguous option: $1
23112 Try \`$0 --help' for more information." >&2;}
23113    { (exit 1); exit 1; }; };;
23114   --help | --hel | -h )
23115     echo "$ac_cs_usage"; exit 0 ;;
23116   --debug | --d* | -d )
23117     debug=: ;;
23118   --file | --fil | --fi | --f )
23119     $ac_shift
23120     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
23121     ac_need_defaults=false;;
23122   --header | --heade | --head | --hea )
23123     $ac_shift
23124     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
23125     ac_need_defaults=false;;
23126   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
23127   | -silent | --silent | --silen | --sile | --sil | --si | --s)
23128     ac_cs_silent=: ;;
23129
23130   # This is an error.
23131   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
23132 Try \`$0 --help' for more information." >&5
23133 echo "$as_me: error: unrecognized option: $1
23134 Try \`$0 --help' for more information." >&2;}
23135    { (exit 1); exit 1; }; } ;;
23136
23137   *) ac_config_targets="$ac_config_targets $1" ;;
23138
23139   esac
23140   shift
23141 done
23142
23143 ac_configure_extra_args=
23144
23145 if $ac_cs_silent; then
23146   exec 6>/dev/null
23147   ac_configure_extra_args="$ac_configure_extra_args --silent"
23148 fi
23149
23150 _ACEOF
23151 cat >>$CONFIG_STATUS <<_ACEOF
23152 if \$ac_cs_recheck; then
23153   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
23154   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
23155 fi
23156
23157 _ACEOF
23158
23159
23160
23161
23162
23163 cat >>$CONFIG_STATUS <<\_ACEOF
23164 for ac_config_target in $ac_config_targets
23165 do
23166   case "$ac_config_target" in
23167   # Handling of arguments.
23168   "GNUmakefile" ) CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
23169   "src/Makefile.global" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
23170   "src/backend/port/tas.s" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
23171   "src/backend/port/dynloader.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
23172   "src/backend/port/pg_sema.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
23173   "src/backend/port/pg_shmem.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
23174   "src/include/dynloader.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
23175   "src/include/pg_config_os.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
23176   "src/Makefile.port" ) CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
23177   "check_win32_symlinks" ) CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
23178   "src/include/pg_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
23179   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
23180 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
23181    { (exit 1); exit 1; }; };;
23182   esac
23183 done
23184
23185 # If the user did not use the arguments to specify the items to instantiate,
23186 # then the envvar interface is used.  Set only those that are not.
23187 # We use the long form for the default assignment because of an extremely
23188 # bizarre bug on SunOS 4.1.3.
23189 if $ac_need_defaults; then
23190   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23191   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23192   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
23193   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
23194 fi
23195
23196 # Have a temporary directory for convenience.  Make it in the build tree
23197 # simply because there is no reason to put it here, and in addition,
23198 # creating and moving files from /tmp can sometimes cause problems.
23199 # Create a temporary directory, and hook for its removal unless debugging.
23200 $debug ||
23201 {
23202   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
23203   trap '{ (exit 1); exit 1; }' 1 2 13 15
23204 }
23205
23206 # Create a (secure) tmp directory for tmp files.
23207
23208 {
23209   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
23210   test -n "$tmp" && test -d "$tmp"
23211 }  ||
23212 {
23213   tmp=./confstat$$-$RANDOM
23214   (umask 077 && mkdir $tmp)
23215 } ||
23216 {
23217    echo "$me: cannot create a temporary directory in ." >&2
23218    { (exit 1); exit 1; }
23219 }
23220
23221 _ACEOF
23222
23223 cat >>$CONFIG_STATUS <<_ACEOF
23224
23225 #
23226 # CONFIG_FILES section.
23227 #
23228
23229 # No need to generate the scripts if there are no CONFIG_FILES.
23230 # This happens for instance when ./config.status config.h
23231 if test -n "\$CONFIG_FILES"; then
23232   # Protect against being on the right side of a sed subst in config.status.
23233   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
23234    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
23235 s,@SHELL@,$SHELL,;t t
23236 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
23237 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
23238 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
23239 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
23240 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
23241 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
23242 s,@exec_prefix@,$exec_prefix,;t t
23243 s,@prefix@,$prefix,;t t
23244 s,@program_transform_name@,$program_transform_name,;t t
23245 s,@bindir@,$bindir,;t t
23246 s,@sbindir@,$sbindir,;t t
23247 s,@libexecdir@,$libexecdir,;t t
23248 s,@datadir@,$datadir,;t t
23249 s,@sysconfdir@,$sysconfdir,;t t
23250 s,@sharedstatedir@,$sharedstatedir,;t t
23251 s,@localstatedir@,$localstatedir,;t t
23252 s,@libdir@,$libdir,;t t
23253 s,@includedir@,$includedir,;t t
23254 s,@oldincludedir@,$oldincludedir,;t t
23255 s,@infodir@,$infodir,;t t
23256 s,@mandir@,$mandir,;t t
23257 s,@build_alias@,$build_alias,;t t
23258 s,@host_alias@,$host_alias,;t t
23259 s,@target_alias@,$target_alias,;t t
23260 s,@DEFS@,$DEFS,;t t
23261 s,@ECHO_C@,$ECHO_C,;t t
23262 s,@ECHO_N@,$ECHO_N,;t t
23263 s,@ECHO_T@,$ECHO_T,;t t
23264 s,@LIBS@,$LIBS,;t t
23265 s,@configure_args@,$configure_args,;t t
23266 s,@build@,$build,;t t
23267 s,@build_cpu@,$build_cpu,;t t
23268 s,@build_vendor@,$build_vendor,;t t
23269 s,@build_os@,$build_os,;t t
23270 s,@host@,$host,;t t
23271 s,@host_cpu@,$host_cpu,;t t
23272 s,@host_vendor@,$host_vendor,;t t
23273 s,@host_os@,$host_os,;t t
23274 s,@PORTNAME@,$PORTNAME,;t t
23275 s,@docdir@,$docdir,;t t
23276 s,@enable_nls@,$enable_nls,;t t
23277 s,@WANTED_LANGUAGES@,$WANTED_LANGUAGES,;t t
23278 s,@default_port@,$default_port,;t t
23279 s,@enable_shared@,$enable_shared,;t t
23280 s,@enable_rpath@,$enable_rpath,;t t
23281 s,@enable_debug@,$enable_debug,;t t
23282 s,@CC@,$CC,;t t
23283 s,@CFLAGS@,$CFLAGS,;t t
23284 s,@LDFLAGS@,$LDFLAGS,;t t
23285 s,@CPPFLAGS@,$CPPFLAGS,;t t
23286 s,@ac_ct_CC@,$ac_ct_CC,;t t
23287 s,@EXEEXT@,$EXEEXT,;t t
23288 s,@OBJEXT@,$OBJEXT,;t t
23289 s,@CPP@,$CPP,;t t
23290 s,@GCC@,$GCC,;t t
23291 s,@TAS@,$TAS,;t t
23292 s,@autodepend@,$autodepend,;t t
23293 s,@INCLUDES@,$INCLUDES,;t t
23294 s,@enable_thread_safety@,$enable_thread_safety,;t t
23295 s,@with_tcl@,$with_tcl,;t t
23296 s,@with_perl@,$with_perl,;t t
23297 s,@with_python@,$with_python,;t t
23298 s,@with_krb5@,$with_krb5,;t t
23299 s,@krb_srvtab@,$krb_srvtab,;t t
23300 s,@with_pam@,$with_pam,;t t
23301 s,@with_ldap@,$with_ldap,;t t
23302 s,@with_bonjour@,$with_bonjour,;t t
23303 s,@with_openssl@,$with_openssl,;t t
23304 s,@with_zlib@,$with_zlib,;t t
23305 s,@EGREP@,$EGREP,;t t
23306 s,@ELF_SYS@,$ELF_SYS,;t t
23307 s,@LDFLAGS_SL@,$LDFLAGS_SL,;t t
23308 s,@AWK@,$AWK,;t t
23309 s,@FLEX@,$FLEX,;t t
23310 s,@FLEXFLAGS@,$FLEXFLAGS,;t t
23311 s,@LN_S@,$LN_S,;t t
23312 s,@LD@,$LD,;t t
23313 s,@with_gnu_ld@,$with_gnu_ld,;t t
23314 s,@ld_R_works@,$ld_R_works,;t t
23315 s,@RANLIB@,$RANLIB,;t t
23316 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
23317 s,@LORDER@,$LORDER,;t t
23318 s,@TAR@,$TAR,;t t
23319 s,@STRIP@,$STRIP,;t t
23320 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
23321 s,@STRIP_STATIC_LIB@,$STRIP_STATIC_LIB,;t t
23322 s,@STRIP_SHARED_LIB@,$STRIP_SHARED_LIB,;t t
23323 s,@YACC@,$YACC,;t t
23324 s,@YFLAGS@,$YFLAGS,;t t
23325 s,@PERL@,$PERL,;t t
23326 s,@perl_archlibexp@,$perl_archlibexp,;t t
23327 s,@perl_privlibexp@,$perl_privlibexp,;t t
23328 s,@perl_useshrplib@,$perl_useshrplib,;t t
23329 s,@perl_embed_ldflags@,$perl_embed_ldflags,;t t
23330 s,@PYTHON@,$PYTHON,;t t
23331 s,@python_version@,$python_version,;t t
23332 s,@python_configdir@,$python_configdir,;t t
23333 s,@python_includespec@,$python_includespec,;t t
23334 s,@python_libdir@,$python_libdir,;t t
23335 s,@python_libspec@,$python_libspec,;t t
23336 s,@python_additional_libs@,$python_additional_libs,;t t
23337 s,@HAVE_IPV6@,$HAVE_IPV6,;t t
23338 s,@LIBOBJS@,$LIBOBJS,;t t
23339 s,@acx_pthread_config@,$acx_pthread_config,;t t
23340 s,@PTHREAD_CC@,$PTHREAD_CC,;t t
23341 s,@PTHREAD_LIBS@,$PTHREAD_LIBS,;t t
23342 s,@PTHREAD_CFLAGS@,$PTHREAD_CFLAGS,;t t
23343 s,@HAVE_POSIX_SIGNALS@,$HAVE_POSIX_SIGNALS,;t t
23344 s,@MSGFMT@,$MSGFMT,;t t
23345 s,@MSGMERGE@,$MSGMERGE,;t t
23346 s,@XGETTEXT@,$XGETTEXT,;t t
23347 s,@localedir@,$localedir,;t t
23348 s,@TCLSH@,$TCLSH,;t t
23349 s,@TCL_CONFIG_SH@,$TCL_CONFIG_SH,;t t
23350 s,@TCL_INCLUDE_SPEC@,$TCL_INCLUDE_SPEC,;t t
23351 s,@TCL_LIB_FILE@,$TCL_LIB_FILE,;t t
23352 s,@TCL_LIBS@,$TCL_LIBS,;t t
23353 s,@TCL_LIB_SPEC@,$TCL_LIB_SPEC,;t t
23354 s,@TCL_SHARED_BUILD@,$TCL_SHARED_BUILD,;t t
23355 s,@TCL_SHLIB_LD_LIBS@,$TCL_SHLIB_LD_LIBS,;t t
23356 s,@NSGMLS@,$NSGMLS,;t t
23357 s,@JADE@,$JADE,;t t
23358 s,@have_docbook@,$have_docbook,;t t
23359 s,@DOCBOOKSTYLE@,$DOCBOOKSTYLE,;t t
23360 s,@COLLATEINDEX@,$COLLATEINDEX,;t t
23361 s,@SGMLSPL@,$SGMLSPL,;t t
23362 s,@vpath_build@,$vpath_build,;t t
23363 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
23364 CEOF
23365
23366 _ACEOF
23367
23368   cat >>$CONFIG_STATUS <<\_ACEOF
23369   # Split the substitutions into bite-sized pieces for seds with
23370   # small command number limits, like on Digital OSF/1 and HP-UX.
23371   ac_max_sed_lines=48
23372   ac_sed_frag=1 # Number of current file.
23373   ac_beg=1 # First line for current file.
23374   ac_end=$ac_max_sed_lines # Line after last line for current file.
23375   ac_more_lines=:
23376   ac_sed_cmds=
23377   while $ac_more_lines; do
23378     if test $ac_beg -gt 1; then
23379       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23380     else
23381       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23382     fi
23383     if test ! -s $tmp/subs.frag; then
23384       ac_more_lines=false
23385     else
23386       # The purpose of the label and of the branching condition is to
23387       # speed up the sed processing (if there are no `@' at all, there
23388       # is no need to browse any of the substitutions).
23389       # These are the two extra sed commands mentioned above.
23390       (echo ':t
23391   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
23392       if test -z "$ac_sed_cmds"; then
23393         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
23394       else
23395         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
23396       fi
23397       ac_sed_frag=`expr $ac_sed_frag + 1`
23398       ac_beg=$ac_end
23399       ac_end=`expr $ac_end + $ac_max_sed_lines`
23400     fi
23401   done
23402   if test -z "$ac_sed_cmds"; then
23403     ac_sed_cmds=cat
23404   fi
23405 fi # test -n "$CONFIG_FILES"
23406
23407 _ACEOF
23408 cat >>$CONFIG_STATUS <<\_ACEOF
23409 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
23410   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23411   case $ac_file in
23412   - | *:- | *:-:* ) # input from stdin
23413         cat >$tmp/stdin
23414         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23415         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23416   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23417         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23418   * )   ac_file_in=$ac_file.in ;;
23419   esac
23420
23421   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
23422   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
23423 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23424          X"$ac_file" : 'X\(//\)[^/]' \| \
23425          X"$ac_file" : 'X\(//\)$' \| \
23426          X"$ac_file" : 'X\(/\)' \| \
23427          .     : '\(.\)' 2>/dev/null ||
23428 echo X"$ac_file" |
23429     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23430           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23431           /^X\(\/\/\)$/{ s//\1/; q; }
23432           /^X\(\/\).*/{ s//\1/; q; }
23433           s/.*/./; q'`
23434   { if $as_mkdir_p; then
23435     mkdir -p "$ac_dir"
23436   else
23437     as_dir="$ac_dir"
23438     as_dirs=
23439     while test ! -d "$as_dir"; do
23440       as_dirs="$as_dir $as_dirs"
23441       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23442 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23443          X"$as_dir" : 'X\(//\)[^/]' \| \
23444          X"$as_dir" : 'X\(//\)$' \| \
23445          X"$as_dir" : 'X\(/\)' \| \
23446          .     : '\(.\)' 2>/dev/null ||
23447 echo X"$as_dir" |
23448     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23449           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23450           /^X\(\/\/\)$/{ s//\1/; q; }
23451           /^X\(\/\).*/{ s//\1/; q; }
23452           s/.*/./; q'`
23453     done
23454     test ! -n "$as_dirs" || mkdir $as_dirs
23455   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23456 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23457    { (exit 1); exit 1; }; }; }
23458
23459   ac_builddir=.
23460
23461 if test "$ac_dir" != .; then
23462   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
23463   # A "../" for each directory in $ac_dir_suffix.
23464   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23465 else
23466   ac_dir_suffix= ac_top_builddir=
23467 fi
23468
23469 case $srcdir in
23470   .)  # No --srcdir option.  We are building in place.
23471     ac_srcdir=.
23472     if test -z "$ac_top_builddir"; then
23473        ac_top_srcdir=.
23474     else
23475        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23476     fi ;;
23477   [\\/]* | ?:[\\/]* )  # Absolute path.
23478     ac_srcdir=$srcdir$ac_dir_suffix;
23479     ac_top_srcdir=$srcdir ;;
23480   *) # Relative path.
23481     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23482     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23483 esac
23484
23485 # Do not use `cd foo && pwd` to compute absolute paths, because
23486 # the directories may not exist.
23487 case `pwd` in
23488 .) ac_abs_builddir="$ac_dir";;
23489 *)
23490   case "$ac_dir" in
23491   .) ac_abs_builddir=`pwd`;;
23492   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
23493   *) ac_abs_builddir=`pwd`/"$ac_dir";;
23494   esac;;
23495 esac
23496 case $ac_abs_builddir in
23497 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23498 *)
23499   case ${ac_top_builddir}. in
23500   .) ac_abs_top_builddir=$ac_abs_builddir;;
23501   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23502   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23503   esac;;
23504 esac
23505 case $ac_abs_builddir in
23506 .) ac_abs_srcdir=$ac_srcdir;;
23507 *)
23508   case $ac_srcdir in
23509   .) ac_abs_srcdir=$ac_abs_builddir;;
23510   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23511   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23512   esac;;
23513 esac
23514 case $ac_abs_builddir in
23515 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23516 *)
23517   case $ac_top_srcdir in
23518   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23519   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23520   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23521   esac;;
23522 esac
23523
23524
23525
23526   if test x"$ac_file" != x-; then
23527     { echo "$as_me:$LINENO: creating $ac_file" >&5
23528 echo "$as_me: creating $ac_file" >&6;}
23529     rm -f "$ac_file"
23530   fi
23531   # Let's still pretend it is `configure' which instantiates (i.e., don't
23532   # use $as_me), people would be surprised to read:
23533   #    /* config.h.  Generated by config.status.  */
23534   if test x"$ac_file" = x-; then
23535     configure_input=
23536   else
23537     configure_input="$ac_file.  "
23538   fi
23539   configure_input=$configure_input"Generated from `echo $ac_file_in |
23540                                      sed 's,.*/,,'` by configure."
23541
23542   # First look for the input files in the build tree, otherwise in the
23543   # src tree.
23544   ac_file_inputs=`IFS=:
23545     for f in $ac_file_in; do
23546       case $f in
23547       -) echo $tmp/stdin ;;
23548       [\\/$]*)
23549          # Absolute (can't be DOS-style, as IFS=:)
23550          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23551 echo "$as_me: error: cannot find input file: $f" >&2;}
23552    { (exit 1); exit 1; }; }
23553          echo "$f";;
23554       *) # Relative
23555          if test -f "$f"; then
23556            # Build tree
23557            echo "$f"
23558          elif test -f "$srcdir/$f"; then
23559            # Source tree
23560            echo "$srcdir/$f"
23561          else
23562            # /dev/null tree
23563            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23564 echo "$as_me: error: cannot find input file: $f" >&2;}
23565    { (exit 1); exit 1; }; }
23566          fi;;
23567       esac
23568     done` || { (exit 1); exit 1; }
23569 _ACEOF
23570 cat >>$CONFIG_STATUS <<_ACEOF
23571   sed "$ac_vpsub
23572 $extrasub
23573 _ACEOF
23574 cat >>$CONFIG_STATUS <<\_ACEOF
23575 :t
23576 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23577 s,@configure_input@,$configure_input,;t t
23578 s,@srcdir@,$ac_srcdir,;t t
23579 s,@abs_srcdir@,$ac_abs_srcdir,;t t
23580 s,@top_srcdir@,$ac_top_srcdir,;t t
23581 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
23582 s,@builddir@,$ac_builddir,;t t
23583 s,@abs_builddir@,$ac_abs_builddir,;t t
23584 s,@top_builddir@,$ac_top_builddir,;t t
23585 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
23586 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
23587   rm -f $tmp/stdin
23588   if test x"$ac_file" != x-; then
23589     mv $tmp/out $ac_file
23590   else
23591     cat $tmp/out
23592     rm -f $tmp/out
23593   fi
23594
23595 done
23596 _ACEOF
23597 cat >>$CONFIG_STATUS <<\_ACEOF
23598
23599 #
23600 # CONFIG_HEADER section.
23601 #
23602
23603 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
23604 # NAME is the cpp macro being defined and VALUE is the value it is being given.
23605 #
23606 # ac_d sets the value in "#define NAME VALUE" lines.
23607 ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
23608 ac_dB='[         ].*$,\1#\2'
23609 ac_dC=' '
23610 ac_dD=',;t'
23611 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
23612 ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
23613 ac_uB='$,\1#\2define\3'
23614 ac_uC=' '
23615 ac_uD=',;t'
23616
23617 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
23618   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23619   case $ac_file in
23620   - | *:- | *:-:* ) # input from stdin
23621         cat >$tmp/stdin
23622         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23623         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23624   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23625         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23626   * )   ac_file_in=$ac_file.in ;;
23627   esac
23628
23629   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
23630 echo "$as_me: creating $ac_file" >&6;}
23631
23632   # First look for the input files in the build tree, otherwise in the
23633   # src tree.
23634   ac_file_inputs=`IFS=:
23635     for f in $ac_file_in; do
23636       case $f in
23637       -) echo $tmp/stdin ;;
23638       [\\/$]*)
23639          # Absolute (can't be DOS-style, as IFS=:)
23640          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23641 echo "$as_me: error: cannot find input file: $f" >&2;}
23642    { (exit 1); exit 1; }; }
23643          # Do quote $f, to prevent DOS paths from being IFS'd.
23644          echo "$f";;
23645       *) # Relative
23646          if test -f "$f"; then
23647            # Build tree
23648            echo "$f"
23649          elif test -f "$srcdir/$f"; then
23650            # Source tree
23651            echo "$srcdir/$f"
23652          else
23653            # /dev/null tree
23654            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23655 echo "$as_me: error: cannot find input file: $f" >&2;}
23656    { (exit 1); exit 1; }; }
23657          fi;;
23658       esac
23659     done` || { (exit 1); exit 1; }
23660   # Remove the trailing spaces.
23661   sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
23662
23663 _ACEOF
23664
23665 # Transform confdefs.h into two sed scripts, `conftest.defines' and
23666 # `conftest.undefs', that substitutes the proper values into
23667 # config.h.in to produce config.h.  The first handles `#define'
23668 # templates, and the second `#undef' templates.
23669 # And first: Protect against being on the right side of a sed subst in
23670 # config.status.  Protect against being in an unquoted here document
23671 # in config.status.
23672 rm -f conftest.defines conftest.undefs
23673 # Using a here document instead of a string reduces the quoting nightmare.
23674 # Putting comments in sed scripts is not portable.
23675 #
23676 # `end' is used to avoid that the second main sed command (meant for
23677 # 0-ary CPP macros) applies to n-ary macro definitions.
23678 # See the Autoconf documentation for `clear'.
23679 cat >confdef2sed.sed <<\_ACEOF
23680 s/[\\&,]/\\&/g
23681 s,[\\$`],\\&,g
23682 t clear
23683 : clear
23684 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
23685 t end
23686 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
23687 : end
23688 _ACEOF
23689 # If some macros were called several times there might be several times
23690 # the same #defines, which is useless.  Nevertheless, we may not want to
23691 # sort them, since we want the *last* AC-DEFINE to be honored.
23692 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
23693 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
23694 rm -f confdef2sed.sed
23695
23696 # This sed command replaces #undef with comments.  This is necessary, for
23697 # example, in the case of _POSIX_SOURCE, which is predefined and required
23698 # on some systems where configure will not decide to define it.
23699 cat >>conftest.undefs <<\_ACEOF
23700 s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
23701 _ACEOF
23702
23703 # Break up conftest.defines because some shells have a limit on the size
23704 # of here documents, and old seds have small limits too (100 cmds).
23705 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
23706 echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
23707 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
23708 echo '  :' >>$CONFIG_STATUS
23709 rm -f conftest.tail
23710 while grep . conftest.defines >/dev/null
23711 do
23712   # Write a limited-size here document to $tmp/defines.sed.
23713   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
23714   # Speed up: don't consider the non `#define' lines.
23715   echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
23716   # Work around the forget-to-reset-the-flag bug.
23717   echo 't clr' >>$CONFIG_STATUS
23718   echo ': clr' >>$CONFIG_STATUS
23719   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
23720   echo 'CEOF
23721   sed -f $tmp/defines.sed $tmp/in >$tmp/out
23722   rm -f $tmp/in
23723   mv $tmp/out $tmp/in
23724 ' >>$CONFIG_STATUS
23725   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
23726   rm -f conftest.defines
23727   mv conftest.tail conftest.defines
23728 done
23729 rm -f conftest.defines
23730 echo '  fi # grep' >>$CONFIG_STATUS
23731 echo >>$CONFIG_STATUS
23732
23733 # Break up conftest.undefs because some shells have a limit on the size
23734 # of here documents, and old seds have small limits too (100 cmds).
23735 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
23736 rm -f conftest.tail
23737 while grep . conftest.undefs >/dev/null
23738 do
23739   # Write a limited-size here document to $tmp/undefs.sed.
23740   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
23741   # Speed up: don't consider the non `#undef'
23742   echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
23743   # Work around the forget-to-reset-the-flag bug.
23744   echo 't clr' >>$CONFIG_STATUS
23745   echo ': clr' >>$CONFIG_STATUS
23746   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
23747   echo 'CEOF
23748   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
23749   rm -f $tmp/in
23750   mv $tmp/out $tmp/in
23751 ' >>$CONFIG_STATUS
23752   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
23753   rm -f conftest.undefs
23754   mv conftest.tail conftest.undefs
23755 done
23756 rm -f conftest.undefs
23757
23758 cat >>$CONFIG_STATUS <<\_ACEOF
23759   # Let's still pretend it is `configure' which instantiates (i.e., don't
23760   # use $as_me), people would be surprised to read:
23761   #    /* config.h.  Generated by config.status.  */
23762   if test x"$ac_file" = x-; then
23763     echo "/* Generated by configure.  */" >$tmp/config.h
23764   else
23765     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
23766   fi
23767   cat $tmp/in >>$tmp/config.h
23768   rm -f $tmp/in
23769   if test x"$ac_file" != x-; then
23770     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
23771       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
23772 echo "$as_me: $ac_file is unchanged" >&6;}
23773     else
23774       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
23775 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23776          X"$ac_file" : 'X\(//\)[^/]' \| \
23777          X"$ac_file" : 'X\(//\)$' \| \
23778          X"$ac_file" : 'X\(/\)' \| \
23779          .     : '\(.\)' 2>/dev/null ||
23780 echo X"$ac_file" |
23781     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23782           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23783           /^X\(\/\/\)$/{ s//\1/; q; }
23784           /^X\(\/\).*/{ s//\1/; q; }
23785           s/.*/./; q'`
23786       { if $as_mkdir_p; then
23787     mkdir -p "$ac_dir"
23788   else
23789     as_dir="$ac_dir"
23790     as_dirs=
23791     while test ! -d "$as_dir"; do
23792       as_dirs="$as_dir $as_dirs"
23793       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23794 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23795          X"$as_dir" : 'X\(//\)[^/]' \| \
23796          X"$as_dir" : 'X\(//\)$' \| \
23797          X"$as_dir" : 'X\(/\)' \| \
23798          .     : '\(.\)' 2>/dev/null ||
23799 echo X"$as_dir" |
23800     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23801           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23802           /^X\(\/\/\)$/{ s//\1/; q; }
23803           /^X\(\/\).*/{ s//\1/; q; }
23804           s/.*/./; q'`
23805     done
23806     test ! -n "$as_dirs" || mkdir $as_dirs
23807   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23808 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23809    { (exit 1); exit 1; }; }; }
23810
23811       rm -f $ac_file
23812       mv $tmp/config.h $ac_file
23813     fi
23814   else
23815     cat $tmp/config.h
23816     rm -f $tmp/config.h
23817   fi
23818   # Run the commands associated with the file.
23819   case $ac_file in
23820     src/include/pg_config.h )
23821 # Update timestamp for pg_config.h (see Makefile.global)
23822 echo >src/include/stamp-h
23823  ;;
23824   esac
23825 done
23826 _ACEOF
23827 cat >>$CONFIG_STATUS <<\_ACEOF
23828
23829 #
23830 # CONFIG_LINKS section.
23831 #
23832
23833 for ac_file in : $CONFIG_LINKS; do test "x$ac_file" = x: && continue
23834   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
23835   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
23836
23837   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_dest" >&5
23838 echo "$as_me: linking $srcdir/$ac_source to $ac_dest" >&6;}
23839
23840   if test ! -r $srcdir/$ac_source; then
23841     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
23842 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
23843    { (exit 1); exit 1; }; }
23844   fi
23845   rm -f $ac_dest
23846
23847   # Make relative symlinks.
23848   ac_dest_dir=`(dirname "$ac_dest") 2>/dev/null ||
23849 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23850          X"$ac_dest" : 'X\(//\)[^/]' \| \
23851          X"$ac_dest" : 'X\(//\)$' \| \
23852          X"$ac_dest" : 'X\(/\)' \| \
23853          .     : '\(.\)' 2>/dev/null ||
23854 echo X"$ac_dest" |
23855     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23856           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23857           /^X\(\/\/\)$/{ s//\1/; q; }
23858           /^X\(\/\).*/{ s//\1/; q; }
23859           s/.*/./; q'`
23860   { if $as_mkdir_p; then
23861     mkdir -p "$ac_dest_dir"
23862   else
23863     as_dir="$ac_dest_dir"
23864     as_dirs=
23865     while test ! -d "$as_dir"; do
23866       as_dirs="$as_dir $as_dirs"
23867       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23868 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23869          X"$as_dir" : 'X\(//\)[^/]' \| \
23870          X"$as_dir" : 'X\(//\)$' \| \
23871          X"$as_dir" : 'X\(/\)' \| \
23872          .     : '\(.\)' 2>/dev/null ||
23873 echo X"$as_dir" |
23874     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23875           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23876           /^X\(\/\/\)$/{ s//\1/; q; }
23877           /^X\(\/\).*/{ s//\1/; q; }
23878           s/.*/./; q'`
23879     done
23880     test ! -n "$as_dirs" || mkdir $as_dirs
23881   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dest_dir\"" >&5
23882 echo "$as_me: error: cannot create directory \"$ac_dest_dir\"" >&2;}
23883    { (exit 1); exit 1; }; }; }
23884
23885   ac_builddir=.
23886
23887 if test "$ac_dest_dir" != .; then
23888   ac_dir_suffix=/`echo "$ac_dest_dir" | sed 's,^\.[\\/],,'`
23889   # A "../" for each directory in $ac_dir_suffix.
23890   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23891 else
23892   ac_dir_suffix= ac_top_builddir=
23893 fi
23894
23895 case $srcdir in
23896   .)  # No --srcdir option.  We are building in place.
23897     ac_srcdir=.
23898     if test -z "$ac_top_builddir"; then
23899        ac_top_srcdir=.
23900     else
23901        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23902     fi ;;
23903   [\\/]* | ?:[\\/]* )  # Absolute path.
23904     ac_srcdir=$srcdir$ac_dir_suffix;
23905     ac_top_srcdir=$srcdir ;;
23906   *) # Relative path.
23907     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23908     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23909 esac
23910
23911 # Do not use `cd foo && pwd` to compute absolute paths, because
23912 # the directories may not exist.
23913 case `pwd` in
23914 .) ac_abs_builddir="$ac_dest_dir";;
23915 *)
23916   case "$ac_dest_dir" in
23917   .) ac_abs_builddir=`pwd`;;
23918   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dest_dir";;
23919   *) ac_abs_builddir=`pwd`/"$ac_dest_dir";;
23920   esac;;
23921 esac
23922 case $ac_abs_builddir in
23923 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23924 *)
23925   case ${ac_top_builddir}. in
23926   .) ac_abs_top_builddir=$ac_abs_builddir;;
23927   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23928   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23929   esac;;
23930 esac
23931 case $ac_abs_builddir in
23932 .) ac_abs_srcdir=$ac_srcdir;;
23933 *)
23934   case $ac_srcdir in
23935   .) ac_abs_srcdir=$ac_abs_builddir;;
23936   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23937   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23938   esac;;
23939 esac
23940 case $ac_abs_builddir in
23941 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23942 *)
23943   case $ac_top_srcdir in
23944   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23945   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23946   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23947   esac;;
23948 esac
23949
23950
23951   case $srcdir in
23952   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
23953       *) ac_rel_source=$ac_top_builddir$srcdir/$ac_source ;;
23954   esac
23955
23956   # Try a symlink, then a hard link, then a copy.
23957   ln -s $ac_rel_source $ac_dest 2>/dev/null ||
23958     ln $srcdir/$ac_source $ac_dest 2>/dev/null ||
23959     cp -p $srcdir/$ac_source $ac_dest ||
23960     { { echo "$as_me:$LINENO: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&5
23961 echo "$as_me: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&2;}
23962    { (exit 1); exit 1; }; }
23963 done
23964 _ACEOF
23965 cat >>$CONFIG_STATUS <<\_ACEOF
23966
23967 #
23968 # CONFIG_COMMANDS section.
23969 #
23970 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
23971   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
23972   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
23973   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
23974 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23975          X"$ac_dest" : 'X\(//\)[^/]' \| \
23976          X"$ac_dest" : 'X\(//\)$' \| \
23977          X"$ac_dest" : 'X\(/\)' \| \
23978          .     : '\(.\)' 2>/dev/null ||
23979 echo X"$ac_dest" |
23980     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23981           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23982           /^X\(\/\/\)$/{ s//\1/; q; }
23983           /^X\(\/\).*/{ s//\1/; q; }
23984           s/.*/./; q'`
23985   { if $as_mkdir_p; then
23986     mkdir -p "$ac_dir"
23987   else
23988     as_dir="$ac_dir"
23989     as_dirs=
23990     while test ! -d "$as_dir"; do
23991       as_dirs="$as_dir $as_dirs"
23992       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23993 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23994          X"$as_dir" : 'X\(//\)[^/]' \| \
23995          X"$as_dir" : 'X\(//\)$' \| \
23996          X"$as_dir" : 'X\(/\)' \| \
23997          .     : '\(.\)' 2>/dev/null ||
23998 echo X"$as_dir" |
23999     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
24000           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
24001           /^X\(\/\/\)$/{ s//\1/; q; }
24002           /^X\(\/\).*/{ s//\1/; q; }
24003           s/.*/./; q'`
24004     done
24005     test ! -n "$as_dirs" || mkdir $as_dirs
24006   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
24007 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
24008    { (exit 1); exit 1; }; }; }
24009
24010   ac_builddir=.
24011
24012 if test "$ac_dir" != .; then
24013   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
24014   # A "../" for each directory in $ac_dir_suffix.
24015   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
24016 else
24017   ac_dir_suffix= ac_top_builddir=
24018 fi
24019
24020 case $srcdir in
24021   .)  # No --srcdir option.  We are building in place.
24022     ac_srcdir=.
24023     if test -z "$ac_top_builddir"; then
24024        ac_top_srcdir=.
24025     else
24026        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
24027     fi ;;
24028   [\\/]* | ?:[\\/]* )  # Absolute path.
24029     ac_srcdir=$srcdir$ac_dir_suffix;
24030     ac_top_srcdir=$srcdir ;;
24031   *) # Relative path.
24032     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
24033     ac_top_srcdir=$ac_top_builddir$srcdir ;;
24034 esac
24035
24036 # Do not use `cd foo && pwd` to compute absolute paths, because
24037 # the directories may not exist.
24038 case `pwd` in
24039 .) ac_abs_builddir="$ac_dir";;
24040 *)
24041   case "$ac_dir" in
24042   .) ac_abs_builddir=`pwd`;;
24043   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
24044   *) ac_abs_builddir=`pwd`/"$ac_dir";;
24045   esac;;
24046 esac
24047 case $ac_abs_builddir in
24048 .) ac_abs_top_builddir=${ac_top_builddir}.;;
24049 *)
24050   case ${ac_top_builddir}. in
24051   .) ac_abs_top_builddir=$ac_abs_builddir;;
24052   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
24053   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
24054   esac;;
24055 esac
24056 case $ac_abs_builddir in
24057 .) ac_abs_srcdir=$ac_srcdir;;
24058 *)
24059   case $ac_srcdir in
24060   .) ac_abs_srcdir=$ac_abs_builddir;;
24061   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
24062   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
24063   esac;;
24064 esac
24065 case $ac_abs_builddir in
24066 .) ac_abs_top_srcdir=$ac_top_srcdir;;
24067 *)
24068   case $ac_top_srcdir in
24069   .) ac_abs_top_srcdir=$ac_abs_builddir;;
24070   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
24071   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
24072   esac;;
24073 esac
24074
24075
24076   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
24077 echo "$as_me: executing $ac_dest commands" >&6;}
24078   case $ac_dest in
24079     check_win32_symlinks )
24080 # Links sometimes fail undetected on Mingw -
24081 # so here we detect it and warn the user
24082 for FILE in $CONFIG_LINKS
24083  do
24084         # test -e works for symlinks in the MinGW console
24085         test -e `expr "$FILE" : '\([^:]*\)'` || { echo "$as_me:$LINENO: WARNING: *** link for $FILE - please fix by hand" >&5
24086 echo "$as_me: WARNING: *** link for $FILE - please fix by hand" >&2;}
24087  done
24088  ;;
24089   esac
24090 done
24091 _ACEOF
24092
24093 cat >>$CONFIG_STATUS <<\_ACEOF
24094
24095 { (exit 0); exit 0; }
24096 _ACEOF
24097 chmod +x $CONFIG_STATUS
24098 ac_clean_files=$ac_clean_files_save
24099
24100
24101 # configure is writing to config.log, and then calls config.status.
24102 # config.status does its own redirection, appending to config.log.
24103 # Unfortunately, on DOS this fails, as config.log is still kept open
24104 # by configure, so config.status won't be able to write to it; its
24105 # output is simply discarded.  So we exec the FD to /dev/null,
24106 # effectively closing config.log, so it can be properly (re)opened and
24107 # appended to by config.status.  When coming back to configure, we
24108 # need to make the FD available again.
24109 if test "$no_create" != yes; then
24110   ac_cs_success=:
24111   ac_config_status_args=
24112   test "$silent" = yes &&
24113     ac_config_status_args="$ac_config_status_args --quiet"
24114   exec 5>/dev/null
24115   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
24116   exec 5>>config.log
24117   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24118   # would make configure fail if this is the last instruction.
24119   $ac_cs_success || { (exit 1); exit 1; }
24120 fi
24121
24122