OSDN Git Service

Make --with-ldap build on Unixware, per Olivier Prenant.
[pg-rex/syncrep.git] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.59 for PostgreSQL 8.3devel.
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.3devel'
275 PACKAGE_STRING='PostgreSQL 8.3devel'
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 DTRACE DTRACEFLAGS enable_dtrace 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 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 LDAP_LIBS_FE LDAP_LIBS_BE 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.3devel 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.3devel:";;
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-dtrace         build with DTrace support
869   --enable-depend         turn on automatic dependency tracking
870   --enable-cassert        enable assertion checks (for debugging)
871   --enable-thread-safety  make client libraries thread-safe
872   --enable-thread-safety-force  force thread-safety in spite of thread test failure
873   --disable-largefile     omit support for large files
874
875 Optional Packages:
876   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
877   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
878
879   --with-docdir=DIR       install the documentation in DIR [PREFIX/doc]
880   --without-docdir        do not install the documentation
881   --with-includes=DIRS    look for additional header files in DIRS
882   --with-libraries=DIRS   look for additional libraries in DIRS
883   --with-libs=DIRS        alternative spelling of --with-libraries
884   --with-pgport=PORTNUM   change default port number [5432]
885   --with-tcl              build Tcl modules (PL/Tcl)
886   --with-tclconfig=DIR    tclConfig.sh is in DIR
887   --with-perl             build Perl modules (PL/Perl)
888   --with-python           build Python modules (PL/Python)
889   --with-krb5             build with Kerberos 5 support
890   --with-krb-srvnam=NAME  name of the default service principal in Kerberos [postgres]
891   --with-pam              build with PAM support
892   --with-ldap             build with LDAP support
893   --with-bonjour          build with Bonjour support
894   --with-openssl          build with OpenSSL support
895   --without-readline      do not use GNU Readline nor BSD Libedit for editing
896   --with-libedit-preferred  prefer BSD Libedit over GNU Readline
897   --without-zlib          do not use Zlib
898   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
899
900 Some influential environment variables:
901   CC          C compiler command
902   CFLAGS      C compiler flags
903   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
904               nonstandard directory <lib dir>
905   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
906               headers in a nonstandard directory <include dir>
907   CPP         C preprocessor
908   LDFLAGS_SL
909   DOCBOOKSTYLE
910               location of DocBook stylesheets
911
912 Use these variables to override the choices made by `configure' or to help
913 it to find libraries and programs with nonstandard names/locations.
914
915 Report bugs to <pgsql-bugs@postgresql.org>.
916 _ACEOF
917 fi
918
919 if test "$ac_init_help" = "recursive"; then
920   # If there are subdirs, report their specific --help.
921   ac_popdir=`pwd`
922   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
923     test -d $ac_dir || continue
924     ac_builddir=.
925
926 if test "$ac_dir" != .; then
927   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
928   # A "../" for each directory in $ac_dir_suffix.
929   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
930 else
931   ac_dir_suffix= ac_top_builddir=
932 fi
933
934 case $srcdir in
935   .)  # No --srcdir option.  We are building in place.
936     ac_srcdir=.
937     if test -z "$ac_top_builddir"; then
938        ac_top_srcdir=.
939     else
940        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
941     fi ;;
942   [\\/]* | ?:[\\/]* )  # Absolute path.
943     ac_srcdir=$srcdir$ac_dir_suffix;
944     ac_top_srcdir=$srcdir ;;
945   *) # Relative path.
946     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
947     ac_top_srcdir=$ac_top_builddir$srcdir ;;
948 esac
949
950 # Do not use `cd foo && pwd` to compute absolute paths, because
951 # the directories may not exist.
952 case `pwd` in
953 .) ac_abs_builddir="$ac_dir";;
954 *)
955   case "$ac_dir" in
956   .) ac_abs_builddir=`pwd`;;
957   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
958   *) ac_abs_builddir=`pwd`/"$ac_dir";;
959   esac;;
960 esac
961 case $ac_abs_builddir in
962 .) ac_abs_top_builddir=${ac_top_builddir}.;;
963 *)
964   case ${ac_top_builddir}. in
965   .) ac_abs_top_builddir=$ac_abs_builddir;;
966   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
967   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
968   esac;;
969 esac
970 case $ac_abs_builddir in
971 .) ac_abs_srcdir=$ac_srcdir;;
972 *)
973   case $ac_srcdir in
974   .) ac_abs_srcdir=$ac_abs_builddir;;
975   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
976   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
977   esac;;
978 esac
979 case $ac_abs_builddir in
980 .) ac_abs_top_srcdir=$ac_top_srcdir;;
981 *)
982   case $ac_top_srcdir in
983   .) ac_abs_top_srcdir=$ac_abs_builddir;;
984   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
985   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
986   esac;;
987 esac
988
989     cd $ac_dir
990     # Check for guested configure; otherwise get Cygnus style configure.
991     if test -f $ac_srcdir/configure.gnu; then
992       echo
993       $SHELL $ac_srcdir/configure.gnu  --help=recursive
994     elif test -f $ac_srcdir/configure; then
995       echo
996       $SHELL $ac_srcdir/configure  --help=recursive
997     elif test -f $ac_srcdir/configure.ac ||
998            test -f $ac_srcdir/configure.in; then
999       echo
1000       $ac_configure --help
1001     else
1002       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1003     fi
1004     cd $ac_popdir
1005   done
1006 fi
1007
1008 test -n "$ac_init_help" && exit 0
1009 if $ac_init_version; then
1010   cat <<\_ACEOF
1011 PostgreSQL configure 8.3devel
1012 generated by GNU Autoconf 2.59
1013
1014 Copyright (C) 2003 Free Software Foundation, Inc.
1015 This configure script is free software; the Free Software Foundation
1016 gives unlimited permission to copy, distribute and modify it.
1017
1018 Copyright (c) 1996-2006, PostgreSQL Global Development Group
1019 _ACEOF
1020   exit 0
1021 fi
1022 exec 5>config.log
1023 cat >&5 <<_ACEOF
1024 This file contains any messages produced by compilers while
1025 running configure, to aid debugging if configure makes a mistake.
1026
1027 It was created by PostgreSQL $as_me 8.3devel, which was
1028 generated by GNU Autoconf 2.59.  Invocation command line was
1029
1030   $ $0 $@
1031
1032 _ACEOF
1033 {
1034 cat <<_ASUNAME
1035 ## --------- ##
1036 ## Platform. ##
1037 ## --------- ##
1038
1039 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1040 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1041 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1042 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1043 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1044
1045 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1046 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1047
1048 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1049 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1050 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1051 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1052 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1053 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1054 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1055
1056 _ASUNAME
1057
1058 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1059 for as_dir in $PATH
1060 do
1061   IFS=$as_save_IFS
1062   test -z "$as_dir" && as_dir=.
1063   echo "PATH: $as_dir"
1064 done
1065
1066 } >&5
1067
1068 cat >&5 <<_ACEOF
1069
1070
1071 ## ----------- ##
1072 ## Core tests. ##
1073 ## ----------- ##
1074
1075 _ACEOF
1076
1077
1078 # Keep a trace of the command line.
1079 # Strip out --no-create and --no-recursion so they do not pile up.
1080 # Strip out --silent because we don't want to record it for future runs.
1081 # Also quote any args containing shell meta-characters.
1082 # Make two passes to allow for proper duplicate-argument suppression.
1083 ac_configure_args=
1084 ac_configure_args0=
1085 ac_configure_args1=
1086 ac_sep=
1087 ac_must_keep_next=false
1088 for ac_pass in 1 2
1089 do
1090   for ac_arg
1091   do
1092     case $ac_arg in
1093     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1094     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1095     | -silent | --silent | --silen | --sile | --sil)
1096       continue ;;
1097     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1098       ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1099     esac
1100     case $ac_pass in
1101     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1102     2)
1103       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1104       if test $ac_must_keep_next = true; then
1105         ac_must_keep_next=false # Got value, back to normal.
1106       else
1107         case $ac_arg in
1108           *=* | --config-cache | -C | -disable-* | --disable-* \
1109           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1110           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1111           | -with-* | --with-* | -without-* | --without-* | --x)
1112             case "$ac_configure_args0 " in
1113               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1114             esac
1115             ;;
1116           -* ) ac_must_keep_next=true ;;
1117         esac
1118       fi
1119       ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1120       # Get rid of the leading space.
1121       ac_sep=" "
1122       ;;
1123     esac
1124   done
1125 done
1126 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1127 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1128
1129 # When interrupted or exit'd, cleanup temporary files, and complete
1130 # config.log.  We remove comments because anyway the quotes in there
1131 # would cause problems or look ugly.
1132 # WARNING: Be sure not to use single quotes in there, as some shells,
1133 # such as our DU 5.0 friend, will then `close' the trap.
1134 trap 'exit_status=$?
1135   # Save into config.log some information that might help in debugging.
1136   {
1137     echo
1138
1139     cat <<\_ASBOX
1140 ## ---------------- ##
1141 ## Cache variables. ##
1142 ## ---------------- ##
1143 _ASBOX
1144     echo
1145     # The following way of writing the cache mishandles newlines in values,
1146 {
1147   (set) 2>&1 |
1148     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1149     *ac_space=\ *)
1150       sed -n \
1151         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1152           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1153       ;;
1154     *)
1155       sed -n \
1156         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1157       ;;
1158     esac;
1159 }
1160     echo
1161
1162     cat <<\_ASBOX
1163 ## ----------------- ##
1164 ## Output variables. ##
1165 ## ----------------- ##
1166 _ASBOX
1167     echo
1168     for ac_var in $ac_subst_vars
1169     do
1170       eval ac_val=$`echo $ac_var`
1171       echo "$ac_var='"'"'$ac_val'"'"'"
1172     done | sort
1173     echo
1174
1175     if test -n "$ac_subst_files"; then
1176       cat <<\_ASBOX
1177 ## ------------- ##
1178 ## Output files. ##
1179 ## ------------- ##
1180 _ASBOX
1181       echo
1182       for ac_var in $ac_subst_files
1183       do
1184         eval ac_val=$`echo $ac_var`
1185         echo "$ac_var='"'"'$ac_val'"'"'"
1186       done | sort
1187       echo
1188     fi
1189
1190     if test -s confdefs.h; then
1191       cat <<\_ASBOX
1192 ## ----------- ##
1193 ## confdefs.h. ##
1194 ## ----------- ##
1195 _ASBOX
1196       echo
1197       sed "/^$/d" confdefs.h | sort
1198       echo
1199     fi
1200     test "$ac_signal" != 0 &&
1201       echo "$as_me: caught signal $ac_signal"
1202     echo "$as_me: exit $exit_status"
1203   } >&5
1204   rm -f core *.core &&
1205   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1206     exit $exit_status
1207      ' 0
1208 for ac_signal in 1 2 13 15; do
1209   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1210 done
1211 ac_signal=0
1212
1213 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1214 rm -rf conftest* confdefs.h
1215 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1216 echo >confdefs.h
1217
1218 # Predefined preprocessor variables.
1219
1220 cat >>confdefs.h <<_ACEOF
1221 #define PACKAGE_NAME "$PACKAGE_NAME"
1222 _ACEOF
1223
1224
1225 cat >>confdefs.h <<_ACEOF
1226 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1227 _ACEOF
1228
1229
1230 cat >>confdefs.h <<_ACEOF
1231 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1232 _ACEOF
1233
1234
1235 cat >>confdefs.h <<_ACEOF
1236 #define PACKAGE_STRING "$PACKAGE_STRING"
1237 _ACEOF
1238
1239
1240 cat >>confdefs.h <<_ACEOF
1241 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1242 _ACEOF
1243
1244
1245 # Let the site file select an alternate cache file if it wants to.
1246 # Prefer explicitly selected file to automatically selected ones.
1247 if test -z "$CONFIG_SITE"; then
1248   if test "x$prefix" != xNONE; then
1249     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1250   else
1251     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1252   fi
1253 fi
1254 for ac_site_file in $CONFIG_SITE; do
1255   if test -r "$ac_site_file"; then
1256     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1257 echo "$as_me: loading site script $ac_site_file" >&6;}
1258     sed 's/^/| /' "$ac_site_file" >&5
1259     . "$ac_site_file"
1260   fi
1261 done
1262
1263 if test -r "$cache_file"; then
1264   # Some versions of bash will fail to source /dev/null (special
1265   # files actually), so we avoid doing that.
1266   if test -f "$cache_file"; then
1267     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1268 echo "$as_me: loading cache $cache_file" >&6;}
1269     case $cache_file in
1270       [\\/]* | ?:[\\/]* ) . $cache_file;;
1271       *)                      . ./$cache_file;;
1272     esac
1273   fi
1274 else
1275   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1276 echo "$as_me: creating cache $cache_file" >&6;}
1277   >$cache_file
1278 fi
1279
1280 # Check that the precious variables saved in the cache have kept the same
1281 # value.
1282 ac_cache_corrupted=false
1283 for ac_var in `(set) 2>&1 |
1284                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1285   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1286   eval ac_new_set=\$ac_env_${ac_var}_set
1287   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1288   eval ac_new_val="\$ac_env_${ac_var}_value"
1289   case $ac_old_set,$ac_new_set in
1290     set,)
1291       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1292 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1293       ac_cache_corrupted=: ;;
1294     ,set)
1295       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1296 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1297       ac_cache_corrupted=: ;;
1298     ,);;
1299     *)
1300       if test "x$ac_old_val" != "x$ac_new_val"; then
1301         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1302 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1303         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1304 echo "$as_me:   former value:  $ac_old_val" >&2;}
1305         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1306 echo "$as_me:   current value: $ac_new_val" >&2;}
1307         ac_cache_corrupted=:
1308       fi;;
1309   esac
1310   # Pass precious variables to config.status.
1311   if test "$ac_new_set" = set; then
1312     case $ac_new_val in
1313     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1314       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1315     *) ac_arg=$ac_var=$ac_new_val ;;
1316     esac
1317     case " $ac_configure_args " in
1318       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1319       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1320     esac
1321   fi
1322 done
1323 if $ac_cache_corrupted; then
1324   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1325 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1326   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1327 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1328    { (exit 1); exit 1; }; }
1329 fi
1330
1331 ac_ext=c
1332 ac_cpp='$CPP $CPPFLAGS'
1333 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1334 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1335 ac_compiler_gnu=$ac_cv_c_compiler_gnu
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
1367 ac_aux_dir=
1368 for ac_dir in config $srcdir/config; do
1369   if test -f $ac_dir/install-sh; then
1370     ac_aux_dir=$ac_dir
1371     ac_install_sh="$ac_aux_dir/install-sh -c"
1372     break
1373   elif test -f $ac_dir/install.sh; then
1374     ac_aux_dir=$ac_dir
1375     ac_install_sh="$ac_aux_dir/install.sh -c"
1376     break
1377   elif test -f $ac_dir/shtool; then
1378     ac_aux_dir=$ac_dir
1379     ac_install_sh="$ac_aux_dir/shtool install -c"
1380     break
1381   fi
1382 done
1383 if test -z "$ac_aux_dir"; then
1384   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config $srcdir/config" >&5
1385 echo "$as_me: error: cannot find install-sh or install.sh in config $srcdir/config" >&2;}
1386    { (exit 1); exit 1; }; }
1387 fi
1388 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1389 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1390 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1391
1392
1393 configure_args=$ac_configure_args
1394
1395
1396
1397 cat >>confdefs.h <<_ACEOF
1398 #define PG_VERSION "$PACKAGE_VERSION"
1399 _ACEOF
1400
1401
1402 # Make sure we can run config.sub.
1403 $ac_config_sub sun4 >/dev/null 2>&1 ||
1404   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1405 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1406    { (exit 1); exit 1; }; }
1407
1408 echo "$as_me:$LINENO: checking build system type" >&5
1409 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1410 if test "${ac_cv_build+set}" = set; then
1411   echo $ECHO_N "(cached) $ECHO_C" >&6
1412 else
1413   ac_cv_build_alias=$build_alias
1414 test -z "$ac_cv_build_alias" &&
1415   ac_cv_build_alias=`$ac_config_guess`
1416 test -z "$ac_cv_build_alias" &&
1417   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1418 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1419    { (exit 1); exit 1; }; }
1420 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1421   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1422 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1423    { (exit 1); exit 1; }; }
1424
1425 fi
1426 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1427 echo "${ECHO_T}$ac_cv_build" >&6
1428 build=$ac_cv_build
1429 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1430 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1431 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1432
1433
1434 echo "$as_me:$LINENO: checking host system type" >&5
1435 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1436 if test "${ac_cv_host+set}" = set; then
1437   echo $ECHO_N "(cached) $ECHO_C" >&6
1438 else
1439   ac_cv_host_alias=$host_alias
1440 test -z "$ac_cv_host_alias" &&
1441   ac_cv_host_alias=$ac_cv_build_alias
1442 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1443   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1444 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1445    { (exit 1); exit 1; }; }
1446
1447 fi
1448 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1449 echo "${ECHO_T}$ac_cv_host" >&6
1450 host=$ac_cv_host
1451 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1452 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1453 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1454
1455
1456
1457 template=
1458 echo "$as_me:$LINENO: checking which template to use" >&5
1459 echo $ECHO_N "checking which template to use... $ECHO_C" >&6
1460
1461
1462 pgac_args="$pgac_args with_template"
1463
1464
1465 # Check whether --with-template or --without-template was given.
1466 if test "${with_template+set}" = set; then
1467   withval="$with_template"
1468
1469   case $withval in
1470     yes)
1471       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1472 echo "$as_me: error: argument required for --with-template option" >&2;}
1473    { (exit 1); exit 1; }; }
1474       ;;
1475     no)
1476       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1477 echo "$as_me: error: argument required for --with-template option" >&2;}
1478    { (exit 1); exit 1; }; }
1479       ;;
1480     *)
1481
1482   case $withval in
1483     list)   echo; ls "$srcdir/src/template"; exit;;
1484     *)      if test -f "$srcdir/src/template/$with_template" ; then
1485               template=$withval
1486             else
1487               { { echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
1488 echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
1489    { (exit 1); exit 1; }; }
1490             fi;;
1491   esac
1492
1493       ;;
1494   esac
1495
1496 else
1497
1498 # --with-template not given
1499
1500 case $host_os in
1501      aix*) template=aix ;;
1502     bsdi*) template=bsdi ;;
1503   cygwin*) template=cygwin ;;
1504   darwin*) template=darwin ;;
1505     dgux*) template=dgux ;;
1506  freebsd*) template=freebsd ;;
1507     hpux*) template=hpux ;;
1508     irix*) template=irix ;;
1509  linux*|gnu*|k*bsd*-gnu)
1510            template=linux ;;
1511    mingw*) template=win32 ;;
1512   netbsd*) template=netbsd ;;
1513 nextstep*) template=nextstep ;;
1514  openbsd*) template=openbsd ;;
1515      osf*) template=osf ;;
1516      sco*) template=sco ;;
1517  solaris*) template=solaris ;;
1518    sunos*) template=sunos4 ;;
1519  sysv4.2*)
1520         case $host_vendor in
1521           univel) template=univel ;;
1522         esac ;;
1523    sysv4*) template=svr4 ;;
1524    sysv5*) template=unixware ;;
1525   ultrix*) template=ultrix4 ;;
1526 esac
1527
1528   if test x"$template" = x"" ; then
1529     { { echo "$as_me:$LINENO: error:
1530 *******************************************************************
1531 PostgreSQL has apparently not been ported to your platform yet.
1532 To try a manual configuration, look into the src/template directory
1533 for a similar platform and use the '--with-template=' option.
1534
1535 Please also contact <pgsql-ports@postgresql.org> to see about
1536 rectifying this.  Include the above 'checking host system type...'
1537 line.
1538 *******************************************************************
1539 " >&5
1540 echo "$as_me: error:
1541 *******************************************************************
1542 PostgreSQL has apparently not been ported to your platform yet.
1543 To try a manual configuration, look into the src/template directory
1544 for a similar platform and use the '--with-template=' option.
1545
1546 Please also contact <pgsql-ports@postgresql.org> to see about
1547 rectifying this.  Include the above 'checking host system type...'
1548 line.
1549 *******************************************************************
1550 " >&2;}
1551    { (exit 1); exit 1; }; }
1552   fi
1553
1554
1555 fi;
1556
1557
1558 echo "$as_me:$LINENO: result: $template" >&5
1559 echo "${ECHO_T}$template" >&6
1560
1561 PORTNAME=$template
1562
1563
1564 # Initialize default assumption that we do not need separate assembly code
1565 # for TAS (test-and-set).  This can be overridden by the template file
1566 # when it's executed.
1567 need_tas=no
1568 tas_file=dummy.s
1569
1570
1571
1572 ##
1573 ## Command line options
1574 ##
1575
1576 #
1577 # Installation directory for documentation
1578 #
1579
1580 pgac_args="$pgac_args with_docdir"
1581
1582
1583 # Check whether --with-docdir or --without-docdir was given.
1584 if test "${with_docdir+set}" = set; then
1585   withval="$with_docdir"
1586
1587   case $withval in
1588     yes)
1589       { { echo "$as_me:$LINENO: error: option --with-docdir requires an argument" >&5
1590 echo "$as_me: error: option --with-docdir requires an argument" >&2;}
1591    { (exit 1); exit 1; }; }
1592       ;;
1593     no)
1594       docdir=
1595       ;;
1596     *)
1597       docdir=$withval
1598       ;;
1599   esac
1600
1601 else
1602   docdir='${prefix}/doc'
1603 fi;
1604
1605
1606
1607
1608 #
1609 # Add non-standard directories to the include path
1610 #
1611
1612 pgac_args="$pgac_args with_includes"
1613
1614
1615 # Check whether --with-includes or --without-includes was given.
1616 if test "${with_includes+set}" = set; then
1617   withval="$with_includes"
1618
1619   case $withval in
1620     yes)
1621       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1622 echo "$as_me: error: argument required for --with-includes option" >&2;}
1623    { (exit 1); exit 1; }; }
1624       ;;
1625     no)
1626       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1627 echo "$as_me: error: argument required for --with-includes option" >&2;}
1628    { (exit 1); exit 1; }; }
1629       ;;
1630     *)
1631
1632       ;;
1633   esac
1634
1635 fi;
1636
1637
1638
1639 #
1640 # Add non-standard directories to the library search path
1641 #
1642
1643 pgac_args="$pgac_args with_libraries"
1644
1645
1646 # Check whether --with-libraries or --without-libraries was given.
1647 if test "${with_libraries+set}" = set; then
1648   withval="$with_libraries"
1649
1650   case $withval in
1651     yes)
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     no)
1657       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
1658 echo "$as_me: error: argument required for --with-libraries option" >&2;}
1659    { (exit 1); exit 1; }; }
1660       ;;
1661     *)
1662       LIBRARY_DIRS=$withval
1663       ;;
1664   esac
1665
1666 fi;
1667
1668
1669
1670 pgac_args="$pgac_args with_libs"
1671
1672
1673 # Check whether --with-libs or --without-libs was given.
1674 if test "${with_libs+set}" = set; then
1675   withval="$with_libs"
1676
1677   case $withval in
1678     yes)
1679       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1680 echo "$as_me: error: argument required for --with-libs option" >&2;}
1681    { (exit 1); exit 1; }; }
1682       ;;
1683     no)
1684       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1685 echo "$as_me: error: argument required for --with-libs option" >&2;}
1686    { (exit 1); exit 1; }; }
1687       ;;
1688     *)
1689       LIBRARY_DIRS=$withval
1690       ;;
1691   esac
1692
1693 fi;
1694
1695
1696
1697 #
1698 # 64-bit integer date/time storage (--enable-integer-datetimes)
1699 #
1700 echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
1701 echo $ECHO_N "checking whether to build with 64-bit integer date/time support... $ECHO_C" >&6
1702
1703 pgac_args="$pgac_args enable_integer_datetimes"
1704
1705 # Check whether --enable-integer-datetimes or --disable-integer-datetimes was given.
1706 if test "${enable_integer_datetimes+set}" = set; then
1707   enableval="$enable_integer_datetimes"
1708
1709   case $enableval in
1710     yes)
1711
1712 cat >>confdefs.h <<\_ACEOF
1713 #define USE_INTEGER_DATETIMES 1
1714 _ACEOF
1715
1716       ;;
1717     no)
1718       :
1719       ;;
1720     *)
1721       { { echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
1722 echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
1723    { (exit 1); exit 1; }; }
1724       ;;
1725   esac
1726
1727 else
1728   enable_integer_datetimes=no
1729
1730 fi;
1731
1732 echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
1733 echo "${ECHO_T}$enable_integer_datetimes" >&6
1734
1735
1736 #
1737 # NLS
1738 #
1739 echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
1740 echo $ECHO_N "checking whether NLS is wanted... $ECHO_C" >&6
1741
1742 pgac_args="$pgac_args enable_nls"
1743
1744 # Check whether --enable-nls or --disable-nls was given.
1745 if test "${enable_nls+set}" = set; then
1746   enableval="$enable_nls"
1747
1748   case $enableval in
1749     yes)
1750       :
1751       ;;
1752     no)
1753       :
1754       ;;
1755     *)
1756       enable_nls=yes
1757 WANTED_LANGUAGES=$enableval
1758       ;;
1759   esac
1760
1761 else
1762   enable_nls=no
1763 fi;
1764
1765
1766 if test "$enable_nls" = yes; then
1767
1768 cat >>confdefs.h <<\_ACEOF
1769 #define ENABLE_NLS 1
1770 _ACEOF
1771
1772 fi
1773
1774 echo "$as_me:$LINENO: result: $enable_nls" >&5
1775 echo "${ECHO_T}$enable_nls" >&6
1776
1777
1778
1779 #
1780 # Default port number (--with-pgport), default 5432
1781 #
1782 echo "$as_me:$LINENO: checking for default port number" >&5
1783 echo $ECHO_N "checking for default port number... $ECHO_C" >&6
1784
1785 pgac_args="$pgac_args with_pgport"
1786
1787
1788 # Check whether --with-pgport or --without-pgport was given.
1789 if test "${with_pgport+set}" = set; then
1790   withval="$with_pgport"
1791
1792   case $withval in
1793     yes)
1794       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1795 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1796    { (exit 1); exit 1; }; }
1797       ;;
1798     no)
1799       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1800 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1801    { (exit 1); exit 1; }; }
1802       ;;
1803     *)
1804       default_port=$withval
1805       ;;
1806   esac
1807
1808 else
1809   default_port=5432
1810 fi;
1811
1812 echo "$as_me:$LINENO: result: $default_port" >&5
1813 echo "${ECHO_T}$default_port" >&6
1814 # Need both of these because some places want an integer and some a string
1815
1816 cat >>confdefs.h <<_ACEOF
1817 #define DEF_PGPORT ${default_port}
1818 _ACEOF
1819
1820
1821 cat >>confdefs.h <<_ACEOF
1822 #define DEF_PGPORT_STR "${default_port}"
1823 _ACEOF
1824
1825
1826
1827 #
1828 # Option to disable shared libraries
1829 #
1830
1831 pgac_args="$pgac_args enable_shared"
1832
1833 # Check whether --enable-shared or --disable-shared was given.
1834 if test "${enable_shared+set}" = set; then
1835   enableval="$enable_shared"
1836
1837   case $enableval in
1838     yes)
1839       :
1840       ;;
1841     no)
1842       :
1843       ;;
1844     *)
1845       { { echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
1846 echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
1847    { (exit 1); exit 1; }; }
1848       ;;
1849   esac
1850
1851 else
1852   enable_shared=yes
1853
1854 fi;
1855
1856
1857
1858 #
1859 # '-rpath'-like feature can be disabled
1860 #
1861
1862 pgac_args="$pgac_args enable_rpath"
1863
1864 # Check whether --enable-rpath or --disable-rpath was given.
1865 if test "${enable_rpath+set}" = set; then
1866   enableval="$enable_rpath"
1867
1868   case $enableval in
1869     yes)
1870       :
1871       ;;
1872     no)
1873       :
1874       ;;
1875     *)
1876       { { echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
1877 echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
1878    { (exit 1); exit 1; }; }
1879       ;;
1880   esac
1881
1882 else
1883   enable_rpath=yes
1884
1885 fi;
1886
1887
1888
1889 #
1890 # Spinlocks
1891 #
1892
1893 pgac_args="$pgac_args enable_spinlocks"
1894
1895 # Check whether --enable-spinlocks or --disable-spinlocks was given.
1896 if test "${enable_spinlocks+set}" = set; then
1897   enableval="$enable_spinlocks"
1898
1899   case $enableval in
1900     yes)
1901       :
1902       ;;
1903     no)
1904       :
1905       ;;
1906     *)
1907       { { echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
1908 echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
1909    { (exit 1); exit 1; }; }
1910       ;;
1911   esac
1912
1913 else
1914   enable_spinlocks=yes
1915
1916 fi;
1917
1918
1919 #
1920 # --enable-debug adds -g to compiler flags
1921 #
1922
1923 pgac_args="$pgac_args enable_debug"
1924
1925 # Check whether --enable-debug or --disable-debug was given.
1926 if test "${enable_debug+set}" = set; then
1927   enableval="$enable_debug"
1928
1929   case $enableval in
1930     yes)
1931       :
1932       ;;
1933     no)
1934       :
1935       ;;
1936     *)
1937       { { echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
1938 echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
1939    { (exit 1); exit 1; }; }
1940       ;;
1941   esac
1942
1943 else
1944   enable_debug=no
1945
1946 fi;
1947
1948
1949
1950 #
1951 # DTrace
1952 #
1953
1954 pgac_args="$pgac_args enable_dtrace"
1955
1956 # Check whether --enable-dtrace or --disable-dtrace was given.
1957 if test "${enable_dtrace+set}" = set; then
1958   enableval="$enable_dtrace"
1959
1960   case $enableval in
1961     yes)
1962
1963 cat >>confdefs.h <<\_ACEOF
1964 #define ENABLE_DTRACE 1
1965 _ACEOF
1966
1967 for ac_prog in dtrace
1968 do
1969   # Extract the first word of "$ac_prog", so it can be a program name with args.
1970 set dummy $ac_prog; ac_word=$2
1971 echo "$as_me:$LINENO: checking for $ac_word" >&5
1972 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1973 if test "${ac_cv_prog_DTRACE+set}" = set; then
1974   echo $ECHO_N "(cached) $ECHO_C" >&6
1975 else
1976   if test -n "$DTRACE"; then
1977   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
1978 else
1979 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1980 for as_dir in $PATH
1981 do
1982   IFS=$as_save_IFS
1983   test -z "$as_dir" && as_dir=.
1984   for ac_exec_ext in '' $ac_executable_extensions; do
1985   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1986     ac_cv_prog_DTRACE="$ac_prog"
1987     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1988     break 2
1989   fi
1990 done
1991 done
1992
1993 fi
1994 fi
1995 DTRACE=$ac_cv_prog_DTRACE
1996 if test -n "$DTRACE"; then
1997   echo "$as_me:$LINENO: result: $DTRACE" >&5
1998 echo "${ECHO_T}$DTRACE" >&6
1999 else
2000   echo "$as_me:$LINENO: result: no" >&5
2001 echo "${ECHO_T}no" >&6
2002 fi
2003
2004   test -n "$DTRACE" && break
2005 done
2006
2007 if test -z "$DTRACE"; then
2008   { { echo "$as_me:$LINENO: error: dtrace not found" >&5
2009 echo "$as_me: error: dtrace not found" >&2;}
2010    { (exit 1); exit 1; }; }
2011 fi
2012
2013       ;;
2014     no)
2015       :
2016       ;;
2017     *)
2018       { { echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2019 echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2020    { (exit 1); exit 1; }; }
2021       ;;
2022   esac
2023
2024 else
2025   enable_dtrace=no
2026
2027 fi;
2028
2029
2030
2031 #
2032 # C compiler
2033 #
2034
2035 # For historical reasons you can also use --with-CC to specify the C compiler
2036 # to use, although the standard way to do this is to set the CC environment
2037 # variable.
2038
2039 pgac_args="$pgac_args with_CC"
2040
2041
2042 # Check whether --with-CC or --without-CC was given.
2043 if test "${with_CC+set}" = set; then
2044   withval="$with_CC"
2045
2046   case $withval in
2047     yes)
2048       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
2049 echo "$as_me: error: argument required for --with-CC option" >&2;}
2050    { (exit 1); exit 1; }; }
2051       ;;
2052     no)
2053       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
2054 echo "$as_me: error: argument required for --with-CC option" >&2;}
2055    { (exit 1); exit 1; }; }
2056       ;;
2057     *)
2058       CC=$with_CC
2059       ;;
2060   esac
2061
2062 fi;
2063
2064
2065 case $template in
2066   aix) pgac_cc_list="gcc xlc";;
2067  irix) pgac_cc_list="cc";; # no gcc
2068     *) pgac_cc_list="gcc cc";;
2069 esac
2070
2071 ac_ext=c
2072 ac_cpp='$CPP $CPPFLAGS'
2073 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2074 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2075 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2076 if test -n "$ac_tool_prefix"; then
2077   for ac_prog in $pgac_cc_list
2078   do
2079     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2080 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2081 echo "$as_me:$LINENO: checking for $ac_word" >&5
2082 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2083 if test "${ac_cv_prog_CC+set}" = set; then
2084   echo $ECHO_N "(cached) $ECHO_C" >&6
2085 else
2086   if test -n "$CC"; then
2087   ac_cv_prog_CC="$CC" # Let the user override the test.
2088 else
2089 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2090 for as_dir in $PATH
2091 do
2092   IFS=$as_save_IFS
2093   test -z "$as_dir" && as_dir=.
2094   for ac_exec_ext in '' $ac_executable_extensions; do
2095   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2096     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2097     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2098     break 2
2099   fi
2100 done
2101 done
2102
2103 fi
2104 fi
2105 CC=$ac_cv_prog_CC
2106 if test -n "$CC"; then
2107   echo "$as_me:$LINENO: result: $CC" >&5
2108 echo "${ECHO_T}$CC" >&6
2109 else
2110   echo "$as_me:$LINENO: result: no" >&5
2111 echo "${ECHO_T}no" >&6
2112 fi
2113
2114     test -n "$CC" && break
2115   done
2116 fi
2117 if test -z "$CC"; then
2118   ac_ct_CC=$CC
2119   for ac_prog in $pgac_cc_list
2120 do
2121   # Extract the first word of "$ac_prog", so it can be a program name with args.
2122 set dummy $ac_prog; ac_word=$2
2123 echo "$as_me:$LINENO: checking for $ac_word" >&5
2124 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
2125 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2126   echo $ECHO_N "(cached) $ECHO_C" >&6
2127 else
2128   if test -n "$ac_ct_CC"; then
2129   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2130 else
2131 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2132 for as_dir in $PATH
2133 do
2134   IFS=$as_save_IFS
2135   test -z "$as_dir" && as_dir=.
2136   for ac_exec_ext in '' $ac_executable_extensions; do
2137   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
2138     ac_cv_prog_ac_ct_CC="$ac_prog"
2139     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2140     break 2
2141   fi
2142 done
2143 done
2144
2145 fi
2146 fi
2147 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2148 if test -n "$ac_ct_CC"; then
2149   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2150 echo "${ECHO_T}$ac_ct_CC" >&6
2151 else
2152   echo "$as_me:$LINENO: result: no" >&5
2153 echo "${ECHO_T}no" >&6
2154 fi
2155
2156   test -n "$ac_ct_CC" && break
2157 done
2158
2159   CC=$ac_ct_CC
2160 fi
2161
2162
2163 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2164 See \`config.log' for more details." >&5
2165 echo "$as_me: error: no acceptable C compiler found in \$PATH
2166 See \`config.log' for more details." >&2;}
2167    { (exit 1); exit 1; }; }
2168
2169 # Provide some information about the compiler.
2170 echo "$as_me:$LINENO:" \
2171      "checking for C compiler version" >&5
2172 ac_compiler=`set X $ac_compile; echo $2`
2173 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
2174   (eval $ac_compiler --version </dev/null >&5) 2>&5
2175   ac_status=$?
2176   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2177   (exit $ac_status); }
2178 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
2179   (eval $ac_compiler -v </dev/null >&5) 2>&5
2180   ac_status=$?
2181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2182   (exit $ac_status); }
2183 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
2184   (eval $ac_compiler -V </dev/null >&5) 2>&5
2185   ac_status=$?
2186   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2187   (exit $ac_status); }
2188
2189 cat >conftest.$ac_ext <<_ACEOF
2190 /* confdefs.h.  */
2191 _ACEOF
2192 cat confdefs.h >>conftest.$ac_ext
2193 cat >>conftest.$ac_ext <<_ACEOF
2194 /* end confdefs.h.  */
2195
2196 int
2197 main ()
2198 {
2199
2200   ;
2201   return 0;
2202 }
2203 _ACEOF
2204 ac_clean_files_save=$ac_clean_files
2205 ac_clean_files="$ac_clean_files a.out a.exe b.out"
2206 # Try to create an executable without -o first, disregard a.out.
2207 # It will help us diagnose broken compilers, and finding out an intuition
2208 # of exeext.
2209 echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2210 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6
2211 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2212 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2213   (eval $ac_link_default) 2>&5
2214   ac_status=$?
2215   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2216   (exit $ac_status); }; then
2217   # Find the output, starting from the most likely.  This scheme is
2218 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
2219 # resort.
2220
2221 # Be careful to initialize this variable, since it used to be cached.
2222 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2223 ac_cv_exeext=
2224 # b.out is created by i960 compilers.
2225 for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
2226 do
2227   test -f "$ac_file" || continue
2228   case $ac_file in
2229     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
2230         ;;
2231     conftest.$ac_ext )
2232         # This is the source file.
2233         ;;
2234     [ab].out )
2235         # We found the default executable, but exeext='' is most
2236         # certainly right.
2237         break;;
2238     *.* )
2239         ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2240         # FIXME: I believe we export ac_cv_exeext for Libtool,
2241         # but it would be cool to find out if it's true.  Does anybody
2242         # maintain Libtool? --akim.
2243         export ac_cv_exeext
2244         break;;
2245     * )
2246         break;;
2247   esac
2248 done
2249 else
2250   echo "$as_me: failed program was:" >&5
2251 sed 's/^/| /' conftest.$ac_ext >&5
2252
2253 { { echo "$as_me:$LINENO: error: C compiler cannot create executables
2254 See \`config.log' for more details." >&5
2255 echo "$as_me: error: C compiler cannot create executables
2256 See \`config.log' for more details." >&2;}
2257    { (exit 77); exit 77; }; }
2258 fi
2259
2260 ac_exeext=$ac_cv_exeext
2261 echo "$as_me:$LINENO: result: $ac_file" >&5
2262 echo "${ECHO_T}$ac_file" >&6
2263
2264 # Check the compiler produces executables we can run.  If not, either
2265 # the compiler is broken, or we cross compile.
2266 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2267 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2268 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2269 # If not cross compiling, check that we can run a simple program.
2270 if test "$cross_compiling" != yes; then
2271   if { ac_try='./$ac_file'
2272   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2273   (eval $ac_try) 2>&5
2274   ac_status=$?
2275   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2276   (exit $ac_status); }; }; then
2277     cross_compiling=no
2278   else
2279     if test "$cross_compiling" = maybe; then
2280         cross_compiling=yes
2281     else
2282         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2283 If you meant to cross compile, use \`--host'.
2284 See \`config.log' for more details." >&5
2285 echo "$as_me: error: cannot run C compiled programs.
2286 If you meant to cross compile, use \`--host'.
2287 See \`config.log' for more details." >&2;}
2288    { (exit 1); exit 1; }; }
2289     fi
2290   fi
2291 fi
2292 echo "$as_me:$LINENO: result: yes" >&5
2293 echo "${ECHO_T}yes" >&6
2294
2295 rm -f a.out a.exe conftest$ac_cv_exeext b.out
2296 ac_clean_files=$ac_clean_files_save
2297 # Check the compiler produces executables we can run.  If not, either
2298 # the compiler is broken, or we cross compile.
2299 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2300 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2301 echo "$as_me:$LINENO: result: $cross_compiling" >&5
2302 echo "${ECHO_T}$cross_compiling" >&6
2303
2304 echo "$as_me:$LINENO: checking for suffix of executables" >&5
2305 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2306 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2307   (eval $ac_link) 2>&5
2308   ac_status=$?
2309   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2310   (exit $ac_status); }; then
2311   # If both `conftest.exe' and `conftest' are `present' (well, observable)
2312 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
2313 # work properly (i.e., refer to `conftest.exe'), while it won't with
2314 # `rm'.
2315 for ac_file in conftest.exe conftest conftest.*; do
2316   test -f "$ac_file" || continue
2317   case $ac_file in
2318     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
2319     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2320           export ac_cv_exeext
2321           break;;
2322     * ) break;;
2323   esac
2324 done
2325 else
2326   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
2327 See \`config.log' for more details." >&5
2328 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
2329 See \`config.log' for more details." >&2;}
2330    { (exit 1); exit 1; }; }
2331 fi
2332
2333 rm -f conftest$ac_cv_exeext
2334 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2335 echo "${ECHO_T}$ac_cv_exeext" >&6
2336
2337 rm -f conftest.$ac_ext
2338 EXEEXT=$ac_cv_exeext
2339 ac_exeext=$EXEEXT
2340 echo "$as_me:$LINENO: checking for suffix of object files" >&5
2341 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2342 if test "${ac_cv_objext+set}" = set; then
2343   echo $ECHO_N "(cached) $ECHO_C" >&6
2344 else
2345   cat >conftest.$ac_ext <<_ACEOF
2346 /* confdefs.h.  */
2347 _ACEOF
2348 cat confdefs.h >>conftest.$ac_ext
2349 cat >>conftest.$ac_ext <<_ACEOF
2350 /* end confdefs.h.  */
2351
2352 int
2353 main ()
2354 {
2355
2356   ;
2357   return 0;
2358 }
2359 _ACEOF
2360 rm -f conftest.o conftest.obj
2361 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2362   (eval $ac_compile) 2>&5
2363   ac_status=$?
2364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2365   (exit $ac_status); }; then
2366   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2367   case $ac_file in
2368     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
2369     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2370        break;;
2371   esac
2372 done
2373 else
2374   echo "$as_me: failed program was:" >&5
2375 sed 's/^/| /' conftest.$ac_ext >&5
2376
2377 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
2378 See \`config.log' for more details." >&5
2379 echo "$as_me: error: cannot compute suffix of object files: cannot compile
2380 See \`config.log' for more details." >&2;}
2381    { (exit 1); exit 1; }; }
2382 fi
2383
2384 rm -f conftest.$ac_cv_objext conftest.$ac_ext
2385 fi
2386 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2387 echo "${ECHO_T}$ac_cv_objext" >&6
2388 OBJEXT=$ac_cv_objext
2389 ac_objext=$OBJEXT
2390 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2391 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2392 if test "${ac_cv_c_compiler_gnu+set}" = set; then
2393   echo $ECHO_N "(cached) $ECHO_C" >&6
2394 else
2395   cat >conftest.$ac_ext <<_ACEOF
2396 /* confdefs.h.  */
2397 _ACEOF
2398 cat confdefs.h >>conftest.$ac_ext
2399 cat >>conftest.$ac_ext <<_ACEOF
2400 /* end confdefs.h.  */
2401
2402 int
2403 main ()
2404 {
2405 #ifndef __GNUC__
2406        choke me
2407 #endif
2408
2409   ;
2410   return 0;
2411 }
2412 _ACEOF
2413 rm -f conftest.$ac_objext
2414 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2415   (eval $ac_compile) 2>conftest.er1
2416   ac_status=$?
2417   grep -v '^ *+' conftest.er1 >conftest.err
2418   rm -f conftest.er1
2419   cat conftest.err >&5
2420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2421   (exit $ac_status); } &&
2422          { ac_try='test -z "$ac_c_werror_flag"
2423                          || test ! -s conftest.err'
2424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2425   (eval $ac_try) 2>&5
2426   ac_status=$?
2427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2428   (exit $ac_status); }; } &&
2429          { ac_try='test -s conftest.$ac_objext'
2430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2431   (eval $ac_try) 2>&5
2432   ac_status=$?
2433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2434   (exit $ac_status); }; }; then
2435   ac_compiler_gnu=yes
2436 else
2437   echo "$as_me: failed program was:" >&5
2438 sed 's/^/| /' conftest.$ac_ext >&5
2439
2440 ac_compiler_gnu=no
2441 fi
2442 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2443 ac_cv_c_compiler_gnu=$ac_compiler_gnu
2444
2445 fi
2446 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2447 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2448 GCC=`test $ac_compiler_gnu = yes && echo yes`
2449 ac_test_CFLAGS=${CFLAGS+set}
2450 ac_save_CFLAGS=$CFLAGS
2451 CFLAGS="-g"
2452 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2453 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2454 if test "${ac_cv_prog_cc_g+set}" = set; then
2455   echo $ECHO_N "(cached) $ECHO_C" >&6
2456 else
2457   cat >conftest.$ac_ext <<_ACEOF
2458 /* confdefs.h.  */
2459 _ACEOF
2460 cat confdefs.h >>conftest.$ac_ext
2461 cat >>conftest.$ac_ext <<_ACEOF
2462 /* end confdefs.h.  */
2463
2464 int
2465 main ()
2466 {
2467
2468   ;
2469   return 0;
2470 }
2471 _ACEOF
2472 rm -f conftest.$ac_objext
2473 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2474   (eval $ac_compile) 2>conftest.er1
2475   ac_status=$?
2476   grep -v '^ *+' conftest.er1 >conftest.err
2477   rm -f conftest.er1
2478   cat conftest.err >&5
2479   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2480   (exit $ac_status); } &&
2481          { ac_try='test -z "$ac_c_werror_flag"
2482                          || test ! -s conftest.err'
2483   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2484   (eval $ac_try) 2>&5
2485   ac_status=$?
2486   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2487   (exit $ac_status); }; } &&
2488          { ac_try='test -s conftest.$ac_objext'
2489   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2490   (eval $ac_try) 2>&5
2491   ac_status=$?
2492   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2493   (exit $ac_status); }; }; then
2494   ac_cv_prog_cc_g=yes
2495 else
2496   echo "$as_me: failed program was:" >&5
2497 sed 's/^/| /' conftest.$ac_ext >&5
2498
2499 ac_cv_prog_cc_g=no
2500 fi
2501 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2502 fi
2503 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2504 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2505 if test "$ac_test_CFLAGS" = set; then
2506   CFLAGS=$ac_save_CFLAGS
2507 elif test $ac_cv_prog_cc_g = yes; then
2508   if test "$GCC" = yes; then
2509     CFLAGS="-g -O2"
2510   else
2511     CFLAGS="-g"
2512   fi
2513 else
2514   if test "$GCC" = yes; then
2515     CFLAGS="-O2"
2516   else
2517     CFLAGS=
2518   fi
2519 fi
2520 echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
2521 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
2522 if test "${ac_cv_prog_cc_stdc+set}" = set; then
2523   echo $ECHO_N "(cached) $ECHO_C" >&6
2524 else
2525   ac_cv_prog_cc_stdc=no
2526 ac_save_CC=$CC
2527 cat >conftest.$ac_ext <<_ACEOF
2528 /* confdefs.h.  */
2529 _ACEOF
2530 cat confdefs.h >>conftest.$ac_ext
2531 cat >>conftest.$ac_ext <<_ACEOF
2532 /* end confdefs.h.  */
2533 #include <stdarg.h>
2534 #include <stdio.h>
2535 #include <sys/types.h>
2536 #include <sys/stat.h>
2537 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2538 struct buf { int x; };
2539 FILE * (*rcsopen) (struct buf *, struct stat *, int);
2540 static char *e (p, i)
2541      char **p;
2542      int i;
2543 {
2544   return p[i];
2545 }
2546 static char *f (char * (*g) (char **, int), char **p, ...)
2547 {
2548   char *s;
2549   va_list v;
2550   va_start (v,p);
2551   s = g (p, va_arg (v,int));
2552   va_end (v);
2553   return s;
2554 }
2555
2556 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
2557    function prototypes and stuff, but not '\xHH' hex character constants.
2558    These don't provoke an error unfortunately, instead are silently treated
2559    as 'x'.  The following induces an error, until -std1 is added to get
2560    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
2561    array size at least.  It's necessary to write '\x00'==0 to get something
2562    that's true only with -std1.  */
2563 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
2564
2565 int test (int i, double x);
2566 struct s1 {int (*f) (int a);};
2567 struct s2 {int (*f) (double a);};
2568 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2569 int argc;
2570 char **argv;
2571 int
2572 main ()
2573 {
2574 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2575   ;
2576   return 0;
2577 }
2578 _ACEOF
2579 # Don't try gcc -ansi; that turns off useful extensions and
2580 # breaks some systems' header files.
2581 # AIX                   -qlanglvl=ansi
2582 # Ultrix and OSF/1      -std1
2583 # HP-UX 10.20 and later -Ae
2584 # HP-UX older versions  -Aa -D_HPUX_SOURCE
2585 # SVR4                  -Xc -D__EXTENSIONS__
2586 for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2587 do
2588   CC="$ac_save_CC $ac_arg"
2589   rm -f conftest.$ac_objext
2590 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2591   (eval $ac_compile) 2>conftest.er1
2592   ac_status=$?
2593   grep -v '^ *+' conftest.er1 >conftest.err
2594   rm -f conftest.er1
2595   cat conftest.err >&5
2596   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2597   (exit $ac_status); } &&
2598          { ac_try='test -z "$ac_c_werror_flag"
2599                          || test ! -s conftest.err'
2600   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2601   (eval $ac_try) 2>&5
2602   ac_status=$?
2603   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2604   (exit $ac_status); }; } &&
2605          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
2611   ac_cv_prog_cc_stdc=$ac_arg
2612 break
2613 else
2614   echo "$as_me: failed program was:" >&5
2615 sed 's/^/| /' conftest.$ac_ext >&5
2616
2617 fi
2618 rm -f conftest.err conftest.$ac_objext
2619 done
2620 rm -f conftest.$ac_ext conftest.$ac_objext
2621 CC=$ac_save_CC
2622
2623 fi
2624
2625 case "x$ac_cv_prog_cc_stdc" in
2626   x|xno)
2627     echo "$as_me:$LINENO: result: none needed" >&5
2628 echo "${ECHO_T}none needed" >&6 ;;
2629   *)
2630     echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
2631 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
2632     CC="$CC $ac_cv_prog_cc_stdc" ;;
2633 esac
2634
2635 # Some people use a C++ compiler to compile C.  Since we use `exit',
2636 # in C++ we need to declare it.  In case someone uses the same compiler
2637 # for both compiling C and C++ we need to have the C++ compiler decide
2638 # the declaration of exit, since it's the most demanding environment.
2639 cat >conftest.$ac_ext <<_ACEOF
2640 #ifndef __cplusplus
2641   choke me
2642 #endif
2643 _ACEOF
2644 rm -f conftest.$ac_objext
2645 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2646   (eval $ac_compile) 2>conftest.er1
2647   ac_status=$?
2648   grep -v '^ *+' conftest.er1 >conftest.err
2649   rm -f conftest.er1
2650   cat conftest.err >&5
2651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2652   (exit $ac_status); } &&
2653          { ac_try='test -z "$ac_c_werror_flag"
2654                          || test ! -s conftest.err'
2655   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2656   (eval $ac_try) 2>&5
2657   ac_status=$?
2658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2659   (exit $ac_status); }; } &&
2660          { ac_try='test -s conftest.$ac_objext'
2661   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2662   (eval $ac_try) 2>&5
2663   ac_status=$?
2664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2665   (exit $ac_status); }; }; then
2666   for ac_declaration in \
2667    '' \
2668    'extern "C" void std::exit (int) throw (); using std::exit;' \
2669    'extern "C" void std::exit (int); using std::exit;' \
2670    'extern "C" void exit (int) throw ();' \
2671    'extern "C" void exit (int);' \
2672    'void exit (int);'
2673 do
2674   cat >conftest.$ac_ext <<_ACEOF
2675 /* confdefs.h.  */
2676 _ACEOF
2677 cat confdefs.h >>conftest.$ac_ext
2678 cat >>conftest.$ac_ext <<_ACEOF
2679 /* end confdefs.h.  */
2680 $ac_declaration
2681 #include <stdlib.h>
2682 int
2683 main ()
2684 {
2685 exit (42);
2686   ;
2687   return 0;
2688 }
2689 _ACEOF
2690 rm -f conftest.$ac_objext
2691 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2692   (eval $ac_compile) 2>conftest.er1
2693   ac_status=$?
2694   grep -v '^ *+' conftest.er1 >conftest.err
2695   rm -f conftest.er1
2696   cat conftest.err >&5
2697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2698   (exit $ac_status); } &&
2699          { ac_try='test -z "$ac_c_werror_flag"
2700                          || test ! -s conftest.err'
2701   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2702   (eval $ac_try) 2>&5
2703   ac_status=$?
2704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2705   (exit $ac_status); }; } &&
2706          { ac_try='test -s conftest.$ac_objext'
2707   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2708   (eval $ac_try) 2>&5
2709   ac_status=$?
2710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2711   (exit $ac_status); }; }; then
2712   :
2713 else
2714   echo "$as_me: failed program was:" >&5
2715 sed 's/^/| /' conftest.$ac_ext >&5
2716
2717 continue
2718 fi
2719 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2720   cat >conftest.$ac_ext <<_ACEOF
2721 /* confdefs.h.  */
2722 _ACEOF
2723 cat confdefs.h >>conftest.$ac_ext
2724 cat >>conftest.$ac_ext <<_ACEOF
2725 /* end confdefs.h.  */
2726 $ac_declaration
2727 int
2728 main ()
2729 {
2730 exit (42);
2731   ;
2732   return 0;
2733 }
2734 _ACEOF
2735 rm -f conftest.$ac_objext
2736 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2737   (eval $ac_compile) 2>conftest.er1
2738   ac_status=$?
2739   grep -v '^ *+' conftest.er1 >conftest.err
2740   rm -f conftest.er1
2741   cat conftest.err >&5
2742   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2743   (exit $ac_status); } &&
2744          { ac_try='test -z "$ac_c_werror_flag"
2745                          || test ! -s conftest.err'
2746   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2747   (eval $ac_try) 2>&5
2748   ac_status=$?
2749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2750   (exit $ac_status); }; } &&
2751          { ac_try='test -s conftest.$ac_objext'
2752   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2753   (eval $ac_try) 2>&5
2754   ac_status=$?
2755   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2756   (exit $ac_status); }; }; then
2757   break
2758 else
2759   echo "$as_me: failed program was:" >&5
2760 sed 's/^/| /' conftest.$ac_ext >&5
2761
2762 fi
2763 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2764 done
2765 rm -f conftest*
2766 if test -n "$ac_declaration"; then
2767   echo '#ifdef __cplusplus' >>confdefs.h
2768   echo $ac_declaration      >>confdefs.h
2769   echo '#endif'             >>confdefs.h
2770 fi
2771
2772 else
2773   echo "$as_me: failed program was:" >&5
2774 sed 's/^/| /' conftest.$ac_ext >&5
2775
2776 fi
2777 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2778 ac_ext=c
2779 ac_cpp='$CPP $CPPFLAGS'
2780 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2781 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2782 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2783
2784
2785 unset CFLAGS
2786
2787 #
2788 # Read the template
2789 #
2790 . "$srcdir/src/template/$template" || exit
2791
2792 # CFLAGS are selected so:
2793 # If the user specifies something in the environment, that is used.
2794 # else:  If the template file set something, that is used.
2795 # else:  If the compiler is GCC, then we use -O2.
2796 # else:  If the compiler is something else, then we use -0.
2797
2798 if test "$ac_env_CFLAGS_set" = set; then
2799   CFLAGS=$ac_env_CFLAGS_value
2800 elif test "${CFLAGS+set}" = set; then
2801   : # (keep what template set)
2802 elif test "$GCC" = yes; then
2803   CFLAGS="-O2"
2804 else
2805   # if the user selected debug mode, don't use -O
2806   if test "$enable_debug" != yes; then
2807     CFLAGS="-O"
2808   fi
2809 fi
2810
2811 # Some versions of GCC support some additional useful warning flags.
2812 # Check whether they are supported, and add them to CFLAGS if so.
2813
2814 if test "$GCC" = yes; then
2815
2816 # ICC pretends to be GCC but it's lying; it doesn't support these options.
2817 # So we have to check if "GCC" is really ICC.
2818
2819 cat >conftest.$ac_ext <<_ACEOF
2820 /* confdefs.h.  */
2821 _ACEOF
2822 cat confdefs.h >>conftest.$ac_ext
2823 cat >>conftest.$ac_ext <<_ACEOF
2824 /* end confdefs.h.  */
2825
2826 int
2827 main ()
2828 {
2829 #ifndef __INTEL_COMPILER
2830 choke me
2831 #endif
2832   ;
2833   return 0;
2834 }
2835 _ACEOF
2836 rm -f conftest.$ac_objext
2837 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2838   (eval $ac_compile) 2>conftest.er1
2839   ac_status=$?
2840   grep -v '^ *+' conftest.er1 >conftest.err
2841   rm -f conftest.er1
2842   cat conftest.err >&5
2843   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2844   (exit $ac_status); } &&
2845          { ac_try='test -z "$ac_c_werror_flag"
2846                          || test ! -s conftest.err'
2847   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2848   (eval $ac_try) 2>&5
2849   ac_status=$?
2850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2851   (exit $ac_status); }; } &&
2852          { ac_try='test -s conftest.$ac_objext'
2853   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2854   (eval $ac_try) 2>&5
2855   ac_status=$?
2856   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2857   (exit $ac_status); }; }; then
2858   ICC=yes
2859 else
2860   echo "$as_me: failed program was:" >&5
2861 sed 's/^/| /' conftest.$ac_ext >&5
2862
2863 ICC=no
2864 fi
2865 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2866
2867   if test "$ICC" = no; then
2868     CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith -Winline"
2869
2870     echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
2871 echo $ECHO_N "checking if $CC supports -Wdeclaration-after-statement... $ECHO_C" >&6
2872 pgac_save_CFLAGS=$CFLAGS
2873 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
2874 cat >conftest.$ac_ext <<_ACEOF
2875 /* confdefs.h.  */
2876 _ACEOF
2877 cat confdefs.h >>conftest.$ac_ext
2878 cat >>conftest.$ac_ext <<_ACEOF
2879 /* end confdefs.h.  */
2880
2881 int
2882 main ()
2883 {
2884
2885   ;
2886   return 0;
2887 }
2888 _ACEOF
2889 rm -f conftest.$ac_objext
2890 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2891   (eval $ac_compile) 2>conftest.er1
2892   ac_status=$?
2893   grep -v '^ *+' conftest.er1 >conftest.err
2894   rm -f conftest.er1
2895   cat conftest.err >&5
2896   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2897   (exit $ac_status); } &&
2898          { ac_try='test -z "$ac_c_werror_flag"
2899                          || test ! -s conftest.err'
2900   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2901   (eval $ac_try) 2>&5
2902   ac_status=$?
2903   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2904   (exit $ac_status); }; } &&
2905          { ac_try='test -s conftest.$ac_objext'
2906   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2907   (eval $ac_try) 2>&5
2908   ac_status=$?
2909   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2910   (exit $ac_status); }; }; then
2911   echo "$as_me:$LINENO: result: yes" >&5
2912 echo "${ECHO_T}yes" >&6
2913 else
2914   echo "$as_me: failed program was:" >&5
2915 sed 's/^/| /' conftest.$ac_ext >&5
2916
2917 CFLAGS="$pgac_save_CFLAGS"
2918                     echo "$as_me:$LINENO: result: no" >&5
2919 echo "${ECHO_T}no" >&6
2920 fi
2921 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2922
2923     echo "$as_me:$LINENO: checking if $CC supports -Wendif-labels" >&5
2924 echo $ECHO_N "checking if $CC supports -Wendif-labels... $ECHO_C" >&6
2925 pgac_save_CFLAGS=$CFLAGS
2926 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
2927 cat >conftest.$ac_ext <<_ACEOF
2928 /* confdefs.h.  */
2929 _ACEOF
2930 cat confdefs.h >>conftest.$ac_ext
2931 cat >>conftest.$ac_ext <<_ACEOF
2932 /* end confdefs.h.  */
2933
2934 int
2935 main ()
2936 {
2937
2938   ;
2939   return 0;
2940 }
2941 _ACEOF
2942 rm -f conftest.$ac_objext
2943 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2944   (eval $ac_compile) 2>conftest.er1
2945   ac_status=$?
2946   grep -v '^ *+' conftest.er1 >conftest.err
2947   rm -f conftest.er1
2948   cat conftest.err >&5
2949   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2950   (exit $ac_status); } &&
2951          { ac_try='test -z "$ac_c_werror_flag"
2952                          || test ! -s conftest.err'
2953   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2954   (eval $ac_try) 2>&5
2955   ac_status=$?
2956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2957   (exit $ac_status); }; } &&
2958          { ac_try='test -s conftest.$ac_objext'
2959   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2960   (eval $ac_try) 2>&5
2961   ac_status=$?
2962   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2963   (exit $ac_status); }; }; then
2964   echo "$as_me:$LINENO: result: yes" >&5
2965 echo "${ECHO_T}yes" >&6
2966 else
2967   echo "$as_me: failed program was:" >&5
2968 sed 's/^/| /' conftest.$ac_ext >&5
2969
2970 CFLAGS="$pgac_save_CFLAGS"
2971                     echo "$as_me:$LINENO: result: no" >&5
2972 echo "${ECHO_T}no" >&6
2973 fi
2974 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
2975
2976   else
2977     # Intel compiler has a bug/misoptimization in checking for
2978     # division by NAN (NaN == 0), -mp1 fixes it, so add it to the
2979     # CFLAGS.
2980     echo "$as_me:$LINENO: checking if $CC supports -mp1" >&5
2981 echo $ECHO_N "checking if $CC supports -mp1... $ECHO_C" >&6
2982 pgac_save_CFLAGS=$CFLAGS
2983 CFLAGS="$pgac_save_CFLAGS -mp1"
2984 cat >conftest.$ac_ext <<_ACEOF
2985 /* confdefs.h.  */
2986 _ACEOF
2987 cat confdefs.h >>conftest.$ac_ext
2988 cat >>conftest.$ac_ext <<_ACEOF
2989 /* end confdefs.h.  */
2990
2991 int
2992 main ()
2993 {
2994
2995   ;
2996   return 0;
2997 }
2998 _ACEOF
2999 rm -f conftest.$ac_objext
3000 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3001   (eval $ac_compile) 2>conftest.er1
3002   ac_status=$?
3003   grep -v '^ *+' conftest.er1 >conftest.err
3004   rm -f conftest.er1
3005   cat conftest.err >&5
3006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3007   (exit $ac_status); } &&
3008          { ac_try='test -z "$ac_c_werror_flag"
3009                          || test ! -s conftest.err'
3010   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3011   (eval $ac_try) 2>&5
3012   ac_status=$?
3013   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3014   (exit $ac_status); }; } &&
3015          { ac_try='test -s conftest.$ac_objext'
3016   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3017   (eval $ac_try) 2>&5
3018   ac_status=$?
3019   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3020   (exit $ac_status); }; }; then
3021   echo "$as_me:$LINENO: result: yes" >&5
3022 echo "${ECHO_T}yes" >&6
3023 else
3024   echo "$as_me: failed program was:" >&5
3025 sed 's/^/| /' conftest.$ac_ext >&5
3026
3027 CFLAGS="$pgac_save_CFLAGS"
3028                     echo "$as_me:$LINENO: result: no" >&5
3029 echo "${ECHO_T}no" >&6
3030 fi
3031 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3032
3033   fi
3034
3035   # Disable strict-aliasing rules; needed for gcc 3.3+
3036   echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
3037 echo $ECHO_N "checking if $CC supports -fno-strict-aliasing... $ECHO_C" >&6
3038 pgac_save_CFLAGS=$CFLAGS
3039 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
3040 cat >conftest.$ac_ext <<_ACEOF
3041 /* confdefs.h.  */
3042 _ACEOF
3043 cat confdefs.h >>conftest.$ac_ext
3044 cat >>conftest.$ac_ext <<_ACEOF
3045 /* end confdefs.h.  */
3046
3047 int
3048 main ()
3049 {
3050
3051   ;
3052   return 0;
3053 }
3054 _ACEOF
3055 rm -f conftest.$ac_objext
3056 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3057   (eval $ac_compile) 2>conftest.er1
3058   ac_status=$?
3059   grep -v '^ *+' conftest.er1 >conftest.err
3060   rm -f conftest.er1
3061   cat conftest.err >&5
3062   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3063   (exit $ac_status); } &&
3064          { ac_try='test -z "$ac_c_werror_flag"
3065                          || test ! -s conftest.err'
3066   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3067   (eval $ac_try) 2>&5
3068   ac_status=$?
3069   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3070   (exit $ac_status); }; } &&
3071          { ac_try='test -s conftest.$ac_objext'
3072   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3073   (eval $ac_try) 2>&5
3074   ac_status=$?
3075   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3076   (exit $ac_status); }; }; then
3077   echo "$as_me:$LINENO: result: yes" >&5
3078 echo "${ECHO_T}yes" >&6
3079 else
3080   echo "$as_me: failed program was:" >&5
3081 sed 's/^/| /' conftest.$ac_ext >&5
3082
3083 CFLAGS="$pgac_save_CFLAGS"
3084                     echo "$as_me:$LINENO: result: no" >&5
3085 echo "${ECHO_T}no" >&6
3086 fi
3087 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3088
3089 elif test x"${CC}" = x"xlc"; then
3090   # AIX xlc has to have strict aliasing turned off too
3091   echo "$as_me:$LINENO: checking if $CC supports -qnoansialias" >&5
3092 echo $ECHO_N "checking if $CC supports -qnoansialias... $ECHO_C" >&6
3093 pgac_save_CFLAGS=$CFLAGS
3094 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
3095 cat >conftest.$ac_ext <<_ACEOF
3096 /* confdefs.h.  */
3097 _ACEOF
3098 cat confdefs.h >>conftest.$ac_ext
3099 cat >>conftest.$ac_ext <<_ACEOF
3100 /* end confdefs.h.  */
3101
3102 int
3103 main ()
3104 {
3105
3106   ;
3107   return 0;
3108 }
3109 _ACEOF
3110 rm -f conftest.$ac_objext
3111 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3112   (eval $ac_compile) 2>conftest.er1
3113   ac_status=$?
3114   grep -v '^ *+' conftest.er1 >conftest.err
3115   rm -f conftest.er1
3116   cat conftest.err >&5
3117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3118   (exit $ac_status); } &&
3119          { ac_try='test -z "$ac_c_werror_flag"
3120                          || test ! -s conftest.err'
3121   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3122   (eval $ac_try) 2>&5
3123   ac_status=$?
3124   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3125   (exit $ac_status); }; } &&
3126          { ac_try='test -s conftest.$ac_objext'
3127   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3128   (eval $ac_try) 2>&5
3129   ac_status=$?
3130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3131   (exit $ac_status); }; }; then
3132   echo "$as_me:$LINENO: result: yes" >&5
3133 echo "${ECHO_T}yes" >&6
3134 else
3135   echo "$as_me: failed program was:" >&5
3136 sed 's/^/| /' conftest.$ac_ext >&5
3137
3138 CFLAGS="$pgac_save_CFLAGS"
3139                     echo "$as_me:$LINENO: result: no" >&5
3140 echo "${ECHO_T}no" >&6
3141 fi
3142 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3143
3144 fi
3145
3146 # supply -g if --enable-debug
3147 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
3148   CFLAGS="$CFLAGS -g"
3149 fi
3150
3151 { echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
3152 echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
3153
3154 # We already have this in Makefile.win32, but configure needs it too
3155 if test "$PORTNAME" = "win32"; then
3156   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
3157 fi
3158
3159 # Check if the compiler still works with the template settings
3160 echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
3161 echo $ECHO_N "checking whether the C compiler still works... $ECHO_C" >&6
3162 cat >conftest.$ac_ext <<_ACEOF
3163 /* confdefs.h.  */
3164 _ACEOF
3165 cat confdefs.h >>conftest.$ac_ext
3166 cat >>conftest.$ac_ext <<_ACEOF
3167 /* end confdefs.h.  */
3168
3169 int
3170 main ()
3171 {
3172 return 0;
3173   ;
3174   return 0;
3175 }
3176 _ACEOF
3177 rm -f conftest.$ac_objext conftest$ac_exeext
3178 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3179   (eval $ac_link) 2>conftest.er1
3180   ac_status=$?
3181   grep -v '^ *+' conftest.er1 >conftest.err
3182   rm -f conftest.er1
3183   cat conftest.err >&5
3184   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3185   (exit $ac_status); } &&
3186          { ac_try='test -z "$ac_c_werror_flag"
3187                          || test ! -s conftest.err'
3188   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3189   (eval $ac_try) 2>&5
3190   ac_status=$?
3191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3192   (exit $ac_status); }; } &&
3193          { ac_try='test -s conftest$ac_exeext'
3194   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3195   (eval $ac_try) 2>&5
3196   ac_status=$?
3197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3198   (exit $ac_status); }; }; then
3199   echo "$as_me:$LINENO: result: yes" >&5
3200 echo "${ECHO_T}yes" >&6
3201 else
3202   echo "$as_me: failed program was:" >&5
3203 sed 's/^/| /' conftest.$ac_ext >&5
3204
3205 echo "$as_me:$LINENO: result: no" >&5
3206 echo "${ECHO_T}no" >&6
3207    { { echo "$as_me:$LINENO: error: cannot proceed" >&5
3208 echo "$as_me: error: cannot proceed" >&2;}
3209    { (exit 1); exit 1; }; }
3210 fi
3211 rm -f conftest.err conftest.$ac_objext \
3212       conftest$ac_exeext conftest.$ac_ext
3213
3214 # Defend against gcc -ffast-math
3215 if test "$GCC" = yes; then
3216 cat >conftest.$ac_ext <<_ACEOF
3217 /* confdefs.h.  */
3218 _ACEOF
3219 cat confdefs.h >>conftest.$ac_ext
3220 cat >>conftest.$ac_ext <<_ACEOF
3221 /* end confdefs.h.  */
3222
3223 int
3224 main ()
3225 {
3226 #ifdef __FAST_MATH__
3227 choke me
3228 #endif
3229   ;
3230   return 0;
3231 }
3232 _ACEOF
3233 rm -f conftest.$ac_objext
3234 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
3235   (eval $ac_compile) 2>conftest.er1
3236   ac_status=$?
3237   grep -v '^ *+' conftest.er1 >conftest.err
3238   rm -f conftest.er1
3239   cat conftest.err >&5
3240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3241   (exit $ac_status); } &&
3242          { ac_try='test -z "$ac_c_werror_flag"
3243                          || test ! -s conftest.err'
3244   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3245   (eval $ac_try) 2>&5
3246   ac_status=$?
3247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3248   (exit $ac_status); }; } &&
3249          { ac_try='test -s conftest.$ac_objext'
3250   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3251   (eval $ac_try) 2>&5
3252   ac_status=$?
3253   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3254   (exit $ac_status); }; }; then
3255   :
3256 else
3257   echo "$as_me: failed program was:" >&5
3258 sed 's/^/| /' conftest.$ac_ext >&5
3259
3260 { { echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
3261 echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
3262    { (exit 1); exit 1; }; }
3263 fi
3264 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
3265 fi
3266
3267 ac_ext=c
3268 ac_cpp='$CPP $CPPFLAGS'
3269 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3270 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3271 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3272 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
3273 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
3274 # On Suns, sometimes $CPP names a directory.
3275 if test -n "$CPP" && test -d "$CPP"; then
3276   CPP=
3277 fi
3278 if test -z "$CPP"; then
3279   if test "${ac_cv_prog_CPP+set}" = set; then
3280   echo $ECHO_N "(cached) $ECHO_C" >&6
3281 else
3282       # Double quotes because CPP needs to be expanded
3283     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3284     do
3285       ac_preproc_ok=false
3286 for ac_c_preproc_warn_flag in '' yes
3287 do
3288   # Use a header file that comes with gcc, so configuring glibc
3289   # with a fresh cross-compiler works.
3290   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3291   # <limits.h> exists even on freestanding compilers.
3292   # On the NeXT, cc -E runs the code through the compiler's parser,
3293   # not just through cpp. "Syntax error" is here to catch this case.
3294   cat >conftest.$ac_ext <<_ACEOF
3295 /* confdefs.h.  */
3296 _ACEOF
3297 cat confdefs.h >>conftest.$ac_ext
3298 cat >>conftest.$ac_ext <<_ACEOF
3299 /* end confdefs.h.  */
3300 #ifdef __STDC__
3301 # include <limits.h>
3302 #else
3303 # include <assert.h>
3304 #endif
3305                      Syntax error
3306 _ACEOF
3307 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3308   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3309   ac_status=$?
3310   grep -v '^ *+' conftest.er1 >conftest.err
3311   rm -f conftest.er1
3312   cat conftest.err >&5
3313   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3314   (exit $ac_status); } >/dev/null; then
3315   if test -s conftest.err; then
3316     ac_cpp_err=$ac_c_preproc_warn_flag
3317     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3318   else
3319     ac_cpp_err=
3320   fi
3321 else
3322   ac_cpp_err=yes
3323 fi
3324 if test -z "$ac_cpp_err"; then
3325   :
3326 else
3327   echo "$as_me: failed program was:" >&5
3328 sed 's/^/| /' conftest.$ac_ext >&5
3329
3330   # Broken: fails on valid input.
3331 continue
3332 fi
3333 rm -f conftest.err conftest.$ac_ext
3334
3335   # OK, works on sane cases.  Now check whether non-existent headers
3336   # can be detected and how.
3337   cat >conftest.$ac_ext <<_ACEOF
3338 /* confdefs.h.  */
3339 _ACEOF
3340 cat confdefs.h >>conftest.$ac_ext
3341 cat >>conftest.$ac_ext <<_ACEOF
3342 /* end confdefs.h.  */
3343 #include <ac_nonexistent.h>
3344 _ACEOF
3345 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3346   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3347   ac_status=$?
3348   grep -v '^ *+' conftest.er1 >conftest.err
3349   rm -f conftest.er1
3350   cat conftest.err >&5
3351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3352   (exit $ac_status); } >/dev/null; then
3353   if test -s conftest.err; then
3354     ac_cpp_err=$ac_c_preproc_warn_flag
3355     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3356   else
3357     ac_cpp_err=
3358   fi
3359 else
3360   ac_cpp_err=yes
3361 fi
3362 if test -z "$ac_cpp_err"; then
3363   # Broken: success on invalid input.
3364 continue
3365 else
3366   echo "$as_me: failed program was:" >&5
3367 sed 's/^/| /' conftest.$ac_ext >&5
3368
3369   # Passes both tests.
3370 ac_preproc_ok=:
3371 break
3372 fi
3373 rm -f conftest.err conftest.$ac_ext
3374
3375 done
3376 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3377 rm -f conftest.err conftest.$ac_ext
3378 if $ac_preproc_ok; then
3379   break
3380 fi
3381
3382     done
3383     ac_cv_prog_CPP=$CPP
3384
3385 fi
3386   CPP=$ac_cv_prog_CPP
3387 else
3388   ac_cv_prog_CPP=$CPP
3389 fi
3390 echo "$as_me:$LINENO: result: $CPP" >&5
3391 echo "${ECHO_T}$CPP" >&6
3392 ac_preproc_ok=false
3393 for ac_c_preproc_warn_flag in '' yes
3394 do
3395   # Use a header file that comes with gcc, so configuring glibc
3396   # with a fresh cross-compiler works.
3397   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3398   # <limits.h> exists even on freestanding compilers.
3399   # On the NeXT, cc -E runs the code through the compiler's parser,
3400   # not just through cpp. "Syntax error" is here to catch this case.
3401   cat >conftest.$ac_ext <<_ACEOF
3402 /* confdefs.h.  */
3403 _ACEOF
3404 cat confdefs.h >>conftest.$ac_ext
3405 cat >>conftest.$ac_ext <<_ACEOF
3406 /* end confdefs.h.  */
3407 #ifdef __STDC__
3408 # include <limits.h>
3409 #else
3410 # include <assert.h>
3411 #endif
3412                      Syntax error
3413 _ACEOF
3414 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3415   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3416   ac_status=$?
3417   grep -v '^ *+' conftest.er1 >conftest.err
3418   rm -f conftest.er1
3419   cat conftest.err >&5
3420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3421   (exit $ac_status); } >/dev/null; then
3422   if test -s conftest.err; then
3423     ac_cpp_err=$ac_c_preproc_warn_flag
3424     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3425   else
3426     ac_cpp_err=
3427   fi
3428 else
3429   ac_cpp_err=yes
3430 fi
3431 if test -z "$ac_cpp_err"; then
3432   :
3433 else
3434   echo "$as_me: failed program was:" >&5
3435 sed 's/^/| /' conftest.$ac_ext >&5
3436
3437   # Broken: fails on valid input.
3438 continue
3439 fi
3440 rm -f conftest.err conftest.$ac_ext
3441
3442   # OK, works on sane cases.  Now check whether non-existent headers
3443   # can be detected and how.
3444   cat >conftest.$ac_ext <<_ACEOF
3445 /* confdefs.h.  */
3446 _ACEOF
3447 cat confdefs.h >>conftest.$ac_ext
3448 cat >>conftest.$ac_ext <<_ACEOF
3449 /* end confdefs.h.  */
3450 #include <ac_nonexistent.h>
3451 _ACEOF
3452 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
3453   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
3454   ac_status=$?
3455   grep -v '^ *+' conftest.er1 >conftest.err
3456   rm -f conftest.er1
3457   cat conftest.err >&5
3458   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3459   (exit $ac_status); } >/dev/null; then
3460   if test -s conftest.err; then
3461     ac_cpp_err=$ac_c_preproc_warn_flag
3462     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
3463   else
3464     ac_cpp_err=
3465   fi
3466 else
3467   ac_cpp_err=yes
3468 fi
3469 if test -z "$ac_cpp_err"; then
3470   # Broken: success on invalid input.
3471 continue
3472 else
3473   echo "$as_me: failed program was:" >&5
3474 sed 's/^/| /' conftest.$ac_ext >&5
3475
3476   # Passes both tests.
3477 ac_preproc_ok=:
3478 break
3479 fi
3480 rm -f conftest.err conftest.$ac_ext
3481
3482 done
3483 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3484 rm -f conftest.err conftest.$ac_ext
3485 if $ac_preproc_ok; then
3486   :
3487 else
3488   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3489 See \`config.log' for more details." >&5
3490 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3491 See \`config.log' for more details." >&2;}
3492    { (exit 1); exit 1; }; }
3493 fi
3494
3495 ac_ext=c
3496 ac_cpp='$CPP $CPPFLAGS'
3497 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3498 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3499 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3500
3501
3502
3503 # Create compiler version string
3504 if test x"$GCC" = x"yes" ; then
3505   cc_string="GCC `${CC} --version | sed q`"
3506 else
3507   cc_string=$CC
3508 fi
3509
3510 cat >>confdefs.h <<_ACEOF
3511 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string"
3512 _ACEOF
3513
3514
3515
3516 #
3517 # Set up TAS assembly code if needed; the template file has now had its
3518 # chance to request this.
3519 #
3520           ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
3521
3522
3523 if test "$need_tas" = yes ; then
3524   TAS=tas.o
3525 else
3526   TAS=""
3527 fi
3528
3529
3530
3531 #
3532 # Automatic dependency tracking
3533 #
3534
3535 pgac_args="$pgac_args enable_depend"
3536
3537 # Check whether --enable-depend or --disable-depend was given.
3538 if test "${enable_depend+set}" = set; then
3539   enableval="$enable_depend"
3540
3541   case $enableval in
3542     yes)
3543       autodepend=yes
3544       ;;
3545     no)
3546       :
3547       ;;
3548     *)
3549       { { echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
3550 echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
3551    { (exit 1); exit 1; }; }
3552       ;;
3553   esac
3554
3555 else
3556   enable_depend=no
3557
3558 fi;
3559
3560
3561
3562
3563 #
3564 # Enable assert checks
3565 #
3566
3567 pgac_args="$pgac_args enable_cassert"
3568
3569 # Check whether --enable-cassert or --disable-cassert was given.
3570 if test "${enable_cassert+set}" = set; then
3571   enableval="$enable_cassert"
3572
3573   case $enableval in
3574     yes)
3575
3576 cat >>confdefs.h <<\_ACEOF
3577 #define USE_ASSERT_CHECKING 1
3578 _ACEOF
3579
3580       ;;
3581     no)
3582       :
3583       ;;
3584     *)
3585       { { echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
3586 echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
3587    { (exit 1); exit 1; }; }
3588       ;;
3589   esac
3590
3591 else
3592   enable_cassert=no
3593
3594 fi;
3595
3596
3597
3598 #
3599 # Include directories
3600 #
3601 ac_save_IFS=$IFS
3602 IFS="${IFS}${PATH_SEPARATOR}"
3603 # SRCH_INC comes from the template file
3604 for dir in $with_includes $SRCH_INC; do
3605   if test -d "$dir"; then
3606     INCLUDES="$INCLUDES -I$dir"
3607   else
3608     { echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
3609 echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
3610   fi
3611 done
3612 IFS=$ac_save_IFS
3613
3614
3615
3616 #
3617 # Library directories
3618 #
3619 ac_save_IFS=$IFS
3620 IFS="${IFS}${PATH_SEPARATOR}"
3621 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
3622 for dir in $LIBRARY_DIRS $SRCH_LIB; do
3623   if test -d "$dir"; then
3624     LIBDIRS="$LIBDIRS -L$dir"
3625   else
3626     { echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
3627 echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
3628   fi
3629 done
3630 IFS=$ac_save_IFS
3631
3632 #
3633 # Enable thread-safe client libraries
3634 #
3635 echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
3636 echo $ECHO_N "checking allow thread-safe client libraries... $ECHO_C" >&6
3637
3638 pgac_args="$pgac_args enable_thread_safety"
3639
3640 # Check whether --enable-thread-safety or --disable-thread-safety was given.
3641 if test "${enable_thread_safety+set}" = set; then
3642   enableval="$enable_thread_safety"
3643
3644   case $enableval in
3645     yes)
3646       :
3647       ;;
3648     no)
3649       :
3650       ;;
3651     *)
3652       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
3653 echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
3654    { (exit 1); exit 1; }; }
3655       ;;
3656   esac
3657
3658 else
3659   enable_thread_safety=no
3660
3661 fi;
3662
3663
3664 pgac_args="$pgac_args enable_thread_safety_force"
3665
3666 # Check whether --enable-thread-safety-force or --disable-thread-safety-force was given.
3667 if test "${enable_thread_safety_force+set}" = set; then
3668   enableval="$enable_thread_safety_force"
3669
3670   case $enableval in
3671     yes)
3672       :
3673       ;;
3674     no)
3675       :
3676       ;;
3677     *)
3678       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety-force option" >&5
3679 echo "$as_me: error: no argument expected for --enable-thread-safety-force option" >&2;}
3680    { (exit 1); exit 1; }; }
3681       ;;
3682   esac
3683
3684 else
3685   enable_thread_safety_force=no
3686
3687 fi;
3688
3689 if test "$enable_thread_safety" = yes -o \
3690         "$enable_thread_safety_force" = yes; then
3691   enable_thread_safety="yes"    # for 'force'
3692
3693 cat >>confdefs.h <<\_ACEOF
3694 #define ENABLE_THREAD_SAFETY 1
3695 _ACEOF
3696
3697 fi
3698 echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
3699 echo "${ECHO_T}$enable_thread_safety" >&6
3700
3701
3702 #
3703 # Optionally build Tcl modules (PL/Tcl)
3704 #
3705 echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
3706 echo $ECHO_N "checking whether to build with Tcl... $ECHO_C" >&6
3707
3708 pgac_args="$pgac_args with_tcl"
3709
3710
3711 # Check whether --with-tcl or --without-tcl was given.
3712 if test "${with_tcl+set}" = set; then
3713   withval="$with_tcl"
3714
3715   case $withval in
3716     yes)
3717       :
3718       ;;
3719     no)
3720       :
3721       ;;
3722     *)
3723       { { echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
3724 echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
3725    { (exit 1); exit 1; }; }
3726       ;;
3727   esac
3728
3729 else
3730   with_tcl=no
3731
3732 fi;
3733
3734 echo "$as_me:$LINENO: result: $with_tcl" >&5
3735 echo "${ECHO_T}$with_tcl" >&6
3736
3737
3738 # We see if the path to the Tcl/Tk configuration scripts is specified.
3739 # This will override the use of tclsh to find the paths to search.
3740
3741
3742 pgac_args="$pgac_args with_tclconfig"
3743
3744
3745 # Check whether --with-tclconfig or --without-tclconfig was given.
3746 if test "${with_tclconfig+set}" = set; then
3747   withval="$with_tclconfig"
3748
3749   case $withval in
3750     yes)
3751       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3752 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3753    { (exit 1); exit 1; }; }
3754       ;;
3755     no)
3756       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3757 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3758    { (exit 1); exit 1; }; }
3759       ;;
3760     *)
3761
3762       ;;
3763   esac
3764
3765 fi;
3766
3767
3768 #
3769 # Optionally build Perl modules (PL/Perl)
3770 #
3771 echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
3772 echo $ECHO_N "checking whether to build Perl modules... $ECHO_C" >&6
3773
3774 pgac_args="$pgac_args with_perl"
3775
3776
3777 # Check whether --with-perl or --without-perl was given.
3778 if test "${with_perl+set}" = set; then
3779   withval="$with_perl"
3780
3781   case $withval in
3782     yes)
3783       :
3784       ;;
3785     no)
3786       :
3787       ;;
3788     *)
3789       { { echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
3790 echo "$as_me: error: no argument expected for --with-perl option" >&2;}
3791    { (exit 1); exit 1; }; }
3792       ;;
3793   esac
3794
3795 else
3796   with_perl=no
3797
3798 fi;
3799
3800 echo "$as_me:$LINENO: result: $with_perl" >&5
3801 echo "${ECHO_T}$with_perl" >&6
3802
3803
3804 #
3805 # Optionally build Python modules (PL/Python)
3806 #
3807 echo "$as_me:$LINENO: checking whether to build Python modules" >&5
3808 echo $ECHO_N "checking whether to build Python modules... $ECHO_C" >&6
3809
3810 pgac_args="$pgac_args with_python"
3811
3812
3813 # Check whether --with-python or --without-python was given.
3814 if test "${with_python+set}" = set; then
3815   withval="$with_python"
3816
3817   case $withval in
3818     yes)
3819       :
3820       ;;
3821     no)
3822       :
3823       ;;
3824     *)
3825       { { echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
3826 echo "$as_me: error: no argument expected for --with-python option" >&2;}
3827    { (exit 1); exit 1; }; }
3828       ;;
3829   esac
3830
3831 else
3832   with_python=no
3833
3834 fi;
3835
3836 echo "$as_me:$LINENO: result: $with_python" >&5
3837 echo "${ECHO_T}$with_python" >&6
3838
3839
3840 #
3841 # Kerberos 5
3842 #
3843 echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
3844 echo $ECHO_N "checking whether to build with Kerberos 5 support... $ECHO_C" >&6
3845
3846 pgac_args="$pgac_args with_krb5"
3847
3848
3849 # Check whether --with-krb5 or --without-krb5 was given.
3850 if test "${with_krb5+set}" = set; then
3851   withval="$with_krb5"
3852
3853   case $withval in
3854     yes)
3855
3856
3857 cat >>confdefs.h <<\_ACEOF
3858 #define KRB5 1
3859 _ACEOF
3860
3861   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
3862
3863       ;;
3864     no)
3865       :
3866       ;;
3867     *)
3868       { { echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
3869 echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
3870    { (exit 1); exit 1; }; }
3871       ;;
3872   esac
3873
3874 else
3875   with_krb5=no
3876
3877 fi;
3878
3879 echo "$as_me:$LINENO: result: $with_krb5" >&5
3880 echo "${ECHO_T}$with_krb5" >&6
3881
3882
3883
3884
3885
3886
3887 #
3888 # Kerberos configuration parameters
3889 #
3890
3891 pgac_args="$pgac_args with_krb_srvnam"
3892
3893
3894 # Check whether --with-krb-srvnam or --without-krb-srvnam was given.
3895 if test "${with_krb_srvnam+set}" = set; then
3896   withval="$with_krb_srvnam"
3897
3898   case $withval in
3899     yes)
3900       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3901 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3902    { (exit 1); exit 1; }; }
3903       ;;
3904     no)
3905       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3906 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3907    { (exit 1); exit 1; }; }
3908       ;;
3909     *)
3910
3911       ;;
3912   esac
3913
3914 else
3915   with_krb_srvnam="postgres"
3916 fi;
3917
3918
3919 cat >>confdefs.h <<_ACEOF
3920 #define PG_KRB_SRVNAM "$with_krb_srvnam"
3921 _ACEOF
3922
3923
3924
3925 #
3926 # PAM
3927 #
3928 echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
3929 echo $ECHO_N "checking whether to build with PAM support... $ECHO_C" >&6
3930
3931 pgac_args="$pgac_args with_pam"
3932
3933
3934 # Check whether --with-pam or --without-pam was given.
3935 if test "${with_pam+set}" = set; then
3936   withval="$with_pam"
3937
3938   case $withval in
3939     yes)
3940
3941 cat >>confdefs.h <<\_ACEOF
3942 #define USE_PAM 1
3943 _ACEOF
3944
3945       ;;
3946     no)
3947       :
3948       ;;
3949     *)
3950       { { echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
3951 echo "$as_me: error: no argument expected for --with-pam option" >&2;}
3952    { (exit 1); exit 1; }; }
3953       ;;
3954   esac
3955
3956 else
3957   with_pam=no
3958
3959 fi;
3960
3961 echo "$as_me:$LINENO: result: $with_pam" >&5
3962 echo "${ECHO_T}$with_pam" >&6
3963
3964
3965
3966 #
3967 # LDAP
3968 #
3969 echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
3970 echo $ECHO_N "checking whether to build with LDAP support... $ECHO_C" >&6
3971
3972 pgac_args="$pgac_args with_ldap"
3973
3974
3975 # Check whether --with-ldap or --without-ldap was given.
3976 if test "${with_ldap+set}" = set; then
3977   withval="$with_ldap"
3978
3979   case $withval in
3980     yes)
3981
3982 cat >>confdefs.h <<\_ACEOF
3983 #define USE_LDAP 1
3984 _ACEOF
3985
3986       ;;
3987     no)
3988       :
3989       ;;
3990     *)
3991       { { echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
3992 echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
3993    { (exit 1); exit 1; }; }
3994       ;;
3995   esac
3996
3997 else
3998   with_ldap=no
3999
4000 fi;
4001
4002 echo "$as_me:$LINENO: result: $with_ldap" >&5
4003 echo "${ECHO_T}$with_ldap" >&6
4004
4005
4006
4007 #
4008 # Bonjour
4009 #
4010 echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
4011 echo $ECHO_N "checking whether to build with Bonjour support... $ECHO_C" >&6
4012
4013 pgac_args="$pgac_args with_bonjour"
4014
4015
4016 # Check whether --with-bonjour or --without-bonjour was given.
4017 if test "${with_bonjour+set}" = set; then
4018   withval="$with_bonjour"
4019
4020   case $withval in
4021     yes)
4022
4023 cat >>confdefs.h <<\_ACEOF
4024 #define USE_BONJOUR 1
4025 _ACEOF
4026
4027       ;;
4028     no)
4029       :
4030       ;;
4031     *)
4032       { { echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
4033 echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
4034    { (exit 1); exit 1; }; }
4035       ;;
4036   esac
4037
4038 else
4039   with_bonjour=no
4040
4041 fi;
4042
4043 echo "$as_me:$LINENO: result: $with_bonjour" >&5
4044 echo "${ECHO_T}$with_bonjour" >&6
4045
4046
4047
4048 #
4049 # OpenSSL
4050 #
4051 echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
4052 echo $ECHO_N "checking whether to build with OpenSSL support... $ECHO_C" >&6
4053
4054 pgac_args="$pgac_args with_openssl"
4055
4056
4057 # Check whether --with-openssl or --without-openssl was given.
4058 if test "${with_openssl+set}" = set; then
4059   withval="$with_openssl"
4060
4061   case $withval in
4062     yes)
4063
4064 cat >>confdefs.h <<\_ACEOF
4065 #define USE_SSL 1
4066 _ACEOF
4067
4068       ;;
4069     no)
4070       :
4071       ;;
4072     *)
4073       { { echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
4074 echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
4075    { (exit 1); exit 1; }; }
4076       ;;
4077   esac
4078
4079 else
4080   with_openssl=no
4081
4082 fi;
4083
4084 echo "$as_me:$LINENO: result: $with_openssl" >&5
4085 echo "${ECHO_T}$with_openssl" >&6
4086
4087
4088
4089 #
4090 # Readline
4091 #
4092
4093 pgac_args="$pgac_args with_readline"
4094
4095
4096 # Check whether --with-readline or --without-readline was given.
4097 if test "${with_readline+set}" = set; then
4098   withval="$with_readline"
4099
4100   case $withval in
4101     yes)
4102       :
4103       ;;
4104     no)
4105       :
4106       ;;
4107     *)
4108       { { echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
4109 echo "$as_me: error: no argument expected for --with-readline option" >&2;}
4110    { (exit 1); exit 1; }; }
4111       ;;
4112   esac
4113
4114 else
4115   with_readline=yes
4116
4117 fi;
4118
4119 # readline on MinGW has problems with backslashes in psql and other bugs.
4120 # This is particularly a problem with non-US code pages.
4121 # Therefore disable its use until we understand the cause. 2004-07-20
4122 if test "$PORTNAME" = "win32"; then
4123   if test "$with_readline" = yes; then
4124     { echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
4125 echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
4126     with_readline=no
4127   fi
4128 fi
4129
4130
4131 #
4132 # Prefer libedit
4133 #
4134
4135 pgac_args="$pgac_args with_libedit_preferred"
4136
4137
4138 # Check whether --with-libedit-preferred or --without-libedit-preferred was given.
4139 if test "${with_libedit_preferred+set}" = set; then
4140   withval="$with_libedit_preferred"
4141
4142   case $withval in
4143     yes)
4144       :
4145       ;;
4146     no)
4147       :
4148       ;;
4149     *)
4150       { { echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
4151 echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
4152    { (exit 1); exit 1; }; }
4153       ;;
4154   esac
4155
4156 else
4157   with_libedit_preferred=no
4158
4159 fi;
4160
4161
4162
4163 #
4164 # Zlib
4165 #
4166
4167 pgac_args="$pgac_args with_zlib"
4168
4169
4170 # Check whether --with-zlib or --without-zlib was given.
4171 if test "${with_zlib+set}" = set; then
4172   withval="$with_zlib"
4173
4174   case $withval in
4175     yes)
4176       :
4177       ;;
4178     no)
4179       :
4180       ;;
4181     *)
4182       { { echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
4183 echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
4184    { (exit 1); exit 1; }; }
4185       ;;
4186   esac
4187
4188 else
4189   with_zlib=yes
4190
4191 fi;
4192
4193
4194
4195 #
4196 # Elf
4197 #
4198
4199 # Assume system is ELF if it predefines __ELF__ as 1,
4200 # otherwise believe host_os based default.
4201 case $host_os in
4202     freebsd1*|freebsd2*) elf=no;;
4203     freebsd3*|freebsd4*) elf=yes;;
4204 esac
4205
4206
4207 echo "$as_me:$LINENO: checking for egrep" >&5
4208 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
4209 if test "${ac_cv_prog_egrep+set}" = set; then
4210   echo $ECHO_N "(cached) $ECHO_C" >&6
4211 else
4212   if echo a | (grep -E '(a|b)') >/dev/null 2>&1
4213     then ac_cv_prog_egrep='grep -E'
4214     else ac_cv_prog_egrep='egrep'
4215     fi
4216 fi
4217 echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
4218 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
4219  EGREP=$ac_cv_prog_egrep
4220
4221
4222 cat >conftest.$ac_ext <<_ACEOF
4223 /* confdefs.h.  */
4224 _ACEOF
4225 cat confdefs.h >>conftest.$ac_ext
4226 cat >>conftest.$ac_ext <<_ACEOF
4227 /* end confdefs.h.  */
4228 #if __ELF__
4229   yes
4230 #endif
4231
4232 _ACEOF
4233 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4234   $EGREP "yes" >/dev/null 2>&1; then
4235   ELF_SYS=true
4236 else
4237   if test "X$elf" = "Xyes" ; then
4238   ELF_SYS=true
4239 else
4240   ELF_SYS=
4241 fi
4242 fi
4243 rm -f conftest*
4244
4245
4246
4247 #
4248 # Assignments
4249 #
4250
4251 CPPFLAGS="$CPPFLAGS $INCLUDES"
4252 LDFLAGS="$LDFLAGS $LIBDIRS"
4253
4254 { echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
4255 echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
4256 { echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
4257 echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
4258
4259
4260
4261 for ac_prog in gawk mawk nawk awk
4262 do
4263   # Extract the first word of "$ac_prog", so it can be a program name with args.
4264 set dummy $ac_prog; ac_word=$2
4265 echo "$as_me:$LINENO: checking for $ac_word" >&5
4266 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4267 if test "${ac_cv_prog_AWK+set}" = set; then
4268   echo $ECHO_N "(cached) $ECHO_C" >&6
4269 else
4270   if test -n "$AWK"; then
4271   ac_cv_prog_AWK="$AWK" # Let the user override the test.
4272 else
4273 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4274 for as_dir in $PATH
4275 do
4276   IFS=$as_save_IFS
4277   test -z "$as_dir" && as_dir=.
4278   for ac_exec_ext in '' $ac_executable_extensions; do
4279   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4280     ac_cv_prog_AWK="$ac_prog"
4281     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4282     break 2
4283   fi
4284 done
4285 done
4286
4287 fi
4288 fi
4289 AWK=$ac_cv_prog_AWK
4290 if test -n "$AWK"; then
4291   echo "$as_me:$LINENO: result: $AWK" >&5
4292 echo "${ECHO_T}$AWK" >&6
4293 else
4294   echo "$as_me:$LINENO: result: no" >&5
4295 echo "${ECHO_T}no" >&6
4296 fi
4297
4298   test -n "$AWK" && break
4299 done
4300
4301 echo "$as_me:$LINENO: checking for flex" >&5
4302 echo $ECHO_N "checking for flex... $ECHO_C" >&6
4303 if test "${pgac_cv_path_flex+set}" = set; then
4304   echo $ECHO_N "(cached) $ECHO_C" >&6
4305 else
4306   # Let the user override the test
4307 if test -n "$FLEX"; then
4308   pgac_cv_path_flex=$FLEX
4309 else
4310   pgac_save_IFS=$IFS
4311   IFS=$PATH_SEPARATOR
4312   for pgac_dir in $PATH; do
4313     IFS=$pgac_save_IFS
4314     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
4315       pgac_dir=`pwd`
4316     fi
4317     for pgac_prog in flex lex; do
4318       pgac_candidate="$pgac_dir/$pgac_prog"
4319       if test -f "$pgac_candidate" \
4320         && $pgac_candidate --version </dev/null >/dev/null 2>&1
4321       then
4322         echo '%%'  > conftest.l
4323         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
4324           if $pgac_candidate --version | grep ' 2\.5\.3$' >/dev/null 2>&1; then
4325             pgac_broken_flex=$pgac_candidate
4326             continue
4327           fi
4328
4329           pgac_cv_path_flex=$pgac_candidate
4330           break 2
4331         fi
4332       fi
4333     done
4334   done
4335   rm -f conftest.l lex.yy.c
4336   : ${pgac_cv_path_flex=no}
4337 fi
4338
4339 fi
4340 echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
4341 echo "${ECHO_T}$pgac_cv_path_flex" >&6
4342 if test x"$pgac_cv_path_flex" = x"no"; then
4343   if test -n "$pgac_broken_flex"; then
4344     { echo "$as_me:$LINENO: WARNING:
4345 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
4346 *** should get version 2.5.4 or later." >&5
4347 echo "$as_me: WARNING:
4348 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
4349 *** should get version 2.5.4 or later." >&2;}
4350   fi
4351
4352   { echo "$as_me:$LINENO: WARNING:
4353 *** Without Flex you will not be able to build PostgreSQL from CVS or
4354 *** change any of the scanner definition files.  You can obtain Flex from
4355 *** a GNU mirror site.  (If you are using the official distribution of
4356 *** PostgreSQL then you do not need to worry about this because the Flex
4357 *** output is pre-generated.)" >&5
4358 echo "$as_me: WARNING:
4359 *** Without Flex you will not be able to build PostgreSQL from CVS or
4360 *** change any of the scanner definition files.  You can obtain Flex from
4361 *** a GNU mirror site.  (If you are using the official distribution of
4362 *** PostgreSQL then you do not need to worry about this because the Flex
4363 *** output is pre-generated.)" >&2;}
4364 fi
4365
4366 if test x"$pgac_cv_path_flex" = x"no"; then
4367   FLEX=
4368 else
4369   FLEX=$pgac_cv_path_flex
4370 fi
4371
4372
4373
4374
4375 echo "$as_me:$LINENO: checking whether ln -s works" >&5
4376 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
4377 LN_S=$as_ln_s
4378 if test "$LN_S" = "ln -s"; then
4379   echo "$as_me:$LINENO: result: yes" >&5
4380 echo "${ECHO_T}yes" >&6
4381 else
4382   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
4383 echo "${ECHO_T}no, using $LN_S" >&6
4384 fi
4385
4386
4387 # Check whether --with-gnu-ld or --without-gnu-ld was given.
4388 if test "${with_gnu_ld+set}" = set; then
4389   withval="$with_gnu_ld"
4390   test "$withval" = no || with_gnu_ld=yes
4391 else
4392   with_gnu_ld=no
4393 fi;
4394 ac_prog=ld
4395 if test "$GCC" = yes; then
4396   # Check if gcc -print-prog-name=ld gives a path.
4397   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
4398 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
4399   case $host in
4400   *-*-mingw*)
4401     # gcc leaves a trailing carriage return which upsets mingw
4402     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
4403   *)
4404     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
4405   esac
4406   case "$ac_prog" in
4407     # Accept absolute paths.
4408     [\\/]* | [A-Za-z]:[\\/]*)
4409       re_direlt='/[^/][^/]*/\.\./'
4410       # Canonicalize the path of ld
4411       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
4412       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
4413         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
4414       done
4415       test -z "$LD" && LD="$ac_prog"
4416       ;;
4417   "")
4418     # If it fails, then pretend we aren't using GCC.
4419     ac_prog=ld
4420     ;;
4421   *)
4422     # If it is relative, then search for the first ld in PATH.
4423     with_gnu_ld=unknown
4424     ;;
4425   esac
4426 elif test "$with_gnu_ld" = yes; then
4427   echo "$as_me:$LINENO: checking for GNU ld" >&5
4428 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
4429 else
4430   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
4431 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
4432 fi
4433 if test "${ac_cv_path_LD+set}" = set; then
4434   echo $ECHO_N "(cached) $ECHO_C" >&6
4435 else
4436   if test -z "$LD"; then
4437   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
4438   for ac_dir in $PATH; do
4439     test -z "$ac_dir" && ac_dir=.
4440     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
4441       ac_cv_path_LD="$ac_dir/$ac_prog"
4442       # Check to see if the program is GNU ld.  I'd rather use --version,
4443       # but apparently some GNU ld's only accept -v.
4444       # Break only if it was the GNU/non-GNU ld that we prefer.
4445       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
4446         test "$with_gnu_ld" != no && break
4447       else
4448         test "$with_gnu_ld" != yes && break
4449       fi
4450     fi
4451   done
4452   IFS="$ac_save_ifs"
4453 else
4454   ac_cv_path_LD="$LD" # Let the user override the test with a path.
4455 fi
4456 fi
4457
4458 LD="$ac_cv_path_LD"
4459 if test -n "$LD"; then
4460   echo "$as_me:$LINENO: result: $LD" >&5
4461 echo "${ECHO_T}$LD" >&6
4462 else
4463   echo "$as_me:$LINENO: result: no" >&5
4464 echo "${ECHO_T}no" >&6
4465 fi
4466 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
4467 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
4468    { (exit 1); exit 1; }; }
4469 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
4470 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
4471 if test "${ac_cv_prog_gnu_ld+set}" = set; then
4472   echo $ECHO_N "(cached) $ECHO_C" >&6
4473 else
4474   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
4475 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
4476   ac_cv_prog_gnu_ld=yes
4477 else
4478   ac_cv_prog_gnu_ld=no
4479 fi
4480 fi
4481 echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
4482 echo "${ECHO_T}$ac_cv_prog_gnu_ld" >&6
4483 with_gnu_ld=$ac_cv_prog_gnu_ld
4484
4485
4486
4487
4488 case $host_os in sysv5*)
4489   echo "$as_me:$LINENO: checking whether ld -R works" >&5
4490 echo $ECHO_N "checking whether ld -R works... $ECHO_C" >&6
4491 if test "${pgac_cv_prog_ld_R+set}" = set; then
4492   echo $ECHO_N "(cached) $ECHO_C" >&6
4493 else
4494
4495     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
4496     cat >conftest.$ac_ext <<_ACEOF
4497 /* confdefs.h.  */
4498 _ACEOF
4499 cat confdefs.h >>conftest.$ac_ext
4500 cat >>conftest.$ac_ext <<_ACEOF
4501 /* end confdefs.h.  */
4502
4503 int
4504 main ()
4505 {
4506
4507   ;
4508   return 0;
4509 }
4510 _ACEOF
4511 rm -f conftest.$ac_objext conftest$ac_exeext
4512 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4513   (eval $ac_link) 2>conftest.er1
4514   ac_status=$?
4515   grep -v '^ *+' conftest.er1 >conftest.err
4516   rm -f conftest.er1
4517   cat conftest.err >&5
4518   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4519   (exit $ac_status); } &&
4520          { ac_try='test -z "$ac_c_werror_flag"
4521                          || test ! -s conftest.err'
4522   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4523   (eval $ac_try) 2>&5
4524   ac_status=$?
4525   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4526   (exit $ac_status); }; } &&
4527          { ac_try='test -s conftest$ac_exeext'
4528   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4529   (eval $ac_try) 2>&5
4530   ac_status=$?
4531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4532   (exit $ac_status); }; }; then
4533   pgac_cv_prog_ld_R=yes
4534 else
4535   echo "$as_me: failed program was:" >&5
4536 sed 's/^/| /' conftest.$ac_ext >&5
4537
4538 pgac_cv_prog_ld_R=no
4539 fi
4540 rm -f conftest.err conftest.$ac_objext \
4541       conftest$ac_exeext conftest.$ac_ext
4542     LDFLAGS=$pgac_save_LDFLAGS
4543
4544 fi
4545 echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
4546 echo "${ECHO_T}$pgac_cv_prog_ld_R" >&6
4547   ld_R_works=$pgac_cv_prog_ld_R
4548
4549 esac
4550 if test -n "$ac_tool_prefix"; then
4551   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4552 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4553 echo "$as_me:$LINENO: checking for $ac_word" >&5
4554 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4555 if test "${ac_cv_prog_RANLIB+set}" = set; then
4556   echo $ECHO_N "(cached) $ECHO_C" >&6
4557 else
4558   if test -n "$RANLIB"; then
4559   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4560 else
4561 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4562 for as_dir in $PATH
4563 do
4564   IFS=$as_save_IFS
4565   test -z "$as_dir" && as_dir=.
4566   for ac_exec_ext in '' $ac_executable_extensions; do
4567   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4568     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4569     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4570     break 2
4571   fi
4572 done
4573 done
4574
4575 fi
4576 fi
4577 RANLIB=$ac_cv_prog_RANLIB
4578 if test -n "$RANLIB"; then
4579   echo "$as_me:$LINENO: result: $RANLIB" >&5
4580 echo "${ECHO_T}$RANLIB" >&6
4581 else
4582   echo "$as_me:$LINENO: result: no" >&5
4583 echo "${ECHO_T}no" >&6
4584 fi
4585
4586 fi
4587 if test -z "$ac_cv_prog_RANLIB"; then
4588   ac_ct_RANLIB=$RANLIB
4589   # Extract the first word of "ranlib", so it can be a program name with args.
4590 set dummy ranlib; ac_word=$2
4591 echo "$as_me:$LINENO: checking for $ac_word" >&5
4592 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4593 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4594   echo $ECHO_N "(cached) $ECHO_C" >&6
4595 else
4596   if test -n "$ac_ct_RANLIB"; then
4597   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4598 else
4599 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4600 for as_dir in $PATH
4601 do
4602   IFS=$as_save_IFS
4603   test -z "$as_dir" && as_dir=.
4604   for ac_exec_ext in '' $ac_executable_extensions; do
4605   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4606     ac_cv_prog_ac_ct_RANLIB="ranlib"
4607     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4608     break 2
4609   fi
4610 done
4611 done
4612
4613   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
4614 fi
4615 fi
4616 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4617 if test -n "$ac_ct_RANLIB"; then
4618   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
4619 echo "${ECHO_T}$ac_ct_RANLIB" >&6
4620 else
4621   echo "$as_me:$LINENO: result: no" >&5
4622 echo "${ECHO_T}no" >&6
4623 fi
4624
4625   RANLIB=$ac_ct_RANLIB
4626 else
4627   RANLIB="$ac_cv_prog_RANLIB"
4628 fi
4629
4630 # Extract the first word of "tar", so it can be a program name with args.
4631 set dummy tar; ac_word=$2
4632 echo "$as_me:$LINENO: checking for $ac_word" >&5
4633 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4634 if test "${ac_cv_path_TAR+set}" = set; then
4635   echo $ECHO_N "(cached) $ECHO_C" >&6
4636 else
4637   case $TAR in
4638   [\\/]* | ?:[\\/]*)
4639   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
4640   ;;
4641   *)
4642   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4643 for as_dir in $PATH
4644 do
4645   IFS=$as_save_IFS
4646   test -z "$as_dir" && as_dir=.
4647   for ac_exec_ext in '' $ac_executable_extensions; do
4648   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4649     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
4650     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4651     break 2
4652   fi
4653 done
4654 done
4655
4656   ;;
4657 esac
4658 fi
4659 TAR=$ac_cv_path_TAR
4660
4661 if test -n "$TAR"; then
4662   echo "$as_me:$LINENO: result: $TAR" >&5
4663 echo "${ECHO_T}$TAR" >&6
4664 else
4665   echo "$as_me:$LINENO: result: no" >&5
4666 echo "${ECHO_T}no" >&6
4667 fi
4668
4669
4670   if test -n "$ac_tool_prefix"; then
4671   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4672 set dummy ${ac_tool_prefix}strip; ac_word=$2
4673 echo "$as_me:$LINENO: checking for $ac_word" >&5
4674 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4675 if test "${ac_cv_prog_STRIP+set}" = set; then
4676   echo $ECHO_N "(cached) $ECHO_C" >&6
4677 else
4678   if test -n "$STRIP"; then
4679   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4680 else
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_prog_STRIP="${ac_tool_prefix}strip"
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 fi
4696 fi
4697 STRIP=$ac_cv_prog_STRIP
4698 if test -n "$STRIP"; then
4699   echo "$as_me:$LINENO: result: $STRIP" >&5
4700 echo "${ECHO_T}$STRIP" >&6
4701 else
4702   echo "$as_me:$LINENO: result: no" >&5
4703 echo "${ECHO_T}no" >&6
4704 fi
4705
4706 fi
4707 if test -z "$ac_cv_prog_STRIP"; then
4708   ac_ct_STRIP=$STRIP
4709   # Extract the first word of "strip", so it can be a program name with args.
4710 set dummy strip; ac_word=$2
4711 echo "$as_me:$LINENO: checking for $ac_word" >&5
4712 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4713 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
4714   echo $ECHO_N "(cached) $ECHO_C" >&6
4715 else
4716   if test -n "$ac_ct_STRIP"; then
4717   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
4718 else
4719 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4720 for as_dir in $PATH
4721 do
4722   IFS=$as_save_IFS
4723   test -z "$as_dir" && as_dir=.
4724   for ac_exec_ext in '' $ac_executable_extensions; do
4725   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4726     ac_cv_prog_ac_ct_STRIP="strip"
4727     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4728     break 2
4729   fi
4730 done
4731 done
4732
4733   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
4734 fi
4735 fi
4736 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4737 if test -n "$ac_ct_STRIP"; then
4738   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
4739 echo "${ECHO_T}$ac_ct_STRIP" >&6
4740 else
4741   echo "$as_me:$LINENO: result: no" >&5
4742 echo "${ECHO_T}no" >&6
4743 fi
4744
4745   STRIP=$ac_ct_STRIP
4746 else
4747   STRIP="$ac_cv_prog_STRIP"
4748 fi
4749
4750
4751   echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
4752 echo $ECHO_N "checking whether it is possible to strip libraries... $ECHO_C" >&6
4753   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
4754     STRIP_STATIC_LIB="$STRIP -x"
4755     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
4756     echo "$as_me:$LINENO: result: yes" >&5
4757 echo "${ECHO_T}yes" >&6
4758   else
4759     STRIP_STATIC_LIB=:
4760     STRIP_SHARED_LIB=:
4761     echo "$as_me:$LINENO: result: no" >&5
4762 echo "${ECHO_T}no" >&6
4763   fi
4764
4765
4766
4767
4768 if test -z "$YACC"; then
4769   for ac_prog in 'bison -y'
4770 do
4771   # Extract the first word of "$ac_prog", so it can be a program name with args.
4772 set dummy $ac_prog; ac_word=$2
4773 echo "$as_me:$LINENO: checking for $ac_word" >&5
4774 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4775 if test "${ac_cv_prog_YACC+set}" = set; then
4776   echo $ECHO_N "(cached) $ECHO_C" >&6
4777 else
4778   if test -n "$YACC"; then
4779   ac_cv_prog_YACC="$YACC" # Let the user override the test.
4780 else
4781 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4782 for as_dir in $PATH
4783 do
4784   IFS=$as_save_IFS
4785   test -z "$as_dir" && as_dir=.
4786   for ac_exec_ext in '' $ac_executable_extensions; do
4787   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4788     ac_cv_prog_YACC="$ac_prog"
4789     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4790     break 2
4791   fi
4792 done
4793 done
4794
4795 fi
4796 fi
4797 YACC=$ac_cv_prog_YACC
4798 if test -n "$YACC"; then
4799   echo "$as_me:$LINENO: result: $YACC" >&5
4800 echo "${ECHO_T}$YACC" >&6
4801 else
4802   echo "$as_me:$LINENO: result: no" >&5
4803 echo "${ECHO_T}no" >&6
4804 fi
4805
4806   test -n "$YACC" && break
4807 done
4808
4809
4810   if test "$YACC"; then
4811     if $YACC --version | sed q | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'; then
4812       { echo "$as_me:$LINENO: WARNING:
4813 *** The installed version of Bison is too old to use with PostgreSQL.
4814 *** Bison version 1.875 or later is required." >&5
4815 echo "$as_me: WARNING:
4816 *** The installed version of Bison is too old to use with PostgreSQL.
4817 *** Bison version 1.875 or later is required." >&2;}
4818       YACC=""
4819     fi
4820   fi
4821
4822   if test -z "$YACC"; then
4823     { echo "$as_me:$LINENO: WARNING:
4824 *** Without Bison you will not be able to build PostgreSQL from CVS nor
4825 *** change any of the parser definition files.  You can obtain Bison from
4826 *** a GNU mirror site.  (If you are using the official distribution of
4827 *** PostgreSQL then you do not need to worry about this, because the Bison
4828 *** output is pre-generated.)  To use a different yacc program (possible,
4829 *** but not recommended), set the environment variable YACC before running
4830 *** 'configure'." >&5
4831 echo "$as_me: WARNING:
4832 *** Without Bison you will not be able to build PostgreSQL from CVS nor
4833 *** change any of the parser definition files.  You can obtain Bison from
4834 *** a GNU mirror site.  (If you are using the official distribution of
4835 *** PostgreSQL then you do not need to worry about this, because the Bison
4836 *** output is pre-generated.)  To use a different yacc program (possible,
4837 *** but not recommended), set the environment variable YACC before running
4838 *** 'configure'." >&2;}
4839   fi
4840 fi
4841
4842
4843 # Extract the first word of "perl", so it can be a program name with args.
4844 set dummy perl; ac_word=$2
4845 echo "$as_me:$LINENO: checking for $ac_word" >&5
4846 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4847 if test "${ac_cv_path_PERL+set}" = set; then
4848   echo $ECHO_N "(cached) $ECHO_C" >&6
4849 else
4850   case $PERL in
4851   [\\/]* | ?:[\\/]*)
4852   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
4853   ;;
4854   *)
4855   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4856 for as_dir in $PATH
4857 do
4858   IFS=$as_save_IFS
4859   test -z "$as_dir" && as_dir=.
4860   for ac_exec_ext in '' $ac_executable_extensions; do
4861   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4862     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
4863     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4864     break 2
4865   fi
4866 done
4867 done
4868
4869   ;;
4870 esac
4871 fi
4872 PERL=$ac_cv_path_PERL
4873
4874 if test -n "$PERL"; then
4875   echo "$as_me:$LINENO: result: $PERL" >&5
4876 echo "${ECHO_T}$PERL" >&6
4877 else
4878   echo "$as_me:$LINENO: result: no" >&5
4879 echo "${ECHO_T}no" >&6
4880 fi
4881
4882 if test "$with_perl" = yes; then
4883
4884 echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
4885 echo $ECHO_N "checking for Perl archlibexp... $ECHO_C" >&6
4886 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
4887 echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
4888 echo "${ECHO_T}$perl_archlibexp" >&6
4889 echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
4890 echo $ECHO_N "checking for Perl privlibexp... $ECHO_C" >&6
4891 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
4892 echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
4893 echo "${ECHO_T}$perl_privlibexp" >&6
4894 echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
4895 echo $ECHO_N "checking for Perl useshrplib... $ECHO_C" >&6
4896 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
4897 echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
4898 echo "${ECHO_T}$perl_useshrplib" >&6
4899
4900 echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
4901 echo $ECHO_N "checking for flags to link embedded Perl... $ECHO_C" >&6
4902 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
4903 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
4904 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed "s/^X//;s%$pgac_tmp2%%"`
4905 echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
4906 echo "${ECHO_T}$perl_embed_ldflags" >&6
4907 fi
4908
4909 if test "$with_python" = yes; then
4910   # Extract the first word of "python", so it can be a program name with args.
4911 set dummy python; ac_word=$2
4912 echo "$as_me:$LINENO: checking for $ac_word" >&5
4913 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4914 if test "${ac_cv_path_PYTHON+set}" = set; then
4915   echo $ECHO_N "(cached) $ECHO_C" >&6
4916 else
4917   case $PYTHON in
4918   [\\/]* | ?:[\\/]*)
4919   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
4920   ;;
4921   *)
4922   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4923 for as_dir in $PATH
4924 do
4925   IFS=$as_save_IFS
4926   test -z "$as_dir" && as_dir=.
4927   for ac_exec_ext in '' $ac_executable_extensions; do
4928   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4929     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
4930     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4931     break 2
4932   fi
4933 done
4934 done
4935
4936   ;;
4937 esac
4938 fi
4939 PYTHON=$ac_cv_path_PYTHON
4940
4941 if test -n "$PYTHON"; then
4942   echo "$as_me:$LINENO: result: $PYTHON" >&5
4943 echo "${ECHO_T}$PYTHON" >&6
4944 else
4945   echo "$as_me:$LINENO: result: no" >&5
4946 echo "${ECHO_T}no" >&6
4947 fi
4948
4949 if test x"$PYTHON" = x""; then
4950   { { echo "$as_me:$LINENO: error: Python not found" >&5
4951 echo "$as_me: error: Python not found" >&2;}
4952    { (exit 1); exit 1; }; }
4953 fi
4954
4955
4956 echo "$as_me:$LINENO: checking for Python distutils module" >&5
4957 echo $ECHO_N "checking for Python distutils module... $ECHO_C" >&6
4958 if "${PYTHON}" 2>&- -c 'import distutils'
4959 then
4960     echo "$as_me:$LINENO: result: yes" >&5
4961 echo "${ECHO_T}yes" >&6
4962 else
4963     echo "$as_me:$LINENO: result: no" >&5
4964 echo "${ECHO_T}no" >&6
4965     { { echo "$as_me:$LINENO: error: distutils module not found" >&5
4966 echo "$as_me: error: distutils module not found" >&2;}
4967    { (exit 1); exit 1; }; }
4968 fi
4969 echo "$as_me:$LINENO: checking Python configuration directory" >&5
4970 echo $ECHO_N "checking Python configuration directory... $ECHO_C" >&6
4971 python_version=`${PYTHON} -c "import sys; print sys.version[:3]"`
4972 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')"`
4973 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print '-I'+distutils.sysconfig.get_python_inc()"`
4974
4975 # This should be enough of a message.
4976 echo "$as_me:$LINENO: result: $python_configdir" >&5
4977 echo "${ECHO_T}$python_configdir" >&6
4978
4979
4980 echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
4981 echo $ECHO_N "checking how to link an embedded Python application... $ECHO_C" >&6
4982
4983 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR')))"`
4984 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY')))"`
4985 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('SO')))"`
4986 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
4987
4988 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
4989 then
4990         # New way: use the official shared library
4991         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
4992         python_libspec="-L${python_libdir} -l${ldlibrary}"
4993 else
4994         # Old way: use libpython from python_configdir
4995         python_libdir="${python_configdir}"
4996         python_libspec="-L${python_libdir} -lpython${python_version}"
4997 fi
4998
4999 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','LOCALMODLIBS','BASEMODLIBS')))"`
5000
5001 echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
5002 echo "${ECHO_T}${python_libspec} ${python_additional_libs}" >&6
5003
5004
5005 # threaded python is not supported on bsd's
5006 echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
5007 echo $ECHO_N "checking whether Python is compiled with thread support... $ECHO_C" >&6
5008 pythreads=`${PYTHON} -c "import sys; print int('thread' in sys.builtin_module_names)"`
5009 if test "$pythreads" = "1"; then
5010   echo "$as_me:$LINENO: result: yes" >&5
5011 echo "${ECHO_T}yes" >&6
5012   case $host_os in
5013   openbsd*|freebsd*)
5014     { { echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
5015 echo "$as_me: error: threaded Python not supported on this platform" >&2;}
5016    { (exit 1); exit 1; }; }
5017     ;;
5018   esac
5019 else
5020   echo "$as_me:$LINENO: result: no" >&5
5021 echo "${ECHO_T}no" >&6
5022 fi
5023
5024
5025 fi
5026
5027 # Supply a numeric version string for use by 3rd party add-ons
5028 # awk -F is a regex on some platforms, and not on others, so make "." a tab
5029 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/A-Za-z.*$//' |
5030 tr '.' '        ' |
5031 $AWK '{printf \"%d%02d%02d\", $1, $2, (NF >= 3) ? $3 : 0}'`"
5032
5033 cat >>confdefs.h <<_ACEOF
5034 #define PG_VERSION_NUM $PG_VERSION_NUM
5035 _ACEOF
5036
5037
5038 ##
5039 ## Libraries
5040 ##
5041 ## Most libraries are included only if they demonstrably provide a function
5042 ## we need, but libm is an exception: always include it, because there are
5043 ## too many compilers that play cute optimization games that will break
5044 ## probes for standard functions such as pow().
5045 ##
5046
5047
5048 echo "$as_me:$LINENO: checking for main in -lm" >&5
5049 echo $ECHO_N "checking for main in -lm... $ECHO_C" >&6
5050 if test "${ac_cv_lib_m_main+set}" = set; then
5051   echo $ECHO_N "(cached) $ECHO_C" >&6
5052 else
5053   ac_check_lib_save_LIBS=$LIBS
5054 LIBS="-lm  $LIBS"
5055 cat >conftest.$ac_ext <<_ACEOF
5056 /* confdefs.h.  */
5057 _ACEOF
5058 cat confdefs.h >>conftest.$ac_ext
5059 cat >>conftest.$ac_ext <<_ACEOF
5060 /* end confdefs.h.  */
5061
5062
5063 int
5064 main ()
5065 {
5066 main ();
5067   ;
5068   return 0;
5069 }
5070 _ACEOF
5071 rm -f conftest.$ac_objext conftest$ac_exeext
5072 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5073   (eval $ac_link) 2>conftest.er1
5074   ac_status=$?
5075   grep -v '^ *+' conftest.er1 >conftest.err
5076   rm -f conftest.er1
5077   cat conftest.err >&5
5078   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5079   (exit $ac_status); } &&
5080          { ac_try='test -z "$ac_c_werror_flag"
5081                          || test ! -s conftest.err'
5082   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5083   (eval $ac_try) 2>&5
5084   ac_status=$?
5085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5086   (exit $ac_status); }; } &&
5087          { ac_try='test -s conftest$ac_exeext'
5088   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5089   (eval $ac_try) 2>&5
5090   ac_status=$?
5091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5092   (exit $ac_status); }; }; then
5093   ac_cv_lib_m_main=yes
5094 else
5095   echo "$as_me: failed program was:" >&5
5096 sed 's/^/| /' conftest.$ac_ext >&5
5097
5098 ac_cv_lib_m_main=no
5099 fi
5100 rm -f conftest.err conftest.$ac_objext \
5101       conftest$ac_exeext conftest.$ac_ext
5102 LIBS=$ac_check_lib_save_LIBS
5103 fi
5104 echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
5105 echo "${ECHO_T}$ac_cv_lib_m_main" >&6
5106 if test $ac_cv_lib_m_main = yes; then
5107   cat >>confdefs.h <<_ACEOF
5108 #define HAVE_LIBM 1
5109 _ACEOF
5110
5111   LIBS="-lm $LIBS"
5112
5113 fi
5114
5115 echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
5116 echo $ECHO_N "checking for library containing setproctitle... $ECHO_C" >&6
5117 if test "${ac_cv_search_setproctitle+set}" = set; then
5118   echo $ECHO_N "(cached) $ECHO_C" >&6
5119 else
5120   ac_func_search_save_LIBS=$LIBS
5121 ac_cv_search_setproctitle=no
5122 cat >conftest.$ac_ext <<_ACEOF
5123 /* confdefs.h.  */
5124 _ACEOF
5125 cat confdefs.h >>conftest.$ac_ext
5126 cat >>conftest.$ac_ext <<_ACEOF
5127 /* end confdefs.h.  */
5128
5129 /* Override any gcc2 internal prototype to avoid an error.  */
5130 #ifdef __cplusplus
5131 extern "C"
5132 #endif
5133 /* We use char because int might match the return type of a gcc2
5134    builtin and then its argument prototype would still apply.  */
5135 char setproctitle ();
5136 int
5137 main ()
5138 {
5139 setproctitle ();
5140   ;
5141   return 0;
5142 }
5143 _ACEOF
5144 rm -f conftest.$ac_objext conftest$ac_exeext
5145 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5146   (eval $ac_link) 2>conftest.er1
5147   ac_status=$?
5148   grep -v '^ *+' conftest.er1 >conftest.err
5149   rm -f conftest.er1
5150   cat conftest.err >&5
5151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5152   (exit $ac_status); } &&
5153          { ac_try='test -z "$ac_c_werror_flag"
5154                          || test ! -s conftest.err'
5155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5156   (eval $ac_try) 2>&5
5157   ac_status=$?
5158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5159   (exit $ac_status); }; } &&
5160          { ac_try='test -s conftest$ac_exeext'
5161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5162   (eval $ac_try) 2>&5
5163   ac_status=$?
5164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5165   (exit $ac_status); }; }; then
5166   ac_cv_search_setproctitle="none required"
5167 else
5168   echo "$as_me: failed program was:" >&5
5169 sed 's/^/| /' conftest.$ac_ext >&5
5170
5171 fi
5172 rm -f conftest.err conftest.$ac_objext \
5173       conftest$ac_exeext conftest.$ac_ext
5174 if test "$ac_cv_search_setproctitle" = no; then
5175   for ac_lib in util; do
5176     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5177     cat >conftest.$ac_ext <<_ACEOF
5178 /* confdefs.h.  */
5179 _ACEOF
5180 cat confdefs.h >>conftest.$ac_ext
5181 cat >>conftest.$ac_ext <<_ACEOF
5182 /* end confdefs.h.  */
5183
5184 /* Override any gcc2 internal prototype to avoid an error.  */
5185 #ifdef __cplusplus
5186 extern "C"
5187 #endif
5188 /* We use char because int might match the return type of a gcc2
5189    builtin and then its argument prototype would still apply.  */
5190 char setproctitle ();
5191 int
5192 main ()
5193 {
5194 setproctitle ();
5195   ;
5196   return 0;
5197 }
5198 _ACEOF
5199 rm -f conftest.$ac_objext conftest$ac_exeext
5200 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5201   (eval $ac_link) 2>conftest.er1
5202   ac_status=$?
5203   grep -v '^ *+' conftest.er1 >conftest.err
5204   rm -f conftest.er1
5205   cat conftest.err >&5
5206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5207   (exit $ac_status); } &&
5208          { ac_try='test -z "$ac_c_werror_flag"
5209                          || test ! -s conftest.err'
5210   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5211   (eval $ac_try) 2>&5
5212   ac_status=$?
5213   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5214   (exit $ac_status); }; } &&
5215          { ac_try='test -s conftest$ac_exeext'
5216   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5217   (eval $ac_try) 2>&5
5218   ac_status=$?
5219   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5220   (exit $ac_status); }; }; then
5221   ac_cv_search_setproctitle="-l$ac_lib"
5222 break
5223 else
5224   echo "$as_me: failed program was:" >&5
5225 sed 's/^/| /' conftest.$ac_ext >&5
5226
5227 fi
5228 rm -f conftest.err conftest.$ac_objext \
5229       conftest$ac_exeext conftest.$ac_ext
5230   done
5231 fi
5232 LIBS=$ac_func_search_save_LIBS
5233 fi
5234 echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
5235 echo "${ECHO_T}$ac_cv_search_setproctitle" >&6
5236 if test "$ac_cv_search_setproctitle" != no; then
5237   test "$ac_cv_search_setproctitle" = "none required" || LIBS="$ac_cv_search_setproctitle $LIBS"
5238
5239 fi
5240
5241 echo "$as_me:$LINENO: checking for library containing dlopen" >&5
5242 echo $ECHO_N "checking for library containing dlopen... $ECHO_C" >&6
5243 if test "${ac_cv_search_dlopen+set}" = set; then
5244   echo $ECHO_N "(cached) $ECHO_C" >&6
5245 else
5246   ac_func_search_save_LIBS=$LIBS
5247 ac_cv_search_dlopen=no
5248 cat >conftest.$ac_ext <<_ACEOF
5249 /* confdefs.h.  */
5250 _ACEOF
5251 cat confdefs.h >>conftest.$ac_ext
5252 cat >>conftest.$ac_ext <<_ACEOF
5253 /* end confdefs.h.  */
5254
5255 /* Override any gcc2 internal prototype to avoid an error.  */
5256 #ifdef __cplusplus
5257 extern "C"
5258 #endif
5259 /* We use char because int might match the return type of a gcc2
5260    builtin and then its argument prototype would still apply.  */
5261 char dlopen ();
5262 int
5263 main ()
5264 {
5265 dlopen ();
5266   ;
5267   return 0;
5268 }
5269 _ACEOF
5270 rm -f conftest.$ac_objext conftest$ac_exeext
5271 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5272   (eval $ac_link) 2>conftest.er1
5273   ac_status=$?
5274   grep -v '^ *+' conftest.er1 >conftest.err
5275   rm -f conftest.er1
5276   cat conftest.err >&5
5277   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5278   (exit $ac_status); } &&
5279          { ac_try='test -z "$ac_c_werror_flag"
5280                          || test ! -s conftest.err'
5281   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5282   (eval $ac_try) 2>&5
5283   ac_status=$?
5284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5285   (exit $ac_status); }; } &&
5286          { ac_try='test -s conftest$ac_exeext'
5287   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5288   (eval $ac_try) 2>&5
5289   ac_status=$?
5290   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5291   (exit $ac_status); }; }; then
5292   ac_cv_search_dlopen="none required"
5293 else
5294   echo "$as_me: failed program was:" >&5
5295 sed 's/^/| /' conftest.$ac_ext >&5
5296
5297 fi
5298 rm -f conftest.err conftest.$ac_objext \
5299       conftest$ac_exeext conftest.$ac_ext
5300 if test "$ac_cv_search_dlopen" = no; then
5301   for ac_lib in dl; do
5302     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5303     cat >conftest.$ac_ext <<_ACEOF
5304 /* confdefs.h.  */
5305 _ACEOF
5306 cat confdefs.h >>conftest.$ac_ext
5307 cat >>conftest.$ac_ext <<_ACEOF
5308 /* end confdefs.h.  */
5309
5310 /* Override any gcc2 internal prototype to avoid an error.  */
5311 #ifdef __cplusplus
5312 extern "C"
5313 #endif
5314 /* We use char because int might match the return type of a gcc2
5315    builtin and then its argument prototype would still apply.  */
5316 char dlopen ();
5317 int
5318 main ()
5319 {
5320 dlopen ();
5321   ;
5322   return 0;
5323 }
5324 _ACEOF
5325 rm -f conftest.$ac_objext conftest$ac_exeext
5326 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5327   (eval $ac_link) 2>conftest.er1
5328   ac_status=$?
5329   grep -v '^ *+' conftest.er1 >conftest.err
5330   rm -f conftest.er1
5331   cat conftest.err >&5
5332   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5333   (exit $ac_status); } &&
5334          { ac_try='test -z "$ac_c_werror_flag"
5335                          || test ! -s conftest.err'
5336   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5337   (eval $ac_try) 2>&5
5338   ac_status=$?
5339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5340   (exit $ac_status); }; } &&
5341          { ac_try='test -s conftest$ac_exeext'
5342   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5343   (eval $ac_try) 2>&5
5344   ac_status=$?
5345   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5346   (exit $ac_status); }; }; then
5347   ac_cv_search_dlopen="-l$ac_lib"
5348 break
5349 else
5350   echo "$as_me: failed program was:" >&5
5351 sed 's/^/| /' conftest.$ac_ext >&5
5352
5353 fi
5354 rm -f conftest.err conftest.$ac_objext \
5355       conftest$ac_exeext conftest.$ac_ext
5356   done
5357 fi
5358 LIBS=$ac_func_search_save_LIBS
5359 fi
5360 echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
5361 echo "${ECHO_T}$ac_cv_search_dlopen" >&6
5362 if test "$ac_cv_search_dlopen" != no; then
5363   test "$ac_cv_search_dlopen" = "none required" || LIBS="$ac_cv_search_dlopen $LIBS"
5364
5365 fi
5366
5367 echo "$as_me:$LINENO: checking for library containing socket" >&5
5368 echo $ECHO_N "checking for library containing socket... $ECHO_C" >&6
5369 if test "${ac_cv_search_socket+set}" = set; then
5370   echo $ECHO_N "(cached) $ECHO_C" >&6
5371 else
5372   ac_func_search_save_LIBS=$LIBS
5373 ac_cv_search_socket=no
5374 cat >conftest.$ac_ext <<_ACEOF
5375 /* confdefs.h.  */
5376 _ACEOF
5377 cat confdefs.h >>conftest.$ac_ext
5378 cat >>conftest.$ac_ext <<_ACEOF
5379 /* end confdefs.h.  */
5380
5381 /* Override any gcc2 internal prototype to avoid an error.  */
5382 #ifdef __cplusplus
5383 extern "C"
5384 #endif
5385 /* We use char because int might match the return type of a gcc2
5386    builtin and then its argument prototype would still apply.  */
5387 char socket ();
5388 int
5389 main ()
5390 {
5391 socket ();
5392   ;
5393   return 0;
5394 }
5395 _ACEOF
5396 rm -f conftest.$ac_objext conftest$ac_exeext
5397 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5398   (eval $ac_link) 2>conftest.er1
5399   ac_status=$?
5400   grep -v '^ *+' conftest.er1 >conftest.err
5401   rm -f conftest.er1
5402   cat conftest.err >&5
5403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5404   (exit $ac_status); } &&
5405          { ac_try='test -z "$ac_c_werror_flag"
5406                          || test ! -s conftest.err'
5407   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5408   (eval $ac_try) 2>&5
5409   ac_status=$?
5410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5411   (exit $ac_status); }; } &&
5412          { ac_try='test -s conftest$ac_exeext'
5413   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5414   (eval $ac_try) 2>&5
5415   ac_status=$?
5416   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5417   (exit $ac_status); }; }; then
5418   ac_cv_search_socket="none required"
5419 else
5420   echo "$as_me: failed program was:" >&5
5421 sed 's/^/| /' conftest.$ac_ext >&5
5422
5423 fi
5424 rm -f conftest.err conftest.$ac_objext \
5425       conftest$ac_exeext conftest.$ac_ext
5426 if test "$ac_cv_search_socket" = no; then
5427   for ac_lib in socket wsock32; do
5428     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5429     cat >conftest.$ac_ext <<_ACEOF
5430 /* confdefs.h.  */
5431 _ACEOF
5432 cat confdefs.h >>conftest.$ac_ext
5433 cat >>conftest.$ac_ext <<_ACEOF
5434 /* end confdefs.h.  */
5435
5436 /* Override any gcc2 internal prototype to avoid an error.  */
5437 #ifdef __cplusplus
5438 extern "C"
5439 #endif
5440 /* We use char because int might match the return type of a gcc2
5441    builtin and then its argument prototype would still apply.  */
5442 char socket ();
5443 int
5444 main ()
5445 {
5446 socket ();
5447   ;
5448   return 0;
5449 }
5450 _ACEOF
5451 rm -f conftest.$ac_objext conftest$ac_exeext
5452 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5453   (eval $ac_link) 2>conftest.er1
5454   ac_status=$?
5455   grep -v '^ *+' conftest.er1 >conftest.err
5456   rm -f conftest.er1
5457   cat conftest.err >&5
5458   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5459   (exit $ac_status); } &&
5460          { ac_try='test -z "$ac_c_werror_flag"
5461                          || test ! -s conftest.err'
5462   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5463   (eval $ac_try) 2>&5
5464   ac_status=$?
5465   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5466   (exit $ac_status); }; } &&
5467          { ac_try='test -s conftest$ac_exeext'
5468   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5469   (eval $ac_try) 2>&5
5470   ac_status=$?
5471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5472   (exit $ac_status); }; }; then
5473   ac_cv_search_socket="-l$ac_lib"
5474 break
5475 else
5476   echo "$as_me: failed program was:" >&5
5477 sed 's/^/| /' conftest.$ac_ext >&5
5478
5479 fi
5480 rm -f conftest.err conftest.$ac_objext \
5481       conftest$ac_exeext conftest.$ac_ext
5482   done
5483 fi
5484 LIBS=$ac_func_search_save_LIBS
5485 fi
5486 echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
5487 echo "${ECHO_T}$ac_cv_search_socket" >&6
5488 if test "$ac_cv_search_socket" != no; then
5489   test "$ac_cv_search_socket" = "none required" || LIBS="$ac_cv_search_socket $LIBS"
5490
5491 fi
5492
5493 echo "$as_me:$LINENO: checking for library containing shl_load" >&5
5494 echo $ECHO_N "checking for library containing shl_load... $ECHO_C" >&6
5495 if test "${ac_cv_search_shl_load+set}" = set; then
5496   echo $ECHO_N "(cached) $ECHO_C" >&6
5497 else
5498   ac_func_search_save_LIBS=$LIBS
5499 ac_cv_search_shl_load=no
5500 cat >conftest.$ac_ext <<_ACEOF
5501 /* confdefs.h.  */
5502 _ACEOF
5503 cat confdefs.h >>conftest.$ac_ext
5504 cat >>conftest.$ac_ext <<_ACEOF
5505 /* end confdefs.h.  */
5506
5507 /* Override any gcc2 internal prototype to avoid an error.  */
5508 #ifdef __cplusplus
5509 extern "C"
5510 #endif
5511 /* We use char because int might match the return type of a gcc2
5512    builtin and then its argument prototype would still apply.  */
5513 char shl_load ();
5514 int
5515 main ()
5516 {
5517 shl_load ();
5518   ;
5519   return 0;
5520 }
5521 _ACEOF
5522 rm -f conftest.$ac_objext conftest$ac_exeext
5523 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5524   (eval $ac_link) 2>conftest.er1
5525   ac_status=$?
5526   grep -v '^ *+' conftest.er1 >conftest.err
5527   rm -f conftest.er1
5528   cat conftest.err >&5
5529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5530   (exit $ac_status); } &&
5531          { ac_try='test -z "$ac_c_werror_flag"
5532                          || test ! -s conftest.err'
5533   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5534   (eval $ac_try) 2>&5
5535   ac_status=$?
5536   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5537   (exit $ac_status); }; } &&
5538          { ac_try='test -s conftest$ac_exeext'
5539   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5540   (eval $ac_try) 2>&5
5541   ac_status=$?
5542   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5543   (exit $ac_status); }; }; then
5544   ac_cv_search_shl_load="none required"
5545 else
5546   echo "$as_me: failed program was:" >&5
5547 sed 's/^/| /' conftest.$ac_ext >&5
5548
5549 fi
5550 rm -f conftest.err conftest.$ac_objext \
5551       conftest$ac_exeext conftest.$ac_ext
5552 if test "$ac_cv_search_shl_load" = no; then
5553   for ac_lib in dld; do
5554     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5555     cat >conftest.$ac_ext <<_ACEOF
5556 /* confdefs.h.  */
5557 _ACEOF
5558 cat confdefs.h >>conftest.$ac_ext
5559 cat >>conftest.$ac_ext <<_ACEOF
5560 /* end confdefs.h.  */
5561
5562 /* Override any gcc2 internal prototype to avoid an error.  */
5563 #ifdef __cplusplus
5564 extern "C"
5565 #endif
5566 /* We use char because int might match the return type of a gcc2
5567    builtin and then its argument prototype would still apply.  */
5568 char shl_load ();
5569 int
5570 main ()
5571 {
5572 shl_load ();
5573   ;
5574   return 0;
5575 }
5576 _ACEOF
5577 rm -f conftest.$ac_objext conftest$ac_exeext
5578 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5579   (eval $ac_link) 2>conftest.er1
5580   ac_status=$?
5581   grep -v '^ *+' conftest.er1 >conftest.err
5582   rm -f conftest.er1
5583   cat conftest.err >&5
5584   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5585   (exit $ac_status); } &&
5586          { ac_try='test -z "$ac_c_werror_flag"
5587                          || test ! -s conftest.err'
5588   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5589   (eval $ac_try) 2>&5
5590   ac_status=$?
5591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5592   (exit $ac_status); }; } &&
5593          { ac_try='test -s conftest$ac_exeext'
5594   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5595   (eval $ac_try) 2>&5
5596   ac_status=$?
5597   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5598   (exit $ac_status); }; }; then
5599   ac_cv_search_shl_load="-l$ac_lib"
5600 break
5601 else
5602   echo "$as_me: failed program was:" >&5
5603 sed 's/^/| /' conftest.$ac_ext >&5
5604
5605 fi
5606 rm -f conftest.err conftest.$ac_objext \
5607       conftest$ac_exeext conftest.$ac_ext
5608   done
5609 fi
5610 LIBS=$ac_func_search_save_LIBS
5611 fi
5612 echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
5613 echo "${ECHO_T}$ac_cv_search_shl_load" >&6
5614 if test "$ac_cv_search_shl_load" != no; then
5615   test "$ac_cv_search_shl_load" = "none required" || LIBS="$ac_cv_search_shl_load $LIBS"
5616
5617 fi
5618
5619 # We only use libld in port/dynloader/aix.c
5620 case $host_os in
5621      aix*)
5622         echo "$as_me:$LINENO: checking for library containing ldopen" >&5
5623 echo $ECHO_N "checking for library containing ldopen... $ECHO_C" >&6
5624 if test "${ac_cv_search_ldopen+set}" = set; then
5625   echo $ECHO_N "(cached) $ECHO_C" >&6
5626 else
5627   ac_func_search_save_LIBS=$LIBS
5628 ac_cv_search_ldopen=no
5629 cat >conftest.$ac_ext <<_ACEOF
5630 /* confdefs.h.  */
5631 _ACEOF
5632 cat confdefs.h >>conftest.$ac_ext
5633 cat >>conftest.$ac_ext <<_ACEOF
5634 /* end confdefs.h.  */
5635
5636 /* Override any gcc2 internal prototype to avoid an error.  */
5637 #ifdef __cplusplus
5638 extern "C"
5639 #endif
5640 /* We use char because int might match the return type of a gcc2
5641    builtin and then its argument prototype would still apply.  */
5642 char ldopen ();
5643 int
5644 main ()
5645 {
5646 ldopen ();
5647   ;
5648   return 0;
5649 }
5650 _ACEOF
5651 rm -f conftest.$ac_objext conftest$ac_exeext
5652 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5653   (eval $ac_link) 2>conftest.er1
5654   ac_status=$?
5655   grep -v '^ *+' conftest.er1 >conftest.err
5656   rm -f conftest.er1
5657   cat conftest.err >&5
5658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5659   (exit $ac_status); } &&
5660          { ac_try='test -z "$ac_c_werror_flag"
5661                          || test ! -s conftest.err'
5662   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5663   (eval $ac_try) 2>&5
5664   ac_status=$?
5665   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5666   (exit $ac_status); }; } &&
5667          { ac_try='test -s conftest$ac_exeext'
5668   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5669   (eval $ac_try) 2>&5
5670   ac_status=$?
5671   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5672   (exit $ac_status); }; }; then
5673   ac_cv_search_ldopen="none required"
5674 else
5675   echo "$as_me: failed program was:" >&5
5676 sed 's/^/| /' conftest.$ac_ext >&5
5677
5678 fi
5679 rm -f conftest.err conftest.$ac_objext \
5680       conftest$ac_exeext conftest.$ac_ext
5681 if test "$ac_cv_search_ldopen" = no; then
5682   for ac_lib in ld; do
5683     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5684     cat >conftest.$ac_ext <<_ACEOF
5685 /* confdefs.h.  */
5686 _ACEOF
5687 cat confdefs.h >>conftest.$ac_ext
5688 cat >>conftest.$ac_ext <<_ACEOF
5689 /* end confdefs.h.  */
5690
5691 /* Override any gcc2 internal prototype to avoid an error.  */
5692 #ifdef __cplusplus
5693 extern "C"
5694 #endif
5695 /* We use char because int might match the return type of a gcc2
5696    builtin and then its argument prototype would still apply.  */
5697 char ldopen ();
5698 int
5699 main ()
5700 {
5701 ldopen ();
5702   ;
5703   return 0;
5704 }
5705 _ACEOF
5706 rm -f conftest.$ac_objext conftest$ac_exeext
5707 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5708   (eval $ac_link) 2>conftest.er1
5709   ac_status=$?
5710   grep -v '^ *+' conftest.er1 >conftest.err
5711   rm -f conftest.er1
5712   cat conftest.err >&5
5713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5714   (exit $ac_status); } &&
5715          { ac_try='test -z "$ac_c_werror_flag"
5716                          || test ! -s conftest.err'
5717   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5718   (eval $ac_try) 2>&5
5719   ac_status=$?
5720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5721   (exit $ac_status); }; } &&
5722          { ac_try='test -s conftest$ac_exeext'
5723   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5724   (eval $ac_try) 2>&5
5725   ac_status=$?
5726   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5727   (exit $ac_status); }; }; then
5728   ac_cv_search_ldopen="-l$ac_lib"
5729 break
5730 else
5731   echo "$as_me: failed program was:" >&5
5732 sed 's/^/| /' conftest.$ac_ext >&5
5733
5734 fi
5735 rm -f conftest.err conftest.$ac_objext \
5736       conftest$ac_exeext conftest.$ac_ext
5737   done
5738 fi
5739 LIBS=$ac_func_search_save_LIBS
5740 fi
5741 echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
5742 echo "${ECHO_T}$ac_cv_search_ldopen" >&6
5743 if test "$ac_cv_search_ldopen" != no; then
5744   test "$ac_cv_search_ldopen" = "none required" || LIBS="$ac_cv_search_ldopen $LIBS"
5745
5746 fi
5747
5748         ;;
5749 esac
5750 echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
5751 echo $ECHO_N "checking for library containing getopt_long... $ECHO_C" >&6
5752 if test "${ac_cv_search_getopt_long+set}" = set; then
5753   echo $ECHO_N "(cached) $ECHO_C" >&6
5754 else
5755   ac_func_search_save_LIBS=$LIBS
5756 ac_cv_search_getopt_long=no
5757 cat >conftest.$ac_ext <<_ACEOF
5758 /* confdefs.h.  */
5759 _ACEOF
5760 cat confdefs.h >>conftest.$ac_ext
5761 cat >>conftest.$ac_ext <<_ACEOF
5762 /* end confdefs.h.  */
5763
5764 /* Override any gcc2 internal prototype to avoid an error.  */
5765 #ifdef __cplusplus
5766 extern "C"
5767 #endif
5768 /* We use char because int might match the return type of a gcc2
5769    builtin and then its argument prototype would still apply.  */
5770 char getopt_long ();
5771 int
5772 main ()
5773 {
5774 getopt_long ();
5775   ;
5776   return 0;
5777 }
5778 _ACEOF
5779 rm -f conftest.$ac_objext conftest$ac_exeext
5780 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5781   (eval $ac_link) 2>conftest.er1
5782   ac_status=$?
5783   grep -v '^ *+' conftest.er1 >conftest.err
5784   rm -f conftest.er1
5785   cat conftest.err >&5
5786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5787   (exit $ac_status); } &&
5788          { ac_try='test -z "$ac_c_werror_flag"
5789                          || test ! -s conftest.err'
5790   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5791   (eval $ac_try) 2>&5
5792   ac_status=$?
5793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5794   (exit $ac_status); }; } &&
5795          { ac_try='test -s conftest$ac_exeext'
5796   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5797   (eval $ac_try) 2>&5
5798   ac_status=$?
5799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5800   (exit $ac_status); }; }; then
5801   ac_cv_search_getopt_long="none required"
5802 else
5803   echo "$as_me: failed program was:" >&5
5804 sed 's/^/| /' conftest.$ac_ext >&5
5805
5806 fi
5807 rm -f conftest.err conftest.$ac_objext \
5808       conftest$ac_exeext conftest.$ac_ext
5809 if test "$ac_cv_search_getopt_long" = no; then
5810   for ac_lib in getopt gnugetopt; do
5811     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5812     cat >conftest.$ac_ext <<_ACEOF
5813 /* confdefs.h.  */
5814 _ACEOF
5815 cat confdefs.h >>conftest.$ac_ext
5816 cat >>conftest.$ac_ext <<_ACEOF
5817 /* end confdefs.h.  */
5818
5819 /* Override any gcc2 internal prototype to avoid an error.  */
5820 #ifdef __cplusplus
5821 extern "C"
5822 #endif
5823 /* We use char because int might match the return type of a gcc2
5824    builtin and then its argument prototype would still apply.  */
5825 char getopt_long ();
5826 int
5827 main ()
5828 {
5829 getopt_long ();
5830   ;
5831   return 0;
5832 }
5833 _ACEOF
5834 rm -f conftest.$ac_objext conftest$ac_exeext
5835 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5836   (eval $ac_link) 2>conftest.er1
5837   ac_status=$?
5838   grep -v '^ *+' conftest.er1 >conftest.err
5839   rm -f conftest.er1
5840   cat conftest.err >&5
5841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5842   (exit $ac_status); } &&
5843          { ac_try='test -z "$ac_c_werror_flag"
5844                          || test ! -s conftest.err'
5845   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5846   (eval $ac_try) 2>&5
5847   ac_status=$?
5848   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5849   (exit $ac_status); }; } &&
5850          { ac_try='test -s conftest$ac_exeext'
5851   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5852   (eval $ac_try) 2>&5
5853   ac_status=$?
5854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5855   (exit $ac_status); }; }; then
5856   ac_cv_search_getopt_long="-l$ac_lib"
5857 break
5858 else
5859   echo "$as_me: failed program was:" >&5
5860 sed 's/^/| /' conftest.$ac_ext >&5
5861
5862 fi
5863 rm -f conftest.err conftest.$ac_objext \
5864       conftest$ac_exeext conftest.$ac_ext
5865   done
5866 fi
5867 LIBS=$ac_func_search_save_LIBS
5868 fi
5869 echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
5870 echo "${ECHO_T}$ac_cv_search_getopt_long" >&6
5871 if test "$ac_cv_search_getopt_long" != no; then
5872   test "$ac_cv_search_getopt_long" = "none required" || LIBS="$ac_cv_search_getopt_long $LIBS"
5873
5874 fi
5875
5876 echo "$as_me:$LINENO: checking for library containing crypt" >&5
5877 echo $ECHO_N "checking for library containing crypt... $ECHO_C" >&6
5878 if test "${ac_cv_search_crypt+set}" = set; then
5879   echo $ECHO_N "(cached) $ECHO_C" >&6
5880 else
5881   ac_func_search_save_LIBS=$LIBS
5882 ac_cv_search_crypt=no
5883 cat >conftest.$ac_ext <<_ACEOF
5884 /* confdefs.h.  */
5885 _ACEOF
5886 cat confdefs.h >>conftest.$ac_ext
5887 cat >>conftest.$ac_ext <<_ACEOF
5888 /* end confdefs.h.  */
5889
5890 /* Override any gcc2 internal prototype to avoid an error.  */
5891 #ifdef __cplusplus
5892 extern "C"
5893 #endif
5894 /* We use char because int might match the return type of a gcc2
5895    builtin and then its argument prototype would still apply.  */
5896 char crypt ();
5897 int
5898 main ()
5899 {
5900 crypt ();
5901   ;
5902   return 0;
5903 }
5904 _ACEOF
5905 rm -f conftest.$ac_objext conftest$ac_exeext
5906 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5907   (eval $ac_link) 2>conftest.er1
5908   ac_status=$?
5909   grep -v '^ *+' conftest.er1 >conftest.err
5910   rm -f conftest.er1
5911   cat conftest.err >&5
5912   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5913   (exit $ac_status); } &&
5914          { ac_try='test -z "$ac_c_werror_flag"
5915                          || test ! -s conftest.err'
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); }; } &&
5921          { ac_try='test -s conftest$ac_exeext'
5922   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5923   (eval $ac_try) 2>&5
5924   ac_status=$?
5925   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5926   (exit $ac_status); }; }; then
5927   ac_cv_search_crypt="none required"
5928 else
5929   echo "$as_me: failed program was:" >&5
5930 sed 's/^/| /' conftest.$ac_ext >&5
5931
5932 fi
5933 rm -f conftest.err conftest.$ac_objext \
5934       conftest$ac_exeext conftest.$ac_ext
5935 if test "$ac_cv_search_crypt" = no; then
5936   for ac_lib in crypt; do
5937     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5938     cat >conftest.$ac_ext <<_ACEOF
5939 /* confdefs.h.  */
5940 _ACEOF
5941 cat confdefs.h >>conftest.$ac_ext
5942 cat >>conftest.$ac_ext <<_ACEOF
5943 /* end confdefs.h.  */
5944
5945 /* Override any gcc2 internal prototype to avoid an error.  */
5946 #ifdef __cplusplus
5947 extern "C"
5948 #endif
5949 /* We use char because int might match the return type of a gcc2
5950    builtin and then its argument prototype would still apply.  */
5951 char crypt ();
5952 int
5953 main ()
5954 {
5955 crypt ();
5956   ;
5957   return 0;
5958 }
5959 _ACEOF
5960 rm -f conftest.$ac_objext conftest$ac_exeext
5961 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5962   (eval $ac_link) 2>conftest.er1
5963   ac_status=$?
5964   grep -v '^ *+' conftest.er1 >conftest.err
5965   rm -f conftest.er1
5966   cat conftest.err >&5
5967   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5968   (exit $ac_status); } &&
5969          { ac_try='test -z "$ac_c_werror_flag"
5970                          || test ! -s conftest.err'
5971   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5972   (eval $ac_try) 2>&5
5973   ac_status=$?
5974   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5975   (exit $ac_status); }; } &&
5976          { ac_try='test -s conftest$ac_exeext'
5977   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5978   (eval $ac_try) 2>&5
5979   ac_status=$?
5980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5981   (exit $ac_status); }; }; then
5982   ac_cv_search_crypt="-l$ac_lib"
5983 break
5984 else
5985   echo "$as_me: failed program was:" >&5
5986 sed 's/^/| /' conftest.$ac_ext >&5
5987
5988 fi
5989 rm -f conftest.err conftest.$ac_objext \
5990       conftest$ac_exeext conftest.$ac_ext
5991   done
5992 fi
5993 LIBS=$ac_func_search_save_LIBS
5994 fi
5995 echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
5996 echo "${ECHO_T}$ac_cv_search_crypt" >&6
5997 if test "$ac_cv_search_crypt" != no; then
5998   test "$ac_cv_search_crypt" = "none required" || LIBS="$ac_cv_search_crypt $LIBS"
5999
6000 fi
6001
6002 # Solaris:
6003 echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
6004 echo $ECHO_N "checking for library containing fdatasync... $ECHO_C" >&6
6005 if test "${ac_cv_search_fdatasync+set}" = set; then
6006   echo $ECHO_N "(cached) $ECHO_C" >&6
6007 else
6008   ac_func_search_save_LIBS=$LIBS
6009 ac_cv_search_fdatasync=no
6010 cat >conftest.$ac_ext <<_ACEOF
6011 /* confdefs.h.  */
6012 _ACEOF
6013 cat confdefs.h >>conftest.$ac_ext
6014 cat >>conftest.$ac_ext <<_ACEOF
6015 /* end confdefs.h.  */
6016
6017 /* Override any gcc2 internal prototype to avoid an error.  */
6018 #ifdef __cplusplus
6019 extern "C"
6020 #endif
6021 /* We use char because int might match the return type of a gcc2
6022    builtin and then its argument prototype would still apply.  */
6023 char fdatasync ();
6024 int
6025 main ()
6026 {
6027 fdatasync ();
6028   ;
6029   return 0;
6030 }
6031 _ACEOF
6032 rm -f conftest.$ac_objext conftest$ac_exeext
6033 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6034   (eval $ac_link) 2>conftest.er1
6035   ac_status=$?
6036   grep -v '^ *+' conftest.er1 >conftest.err
6037   rm -f conftest.er1
6038   cat conftest.err >&5
6039   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6040   (exit $ac_status); } &&
6041          { ac_try='test -z "$ac_c_werror_flag"
6042                          || test ! -s conftest.err'
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); }; } &&
6048          { ac_try='test -s conftest$ac_exeext'
6049   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6050   (eval $ac_try) 2>&5
6051   ac_status=$?
6052   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6053   (exit $ac_status); }; }; then
6054   ac_cv_search_fdatasync="none required"
6055 else
6056   echo "$as_me: failed program was:" >&5
6057 sed 's/^/| /' conftest.$ac_ext >&5
6058
6059 fi
6060 rm -f conftest.err conftest.$ac_objext \
6061       conftest$ac_exeext conftest.$ac_ext
6062 if test "$ac_cv_search_fdatasync" = no; then
6063   for ac_lib in rt posix4; do
6064     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6065     cat >conftest.$ac_ext <<_ACEOF
6066 /* confdefs.h.  */
6067 _ACEOF
6068 cat confdefs.h >>conftest.$ac_ext
6069 cat >>conftest.$ac_ext <<_ACEOF
6070 /* end confdefs.h.  */
6071
6072 /* Override any gcc2 internal prototype to avoid an error.  */
6073 #ifdef __cplusplus
6074 extern "C"
6075 #endif
6076 /* We use char because int might match the return type of a gcc2
6077    builtin and then its argument prototype would still apply.  */
6078 char fdatasync ();
6079 int
6080 main ()
6081 {
6082 fdatasync ();
6083   ;
6084   return 0;
6085 }
6086 _ACEOF
6087 rm -f conftest.$ac_objext conftest$ac_exeext
6088 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6089   (eval $ac_link) 2>conftest.er1
6090   ac_status=$?
6091   grep -v '^ *+' conftest.er1 >conftest.err
6092   rm -f conftest.er1
6093   cat conftest.err >&5
6094   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6095   (exit $ac_status); } &&
6096          { ac_try='test -z "$ac_c_werror_flag"
6097                          || test ! -s conftest.err'
6098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6099   (eval $ac_try) 2>&5
6100   ac_status=$?
6101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6102   (exit $ac_status); }; } &&
6103          { ac_try='test -s conftest$ac_exeext'
6104   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6105   (eval $ac_try) 2>&5
6106   ac_status=$?
6107   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6108   (exit $ac_status); }; }; then
6109   ac_cv_search_fdatasync="-l$ac_lib"
6110 break
6111 else
6112   echo "$as_me: failed program was:" >&5
6113 sed 's/^/| /' conftest.$ac_ext >&5
6114
6115 fi
6116 rm -f conftest.err conftest.$ac_objext \
6117       conftest$ac_exeext conftest.$ac_ext
6118   done
6119 fi
6120 LIBS=$ac_func_search_save_LIBS
6121 fi
6122 echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
6123 echo "${ECHO_T}$ac_cv_search_fdatasync" >&6
6124 if test "$ac_cv_search_fdatasync" != no; then
6125   test "$ac_cv_search_fdatasync" = "none required" || LIBS="$ac_cv_search_fdatasync $LIBS"
6126
6127 fi
6128
6129 # Cygwin:
6130 echo "$as_me:$LINENO: checking for library containing shmget" >&5
6131 echo $ECHO_N "checking for library containing shmget... $ECHO_C" >&6
6132 if test "${ac_cv_search_shmget+set}" = set; then
6133   echo $ECHO_N "(cached) $ECHO_C" >&6
6134 else
6135   ac_func_search_save_LIBS=$LIBS
6136 ac_cv_search_shmget=no
6137 cat >conftest.$ac_ext <<_ACEOF
6138 /* confdefs.h.  */
6139 _ACEOF
6140 cat confdefs.h >>conftest.$ac_ext
6141 cat >>conftest.$ac_ext <<_ACEOF
6142 /* end confdefs.h.  */
6143
6144 /* Override any gcc2 internal prototype to avoid an error.  */
6145 #ifdef __cplusplus
6146 extern "C"
6147 #endif
6148 /* We use char because int might match the return type of a gcc2
6149    builtin and then its argument prototype would still apply.  */
6150 char shmget ();
6151 int
6152 main ()
6153 {
6154 shmget ();
6155   ;
6156   return 0;
6157 }
6158 _ACEOF
6159 rm -f conftest.$ac_objext conftest$ac_exeext
6160 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6161   (eval $ac_link) 2>conftest.er1
6162   ac_status=$?
6163   grep -v '^ *+' conftest.er1 >conftest.err
6164   rm -f conftest.er1
6165   cat conftest.err >&5
6166   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6167   (exit $ac_status); } &&
6168          { ac_try='test -z "$ac_c_werror_flag"
6169                          || test ! -s conftest.err'
6170   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6171   (eval $ac_try) 2>&5
6172   ac_status=$?
6173   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6174   (exit $ac_status); }; } &&
6175          { ac_try='test -s conftest$ac_exeext'
6176   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6177   (eval $ac_try) 2>&5
6178   ac_status=$?
6179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6180   (exit $ac_status); }; }; then
6181   ac_cv_search_shmget="none required"
6182 else
6183   echo "$as_me: failed program was:" >&5
6184 sed 's/^/| /' conftest.$ac_ext >&5
6185
6186 fi
6187 rm -f conftest.err conftest.$ac_objext \
6188       conftest$ac_exeext conftest.$ac_ext
6189 if test "$ac_cv_search_shmget" = no; then
6190   for ac_lib in cygipc; do
6191     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6192     cat >conftest.$ac_ext <<_ACEOF
6193 /* confdefs.h.  */
6194 _ACEOF
6195 cat confdefs.h >>conftest.$ac_ext
6196 cat >>conftest.$ac_ext <<_ACEOF
6197 /* end confdefs.h.  */
6198
6199 /* Override any gcc2 internal prototype to avoid an error.  */
6200 #ifdef __cplusplus
6201 extern "C"
6202 #endif
6203 /* We use char because int might match the return type of a gcc2
6204    builtin and then its argument prototype would still apply.  */
6205 char shmget ();
6206 int
6207 main ()
6208 {
6209 shmget ();
6210   ;
6211   return 0;
6212 }
6213 _ACEOF
6214 rm -f conftest.$ac_objext conftest$ac_exeext
6215 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6216   (eval $ac_link) 2>conftest.er1
6217   ac_status=$?
6218   grep -v '^ *+' conftest.er1 >conftest.err
6219   rm -f conftest.er1
6220   cat conftest.err >&5
6221   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6222   (exit $ac_status); } &&
6223          { ac_try='test -z "$ac_c_werror_flag"
6224                          || test ! -s conftest.err'
6225   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6226   (eval $ac_try) 2>&5
6227   ac_status=$?
6228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6229   (exit $ac_status); }; } &&
6230          { ac_try='test -s conftest$ac_exeext'
6231   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6232   (eval $ac_try) 2>&5
6233   ac_status=$?
6234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6235   (exit $ac_status); }; }; then
6236   ac_cv_search_shmget="-l$ac_lib"
6237 break
6238 else
6239   echo "$as_me: failed program was:" >&5
6240 sed 's/^/| /' conftest.$ac_ext >&5
6241
6242 fi
6243 rm -f conftest.err conftest.$ac_objext \
6244       conftest$ac_exeext conftest.$ac_ext
6245   done
6246 fi
6247 LIBS=$ac_func_search_save_LIBS
6248 fi
6249 echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
6250 echo "${ECHO_T}$ac_cv_search_shmget" >&6
6251 if test "$ac_cv_search_shmget" != no; then
6252   test "$ac_cv_search_shmget" = "none required" || LIBS="$ac_cv_search_shmget $LIBS"
6253
6254 fi
6255
6256
6257 if test "$with_readline" = yes; then
6258
6259
6260 if test "${pgac_cv_check_readline+set}" = set; then
6261   echo $ECHO_N "(cached) $ECHO_C" >&6
6262 else
6263   pgac_cv_check_readline=no
6264 pgac_save_LIBS=$LIBS
6265 if test x"$with_libedit_preferred" != x"yes"
6266 then    READLINE_ORDER="-lreadline -ledit"
6267 else    READLINE_ORDER="-ledit -lreadline"
6268 fi
6269 for pgac_rllib in $READLINE_ORDER ; do
6270   echo "$as_me:$LINENO: checking for ${pgac_rllib}" >&5
6271 echo $ECHO_N "checking for ${pgac_rllib}... $ECHO_C" >&6
6272   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
6273     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
6274     cat >conftest.$ac_ext <<_ACEOF
6275 /* confdefs.h.  */
6276 _ACEOF
6277 cat confdefs.h >>conftest.$ac_ext
6278 cat >>conftest.$ac_ext <<_ACEOF
6279 /* end confdefs.h.  */
6280
6281 /* Override any gcc2 internal prototype to avoid an error.  */
6282 #ifdef __cplusplus
6283 extern "C"
6284 #endif
6285 /* We use char because int might match the return type of a gcc2
6286    builtin and then its argument prototype would still apply.  */
6287 char readline ();
6288 int
6289 main ()
6290 {
6291 readline ();
6292   ;
6293   return 0;
6294 }
6295 _ACEOF
6296 rm -f conftest.$ac_objext conftest$ac_exeext
6297 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6298   (eval $ac_link) 2>conftest.er1
6299   ac_status=$?
6300   grep -v '^ *+' conftest.er1 >conftest.err
6301   rm -f conftest.er1
6302   cat conftest.err >&5
6303   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6304   (exit $ac_status); } &&
6305          { ac_try='test -z "$ac_c_werror_flag"
6306                          || test ! -s conftest.err'
6307   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6308   (eval $ac_try) 2>&5
6309   ac_status=$?
6310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6311   (exit $ac_status); }; } &&
6312          { ac_try='test -s conftest$ac_exeext'
6313   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6314   (eval $ac_try) 2>&5
6315   ac_status=$?
6316   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6317   (exit $ac_status); }; }; then
6318
6319       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
6320       # recognize dependent libraries; assume curses is needed if we didn't
6321       # find any dependency.
6322       case $host_os in
6323         netbsd* | openbsd* | irix*)
6324           if test x"$pgac_lib" = x"" ; then
6325             pgac_lib=" -lcurses"
6326           fi ;;
6327       esac
6328
6329       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
6330       break
6331
6332 else
6333   echo "$as_me: failed program was:" >&5
6334 sed 's/^/| /' conftest.$ac_ext >&5
6335
6336 fi
6337 rm -f conftest.err conftest.$ac_objext \
6338       conftest$ac_exeext conftest.$ac_ext
6339   done
6340   if test "$pgac_cv_check_readline" != no ; then
6341     echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
6342 echo "${ECHO_T}yes ($pgac_cv_check_readline)" >&6
6343     break
6344   else
6345     echo "$as_me:$LINENO: result: no" >&5
6346 echo "${ECHO_T}no" >&6
6347   fi
6348 done
6349 LIBS=$pgac_save_LIBS
6350
6351 fi
6352
6353 if test "$pgac_cv_check_readline" != no ; then
6354   LIBS="$pgac_cv_check_readline $LIBS"
6355
6356 cat >>confdefs.h <<\_ACEOF
6357 #define HAVE_LIBREADLINE 1
6358 _ACEOF
6359
6360 fi
6361
6362
6363   if test x"$pgac_cv_check_readline" = x"no"; then
6364     { { echo "$as_me:$LINENO: error: readline library not found
6365 If you have readline already installed, see config.log for details on the
6366 failure.  It is possible the compiler isn't looking in the proper directory.
6367 Use --without-readline to disable readline support." >&5
6368 echo "$as_me: error: readline library not found
6369 If you have readline already installed, see config.log for details on the
6370 failure.  It is possible the compiler isn't looking in the proper directory.
6371 Use --without-readline to disable readline support." >&2;}
6372    { (exit 1); exit 1; }; }
6373   fi
6374 fi
6375
6376 if test "$with_zlib" = yes; then
6377
6378 echo "$as_me:$LINENO: checking for inflate in -lz" >&5
6379 echo $ECHO_N "checking for inflate in -lz... $ECHO_C" >&6
6380 if test "${ac_cv_lib_z_inflate+set}" = set; then
6381   echo $ECHO_N "(cached) $ECHO_C" >&6
6382 else
6383   ac_check_lib_save_LIBS=$LIBS
6384 LIBS="-lz  $LIBS"
6385 cat >conftest.$ac_ext <<_ACEOF
6386 /* confdefs.h.  */
6387 _ACEOF
6388 cat confdefs.h >>conftest.$ac_ext
6389 cat >>conftest.$ac_ext <<_ACEOF
6390 /* end confdefs.h.  */
6391
6392 /* Override any gcc2 internal prototype to avoid an error.  */
6393 #ifdef __cplusplus
6394 extern "C"
6395 #endif
6396 /* We use char because int might match the return type of a gcc2
6397    builtin and then its argument prototype would still apply.  */
6398 char inflate ();
6399 int
6400 main ()
6401 {
6402 inflate ();
6403   ;
6404   return 0;
6405 }
6406 _ACEOF
6407 rm -f conftest.$ac_objext conftest$ac_exeext
6408 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6409   (eval $ac_link) 2>conftest.er1
6410   ac_status=$?
6411   grep -v '^ *+' conftest.er1 >conftest.err
6412   rm -f conftest.er1
6413   cat conftest.err >&5
6414   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6415   (exit $ac_status); } &&
6416          { ac_try='test -z "$ac_c_werror_flag"
6417                          || test ! -s conftest.err'
6418   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6419   (eval $ac_try) 2>&5
6420   ac_status=$?
6421   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6422   (exit $ac_status); }; } &&
6423          { ac_try='test -s conftest$ac_exeext'
6424   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6425   (eval $ac_try) 2>&5
6426   ac_status=$?
6427   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6428   (exit $ac_status); }; }; then
6429   ac_cv_lib_z_inflate=yes
6430 else
6431   echo "$as_me: failed program was:" >&5
6432 sed 's/^/| /' conftest.$ac_ext >&5
6433
6434 ac_cv_lib_z_inflate=no
6435 fi
6436 rm -f conftest.err conftest.$ac_objext \
6437       conftest$ac_exeext conftest.$ac_ext
6438 LIBS=$ac_check_lib_save_LIBS
6439 fi
6440 echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
6441 echo "${ECHO_T}$ac_cv_lib_z_inflate" >&6
6442 if test $ac_cv_lib_z_inflate = yes; then
6443   cat >>confdefs.h <<_ACEOF
6444 #define HAVE_LIBZ 1
6445 _ACEOF
6446
6447   LIBS="-lz $LIBS"
6448
6449 else
6450   { { echo "$as_me:$LINENO: error: zlib library not found
6451 If you have zlib already installed, see config.log for details on the
6452 failure.  It is possible the compiler isn't looking in the proper directory.
6453 Use --without-zlib to disable zlib support." >&5
6454 echo "$as_me: error: zlib library not found
6455 If you have zlib already installed, see config.log for details on the
6456 failure.  It is possible the compiler isn't looking in the proper directory.
6457 Use --without-zlib to disable zlib support." >&2;}
6458    { (exit 1); exit 1; }; }
6459 fi
6460
6461 fi
6462
6463 if test "$enable_spinlocks" = yes; then
6464
6465 cat >>confdefs.h <<\_ACEOF
6466 #define HAVE_SPINLOCKS 1
6467 _ACEOF
6468
6469 else
6470   { echo "$as_me:$LINENO: WARNING:
6471 *** Not using spinlocks will cause poor performance." >&5
6472 echo "$as_me: WARNING:
6473 *** Not using spinlocks will cause poor performance." >&2;}
6474 fi
6475
6476 if test "$with_krb5" = yes ; then
6477   if test "$PORTNAME" != "win32"; then
6478      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6479 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6480 if test "${ac_cv_search_com_err+set}" = set; then
6481   echo $ECHO_N "(cached) $ECHO_C" >&6
6482 else
6483   ac_func_search_save_LIBS=$LIBS
6484 ac_cv_search_com_err=no
6485 cat >conftest.$ac_ext <<_ACEOF
6486 /* confdefs.h.  */
6487 _ACEOF
6488 cat confdefs.h >>conftest.$ac_ext
6489 cat >>conftest.$ac_ext <<_ACEOF
6490 /* end confdefs.h.  */
6491
6492 /* Override any gcc2 internal prototype to avoid an error.  */
6493 #ifdef __cplusplus
6494 extern "C"
6495 #endif
6496 /* We use char because int might match the return type of a gcc2
6497    builtin and then its argument prototype would still apply.  */
6498 char com_err ();
6499 int
6500 main ()
6501 {
6502 com_err ();
6503   ;
6504   return 0;
6505 }
6506 _ACEOF
6507 rm -f conftest.$ac_objext conftest$ac_exeext
6508 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6509   (eval $ac_link) 2>conftest.er1
6510   ac_status=$?
6511   grep -v '^ *+' conftest.er1 >conftest.err
6512   rm -f conftest.er1
6513   cat conftest.err >&5
6514   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6515   (exit $ac_status); } &&
6516          { ac_try='test -z "$ac_c_werror_flag"
6517                          || test ! -s conftest.err'
6518   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6519   (eval $ac_try) 2>&5
6520   ac_status=$?
6521   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6522   (exit $ac_status); }; } &&
6523          { ac_try='test -s conftest$ac_exeext'
6524   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6525   (eval $ac_try) 2>&5
6526   ac_status=$?
6527   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6528   (exit $ac_status); }; }; then
6529   ac_cv_search_com_err="none required"
6530 else
6531   echo "$as_me: failed program was:" >&5
6532 sed 's/^/| /' conftest.$ac_ext >&5
6533
6534 fi
6535 rm -f conftest.err conftest.$ac_objext \
6536       conftest$ac_exeext conftest.$ac_ext
6537 if test "$ac_cv_search_com_err" = no; then
6538   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' com_err; do
6539     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6540     cat >conftest.$ac_ext <<_ACEOF
6541 /* confdefs.h.  */
6542 _ACEOF
6543 cat confdefs.h >>conftest.$ac_ext
6544 cat >>conftest.$ac_ext <<_ACEOF
6545 /* end confdefs.h.  */
6546
6547 /* Override any gcc2 internal prototype to avoid an error.  */
6548 #ifdef __cplusplus
6549 extern "C"
6550 #endif
6551 /* We use char because int might match the return type of a gcc2
6552    builtin and then its argument prototype would still apply.  */
6553 char com_err ();
6554 int
6555 main ()
6556 {
6557 com_err ();
6558   ;
6559   return 0;
6560 }
6561 _ACEOF
6562 rm -f conftest.$ac_objext conftest$ac_exeext
6563 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6564   (eval $ac_link) 2>conftest.er1
6565   ac_status=$?
6566   grep -v '^ *+' conftest.er1 >conftest.err
6567   rm -f conftest.er1
6568   cat conftest.err >&5
6569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6570   (exit $ac_status); } &&
6571          { ac_try='test -z "$ac_c_werror_flag"
6572                          || test ! -s conftest.err'
6573   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6574   (eval $ac_try) 2>&5
6575   ac_status=$?
6576   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6577   (exit $ac_status); }; } &&
6578          { ac_try='test -s conftest$ac_exeext'
6579   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6580   (eval $ac_try) 2>&5
6581   ac_status=$?
6582   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6583   (exit $ac_status); }; }; then
6584   ac_cv_search_com_err="-l$ac_lib"
6585 break
6586 else
6587   echo "$as_me: failed program was:" >&5
6588 sed 's/^/| /' conftest.$ac_ext >&5
6589
6590 fi
6591 rm -f conftest.err conftest.$ac_objext \
6592       conftest$ac_exeext conftest.$ac_ext
6593   done
6594 fi
6595 LIBS=$ac_func_search_save_LIBS
6596 fi
6597 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6598 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6599 if test "$ac_cv_search_com_err" != no; then
6600   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6601
6602 else
6603   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6604 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6605    { (exit 1); exit 1; }; }
6606 fi
6607
6608      echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
6609 echo $ECHO_N "checking for library containing krb5_sendauth... $ECHO_C" >&6
6610 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
6611   echo $ECHO_N "(cached) $ECHO_C" >&6
6612 else
6613   ac_func_search_save_LIBS=$LIBS
6614 ac_cv_search_krb5_sendauth=no
6615 cat >conftest.$ac_ext <<_ACEOF
6616 /* confdefs.h.  */
6617 _ACEOF
6618 cat confdefs.h >>conftest.$ac_ext
6619 cat >>conftest.$ac_ext <<_ACEOF
6620 /* end confdefs.h.  */
6621
6622 /* Override any gcc2 internal prototype to avoid an error.  */
6623 #ifdef __cplusplus
6624 extern "C"
6625 #endif
6626 /* We use char because int might match the return type of a gcc2
6627    builtin and then its argument prototype would still apply.  */
6628 char krb5_sendauth ();
6629 int
6630 main ()
6631 {
6632 krb5_sendauth ();
6633   ;
6634   return 0;
6635 }
6636 _ACEOF
6637 rm -f conftest.$ac_objext conftest$ac_exeext
6638 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6639   (eval $ac_link) 2>conftest.er1
6640   ac_status=$?
6641   grep -v '^ *+' conftest.er1 >conftest.err
6642   rm -f conftest.er1
6643   cat conftest.err >&5
6644   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6645   (exit $ac_status); } &&
6646          { ac_try='test -z "$ac_c_werror_flag"
6647                          || test ! -s conftest.err'
6648   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6649   (eval $ac_try) 2>&5
6650   ac_status=$?
6651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6652   (exit $ac_status); }; } &&
6653          { ac_try='test -s conftest$ac_exeext'
6654   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6655   (eval $ac_try) 2>&5
6656   ac_status=$?
6657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6658   (exit $ac_status); }; }; then
6659   ac_cv_search_krb5_sendauth="none required"
6660 else
6661   echo "$as_me: failed program was:" >&5
6662 sed 's/^/| /' conftest.$ac_ext >&5
6663
6664 fi
6665 rm -f conftest.err conftest.$ac_objext \
6666       conftest$ac_exeext conftest.$ac_ext
6667 if test "$ac_cv_search_krb5_sendauth" = no; then
6668   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken'; do
6669     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6670     cat >conftest.$ac_ext <<_ACEOF
6671 /* confdefs.h.  */
6672 _ACEOF
6673 cat confdefs.h >>conftest.$ac_ext
6674 cat >>conftest.$ac_ext <<_ACEOF
6675 /* end confdefs.h.  */
6676
6677 /* Override any gcc2 internal prototype to avoid an error.  */
6678 #ifdef __cplusplus
6679 extern "C"
6680 #endif
6681 /* We use char because int might match the return type of a gcc2
6682    builtin and then its argument prototype would still apply.  */
6683 char krb5_sendauth ();
6684 int
6685 main ()
6686 {
6687 krb5_sendauth ();
6688   ;
6689   return 0;
6690 }
6691 _ACEOF
6692 rm -f conftest.$ac_objext conftest$ac_exeext
6693 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6694   (eval $ac_link) 2>conftest.er1
6695   ac_status=$?
6696   grep -v '^ *+' conftest.er1 >conftest.err
6697   rm -f conftest.er1
6698   cat conftest.err >&5
6699   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6700   (exit $ac_status); } &&
6701          { ac_try='test -z "$ac_c_werror_flag"
6702                          || test ! -s conftest.err'
6703   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6704   (eval $ac_try) 2>&5
6705   ac_status=$?
6706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6707   (exit $ac_status); }; } &&
6708          { ac_try='test -s conftest$ac_exeext'
6709   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6710   (eval $ac_try) 2>&5
6711   ac_status=$?
6712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6713   (exit $ac_status); }; }; then
6714   ac_cv_search_krb5_sendauth="-l$ac_lib"
6715 break
6716 else
6717   echo "$as_me: failed program was:" >&5
6718 sed 's/^/| /' conftest.$ac_ext >&5
6719
6720 fi
6721 rm -f conftest.err conftest.$ac_objext \
6722       conftest$ac_exeext conftest.$ac_ext
6723   done
6724 fi
6725 LIBS=$ac_func_search_save_LIBS
6726 fi
6727 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
6728 echo "${ECHO_T}$ac_cv_search_krb5_sendauth" >&6
6729 if test "$ac_cv_search_krb5_sendauth" != no; then
6730   test "$ac_cv_search_krb5_sendauth" = "none required" || LIBS="$ac_cv_search_krb5_sendauth $LIBS"
6731
6732 else
6733   { { echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
6734 echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
6735    { (exit 1); exit 1; }; }
6736 fi
6737
6738   else
6739      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6740 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6741 if test "${ac_cv_search_com_err+set}" = set; then
6742   echo $ECHO_N "(cached) $ECHO_C" >&6
6743 else
6744   ac_func_search_save_LIBS=$LIBS
6745 ac_cv_search_com_err=no
6746 cat >conftest.$ac_ext <<_ACEOF
6747 /* confdefs.h.  */
6748 _ACEOF
6749 cat confdefs.h >>conftest.$ac_ext
6750 cat >>conftest.$ac_ext <<_ACEOF
6751 /* end confdefs.h.  */
6752
6753 /* Override any gcc2 internal prototype to avoid an error.  */
6754 #ifdef __cplusplus
6755 extern "C"
6756 #endif
6757 /* We use char because int might match the return type of a gcc2
6758    builtin and then its argument prototype would still apply.  */
6759 char com_err ();
6760 int
6761 main ()
6762 {
6763 com_err ();
6764   ;
6765   return 0;
6766 }
6767 _ACEOF
6768 rm -f conftest.$ac_objext conftest$ac_exeext
6769 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6770   (eval $ac_link) 2>conftest.er1
6771   ac_status=$?
6772   grep -v '^ *+' conftest.er1 >conftest.err
6773   rm -f conftest.er1
6774   cat conftest.err >&5
6775   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6776   (exit $ac_status); } &&
6777          { ac_try='test -z "$ac_c_werror_flag"
6778                          || test ! -s conftest.err'
6779   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6780   (eval $ac_try) 2>&5
6781   ac_status=$?
6782   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6783   (exit $ac_status); }; } &&
6784          { ac_try='test -s conftest$ac_exeext'
6785   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6786   (eval $ac_try) 2>&5
6787   ac_status=$?
6788   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6789   (exit $ac_status); }; }; then
6790   ac_cv_search_com_err="none required"
6791 else
6792   echo "$as_me: failed program was:" >&5
6793 sed 's/^/| /' conftest.$ac_ext >&5
6794
6795 fi
6796 rm -f conftest.err conftest.$ac_objext \
6797       conftest$ac_exeext conftest.$ac_ext
6798 if test "$ac_cv_search_com_err" = no; then
6799   for ac_lib in 'comerr32 -lkrb5_32'; do
6800     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6801     cat >conftest.$ac_ext <<_ACEOF
6802 /* confdefs.h.  */
6803 _ACEOF
6804 cat confdefs.h >>conftest.$ac_ext
6805 cat >>conftest.$ac_ext <<_ACEOF
6806 /* end confdefs.h.  */
6807
6808 /* Override any gcc2 internal prototype to avoid an error.  */
6809 #ifdef __cplusplus
6810 extern "C"
6811 #endif
6812 /* We use char because int might match the return type of a gcc2
6813    builtin and then its argument prototype would still apply.  */
6814 char com_err ();
6815 int
6816 main ()
6817 {
6818 com_err ();
6819   ;
6820   return 0;
6821 }
6822 _ACEOF
6823 rm -f conftest.$ac_objext conftest$ac_exeext
6824 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6825   (eval $ac_link) 2>conftest.er1
6826   ac_status=$?
6827   grep -v '^ *+' conftest.er1 >conftest.err
6828   rm -f conftest.er1
6829   cat conftest.err >&5
6830   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6831   (exit $ac_status); } &&
6832          { ac_try='test -z "$ac_c_werror_flag"
6833                          || test ! -s conftest.err'
6834   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6835   (eval $ac_try) 2>&5
6836   ac_status=$?
6837   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6838   (exit $ac_status); }; } &&
6839          { ac_try='test -s conftest$ac_exeext'
6840   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6841   (eval $ac_try) 2>&5
6842   ac_status=$?
6843   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6844   (exit $ac_status); }; }; then
6845   ac_cv_search_com_err="-l$ac_lib"
6846 break
6847 else
6848   echo "$as_me: failed program was:" >&5
6849 sed 's/^/| /' conftest.$ac_ext >&5
6850
6851 fi
6852 rm -f conftest.err conftest.$ac_objext \
6853       conftest$ac_exeext conftest.$ac_ext
6854   done
6855 fi
6856 LIBS=$ac_func_search_save_LIBS
6857 fi
6858 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6859 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6860 if test "$ac_cv_search_com_err" != no; then
6861   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6862
6863 else
6864   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6865 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6866    { (exit 1); exit 1; }; }
6867 fi
6868
6869   fi
6870 fi
6871
6872 if test "$with_openssl" = yes ; then
6873     if test "$PORTNAME" != "win32"; then
6874
6875 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
6876 echo $ECHO_N "checking for CRYPTO_new_ex_data in -lcrypto... $ECHO_C" >&6
6877 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
6878   echo $ECHO_N "(cached) $ECHO_C" >&6
6879 else
6880   ac_check_lib_save_LIBS=$LIBS
6881 LIBS="-lcrypto  $LIBS"
6882 cat >conftest.$ac_ext <<_ACEOF
6883 /* confdefs.h.  */
6884 _ACEOF
6885 cat confdefs.h >>conftest.$ac_ext
6886 cat >>conftest.$ac_ext <<_ACEOF
6887 /* end confdefs.h.  */
6888
6889 /* Override any gcc2 internal prototype to avoid an error.  */
6890 #ifdef __cplusplus
6891 extern "C"
6892 #endif
6893 /* We use char because int might match the return type of a gcc2
6894    builtin and then its argument prototype would still apply.  */
6895 char CRYPTO_new_ex_data ();
6896 int
6897 main ()
6898 {
6899 CRYPTO_new_ex_data ();
6900   ;
6901   return 0;
6902 }
6903 _ACEOF
6904 rm -f conftest.$ac_objext conftest$ac_exeext
6905 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6906   (eval $ac_link) 2>conftest.er1
6907   ac_status=$?
6908   grep -v '^ *+' conftest.er1 >conftest.err
6909   rm -f conftest.er1
6910   cat conftest.err >&5
6911   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6912   (exit $ac_status); } &&
6913          { ac_try='test -z "$ac_c_werror_flag"
6914                          || test ! -s conftest.err'
6915   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6916   (eval $ac_try) 2>&5
6917   ac_status=$?
6918   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6919   (exit $ac_status); }; } &&
6920          { ac_try='test -s conftest$ac_exeext'
6921   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6922   (eval $ac_try) 2>&5
6923   ac_status=$?
6924   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6925   (exit $ac_status); }; }; then
6926   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
6927 else
6928   echo "$as_me: failed program was:" >&5
6929 sed 's/^/| /' conftest.$ac_ext >&5
6930
6931 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
6932 fi
6933 rm -f conftest.err conftest.$ac_objext \
6934       conftest$ac_exeext conftest.$ac_ext
6935 LIBS=$ac_check_lib_save_LIBS
6936 fi
6937 echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
6938 echo "${ECHO_T}$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6
6939 if test $ac_cv_lib_crypto_CRYPTO_new_ex_data = yes; then
6940   cat >>confdefs.h <<_ACEOF
6941 #define HAVE_LIBCRYPTO 1
6942 _ACEOF
6943
6944   LIBS="-lcrypto $LIBS"
6945
6946 else
6947   { { echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
6948 echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
6949    { (exit 1); exit 1; }; }
6950 fi
6951
6952
6953 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
6954 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
6955 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
6956   echo $ECHO_N "(cached) $ECHO_C" >&6
6957 else
6958   ac_check_lib_save_LIBS=$LIBS
6959 LIBS="-lssl  $LIBS"
6960 cat >conftest.$ac_ext <<_ACEOF
6961 /* confdefs.h.  */
6962 _ACEOF
6963 cat confdefs.h >>conftest.$ac_ext
6964 cat >>conftest.$ac_ext <<_ACEOF
6965 /* end confdefs.h.  */
6966
6967 /* Override any gcc2 internal prototype to avoid an error.  */
6968 #ifdef __cplusplus
6969 extern "C"
6970 #endif
6971 /* We use char because int might match the return type of a gcc2
6972    builtin and then its argument prototype would still apply.  */
6973 char SSL_library_init ();
6974 int
6975 main ()
6976 {
6977 SSL_library_init ();
6978   ;
6979   return 0;
6980 }
6981 _ACEOF
6982 rm -f conftest.$ac_objext conftest$ac_exeext
6983 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6984   (eval $ac_link) 2>conftest.er1
6985   ac_status=$?
6986   grep -v '^ *+' conftest.er1 >conftest.err
6987   rm -f conftest.er1
6988   cat conftest.err >&5
6989   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6990   (exit $ac_status); } &&
6991          { ac_try='test -z "$ac_c_werror_flag"
6992                          || test ! -s conftest.err'
6993   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6994   (eval $ac_try) 2>&5
6995   ac_status=$?
6996   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6997   (exit $ac_status); }; } &&
6998          { ac_try='test -s conftest$ac_exeext'
6999   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7000   (eval $ac_try) 2>&5
7001   ac_status=$?
7002   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7003   (exit $ac_status); }; }; then
7004   ac_cv_lib_ssl_SSL_library_init=yes
7005 else
7006   echo "$as_me: failed program was:" >&5
7007 sed 's/^/| /' conftest.$ac_ext >&5
7008
7009 ac_cv_lib_ssl_SSL_library_init=no
7010 fi
7011 rm -f conftest.err conftest.$ac_objext \
7012       conftest$ac_exeext conftest.$ac_ext
7013 LIBS=$ac_check_lib_save_LIBS
7014 fi
7015 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
7016 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
7017 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
7018   cat >>confdefs.h <<_ACEOF
7019 #define HAVE_LIBSSL 1
7020 _ACEOF
7021
7022   LIBS="-lssl $LIBS"
7023
7024 else
7025   { { echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
7026 echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
7027    { (exit 1); exit 1; }; }
7028 fi
7029
7030   else
7031
7032 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
7033 echo $ECHO_N "checking for CRYPTO_new_ex_data in -leay32... $ECHO_C" >&6
7034 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
7035   echo $ECHO_N "(cached) $ECHO_C" >&6
7036 else
7037   ac_check_lib_save_LIBS=$LIBS
7038 LIBS="-leay32  $LIBS"
7039 cat >conftest.$ac_ext <<_ACEOF
7040 /* confdefs.h.  */
7041 _ACEOF
7042 cat confdefs.h >>conftest.$ac_ext
7043 cat >>conftest.$ac_ext <<_ACEOF
7044 /* end confdefs.h.  */
7045
7046 /* Override any gcc2 internal prototype to avoid an error.  */
7047 #ifdef __cplusplus
7048 extern "C"
7049 #endif
7050 /* We use char because int might match the return type of a gcc2
7051    builtin and then its argument prototype would still apply.  */
7052 char CRYPTO_new_ex_data ();
7053 int
7054 main ()
7055 {
7056 CRYPTO_new_ex_data ();
7057   ;
7058   return 0;
7059 }
7060 _ACEOF
7061 rm -f conftest.$ac_objext conftest$ac_exeext
7062 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7063   (eval $ac_link) 2>conftest.er1
7064   ac_status=$?
7065   grep -v '^ *+' conftest.er1 >conftest.err
7066   rm -f conftest.er1
7067   cat conftest.err >&5
7068   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7069   (exit $ac_status); } &&
7070          { ac_try='test -z "$ac_c_werror_flag"
7071                          || test ! -s conftest.err'
7072   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7073   (eval $ac_try) 2>&5
7074   ac_status=$?
7075   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7076   (exit $ac_status); }; } &&
7077          { ac_try='test -s conftest$ac_exeext'
7078   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7079   (eval $ac_try) 2>&5
7080   ac_status=$?
7081   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7082   (exit $ac_status); }; }; then
7083   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
7084 else
7085   echo "$as_me: failed program was:" >&5
7086 sed 's/^/| /' conftest.$ac_ext >&5
7087
7088 ac_cv_lib_eay32_CRYPTO_new_ex_data=no
7089 fi
7090 rm -f conftest.err conftest.$ac_objext \
7091       conftest$ac_exeext conftest.$ac_ext
7092 LIBS=$ac_check_lib_save_LIBS
7093 fi
7094 echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
7095 echo "${ECHO_T}$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6
7096 if test $ac_cv_lib_eay32_CRYPTO_new_ex_data = yes; then
7097   cat >>confdefs.h <<_ACEOF
7098 #define HAVE_LIBEAY32 1
7099 _ACEOF
7100
7101   LIBS="-leay32 $LIBS"
7102
7103 else
7104   { { echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
7105 echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
7106    { (exit 1); exit 1; }; }
7107 fi
7108
7109
7110 echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
7111 echo $ECHO_N "checking for SSL_library_init in -lssleay32... $ECHO_C" >&6
7112 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
7113   echo $ECHO_N "(cached) $ECHO_C" >&6
7114 else
7115   ac_check_lib_save_LIBS=$LIBS
7116 LIBS="-lssleay32  $LIBS"
7117 cat >conftest.$ac_ext <<_ACEOF
7118 /* confdefs.h.  */
7119 _ACEOF
7120 cat confdefs.h >>conftest.$ac_ext
7121 cat >>conftest.$ac_ext <<_ACEOF
7122 /* end confdefs.h.  */
7123
7124 /* Override any gcc2 internal prototype to avoid an error.  */
7125 #ifdef __cplusplus
7126 extern "C"
7127 #endif
7128 /* We use char because int might match the return type of a gcc2
7129    builtin and then its argument prototype would still apply.  */
7130 char SSL_library_init ();
7131 int
7132 main ()
7133 {
7134 SSL_library_init ();
7135   ;
7136   return 0;
7137 }
7138 _ACEOF
7139 rm -f conftest.$ac_objext conftest$ac_exeext
7140 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7141   (eval $ac_link) 2>conftest.er1
7142   ac_status=$?
7143   grep -v '^ *+' conftest.er1 >conftest.err
7144   rm -f conftest.er1
7145   cat conftest.err >&5
7146   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7147   (exit $ac_status); } &&
7148          { ac_try='test -z "$ac_c_werror_flag"
7149                          || test ! -s conftest.err'
7150   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7151   (eval $ac_try) 2>&5
7152   ac_status=$?
7153   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7154   (exit $ac_status); }; } &&
7155          { ac_try='test -s conftest$ac_exeext'
7156   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7157   (eval $ac_try) 2>&5
7158   ac_status=$?
7159   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7160   (exit $ac_status); }; }; then
7161   ac_cv_lib_ssleay32_SSL_library_init=yes
7162 else
7163   echo "$as_me: failed program was:" >&5
7164 sed 's/^/| /' conftest.$ac_ext >&5
7165
7166 ac_cv_lib_ssleay32_SSL_library_init=no
7167 fi
7168 rm -f conftest.err conftest.$ac_objext \
7169       conftest$ac_exeext conftest.$ac_ext
7170 LIBS=$ac_check_lib_save_LIBS
7171 fi
7172 echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
7173 echo "${ECHO_T}$ac_cv_lib_ssleay32_SSL_library_init" >&6
7174 if test $ac_cv_lib_ssleay32_SSL_library_init = yes; then
7175   cat >>confdefs.h <<_ACEOF
7176 #define HAVE_LIBSSLEAY32 1
7177 _ACEOF
7178
7179   LIBS="-lssleay32 $LIBS"
7180
7181 else
7182   { { echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
7183 echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
7184    { (exit 1); exit 1; }; }
7185 fi
7186
7187   fi
7188 fi
7189
7190 if test "$with_pam" = yes ; then
7191
7192 echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
7193 echo $ECHO_N "checking for pam_start in -lpam... $ECHO_C" >&6
7194 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
7195   echo $ECHO_N "(cached) $ECHO_C" >&6
7196 else
7197   ac_check_lib_save_LIBS=$LIBS
7198 LIBS="-lpam  $LIBS"
7199 cat >conftest.$ac_ext <<_ACEOF
7200 /* confdefs.h.  */
7201 _ACEOF
7202 cat confdefs.h >>conftest.$ac_ext
7203 cat >>conftest.$ac_ext <<_ACEOF
7204 /* end confdefs.h.  */
7205
7206 /* Override any gcc2 internal prototype to avoid an error.  */
7207 #ifdef __cplusplus
7208 extern "C"
7209 #endif
7210 /* We use char because int might match the return type of a gcc2
7211    builtin and then its argument prototype would still apply.  */
7212 char pam_start ();
7213 int
7214 main ()
7215 {
7216 pam_start ();
7217   ;
7218   return 0;
7219 }
7220 _ACEOF
7221 rm -f conftest.$ac_objext conftest$ac_exeext
7222 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7223   (eval $ac_link) 2>conftest.er1
7224   ac_status=$?
7225   grep -v '^ *+' conftest.er1 >conftest.err
7226   rm -f conftest.er1
7227   cat conftest.err >&5
7228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7229   (exit $ac_status); } &&
7230          { ac_try='test -z "$ac_c_werror_flag"
7231                          || test ! -s conftest.err'
7232   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7233   (eval $ac_try) 2>&5
7234   ac_status=$?
7235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7236   (exit $ac_status); }; } &&
7237          { ac_try='test -s conftest$ac_exeext'
7238   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7239   (eval $ac_try) 2>&5
7240   ac_status=$?
7241   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7242   (exit $ac_status); }; }; then
7243   ac_cv_lib_pam_pam_start=yes
7244 else
7245   echo "$as_me: failed program was:" >&5
7246 sed 's/^/| /' conftest.$ac_ext >&5
7247
7248 ac_cv_lib_pam_pam_start=no
7249 fi
7250 rm -f conftest.err conftest.$ac_objext \
7251       conftest$ac_exeext conftest.$ac_ext
7252 LIBS=$ac_check_lib_save_LIBS
7253 fi
7254 echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
7255 echo "${ECHO_T}$ac_cv_lib_pam_pam_start" >&6
7256 if test $ac_cv_lib_pam_pam_start = yes; then
7257   cat >>confdefs.h <<_ACEOF
7258 #define HAVE_LIBPAM 1
7259 _ACEOF
7260
7261   LIBS="-lpam $LIBS"
7262
7263 else
7264   { { echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
7265 echo "$as_me: error: library 'pam' is required for PAM" >&2;}
7266    { (exit 1); exit 1; }; }
7267 fi
7268
7269 fi
7270
7271
7272 ##
7273 ## Header files
7274 ##
7275
7276 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
7277 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
7278 if test "${ac_cv_header_stdc+set}" = set; then
7279   echo $ECHO_N "(cached) $ECHO_C" >&6
7280 else
7281   cat >conftest.$ac_ext <<_ACEOF
7282 /* confdefs.h.  */
7283 _ACEOF
7284 cat confdefs.h >>conftest.$ac_ext
7285 cat >>conftest.$ac_ext <<_ACEOF
7286 /* end confdefs.h.  */
7287 #include <stdlib.h>
7288 #include <stdarg.h>
7289 #include <string.h>
7290 #include <float.h>
7291
7292 int
7293 main ()
7294 {
7295
7296   ;
7297   return 0;
7298 }
7299 _ACEOF
7300 rm -f conftest.$ac_objext
7301 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7302   (eval $ac_compile) 2>conftest.er1
7303   ac_status=$?
7304   grep -v '^ *+' conftest.er1 >conftest.err
7305   rm -f conftest.er1
7306   cat conftest.err >&5
7307   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7308   (exit $ac_status); } &&
7309          { ac_try='test -z "$ac_c_werror_flag"
7310                          || test ! -s conftest.err'
7311   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7312   (eval $ac_try) 2>&5
7313   ac_status=$?
7314   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7315   (exit $ac_status); }; } &&
7316          { ac_try='test -s conftest.$ac_objext'
7317   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7318   (eval $ac_try) 2>&5
7319   ac_status=$?
7320   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7321   (exit $ac_status); }; }; then
7322   ac_cv_header_stdc=yes
7323 else
7324   echo "$as_me: failed program was:" >&5
7325 sed 's/^/| /' conftest.$ac_ext >&5
7326
7327 ac_cv_header_stdc=no
7328 fi
7329 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7330
7331 if test $ac_cv_header_stdc = yes; then
7332   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7333   cat >conftest.$ac_ext <<_ACEOF
7334 /* confdefs.h.  */
7335 _ACEOF
7336 cat confdefs.h >>conftest.$ac_ext
7337 cat >>conftest.$ac_ext <<_ACEOF
7338 /* end confdefs.h.  */
7339 #include <string.h>
7340
7341 _ACEOF
7342 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7343   $EGREP "memchr" >/dev/null 2>&1; then
7344   :
7345 else
7346   ac_cv_header_stdc=no
7347 fi
7348 rm -f conftest*
7349
7350 fi
7351
7352 if test $ac_cv_header_stdc = yes; then
7353   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7354   cat >conftest.$ac_ext <<_ACEOF
7355 /* confdefs.h.  */
7356 _ACEOF
7357 cat confdefs.h >>conftest.$ac_ext
7358 cat >>conftest.$ac_ext <<_ACEOF
7359 /* end confdefs.h.  */
7360 #include <stdlib.h>
7361
7362 _ACEOF
7363 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7364   $EGREP "free" >/dev/null 2>&1; then
7365   :
7366 else
7367   ac_cv_header_stdc=no
7368 fi
7369 rm -f conftest*
7370
7371 fi
7372
7373 if test $ac_cv_header_stdc = yes; then
7374   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7375   if test "$cross_compiling" = yes; then
7376   :
7377 else
7378   cat >conftest.$ac_ext <<_ACEOF
7379 /* confdefs.h.  */
7380 _ACEOF
7381 cat confdefs.h >>conftest.$ac_ext
7382 cat >>conftest.$ac_ext <<_ACEOF
7383 /* end confdefs.h.  */
7384 #include <ctype.h>
7385 #if ((' ' & 0x0FF) == 0x020)
7386 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7387 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7388 #else
7389 # define ISLOWER(c) \
7390                    (('a' <= (c) && (c) <= 'i') \
7391                      || ('j' <= (c) && (c) <= 'r') \
7392                      || ('s' <= (c) && (c) <= 'z'))
7393 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7394 #endif
7395
7396 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7397 int
7398 main ()
7399 {
7400   int i;
7401   for (i = 0; i < 256; i++)
7402     if (XOR (islower (i), ISLOWER (i))
7403         || toupper (i) != TOUPPER (i))
7404       exit(2);
7405   exit (0);
7406 }
7407 _ACEOF
7408 rm -f conftest$ac_exeext
7409 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7410   (eval $ac_link) 2>&5
7411   ac_status=$?
7412   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7413   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7415   (eval $ac_try) 2>&5
7416   ac_status=$?
7417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7418   (exit $ac_status); }; }; then
7419   :
7420 else
7421   echo "$as_me: program exited with status $ac_status" >&5
7422 echo "$as_me: failed program was:" >&5
7423 sed 's/^/| /' conftest.$ac_ext >&5
7424
7425 ( exit $ac_status )
7426 ac_cv_header_stdc=no
7427 fi
7428 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7429 fi
7430 fi
7431 fi
7432 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
7433 echo "${ECHO_T}$ac_cv_header_stdc" >&6
7434 if test $ac_cv_header_stdc = yes; then
7435
7436 cat >>confdefs.h <<\_ACEOF
7437 #define STDC_HEADERS 1
7438 _ACEOF
7439
7440 fi
7441
7442 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
7443
7444
7445
7446
7447
7448
7449
7450
7451
7452 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7453                   inttypes.h stdint.h unistd.h
7454 do
7455 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7456 echo "$as_me:$LINENO: checking for $ac_header" >&5
7457 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7458 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7459   echo $ECHO_N "(cached) $ECHO_C" >&6
7460 else
7461   cat >conftest.$ac_ext <<_ACEOF
7462 /* confdefs.h.  */
7463 _ACEOF
7464 cat confdefs.h >>conftest.$ac_ext
7465 cat >>conftest.$ac_ext <<_ACEOF
7466 /* end confdefs.h.  */
7467 $ac_includes_default
7468
7469 #include <$ac_header>
7470 _ACEOF
7471 rm -f conftest.$ac_objext
7472 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7473   (eval $ac_compile) 2>conftest.er1
7474   ac_status=$?
7475   grep -v '^ *+' conftest.er1 >conftest.err
7476   rm -f conftest.er1
7477   cat conftest.err >&5
7478   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7479   (exit $ac_status); } &&
7480          { ac_try='test -z "$ac_c_werror_flag"
7481                          || test ! -s conftest.err'
7482   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7483   (eval $ac_try) 2>&5
7484   ac_status=$?
7485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7486   (exit $ac_status); }; } &&
7487          { ac_try='test -s conftest.$ac_objext'
7488   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7489   (eval $ac_try) 2>&5
7490   ac_status=$?
7491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7492   (exit $ac_status); }; }; then
7493   eval "$as_ac_Header=yes"
7494 else
7495   echo "$as_me: failed program was:" >&5
7496 sed 's/^/| /' conftest.$ac_ext >&5
7497
7498 eval "$as_ac_Header=no"
7499 fi
7500 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7501 fi
7502 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7503 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7504 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7505   cat >>confdefs.h <<_ACEOF
7506 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7507 _ACEOF
7508
7509 fi
7510
7511 done
7512
7513
7514
7515
7516
7517
7518
7519
7520
7521
7522
7523
7524
7525
7526
7527
7528
7529
7530
7531
7532
7533
7534
7535
7536
7537
7538
7539
7540 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/resource.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
7541 do
7542 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7543 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7544   echo "$as_me:$LINENO: checking for $ac_header" >&5
7545 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7546 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7547   echo $ECHO_N "(cached) $ECHO_C" >&6
7548 fi
7549 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7550 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7551 else
7552   # Is the header compilable?
7553 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7554 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7555 cat >conftest.$ac_ext <<_ACEOF
7556 /* confdefs.h.  */
7557 _ACEOF
7558 cat confdefs.h >>conftest.$ac_ext
7559 cat >>conftest.$ac_ext <<_ACEOF
7560 /* end confdefs.h.  */
7561 $ac_includes_default
7562 #include <$ac_header>
7563 _ACEOF
7564 rm -f conftest.$ac_objext
7565 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7566   (eval $ac_compile) 2>conftest.er1
7567   ac_status=$?
7568   grep -v '^ *+' conftest.er1 >conftest.err
7569   rm -f conftest.er1
7570   cat conftest.err >&5
7571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7572   (exit $ac_status); } &&
7573          { ac_try='test -z "$ac_c_werror_flag"
7574                          || test ! -s conftest.err'
7575   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7576   (eval $ac_try) 2>&5
7577   ac_status=$?
7578   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7579   (exit $ac_status); }; } &&
7580          { ac_try='test -s conftest.$ac_objext'
7581   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7582   (eval $ac_try) 2>&5
7583   ac_status=$?
7584   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7585   (exit $ac_status); }; }; then
7586   ac_header_compiler=yes
7587 else
7588   echo "$as_me: failed program was:" >&5
7589 sed 's/^/| /' conftest.$ac_ext >&5
7590
7591 ac_header_compiler=no
7592 fi
7593 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7594 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7595 echo "${ECHO_T}$ac_header_compiler" >&6
7596
7597 # Is the header present?
7598 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7599 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7600 cat >conftest.$ac_ext <<_ACEOF
7601 /* confdefs.h.  */
7602 _ACEOF
7603 cat confdefs.h >>conftest.$ac_ext
7604 cat >>conftest.$ac_ext <<_ACEOF
7605 /* end confdefs.h.  */
7606 #include <$ac_header>
7607 _ACEOF
7608 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7609   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7610   ac_status=$?
7611   grep -v '^ *+' conftest.er1 >conftest.err
7612   rm -f conftest.er1
7613   cat conftest.err >&5
7614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7615   (exit $ac_status); } >/dev/null; then
7616   if test -s conftest.err; then
7617     ac_cpp_err=$ac_c_preproc_warn_flag
7618     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7619   else
7620     ac_cpp_err=
7621   fi
7622 else
7623   ac_cpp_err=yes
7624 fi
7625 if test -z "$ac_cpp_err"; then
7626   ac_header_preproc=yes
7627 else
7628   echo "$as_me: failed program was:" >&5
7629 sed 's/^/| /' conftest.$ac_ext >&5
7630
7631   ac_header_preproc=no
7632 fi
7633 rm -f conftest.err conftest.$ac_ext
7634 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7635 echo "${ECHO_T}$ac_header_preproc" >&6
7636
7637 # So?  What about this header?
7638 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7639   yes:no: )
7640     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7641 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7642     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7643 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7644     ac_header_preproc=yes
7645     ;;
7646   no:yes:* )
7647     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7648 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7649     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7650 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7651     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7652 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7653     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7654 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7655     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7656 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7657     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7658 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7659     (
7660       cat <<\_ASBOX
7661 ## ---------------------------------------- ##
7662 ## Report this to pgsql-bugs@postgresql.org ##
7663 ## ---------------------------------------- ##
7664 _ASBOX
7665     ) |
7666       sed "s/^/$as_me: WARNING:     /" >&2
7667     ;;
7668 esac
7669 echo "$as_me:$LINENO: checking for $ac_header" >&5
7670 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7671 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7672   echo $ECHO_N "(cached) $ECHO_C" >&6
7673 else
7674   eval "$as_ac_Header=\$ac_header_preproc"
7675 fi
7676 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7677 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7678
7679 fi
7680 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7681   cat >>confdefs.h <<_ACEOF
7682 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7683 _ACEOF
7684
7685 fi
7686
7687 done
7688
7689
7690 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
7691 # netinet/in.h is included first.
7692
7693 for ac_header in netinet/in.h
7694 do
7695 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7696 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7697   echo "$as_me:$LINENO: checking for $ac_header" >&5
7698 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7699 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7700   echo $ECHO_N "(cached) $ECHO_C" >&6
7701 fi
7702 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7703 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7704 else
7705   # Is the header compilable?
7706 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7707 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7708 cat >conftest.$ac_ext <<_ACEOF
7709 /* confdefs.h.  */
7710 _ACEOF
7711 cat confdefs.h >>conftest.$ac_ext
7712 cat >>conftest.$ac_ext <<_ACEOF
7713 /* end confdefs.h.  */
7714 $ac_includes_default
7715 #include <$ac_header>
7716 _ACEOF
7717 rm -f conftest.$ac_objext
7718 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7719   (eval $ac_compile) 2>conftest.er1
7720   ac_status=$?
7721   grep -v '^ *+' conftest.er1 >conftest.err
7722   rm -f conftest.er1
7723   cat conftest.err >&5
7724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7725   (exit $ac_status); } &&
7726          { ac_try='test -z "$ac_c_werror_flag"
7727                          || test ! -s conftest.err'
7728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7729   (eval $ac_try) 2>&5
7730   ac_status=$?
7731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7732   (exit $ac_status); }; } &&
7733          { ac_try='test -s conftest.$ac_objext'
7734   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7735   (eval $ac_try) 2>&5
7736   ac_status=$?
7737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7738   (exit $ac_status); }; }; then
7739   ac_header_compiler=yes
7740 else
7741   echo "$as_me: failed program was:" >&5
7742 sed 's/^/| /' conftest.$ac_ext >&5
7743
7744 ac_header_compiler=no
7745 fi
7746 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7747 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7748 echo "${ECHO_T}$ac_header_compiler" >&6
7749
7750 # Is the header present?
7751 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7752 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7753 cat >conftest.$ac_ext <<_ACEOF
7754 /* confdefs.h.  */
7755 _ACEOF
7756 cat confdefs.h >>conftest.$ac_ext
7757 cat >>conftest.$ac_ext <<_ACEOF
7758 /* end confdefs.h.  */
7759 #include <$ac_header>
7760 _ACEOF
7761 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7762   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7763   ac_status=$?
7764   grep -v '^ *+' conftest.er1 >conftest.err
7765   rm -f conftest.er1
7766   cat conftest.err >&5
7767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7768   (exit $ac_status); } >/dev/null; then
7769   if test -s conftest.err; then
7770     ac_cpp_err=$ac_c_preproc_warn_flag
7771     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7772   else
7773     ac_cpp_err=
7774   fi
7775 else
7776   ac_cpp_err=yes
7777 fi
7778 if test -z "$ac_cpp_err"; then
7779   ac_header_preproc=yes
7780 else
7781   echo "$as_me: failed program was:" >&5
7782 sed 's/^/| /' conftest.$ac_ext >&5
7783
7784   ac_header_preproc=no
7785 fi
7786 rm -f conftest.err conftest.$ac_ext
7787 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7788 echo "${ECHO_T}$ac_header_preproc" >&6
7789
7790 # So?  What about this header?
7791 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7792   yes:no: )
7793     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7794 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7795     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7796 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7797     ac_header_preproc=yes
7798     ;;
7799   no:yes:* )
7800     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7801 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7802     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7803 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7804     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7805 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7806     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7807 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7808     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7809 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7810     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7811 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7812     (
7813       cat <<\_ASBOX
7814 ## ---------------------------------------- ##
7815 ## Report this to pgsql-bugs@postgresql.org ##
7816 ## ---------------------------------------- ##
7817 _ASBOX
7818     ) |
7819       sed "s/^/$as_me: WARNING:     /" >&2
7820     ;;
7821 esac
7822 echo "$as_me:$LINENO: checking for $ac_header" >&5
7823 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7824 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7825   echo $ECHO_N "(cached) $ECHO_C" >&6
7826 else
7827   eval "$as_ac_Header=\$ac_header_preproc"
7828 fi
7829 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7830 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7831
7832 fi
7833 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7834   cat >>confdefs.h <<_ACEOF
7835 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7836 _ACEOF
7837
7838 fi
7839
7840 done
7841
7842
7843 for ac_header in netinet/tcp.h
7844 do
7845 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7846 echo "$as_me:$LINENO: checking for $ac_header" >&5
7847 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7848 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7849   echo $ECHO_N "(cached) $ECHO_C" >&6
7850 else
7851   cat >conftest.$ac_ext <<_ACEOF
7852 /* confdefs.h.  */
7853 _ACEOF
7854 cat confdefs.h >>conftest.$ac_ext
7855 cat >>conftest.$ac_ext <<_ACEOF
7856 /* end confdefs.h.  */
7857 $ac_includes_default
7858 #ifdef HAVE_NETINET_IN_H
7859 #include <netinet/in.h>
7860 #endif
7861
7862
7863 #include <$ac_header>
7864 _ACEOF
7865 rm -f conftest.$ac_objext
7866 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7867   (eval $ac_compile) 2>conftest.er1
7868   ac_status=$?
7869   grep -v '^ *+' conftest.er1 >conftest.err
7870   rm -f conftest.er1
7871   cat conftest.err >&5
7872   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7873   (exit $ac_status); } &&
7874          { ac_try='test -z "$ac_c_werror_flag"
7875                          || test ! -s conftest.err'
7876   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7877   (eval $ac_try) 2>&5
7878   ac_status=$?
7879   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7880   (exit $ac_status); }; } &&
7881          { ac_try='test -s conftest.$ac_objext'
7882   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7883   (eval $ac_try) 2>&5
7884   ac_status=$?
7885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7886   (exit $ac_status); }; }; then
7887   eval "$as_ac_Header=yes"
7888 else
7889   echo "$as_me: failed program was:" >&5
7890 sed 's/^/| /' conftest.$ac_ext >&5
7891
7892 eval "$as_ac_Header=no"
7893 fi
7894 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7895 fi
7896 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7897 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7898 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7899   cat >>confdefs.h <<_ACEOF
7900 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7901 _ACEOF
7902
7903 fi
7904
7905 done
7906
7907
7908 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
7909
7910 for ac_header in readline/readline.h
7911 do
7912 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7913 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7914   echo "$as_me:$LINENO: checking for $ac_header" >&5
7915 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7916 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7917   echo $ECHO_N "(cached) $ECHO_C" >&6
7918 fi
7919 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7920 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7921 else
7922   # Is the header compilable?
7923 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7924 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7925 cat >conftest.$ac_ext <<_ACEOF
7926 /* confdefs.h.  */
7927 _ACEOF
7928 cat confdefs.h >>conftest.$ac_ext
7929 cat >>conftest.$ac_ext <<_ACEOF
7930 /* end confdefs.h.  */
7931 $ac_includes_default
7932 #include <$ac_header>
7933 _ACEOF
7934 rm -f conftest.$ac_objext
7935 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7936   (eval $ac_compile) 2>conftest.er1
7937   ac_status=$?
7938   grep -v '^ *+' conftest.er1 >conftest.err
7939   rm -f conftest.er1
7940   cat conftest.err >&5
7941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7942   (exit $ac_status); } &&
7943          { ac_try='test -z "$ac_c_werror_flag"
7944                          || test ! -s conftest.err'
7945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7946   (eval $ac_try) 2>&5
7947   ac_status=$?
7948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7949   (exit $ac_status); }; } &&
7950          { ac_try='test -s conftest.$ac_objext'
7951   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7952   (eval $ac_try) 2>&5
7953   ac_status=$?
7954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7955   (exit $ac_status); }; }; then
7956   ac_header_compiler=yes
7957 else
7958   echo "$as_me: failed program was:" >&5
7959 sed 's/^/| /' conftest.$ac_ext >&5
7960
7961 ac_header_compiler=no
7962 fi
7963 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
7964 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7965 echo "${ECHO_T}$ac_header_compiler" >&6
7966
7967 # Is the header present?
7968 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7969 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7970 cat >conftest.$ac_ext <<_ACEOF
7971 /* confdefs.h.  */
7972 _ACEOF
7973 cat confdefs.h >>conftest.$ac_ext
7974 cat >>conftest.$ac_ext <<_ACEOF
7975 /* end confdefs.h.  */
7976 #include <$ac_header>
7977 _ACEOF
7978 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7979   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7980   ac_status=$?
7981   grep -v '^ *+' conftest.er1 >conftest.err
7982   rm -f conftest.er1
7983   cat conftest.err >&5
7984   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7985   (exit $ac_status); } >/dev/null; then
7986   if test -s conftest.err; then
7987     ac_cpp_err=$ac_c_preproc_warn_flag
7988     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
7989   else
7990     ac_cpp_err=
7991   fi
7992 else
7993   ac_cpp_err=yes
7994 fi
7995 if test -z "$ac_cpp_err"; then
7996   ac_header_preproc=yes
7997 else
7998   echo "$as_me: failed program was:" >&5
7999 sed 's/^/| /' conftest.$ac_ext >&5
8000
8001   ac_header_preproc=no
8002 fi
8003 rm -f conftest.err conftest.$ac_ext
8004 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8005 echo "${ECHO_T}$ac_header_preproc" >&6
8006
8007 # So?  What about this header?
8008 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8009   yes:no: )
8010     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8011 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8012     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8013 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8014     ac_header_preproc=yes
8015     ;;
8016   no:yes:* )
8017     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8018 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8019     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8020 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8021     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8022 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8023     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8024 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8025     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8026 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8027     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8028 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8029     (
8030       cat <<\_ASBOX
8031 ## ---------------------------------------- ##
8032 ## Report this to pgsql-bugs@postgresql.org ##
8033 ## ---------------------------------------- ##
8034 _ASBOX
8035     ) |
8036       sed "s/^/$as_me: WARNING:     /" >&2
8037     ;;
8038 esac
8039 echo "$as_me:$LINENO: checking for $ac_header" >&5
8040 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8041 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8042   echo $ECHO_N "(cached) $ECHO_C" >&6
8043 else
8044   eval "$as_ac_Header=\$ac_header_preproc"
8045 fi
8046 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8047 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8048
8049 fi
8050 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8051   cat >>confdefs.h <<_ACEOF
8052 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8053 _ACEOF
8054
8055 else
8056
8057 for ac_header in readline.h
8058 do
8059 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8060 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8061   echo "$as_me:$LINENO: checking for $ac_header" >&5
8062 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8063 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8064   echo $ECHO_N "(cached) $ECHO_C" >&6
8065 fi
8066 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8067 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8068 else
8069   # Is the header compilable?
8070 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8071 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8072 cat >conftest.$ac_ext <<_ACEOF
8073 /* confdefs.h.  */
8074 _ACEOF
8075 cat confdefs.h >>conftest.$ac_ext
8076 cat >>conftest.$ac_ext <<_ACEOF
8077 /* end confdefs.h.  */
8078 $ac_includes_default
8079 #include <$ac_header>
8080 _ACEOF
8081 rm -f conftest.$ac_objext
8082 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8083   (eval $ac_compile) 2>conftest.er1
8084   ac_status=$?
8085   grep -v '^ *+' conftest.er1 >conftest.err
8086   rm -f conftest.er1
8087   cat conftest.err >&5
8088   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8089   (exit $ac_status); } &&
8090          { ac_try='test -z "$ac_c_werror_flag"
8091                          || test ! -s conftest.err'
8092   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8093   (eval $ac_try) 2>&5
8094   ac_status=$?
8095   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8096   (exit $ac_status); }; } &&
8097          { ac_try='test -s conftest.$ac_objext'
8098   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8099   (eval $ac_try) 2>&5
8100   ac_status=$?
8101   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8102   (exit $ac_status); }; }; then
8103   ac_header_compiler=yes
8104 else
8105   echo "$as_me: failed program was:" >&5
8106 sed 's/^/| /' conftest.$ac_ext >&5
8107
8108 ac_header_compiler=no
8109 fi
8110 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8111 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8112 echo "${ECHO_T}$ac_header_compiler" >&6
8113
8114 # Is the header present?
8115 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8116 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8117 cat >conftest.$ac_ext <<_ACEOF
8118 /* confdefs.h.  */
8119 _ACEOF
8120 cat confdefs.h >>conftest.$ac_ext
8121 cat >>conftest.$ac_ext <<_ACEOF
8122 /* end confdefs.h.  */
8123 #include <$ac_header>
8124 _ACEOF
8125 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8126   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8127   ac_status=$?
8128   grep -v '^ *+' conftest.er1 >conftest.err
8129   rm -f conftest.er1
8130   cat conftest.err >&5
8131   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8132   (exit $ac_status); } >/dev/null; then
8133   if test -s conftest.err; then
8134     ac_cpp_err=$ac_c_preproc_warn_flag
8135     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8136   else
8137     ac_cpp_err=
8138   fi
8139 else
8140   ac_cpp_err=yes
8141 fi
8142 if test -z "$ac_cpp_err"; then
8143   ac_header_preproc=yes
8144 else
8145   echo "$as_me: failed program was:" >&5
8146 sed 's/^/| /' conftest.$ac_ext >&5
8147
8148   ac_header_preproc=no
8149 fi
8150 rm -f conftest.err conftest.$ac_ext
8151 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8152 echo "${ECHO_T}$ac_header_preproc" >&6
8153
8154 # So?  What about this header?
8155 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8156   yes:no: )
8157     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8158 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8159     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8160 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8161     ac_header_preproc=yes
8162     ;;
8163   no:yes:* )
8164     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8165 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8166     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8167 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8168     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8169 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8170     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8171 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8172     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8173 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8174     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8175 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8176     (
8177       cat <<\_ASBOX
8178 ## ---------------------------------------- ##
8179 ## Report this to pgsql-bugs@postgresql.org ##
8180 ## ---------------------------------------- ##
8181 _ASBOX
8182     ) |
8183       sed "s/^/$as_me: WARNING:     /" >&2
8184     ;;
8185 esac
8186 echo "$as_me:$LINENO: checking for $ac_header" >&5
8187 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8188 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8189   echo $ECHO_N "(cached) $ECHO_C" >&6
8190 else
8191   eval "$as_ac_Header=\$ac_header_preproc"
8192 fi
8193 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8194 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8195
8196 fi
8197 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8198   cat >>confdefs.h <<_ACEOF
8199 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8200 _ACEOF
8201
8202 else
8203   { { echo "$as_me:$LINENO: error: readline header not found
8204 If you have readline already installed, see config.log for details on the
8205 failure.  It is possible the compiler isn't looking in the proper directory.
8206 Use --without-readline to disable readline support." >&5
8207 echo "$as_me: error: readline header not found
8208 If you have readline already installed, see config.log for details on the
8209 failure.  It is possible the compiler isn't looking in the proper directory.
8210 Use --without-readline to disable readline support." >&2;}
8211    { (exit 1); exit 1; }; }
8212 fi
8213
8214 done
8215
8216 fi
8217
8218 done
8219
8220
8221 for ac_header in readline/history.h
8222 do
8223 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8224 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8225   echo "$as_me:$LINENO: checking for $ac_header" >&5
8226 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8227 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8228   echo $ECHO_N "(cached) $ECHO_C" >&6
8229 fi
8230 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8231 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8232 else
8233   # Is the header compilable?
8234 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8235 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8236 cat >conftest.$ac_ext <<_ACEOF
8237 /* confdefs.h.  */
8238 _ACEOF
8239 cat confdefs.h >>conftest.$ac_ext
8240 cat >>conftest.$ac_ext <<_ACEOF
8241 /* end confdefs.h.  */
8242 $ac_includes_default
8243 #include <$ac_header>
8244 _ACEOF
8245 rm -f conftest.$ac_objext
8246 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8247   (eval $ac_compile) 2>conftest.er1
8248   ac_status=$?
8249   grep -v '^ *+' conftest.er1 >conftest.err
8250   rm -f conftest.er1
8251   cat conftest.err >&5
8252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8253   (exit $ac_status); } &&
8254          { ac_try='test -z "$ac_c_werror_flag"
8255                          || test ! -s conftest.err'
8256   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8257   (eval $ac_try) 2>&5
8258   ac_status=$?
8259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8260   (exit $ac_status); }; } &&
8261          { ac_try='test -s conftest.$ac_objext'
8262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8263   (eval $ac_try) 2>&5
8264   ac_status=$?
8265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8266   (exit $ac_status); }; }; then
8267   ac_header_compiler=yes
8268 else
8269   echo "$as_me: failed program was:" >&5
8270 sed 's/^/| /' conftest.$ac_ext >&5
8271
8272 ac_header_compiler=no
8273 fi
8274 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8275 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8276 echo "${ECHO_T}$ac_header_compiler" >&6
8277
8278 # Is the header present?
8279 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8280 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8281 cat >conftest.$ac_ext <<_ACEOF
8282 /* confdefs.h.  */
8283 _ACEOF
8284 cat confdefs.h >>conftest.$ac_ext
8285 cat >>conftest.$ac_ext <<_ACEOF
8286 /* end confdefs.h.  */
8287 #include <$ac_header>
8288 _ACEOF
8289 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8290   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8291   ac_status=$?
8292   grep -v '^ *+' conftest.er1 >conftest.err
8293   rm -f conftest.er1
8294   cat conftest.err >&5
8295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8296   (exit $ac_status); } >/dev/null; then
8297   if test -s conftest.err; then
8298     ac_cpp_err=$ac_c_preproc_warn_flag
8299     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8300   else
8301     ac_cpp_err=
8302   fi
8303 else
8304   ac_cpp_err=yes
8305 fi
8306 if test -z "$ac_cpp_err"; then
8307   ac_header_preproc=yes
8308 else
8309   echo "$as_me: failed program was:" >&5
8310 sed 's/^/| /' conftest.$ac_ext >&5
8311
8312   ac_header_preproc=no
8313 fi
8314 rm -f conftest.err conftest.$ac_ext
8315 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8316 echo "${ECHO_T}$ac_header_preproc" >&6
8317
8318 # So?  What about this header?
8319 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8320   yes:no: )
8321     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8322 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8323     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8324 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8325     ac_header_preproc=yes
8326     ;;
8327   no:yes:* )
8328     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8329 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8330     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8331 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8332     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8333 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8334     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8335 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8336     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8337 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8338     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8339 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8340     (
8341       cat <<\_ASBOX
8342 ## ---------------------------------------- ##
8343 ## Report this to pgsql-bugs@postgresql.org ##
8344 ## ---------------------------------------- ##
8345 _ASBOX
8346     ) |
8347       sed "s/^/$as_me: WARNING:     /" >&2
8348     ;;
8349 esac
8350 echo "$as_me:$LINENO: checking for $ac_header" >&5
8351 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8352 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8353   echo $ECHO_N "(cached) $ECHO_C" >&6
8354 else
8355   eval "$as_ac_Header=\$ac_header_preproc"
8356 fi
8357 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8358 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8359
8360 fi
8361 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8362   cat >>confdefs.h <<_ACEOF
8363 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8364 _ACEOF
8365
8366 else
8367
8368 for ac_header in history.h
8369 do
8370 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8371 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8372   echo "$as_me:$LINENO: checking for $ac_header" >&5
8373 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8374 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8375   echo $ECHO_N "(cached) $ECHO_C" >&6
8376 fi
8377 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8378 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8379 else
8380   # Is the header compilable?
8381 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8382 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8383 cat >conftest.$ac_ext <<_ACEOF
8384 /* confdefs.h.  */
8385 _ACEOF
8386 cat confdefs.h >>conftest.$ac_ext
8387 cat >>conftest.$ac_ext <<_ACEOF
8388 /* end confdefs.h.  */
8389 $ac_includes_default
8390 #include <$ac_header>
8391 _ACEOF
8392 rm -f conftest.$ac_objext
8393 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8394   (eval $ac_compile) 2>conftest.er1
8395   ac_status=$?
8396   grep -v '^ *+' conftest.er1 >conftest.err
8397   rm -f conftest.er1
8398   cat conftest.err >&5
8399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8400   (exit $ac_status); } &&
8401          { ac_try='test -z "$ac_c_werror_flag"
8402                          || test ! -s conftest.err'
8403   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8404   (eval $ac_try) 2>&5
8405   ac_status=$?
8406   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8407   (exit $ac_status); }; } &&
8408          { ac_try='test -s conftest.$ac_objext'
8409   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8410   (eval $ac_try) 2>&5
8411   ac_status=$?
8412   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8413   (exit $ac_status); }; }; then
8414   ac_header_compiler=yes
8415 else
8416   echo "$as_me: failed program was:" >&5
8417 sed 's/^/| /' conftest.$ac_ext >&5
8418
8419 ac_header_compiler=no
8420 fi
8421 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8422 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8423 echo "${ECHO_T}$ac_header_compiler" >&6
8424
8425 # Is the header present?
8426 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8427 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8428 cat >conftest.$ac_ext <<_ACEOF
8429 /* confdefs.h.  */
8430 _ACEOF
8431 cat confdefs.h >>conftest.$ac_ext
8432 cat >>conftest.$ac_ext <<_ACEOF
8433 /* end confdefs.h.  */
8434 #include <$ac_header>
8435 _ACEOF
8436 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8437   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8438   ac_status=$?
8439   grep -v '^ *+' conftest.er1 >conftest.err
8440   rm -f conftest.er1
8441   cat conftest.err >&5
8442   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8443   (exit $ac_status); } >/dev/null; then
8444   if test -s conftest.err; then
8445     ac_cpp_err=$ac_c_preproc_warn_flag
8446     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8447   else
8448     ac_cpp_err=
8449   fi
8450 else
8451   ac_cpp_err=yes
8452 fi
8453 if test -z "$ac_cpp_err"; then
8454   ac_header_preproc=yes
8455 else
8456   echo "$as_me: failed program was:" >&5
8457 sed 's/^/| /' conftest.$ac_ext >&5
8458
8459   ac_header_preproc=no
8460 fi
8461 rm -f conftest.err conftest.$ac_ext
8462 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8463 echo "${ECHO_T}$ac_header_preproc" >&6
8464
8465 # So?  What about this header?
8466 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8467   yes:no: )
8468     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8469 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8470     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8471 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8472     ac_header_preproc=yes
8473     ;;
8474   no:yes:* )
8475     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8476 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8477     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8478 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8479     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8480 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8481     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8482 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8483     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8484 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8485     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8486 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8487     (
8488       cat <<\_ASBOX
8489 ## ---------------------------------------- ##
8490 ## Report this to pgsql-bugs@postgresql.org ##
8491 ## ---------------------------------------- ##
8492 _ASBOX
8493     ) |
8494       sed "s/^/$as_me: WARNING:     /" >&2
8495     ;;
8496 esac
8497 echo "$as_me:$LINENO: checking for $ac_header" >&5
8498 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8499 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8500   echo $ECHO_N "(cached) $ECHO_C" >&6
8501 else
8502   eval "$as_ac_Header=\$ac_header_preproc"
8503 fi
8504 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8505 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8506
8507 fi
8508 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8509   cat >>confdefs.h <<_ACEOF
8510 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8511 _ACEOF
8512
8513 else
8514   { { echo "$as_me:$LINENO: error: history header not found
8515 If you have readline already installed, see config.log for details on the
8516 failure.  It is possible the compiler isn't looking in the proper directory.
8517 Use --without-readline to disable readline support." >&5
8518 echo "$as_me: error: history header not found
8519 If you have readline already installed, see config.log for details on the
8520 failure.  It is possible the compiler isn't looking in the proper directory.
8521 Use --without-readline to disable readline support." >&2;}
8522    { (exit 1); exit 1; }; }
8523 fi
8524
8525 done
8526
8527 fi
8528
8529 done
8530
8531 fi
8532
8533 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
8534 # Some installations of libedit usurp /usr/include/readline/, which seems
8535 # bad practice, since in combined installations readline will have its headers
8536 # there.  We might have to resort to AC_EGREP checks to make sure we found
8537 # the proper header...
8538
8539 for ac_header in editline/readline.h
8540 do
8541 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8542 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8543   echo "$as_me:$LINENO: checking for $ac_header" >&5
8544 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8545 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8546   echo $ECHO_N "(cached) $ECHO_C" >&6
8547 fi
8548 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8549 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8550 else
8551   # Is the header compilable?
8552 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8553 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8554 cat >conftest.$ac_ext <<_ACEOF
8555 /* confdefs.h.  */
8556 _ACEOF
8557 cat confdefs.h >>conftest.$ac_ext
8558 cat >>conftest.$ac_ext <<_ACEOF
8559 /* end confdefs.h.  */
8560 $ac_includes_default
8561 #include <$ac_header>
8562 _ACEOF
8563 rm -f conftest.$ac_objext
8564 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8565   (eval $ac_compile) 2>conftest.er1
8566   ac_status=$?
8567   grep -v '^ *+' conftest.er1 >conftest.err
8568   rm -f conftest.er1
8569   cat conftest.err >&5
8570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8571   (exit $ac_status); } &&
8572          { ac_try='test -z "$ac_c_werror_flag"
8573                          || test ! -s conftest.err'
8574   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8575   (eval $ac_try) 2>&5
8576   ac_status=$?
8577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8578   (exit $ac_status); }; } &&
8579          { ac_try='test -s conftest.$ac_objext'
8580   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8581   (eval $ac_try) 2>&5
8582   ac_status=$?
8583   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8584   (exit $ac_status); }; }; then
8585   ac_header_compiler=yes
8586 else
8587   echo "$as_me: failed program was:" >&5
8588 sed 's/^/| /' conftest.$ac_ext >&5
8589
8590 ac_header_compiler=no
8591 fi
8592 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8593 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8594 echo "${ECHO_T}$ac_header_compiler" >&6
8595
8596 # Is the header present?
8597 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8598 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8599 cat >conftest.$ac_ext <<_ACEOF
8600 /* confdefs.h.  */
8601 _ACEOF
8602 cat confdefs.h >>conftest.$ac_ext
8603 cat >>conftest.$ac_ext <<_ACEOF
8604 /* end confdefs.h.  */
8605 #include <$ac_header>
8606 _ACEOF
8607 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8608   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8609   ac_status=$?
8610   grep -v '^ *+' conftest.er1 >conftest.err
8611   rm -f conftest.er1
8612   cat conftest.err >&5
8613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8614   (exit $ac_status); } >/dev/null; then
8615   if test -s conftest.err; then
8616     ac_cpp_err=$ac_c_preproc_warn_flag
8617     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8618   else
8619     ac_cpp_err=
8620   fi
8621 else
8622   ac_cpp_err=yes
8623 fi
8624 if test -z "$ac_cpp_err"; then
8625   ac_header_preproc=yes
8626 else
8627   echo "$as_me: failed program was:" >&5
8628 sed 's/^/| /' conftest.$ac_ext >&5
8629
8630   ac_header_preproc=no
8631 fi
8632 rm -f conftest.err conftest.$ac_ext
8633 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8634 echo "${ECHO_T}$ac_header_preproc" >&6
8635
8636 # So?  What about this header?
8637 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8638   yes:no: )
8639     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8640 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8641     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8642 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8643     ac_header_preproc=yes
8644     ;;
8645   no:yes:* )
8646     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8647 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8648     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8649 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8650     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8651 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8652     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8653 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8654     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8655 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8656     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8657 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8658     (
8659       cat <<\_ASBOX
8660 ## ---------------------------------------- ##
8661 ## Report this to pgsql-bugs@postgresql.org ##
8662 ## ---------------------------------------- ##
8663 _ASBOX
8664     ) |
8665       sed "s/^/$as_me: WARNING:     /" >&2
8666     ;;
8667 esac
8668 echo "$as_me:$LINENO: checking for $ac_header" >&5
8669 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8670 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8671   echo $ECHO_N "(cached) $ECHO_C" >&6
8672 else
8673   eval "$as_ac_Header=\$ac_header_preproc"
8674 fi
8675 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8676 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8677
8678 fi
8679 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8680   cat >>confdefs.h <<_ACEOF
8681 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8682 _ACEOF
8683
8684 else
8685
8686 for ac_header in readline.h
8687 do
8688 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8689 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8690   echo "$as_me:$LINENO: checking for $ac_header" >&5
8691 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8692 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8693   echo $ECHO_N "(cached) $ECHO_C" >&6
8694 fi
8695 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8696 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8697 else
8698   # Is the header compilable?
8699 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8700 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8701 cat >conftest.$ac_ext <<_ACEOF
8702 /* confdefs.h.  */
8703 _ACEOF
8704 cat confdefs.h >>conftest.$ac_ext
8705 cat >>conftest.$ac_ext <<_ACEOF
8706 /* end confdefs.h.  */
8707 $ac_includes_default
8708 #include <$ac_header>
8709 _ACEOF
8710 rm -f conftest.$ac_objext
8711 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8712   (eval $ac_compile) 2>conftest.er1
8713   ac_status=$?
8714   grep -v '^ *+' conftest.er1 >conftest.err
8715   rm -f conftest.er1
8716   cat conftest.err >&5
8717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8718   (exit $ac_status); } &&
8719          { ac_try='test -z "$ac_c_werror_flag"
8720                          || test ! -s conftest.err'
8721   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8722   (eval $ac_try) 2>&5
8723   ac_status=$?
8724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8725   (exit $ac_status); }; } &&
8726          { ac_try='test -s conftest.$ac_objext'
8727   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8728   (eval $ac_try) 2>&5
8729   ac_status=$?
8730   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8731   (exit $ac_status); }; }; then
8732   ac_header_compiler=yes
8733 else
8734   echo "$as_me: failed program was:" >&5
8735 sed 's/^/| /' conftest.$ac_ext >&5
8736
8737 ac_header_compiler=no
8738 fi
8739 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8740 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8741 echo "${ECHO_T}$ac_header_compiler" >&6
8742
8743 # Is the header present?
8744 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8745 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8746 cat >conftest.$ac_ext <<_ACEOF
8747 /* confdefs.h.  */
8748 _ACEOF
8749 cat confdefs.h >>conftest.$ac_ext
8750 cat >>conftest.$ac_ext <<_ACEOF
8751 /* end confdefs.h.  */
8752 #include <$ac_header>
8753 _ACEOF
8754 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8755   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8756   ac_status=$?
8757   grep -v '^ *+' conftest.er1 >conftest.err
8758   rm -f conftest.er1
8759   cat conftest.err >&5
8760   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8761   (exit $ac_status); } >/dev/null; then
8762   if test -s conftest.err; then
8763     ac_cpp_err=$ac_c_preproc_warn_flag
8764     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8765   else
8766     ac_cpp_err=
8767   fi
8768 else
8769   ac_cpp_err=yes
8770 fi
8771 if test -z "$ac_cpp_err"; then
8772   ac_header_preproc=yes
8773 else
8774   echo "$as_me: failed program was:" >&5
8775 sed 's/^/| /' conftest.$ac_ext >&5
8776
8777   ac_header_preproc=no
8778 fi
8779 rm -f conftest.err conftest.$ac_ext
8780 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8781 echo "${ECHO_T}$ac_header_preproc" >&6
8782
8783 # So?  What about this header?
8784 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8785   yes:no: )
8786     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8787 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8788     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8789 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8790     ac_header_preproc=yes
8791     ;;
8792   no:yes:* )
8793     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8794 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8795     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8796 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8797     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8798 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8799     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8800 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8801     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8802 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8803     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8804 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8805     (
8806       cat <<\_ASBOX
8807 ## ---------------------------------------- ##
8808 ## Report this to pgsql-bugs@postgresql.org ##
8809 ## ---------------------------------------- ##
8810 _ASBOX
8811     ) |
8812       sed "s/^/$as_me: WARNING:     /" >&2
8813     ;;
8814 esac
8815 echo "$as_me:$LINENO: checking for $ac_header" >&5
8816 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8817 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8818   echo $ECHO_N "(cached) $ECHO_C" >&6
8819 else
8820   eval "$as_ac_Header=\$ac_header_preproc"
8821 fi
8822 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8823 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8824
8825 fi
8826 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8827   cat >>confdefs.h <<_ACEOF
8828 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8829 _ACEOF
8830
8831 else
8832
8833 for ac_header in readline/readline.h
8834 do
8835 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8836 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8837   echo "$as_me:$LINENO: checking for $ac_header" >&5
8838 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8839 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8840   echo $ECHO_N "(cached) $ECHO_C" >&6
8841 fi
8842 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8843 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8844 else
8845   # Is the header compilable?
8846 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8847 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8848 cat >conftest.$ac_ext <<_ACEOF
8849 /* confdefs.h.  */
8850 _ACEOF
8851 cat confdefs.h >>conftest.$ac_ext
8852 cat >>conftest.$ac_ext <<_ACEOF
8853 /* end confdefs.h.  */
8854 $ac_includes_default
8855 #include <$ac_header>
8856 _ACEOF
8857 rm -f conftest.$ac_objext
8858 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8859   (eval $ac_compile) 2>conftest.er1
8860   ac_status=$?
8861   grep -v '^ *+' conftest.er1 >conftest.err
8862   rm -f conftest.er1
8863   cat conftest.err >&5
8864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8865   (exit $ac_status); } &&
8866          { ac_try='test -z "$ac_c_werror_flag"
8867                          || test ! -s conftest.err'
8868   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8869   (eval $ac_try) 2>&5
8870   ac_status=$?
8871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8872   (exit $ac_status); }; } &&
8873          { ac_try='test -s conftest.$ac_objext'
8874   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8875   (eval $ac_try) 2>&5
8876   ac_status=$?
8877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8878   (exit $ac_status); }; }; then
8879   ac_header_compiler=yes
8880 else
8881   echo "$as_me: failed program was:" >&5
8882 sed 's/^/| /' conftest.$ac_ext >&5
8883
8884 ac_header_compiler=no
8885 fi
8886 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
8887 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8888 echo "${ECHO_T}$ac_header_compiler" >&6
8889
8890 # Is the header present?
8891 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8892 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8893 cat >conftest.$ac_ext <<_ACEOF
8894 /* confdefs.h.  */
8895 _ACEOF
8896 cat confdefs.h >>conftest.$ac_ext
8897 cat >>conftest.$ac_ext <<_ACEOF
8898 /* end confdefs.h.  */
8899 #include <$ac_header>
8900 _ACEOF
8901 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8902   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8903   ac_status=$?
8904   grep -v '^ *+' conftest.er1 >conftest.err
8905   rm -f conftest.er1
8906   cat conftest.err >&5
8907   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8908   (exit $ac_status); } >/dev/null; then
8909   if test -s conftest.err; then
8910     ac_cpp_err=$ac_c_preproc_warn_flag
8911     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
8912   else
8913     ac_cpp_err=
8914   fi
8915 else
8916   ac_cpp_err=yes
8917 fi
8918 if test -z "$ac_cpp_err"; then
8919   ac_header_preproc=yes
8920 else
8921   echo "$as_me: failed program was:" >&5
8922 sed 's/^/| /' conftest.$ac_ext >&5
8923
8924   ac_header_preproc=no
8925 fi
8926 rm -f conftest.err conftest.$ac_ext
8927 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8928 echo "${ECHO_T}$ac_header_preproc" >&6
8929
8930 # So?  What about this header?
8931 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
8932   yes:no: )
8933     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8934 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8935     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
8936 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
8937     ac_header_preproc=yes
8938     ;;
8939   no:yes:* )
8940     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8941 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8942     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
8943 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
8944     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
8945 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
8946     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
8947 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
8948     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8949 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
8950     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
8951 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
8952     (
8953       cat <<\_ASBOX
8954 ## ---------------------------------------- ##
8955 ## Report this to pgsql-bugs@postgresql.org ##
8956 ## ---------------------------------------- ##
8957 _ASBOX
8958     ) |
8959       sed "s/^/$as_me: WARNING:     /" >&2
8960     ;;
8961 esac
8962 echo "$as_me:$LINENO: checking for $ac_header" >&5
8963 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8964 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8965   echo $ECHO_N "(cached) $ECHO_C" >&6
8966 else
8967   eval "$as_ac_Header=\$ac_header_preproc"
8968 fi
8969 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8970 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8971
8972 fi
8973 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8974   cat >>confdefs.h <<_ACEOF
8975 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8976 _ACEOF
8977
8978 else
8979   { { echo "$as_me:$LINENO: error: readline header not found
8980 If you have libedit already installed, see config.log for details on the
8981 failure.  It is possible the compiler isn't looking in the proper directory.
8982 Use --without-readline to disable libedit support." >&5
8983 echo "$as_me: error: readline header not found
8984 If you have libedit already installed, see config.log for details on the
8985 failure.  It is possible the compiler isn't looking in the proper directory.
8986 Use --without-readline to disable libedit support." >&2;}
8987    { (exit 1); exit 1; }; }
8988 fi
8989
8990 done
8991
8992 fi
8993
8994 done
8995
8996 fi
8997
8998 done
8999
9000 # Note: in a libedit installation, history.h is sometimes a dummy, and may
9001 # not be there at all.  Hence, don't complain if not found.  We must check
9002 # though, since in yet other versions it is an independent header.
9003
9004 for ac_header in editline/history.h
9005 do
9006 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9007 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9008   echo "$as_me:$LINENO: checking for $ac_header" >&5
9009 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9010 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9011   echo $ECHO_N "(cached) $ECHO_C" >&6
9012 fi
9013 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9014 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9015 else
9016   # Is the header compilable?
9017 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9018 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9019 cat >conftest.$ac_ext <<_ACEOF
9020 /* confdefs.h.  */
9021 _ACEOF
9022 cat confdefs.h >>conftest.$ac_ext
9023 cat >>conftest.$ac_ext <<_ACEOF
9024 /* end confdefs.h.  */
9025 $ac_includes_default
9026 #include <$ac_header>
9027 _ACEOF
9028 rm -f conftest.$ac_objext
9029 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9030   (eval $ac_compile) 2>conftest.er1
9031   ac_status=$?
9032   grep -v '^ *+' conftest.er1 >conftest.err
9033   rm -f conftest.er1
9034   cat conftest.err >&5
9035   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9036   (exit $ac_status); } &&
9037          { ac_try='test -z "$ac_c_werror_flag"
9038                          || test ! -s conftest.err'
9039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9040   (eval $ac_try) 2>&5
9041   ac_status=$?
9042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9043   (exit $ac_status); }; } &&
9044          { ac_try='test -s conftest.$ac_objext'
9045   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9046   (eval $ac_try) 2>&5
9047   ac_status=$?
9048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9049   (exit $ac_status); }; }; then
9050   ac_header_compiler=yes
9051 else
9052   echo "$as_me: failed program was:" >&5
9053 sed 's/^/| /' conftest.$ac_ext >&5
9054
9055 ac_header_compiler=no
9056 fi
9057 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9058 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9059 echo "${ECHO_T}$ac_header_compiler" >&6
9060
9061 # Is the header present?
9062 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9063 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9064 cat >conftest.$ac_ext <<_ACEOF
9065 /* confdefs.h.  */
9066 _ACEOF
9067 cat confdefs.h >>conftest.$ac_ext
9068 cat >>conftest.$ac_ext <<_ACEOF
9069 /* end confdefs.h.  */
9070 #include <$ac_header>
9071 _ACEOF
9072 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9073   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9074   ac_status=$?
9075   grep -v '^ *+' conftest.er1 >conftest.err
9076   rm -f conftest.er1
9077   cat conftest.err >&5
9078   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9079   (exit $ac_status); } >/dev/null; then
9080   if test -s conftest.err; then
9081     ac_cpp_err=$ac_c_preproc_warn_flag
9082     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9083   else
9084     ac_cpp_err=
9085   fi
9086 else
9087   ac_cpp_err=yes
9088 fi
9089 if test -z "$ac_cpp_err"; then
9090   ac_header_preproc=yes
9091 else
9092   echo "$as_me: failed program was:" >&5
9093 sed 's/^/| /' conftest.$ac_ext >&5
9094
9095   ac_header_preproc=no
9096 fi
9097 rm -f conftest.err conftest.$ac_ext
9098 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9099 echo "${ECHO_T}$ac_header_preproc" >&6
9100
9101 # So?  What about this header?
9102 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9103   yes:no: )
9104     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9105 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9106     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9107 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9108     ac_header_preproc=yes
9109     ;;
9110   no:yes:* )
9111     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9112 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9113     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9114 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9115     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9116 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9117     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9118 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9119     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9120 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9121     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9122 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9123     (
9124       cat <<\_ASBOX
9125 ## ---------------------------------------- ##
9126 ## Report this to pgsql-bugs@postgresql.org ##
9127 ## ---------------------------------------- ##
9128 _ASBOX
9129     ) |
9130       sed "s/^/$as_me: WARNING:     /" >&2
9131     ;;
9132 esac
9133 echo "$as_me:$LINENO: checking for $ac_header" >&5
9134 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9135 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9136   echo $ECHO_N "(cached) $ECHO_C" >&6
9137 else
9138   eval "$as_ac_Header=\$ac_header_preproc"
9139 fi
9140 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9141 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9142
9143 fi
9144 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9145   cat >>confdefs.h <<_ACEOF
9146 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9147 _ACEOF
9148
9149 else
9150
9151 for ac_header in history.h
9152 do
9153 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9154 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9155   echo "$as_me:$LINENO: checking for $ac_header" >&5
9156 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9157 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9158   echo $ECHO_N "(cached) $ECHO_C" >&6
9159 fi
9160 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9161 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9162 else
9163   # Is the header compilable?
9164 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9165 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9166 cat >conftest.$ac_ext <<_ACEOF
9167 /* confdefs.h.  */
9168 _ACEOF
9169 cat confdefs.h >>conftest.$ac_ext
9170 cat >>conftest.$ac_ext <<_ACEOF
9171 /* end confdefs.h.  */
9172 $ac_includes_default
9173 #include <$ac_header>
9174 _ACEOF
9175 rm -f conftest.$ac_objext
9176 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9177   (eval $ac_compile) 2>conftest.er1
9178   ac_status=$?
9179   grep -v '^ *+' conftest.er1 >conftest.err
9180   rm -f conftest.er1
9181   cat conftest.err >&5
9182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9183   (exit $ac_status); } &&
9184          { ac_try='test -z "$ac_c_werror_flag"
9185                          || test ! -s conftest.err'
9186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9187   (eval $ac_try) 2>&5
9188   ac_status=$?
9189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9190   (exit $ac_status); }; } &&
9191          { ac_try='test -s conftest.$ac_objext'
9192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9193   (eval $ac_try) 2>&5
9194   ac_status=$?
9195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9196   (exit $ac_status); }; }; then
9197   ac_header_compiler=yes
9198 else
9199   echo "$as_me: failed program was:" >&5
9200 sed 's/^/| /' conftest.$ac_ext >&5
9201
9202 ac_header_compiler=no
9203 fi
9204 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9205 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9206 echo "${ECHO_T}$ac_header_compiler" >&6
9207
9208 # Is the header present?
9209 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9210 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9211 cat >conftest.$ac_ext <<_ACEOF
9212 /* confdefs.h.  */
9213 _ACEOF
9214 cat confdefs.h >>conftest.$ac_ext
9215 cat >>conftest.$ac_ext <<_ACEOF
9216 /* end confdefs.h.  */
9217 #include <$ac_header>
9218 _ACEOF
9219 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9220   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9221   ac_status=$?
9222   grep -v '^ *+' conftest.er1 >conftest.err
9223   rm -f conftest.er1
9224   cat conftest.err >&5
9225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9226   (exit $ac_status); } >/dev/null; then
9227   if test -s conftest.err; then
9228     ac_cpp_err=$ac_c_preproc_warn_flag
9229     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9230   else
9231     ac_cpp_err=
9232   fi
9233 else
9234   ac_cpp_err=yes
9235 fi
9236 if test -z "$ac_cpp_err"; then
9237   ac_header_preproc=yes
9238 else
9239   echo "$as_me: failed program was:" >&5
9240 sed 's/^/| /' conftest.$ac_ext >&5
9241
9242   ac_header_preproc=no
9243 fi
9244 rm -f conftest.err conftest.$ac_ext
9245 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9246 echo "${ECHO_T}$ac_header_preproc" >&6
9247
9248 # So?  What about this header?
9249 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9250   yes:no: )
9251     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9252 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9253     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9254 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9255     ac_header_preproc=yes
9256     ;;
9257   no:yes:* )
9258     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9259 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9260     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9261 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9262     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9263 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9264     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9265 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9266     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9267 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9268     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9269 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9270     (
9271       cat <<\_ASBOX
9272 ## ---------------------------------------- ##
9273 ## Report this to pgsql-bugs@postgresql.org ##
9274 ## ---------------------------------------- ##
9275 _ASBOX
9276     ) |
9277       sed "s/^/$as_me: WARNING:     /" >&2
9278     ;;
9279 esac
9280 echo "$as_me:$LINENO: checking for $ac_header" >&5
9281 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9282 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9283   echo $ECHO_N "(cached) $ECHO_C" >&6
9284 else
9285   eval "$as_ac_Header=\$ac_header_preproc"
9286 fi
9287 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9288 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9289
9290 fi
9291 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9292   cat >>confdefs.h <<_ACEOF
9293 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9294 _ACEOF
9295
9296 else
9297
9298 for ac_header in readline/history.h
9299 do
9300 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9301 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9302   echo "$as_me:$LINENO: checking for $ac_header" >&5
9303 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9304 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9305   echo $ECHO_N "(cached) $ECHO_C" >&6
9306 fi
9307 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9308 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9309 else
9310   # Is the header compilable?
9311 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9312 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9313 cat >conftest.$ac_ext <<_ACEOF
9314 /* confdefs.h.  */
9315 _ACEOF
9316 cat confdefs.h >>conftest.$ac_ext
9317 cat >>conftest.$ac_ext <<_ACEOF
9318 /* end confdefs.h.  */
9319 $ac_includes_default
9320 #include <$ac_header>
9321 _ACEOF
9322 rm -f conftest.$ac_objext
9323 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9324   (eval $ac_compile) 2>conftest.er1
9325   ac_status=$?
9326   grep -v '^ *+' conftest.er1 >conftest.err
9327   rm -f conftest.er1
9328   cat conftest.err >&5
9329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9330   (exit $ac_status); } &&
9331          { ac_try='test -z "$ac_c_werror_flag"
9332                          || test ! -s conftest.err'
9333   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9334   (eval $ac_try) 2>&5
9335   ac_status=$?
9336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9337   (exit $ac_status); }; } &&
9338          { ac_try='test -s conftest.$ac_objext'
9339   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9340   (eval $ac_try) 2>&5
9341   ac_status=$?
9342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9343   (exit $ac_status); }; }; then
9344   ac_header_compiler=yes
9345 else
9346   echo "$as_me: failed program was:" >&5
9347 sed 's/^/| /' conftest.$ac_ext >&5
9348
9349 ac_header_compiler=no
9350 fi
9351 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9352 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9353 echo "${ECHO_T}$ac_header_compiler" >&6
9354
9355 # Is the header present?
9356 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9357 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9358 cat >conftest.$ac_ext <<_ACEOF
9359 /* confdefs.h.  */
9360 _ACEOF
9361 cat confdefs.h >>conftest.$ac_ext
9362 cat >>conftest.$ac_ext <<_ACEOF
9363 /* end confdefs.h.  */
9364 #include <$ac_header>
9365 _ACEOF
9366 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9367   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9368   ac_status=$?
9369   grep -v '^ *+' conftest.er1 >conftest.err
9370   rm -f conftest.er1
9371   cat conftest.err >&5
9372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9373   (exit $ac_status); } >/dev/null; then
9374   if test -s conftest.err; then
9375     ac_cpp_err=$ac_c_preproc_warn_flag
9376     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9377   else
9378     ac_cpp_err=
9379   fi
9380 else
9381   ac_cpp_err=yes
9382 fi
9383 if test -z "$ac_cpp_err"; then
9384   ac_header_preproc=yes
9385 else
9386   echo "$as_me: failed program was:" >&5
9387 sed 's/^/| /' conftest.$ac_ext >&5
9388
9389   ac_header_preproc=no
9390 fi
9391 rm -f conftest.err conftest.$ac_ext
9392 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9393 echo "${ECHO_T}$ac_header_preproc" >&6
9394
9395 # So?  What about this header?
9396 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9397   yes:no: )
9398     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9399 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9400     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9401 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9402     ac_header_preproc=yes
9403     ;;
9404   no:yes:* )
9405     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9406 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9407     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9408 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9409     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9410 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9411     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9412 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9413     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9414 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9415     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9416 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9417     (
9418       cat <<\_ASBOX
9419 ## ---------------------------------------- ##
9420 ## Report this to pgsql-bugs@postgresql.org ##
9421 ## ---------------------------------------- ##
9422 _ASBOX
9423     ) |
9424       sed "s/^/$as_me: WARNING:     /" >&2
9425     ;;
9426 esac
9427 echo "$as_me:$LINENO: checking for $ac_header" >&5
9428 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9429 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9430   echo $ECHO_N "(cached) $ECHO_C" >&6
9431 else
9432   eval "$as_ac_Header=\$ac_header_preproc"
9433 fi
9434 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9435 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9436
9437 fi
9438 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9439   cat >>confdefs.h <<_ACEOF
9440 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9441 _ACEOF
9442
9443 fi
9444
9445 done
9446
9447 fi
9448
9449 done
9450
9451 fi
9452
9453 done
9454
9455 fi
9456
9457 if test "$with_zlib" = yes; then
9458   if test "${ac_cv_header_zlib_h+set}" = set; then
9459   echo "$as_me:$LINENO: checking for zlib.h" >&5
9460 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
9461 if test "${ac_cv_header_zlib_h+set}" = set; then
9462   echo $ECHO_N "(cached) $ECHO_C" >&6
9463 fi
9464 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
9465 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
9466 else
9467   # Is the header compilable?
9468 echo "$as_me:$LINENO: checking zlib.h usability" >&5
9469 echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6
9470 cat >conftest.$ac_ext <<_ACEOF
9471 /* confdefs.h.  */
9472 _ACEOF
9473 cat confdefs.h >>conftest.$ac_ext
9474 cat >>conftest.$ac_ext <<_ACEOF
9475 /* end confdefs.h.  */
9476 $ac_includes_default
9477 #include <zlib.h>
9478 _ACEOF
9479 rm -f conftest.$ac_objext
9480 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9481   (eval $ac_compile) 2>conftest.er1
9482   ac_status=$?
9483   grep -v '^ *+' conftest.er1 >conftest.err
9484   rm -f conftest.er1
9485   cat conftest.err >&5
9486   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9487   (exit $ac_status); } &&
9488          { ac_try='test -z "$ac_c_werror_flag"
9489                          || test ! -s conftest.err'
9490   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9491   (eval $ac_try) 2>&5
9492   ac_status=$?
9493   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9494   (exit $ac_status); }; } &&
9495          { ac_try='test -s conftest.$ac_objext'
9496   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9497   (eval $ac_try) 2>&5
9498   ac_status=$?
9499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9500   (exit $ac_status); }; }; then
9501   ac_header_compiler=yes
9502 else
9503   echo "$as_me: failed program was:" >&5
9504 sed 's/^/| /' conftest.$ac_ext >&5
9505
9506 ac_header_compiler=no
9507 fi
9508 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9509 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9510 echo "${ECHO_T}$ac_header_compiler" >&6
9511
9512 # Is the header present?
9513 echo "$as_me:$LINENO: checking zlib.h presence" >&5
9514 echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6
9515 cat >conftest.$ac_ext <<_ACEOF
9516 /* confdefs.h.  */
9517 _ACEOF
9518 cat confdefs.h >>conftest.$ac_ext
9519 cat >>conftest.$ac_ext <<_ACEOF
9520 /* end confdefs.h.  */
9521 #include <zlib.h>
9522 _ACEOF
9523 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9524   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9525   ac_status=$?
9526   grep -v '^ *+' conftest.er1 >conftest.err
9527   rm -f conftest.er1
9528   cat conftest.err >&5
9529   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9530   (exit $ac_status); } >/dev/null; then
9531   if test -s conftest.err; then
9532     ac_cpp_err=$ac_c_preproc_warn_flag
9533     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9534   else
9535     ac_cpp_err=
9536   fi
9537 else
9538   ac_cpp_err=yes
9539 fi
9540 if test -z "$ac_cpp_err"; then
9541   ac_header_preproc=yes
9542 else
9543   echo "$as_me: failed program was:" >&5
9544 sed 's/^/| /' conftest.$ac_ext >&5
9545
9546   ac_header_preproc=no
9547 fi
9548 rm -f conftest.err conftest.$ac_ext
9549 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9550 echo "${ECHO_T}$ac_header_preproc" >&6
9551
9552 # So?  What about this header?
9553 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9554   yes:no: )
9555     { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
9556 echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9557     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
9558 echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
9559     ac_header_preproc=yes
9560     ;;
9561   no:yes:* )
9562     { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
9563 echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
9564     { echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
9565 echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
9566     { echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
9567 echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
9568     { echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
9569 echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9570     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
9571 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
9572     { echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
9573 echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
9574     (
9575       cat <<\_ASBOX
9576 ## ---------------------------------------- ##
9577 ## Report this to pgsql-bugs@postgresql.org ##
9578 ## ---------------------------------------- ##
9579 _ASBOX
9580     ) |
9581       sed "s/^/$as_me: WARNING:     /" >&2
9582     ;;
9583 esac
9584 echo "$as_me:$LINENO: checking for zlib.h" >&5
9585 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
9586 if test "${ac_cv_header_zlib_h+set}" = set; then
9587   echo $ECHO_N "(cached) $ECHO_C" >&6
9588 else
9589   ac_cv_header_zlib_h=$ac_header_preproc
9590 fi
9591 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
9592 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
9593
9594 fi
9595 if test $ac_cv_header_zlib_h = yes; then
9596   :
9597 else
9598   { { echo "$as_me:$LINENO: error: zlib header not found
9599 If you have zlib already installed, see config.log for details on the
9600 failure.  It is possible the compiler isn't looking in the proper directory.
9601 Use --without-zlib to disable zlib support." >&5
9602 echo "$as_me: error: zlib header not found
9603 If you have zlib already installed, see config.log for details on the
9604 failure.  It is possible the compiler isn't looking in the proper directory.
9605 Use --without-zlib to disable zlib support." >&2;}
9606    { (exit 1); exit 1; }; }
9607 fi
9608
9609
9610 fi
9611
9612 if test "$with_krb5" = yes ; then
9613   if test "${ac_cv_header_krb5_h+set}" = set; then
9614   echo "$as_me:$LINENO: checking for krb5.h" >&5
9615 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9616 if test "${ac_cv_header_krb5_h+set}" = set; then
9617   echo $ECHO_N "(cached) $ECHO_C" >&6
9618 fi
9619 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9620 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9621 else
9622   # Is the header compilable?
9623 echo "$as_me:$LINENO: checking krb5.h usability" >&5
9624 echo $ECHO_N "checking krb5.h usability... $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 $ac_includes_default
9632 #include <krb5.h>
9633 _ACEOF
9634 rm -f conftest.$ac_objext
9635 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9636   (eval $ac_compile) 2>conftest.er1
9637   ac_status=$?
9638   grep -v '^ *+' conftest.er1 >conftest.err
9639   rm -f conftest.er1
9640   cat conftest.err >&5
9641   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9642   (exit $ac_status); } &&
9643          { ac_try='test -z "$ac_c_werror_flag"
9644                          || test ! -s conftest.err'
9645   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9646   (eval $ac_try) 2>&5
9647   ac_status=$?
9648   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9649   (exit $ac_status); }; } &&
9650          { ac_try='test -s conftest.$ac_objext'
9651   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9652   (eval $ac_try) 2>&5
9653   ac_status=$?
9654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9655   (exit $ac_status); }; }; then
9656   ac_header_compiler=yes
9657 else
9658   echo "$as_me: failed program was:" >&5
9659 sed 's/^/| /' conftest.$ac_ext >&5
9660
9661 ac_header_compiler=no
9662 fi
9663 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9664 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9665 echo "${ECHO_T}$ac_header_compiler" >&6
9666
9667 # Is the header present?
9668 echo "$as_me:$LINENO: checking krb5.h presence" >&5
9669 echo $ECHO_N "checking krb5.h presence... $ECHO_C" >&6
9670 cat >conftest.$ac_ext <<_ACEOF
9671 /* confdefs.h.  */
9672 _ACEOF
9673 cat confdefs.h >>conftest.$ac_ext
9674 cat >>conftest.$ac_ext <<_ACEOF
9675 /* end confdefs.h.  */
9676 #include <krb5.h>
9677 _ACEOF
9678 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9679   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9680   ac_status=$?
9681   grep -v '^ *+' conftest.er1 >conftest.err
9682   rm -f conftest.er1
9683   cat conftest.err >&5
9684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9685   (exit $ac_status); } >/dev/null; then
9686   if test -s conftest.err; then
9687     ac_cpp_err=$ac_c_preproc_warn_flag
9688     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9689   else
9690     ac_cpp_err=
9691   fi
9692 else
9693   ac_cpp_err=yes
9694 fi
9695 if test -z "$ac_cpp_err"; then
9696   ac_header_preproc=yes
9697 else
9698   echo "$as_me: failed program was:" >&5
9699 sed 's/^/| /' conftest.$ac_ext >&5
9700
9701   ac_header_preproc=no
9702 fi
9703 rm -f conftest.err conftest.$ac_ext
9704 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9705 echo "${ECHO_T}$ac_header_preproc" >&6
9706
9707 # So?  What about this header?
9708 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9709   yes:no: )
9710     { echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
9711 echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9712     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
9713 echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
9714     ac_header_preproc=yes
9715     ;;
9716   no:yes:* )
9717     { echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
9718 echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
9719     { echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
9720 echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
9721     { echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
9722 echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
9723     { echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
9724 echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9725     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
9726 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
9727     { echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
9728 echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
9729     (
9730       cat <<\_ASBOX
9731 ## ---------------------------------------- ##
9732 ## Report this to pgsql-bugs@postgresql.org ##
9733 ## ---------------------------------------- ##
9734 _ASBOX
9735     ) |
9736       sed "s/^/$as_me: WARNING:     /" >&2
9737     ;;
9738 esac
9739 echo "$as_me:$LINENO: checking for krb5.h" >&5
9740 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9741 if test "${ac_cv_header_krb5_h+set}" = set; then
9742   echo $ECHO_N "(cached) $ECHO_C" >&6
9743 else
9744   ac_cv_header_krb5_h=$ac_header_preproc
9745 fi
9746 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9747 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9748
9749 fi
9750 if test $ac_cv_header_krb5_h = yes; then
9751   :
9752 else
9753   { { echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
9754 echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
9755    { (exit 1); exit 1; }; }
9756 fi
9757
9758
9759 fi
9760
9761 if test "$with_openssl" = yes ; then
9762   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9763   echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9764 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9765 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9766   echo $ECHO_N "(cached) $ECHO_C" >&6
9767 fi
9768 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9769 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9770 else
9771   # Is the header compilable?
9772 echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
9773 echo $ECHO_N "checking openssl/ssl.h usability... $ECHO_C" >&6
9774 cat >conftest.$ac_ext <<_ACEOF
9775 /* confdefs.h.  */
9776 _ACEOF
9777 cat confdefs.h >>conftest.$ac_ext
9778 cat >>conftest.$ac_ext <<_ACEOF
9779 /* end confdefs.h.  */
9780 $ac_includes_default
9781 #include <openssl/ssl.h>
9782 _ACEOF
9783 rm -f conftest.$ac_objext
9784 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9785   (eval $ac_compile) 2>conftest.er1
9786   ac_status=$?
9787   grep -v '^ *+' conftest.er1 >conftest.err
9788   rm -f conftest.er1
9789   cat conftest.err >&5
9790   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9791   (exit $ac_status); } &&
9792          { ac_try='test -z "$ac_c_werror_flag"
9793                          || test ! -s conftest.err'
9794   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9795   (eval $ac_try) 2>&5
9796   ac_status=$?
9797   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9798   (exit $ac_status); }; } &&
9799          { ac_try='test -s conftest.$ac_objext'
9800   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9801   (eval $ac_try) 2>&5
9802   ac_status=$?
9803   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9804   (exit $ac_status); }; }; then
9805   ac_header_compiler=yes
9806 else
9807   echo "$as_me: failed program was:" >&5
9808 sed 's/^/| /' conftest.$ac_ext >&5
9809
9810 ac_header_compiler=no
9811 fi
9812 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9813 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9814 echo "${ECHO_T}$ac_header_compiler" >&6
9815
9816 # Is the header present?
9817 echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
9818 echo $ECHO_N "checking openssl/ssl.h presence... $ECHO_C" >&6
9819 cat >conftest.$ac_ext <<_ACEOF
9820 /* confdefs.h.  */
9821 _ACEOF
9822 cat confdefs.h >>conftest.$ac_ext
9823 cat >>conftest.$ac_ext <<_ACEOF
9824 /* end confdefs.h.  */
9825 #include <openssl/ssl.h>
9826 _ACEOF
9827 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9828   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9829   ac_status=$?
9830   grep -v '^ *+' conftest.er1 >conftest.err
9831   rm -f conftest.er1
9832   cat conftest.err >&5
9833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9834   (exit $ac_status); } >/dev/null; then
9835   if test -s conftest.err; then
9836     ac_cpp_err=$ac_c_preproc_warn_flag
9837     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9838   else
9839     ac_cpp_err=
9840   fi
9841 else
9842   ac_cpp_err=yes
9843 fi
9844 if test -z "$ac_cpp_err"; then
9845   ac_header_preproc=yes
9846 else
9847   echo "$as_me: failed program was:" >&5
9848 sed 's/^/| /' conftest.$ac_ext >&5
9849
9850   ac_header_preproc=no
9851 fi
9852 rm -f conftest.err conftest.$ac_ext
9853 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9854 echo "${ECHO_T}$ac_header_preproc" >&6
9855
9856 # So?  What about this header?
9857 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9858   yes:no: )
9859     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
9860 echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9861     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
9862 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
9863     ac_header_preproc=yes
9864     ;;
9865   no:yes:* )
9866     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
9867 echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
9868     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
9869 echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
9870     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
9871 echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
9872     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
9873 echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
9874     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
9875 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
9876     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
9877 echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
9878     (
9879       cat <<\_ASBOX
9880 ## ---------------------------------------- ##
9881 ## Report this to pgsql-bugs@postgresql.org ##
9882 ## ---------------------------------------- ##
9883 _ASBOX
9884     ) |
9885       sed "s/^/$as_me: WARNING:     /" >&2
9886     ;;
9887 esac
9888 echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9889 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9890 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9891   echo $ECHO_N "(cached) $ECHO_C" >&6
9892 else
9893   ac_cv_header_openssl_ssl_h=$ac_header_preproc
9894 fi
9895 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9896 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9897
9898 fi
9899 if test $ac_cv_header_openssl_ssl_h = yes; then
9900   :
9901 else
9902   { { echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
9903 echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
9904    { (exit 1); exit 1; }; }
9905 fi
9906
9907
9908   if test "${ac_cv_header_openssl_err_h+set}" = set; then
9909   echo "$as_me:$LINENO: checking for openssl/err.h" >&5
9910 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
9911 if test "${ac_cv_header_openssl_err_h+set}" = set; then
9912   echo $ECHO_N "(cached) $ECHO_C" >&6
9913 fi
9914 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
9915 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
9916 else
9917   # Is the header compilable?
9918 echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
9919 echo $ECHO_N "checking openssl/err.h usability... $ECHO_C" >&6
9920 cat >conftest.$ac_ext <<_ACEOF
9921 /* confdefs.h.  */
9922 _ACEOF
9923 cat confdefs.h >>conftest.$ac_ext
9924 cat >>conftest.$ac_ext <<_ACEOF
9925 /* end confdefs.h.  */
9926 $ac_includes_default
9927 #include <openssl/err.h>
9928 _ACEOF
9929 rm -f conftest.$ac_objext
9930 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9931   (eval $ac_compile) 2>conftest.er1
9932   ac_status=$?
9933   grep -v '^ *+' conftest.er1 >conftest.err
9934   rm -f conftest.er1
9935   cat conftest.err >&5
9936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9937   (exit $ac_status); } &&
9938          { ac_try='test -z "$ac_c_werror_flag"
9939                          || test ! -s conftest.err'
9940   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9941   (eval $ac_try) 2>&5
9942   ac_status=$?
9943   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9944   (exit $ac_status); }; } &&
9945          { ac_try='test -s conftest.$ac_objext'
9946   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9947   (eval $ac_try) 2>&5
9948   ac_status=$?
9949   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9950   (exit $ac_status); }; }; then
9951   ac_header_compiler=yes
9952 else
9953   echo "$as_me: failed program was:" >&5
9954 sed 's/^/| /' conftest.$ac_ext >&5
9955
9956 ac_header_compiler=no
9957 fi
9958 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
9959 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9960 echo "${ECHO_T}$ac_header_compiler" >&6
9961
9962 # Is the header present?
9963 echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
9964 echo $ECHO_N "checking openssl/err.h presence... $ECHO_C" >&6
9965 cat >conftest.$ac_ext <<_ACEOF
9966 /* confdefs.h.  */
9967 _ACEOF
9968 cat confdefs.h >>conftest.$ac_ext
9969 cat >>conftest.$ac_ext <<_ACEOF
9970 /* end confdefs.h.  */
9971 #include <openssl/err.h>
9972 _ACEOF
9973 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9974   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9975   ac_status=$?
9976   grep -v '^ *+' conftest.er1 >conftest.err
9977   rm -f conftest.er1
9978   cat conftest.err >&5
9979   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9980   (exit $ac_status); } >/dev/null; then
9981   if test -s conftest.err; then
9982     ac_cpp_err=$ac_c_preproc_warn_flag
9983     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
9984   else
9985     ac_cpp_err=
9986   fi
9987 else
9988   ac_cpp_err=yes
9989 fi
9990 if test -z "$ac_cpp_err"; then
9991   ac_header_preproc=yes
9992 else
9993   echo "$as_me: failed program was:" >&5
9994 sed 's/^/| /' conftest.$ac_ext >&5
9995
9996   ac_header_preproc=no
9997 fi
9998 rm -f conftest.err conftest.$ac_ext
9999 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10000 echo "${ECHO_T}$ac_header_preproc" >&6
10001
10002 # So?  What about this header?
10003 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10004   yes:no: )
10005     { echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
10006 echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10007     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
10008 echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
10009     ac_header_preproc=yes
10010     ;;
10011   no:yes:* )
10012     { echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
10013 echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
10014     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
10015 echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
10016     { echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
10017 echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
10018     { echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
10019 echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10020     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
10021 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
10022     { echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
10023 echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
10024     (
10025       cat <<\_ASBOX
10026 ## ---------------------------------------- ##
10027 ## Report this to pgsql-bugs@postgresql.org ##
10028 ## ---------------------------------------- ##
10029 _ASBOX
10030     ) |
10031       sed "s/^/$as_me: WARNING:     /" >&2
10032     ;;
10033 esac
10034 echo "$as_me:$LINENO: checking for openssl/err.h" >&5
10035 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
10036 if test "${ac_cv_header_openssl_err_h+set}" = set; then
10037   echo $ECHO_N "(cached) $ECHO_C" >&6
10038 else
10039   ac_cv_header_openssl_err_h=$ac_header_preproc
10040 fi
10041 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
10042 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
10043
10044 fi
10045 if test $ac_cv_header_openssl_err_h = yes; then
10046   :
10047 else
10048   { { echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
10049 echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
10050    { (exit 1); exit 1; }; }
10051 fi
10052
10053
10054 fi
10055
10056 if test "$with_pam" = yes ; then
10057
10058 for ac_header in security/pam_appl.h
10059 do
10060 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10061 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10062   echo "$as_me:$LINENO: checking for $ac_header" >&5
10063 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10064 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10065   echo $ECHO_N "(cached) $ECHO_C" >&6
10066 fi
10067 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10068 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10069 else
10070   # Is the header compilable?
10071 echo "$as_me:$LINENO: checking $ac_header usability" >&5
10072 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10073 cat >conftest.$ac_ext <<_ACEOF
10074 /* confdefs.h.  */
10075 _ACEOF
10076 cat confdefs.h >>conftest.$ac_ext
10077 cat >>conftest.$ac_ext <<_ACEOF
10078 /* end confdefs.h.  */
10079 $ac_includes_default
10080 #include <$ac_header>
10081 _ACEOF
10082 rm -f conftest.$ac_objext
10083 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10084   (eval $ac_compile) 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); } &&
10091          { ac_try='test -z "$ac_c_werror_flag"
10092                          || test ! -s conftest.err'
10093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10094   (eval $ac_try) 2>&5
10095   ac_status=$?
10096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10097   (exit $ac_status); }; } &&
10098          { ac_try='test -s conftest.$ac_objext'
10099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10100   (eval $ac_try) 2>&5
10101   ac_status=$?
10102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10103   (exit $ac_status); }; }; then
10104   ac_header_compiler=yes
10105 else
10106   echo "$as_me: failed program was:" >&5
10107 sed 's/^/| /' conftest.$ac_ext >&5
10108
10109 ac_header_compiler=no
10110 fi
10111 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10112 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10113 echo "${ECHO_T}$ac_header_compiler" >&6
10114
10115 # Is the header present?
10116 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10117 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10118 cat >conftest.$ac_ext <<_ACEOF
10119 /* confdefs.h.  */
10120 _ACEOF
10121 cat confdefs.h >>conftest.$ac_ext
10122 cat >>conftest.$ac_ext <<_ACEOF
10123 /* end confdefs.h.  */
10124 #include <$ac_header>
10125 _ACEOF
10126 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10127   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10128   ac_status=$?
10129   grep -v '^ *+' conftest.er1 >conftest.err
10130   rm -f conftest.er1
10131   cat conftest.err >&5
10132   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10133   (exit $ac_status); } >/dev/null; then
10134   if test -s conftest.err; then
10135     ac_cpp_err=$ac_c_preproc_warn_flag
10136     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10137   else
10138     ac_cpp_err=
10139   fi
10140 else
10141   ac_cpp_err=yes
10142 fi
10143 if test -z "$ac_cpp_err"; then
10144   ac_header_preproc=yes
10145 else
10146   echo "$as_me: failed program was:" >&5
10147 sed 's/^/| /' conftest.$ac_ext >&5
10148
10149   ac_header_preproc=no
10150 fi
10151 rm -f conftest.err conftest.$ac_ext
10152 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10153 echo "${ECHO_T}$ac_header_preproc" >&6
10154
10155 # So?  What about this header?
10156 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10157   yes:no: )
10158     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10159 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10160     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10161 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10162     ac_header_preproc=yes
10163     ;;
10164   no:yes:* )
10165     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10166 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10167     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10168 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10169     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10170 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10171     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10172 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10173     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10174 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10175     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10176 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10177     (
10178       cat <<\_ASBOX
10179 ## ---------------------------------------- ##
10180 ## Report this to pgsql-bugs@postgresql.org ##
10181 ## ---------------------------------------- ##
10182 _ASBOX
10183     ) |
10184       sed "s/^/$as_me: WARNING:     /" >&2
10185     ;;
10186 esac
10187 echo "$as_me:$LINENO: checking for $ac_header" >&5
10188 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10189 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10190   echo $ECHO_N "(cached) $ECHO_C" >&6
10191 else
10192   eval "$as_ac_Header=\$ac_header_preproc"
10193 fi
10194 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10195 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10196
10197 fi
10198 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10199   cat >>confdefs.h <<_ACEOF
10200 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10201 _ACEOF
10202
10203 else
10204
10205 for ac_header in pam/pam_appl.h
10206 do
10207 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10208 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10209   echo "$as_me:$LINENO: checking for $ac_header" >&5
10210 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10211 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10212   echo $ECHO_N "(cached) $ECHO_C" >&6
10213 fi
10214 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10215 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10216 else
10217   # Is the header compilable?
10218 echo "$as_me:$LINENO: checking $ac_header usability" >&5
10219 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10220 cat >conftest.$ac_ext <<_ACEOF
10221 /* confdefs.h.  */
10222 _ACEOF
10223 cat confdefs.h >>conftest.$ac_ext
10224 cat >>conftest.$ac_ext <<_ACEOF
10225 /* end confdefs.h.  */
10226 $ac_includes_default
10227 #include <$ac_header>
10228 _ACEOF
10229 rm -f conftest.$ac_objext
10230 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10231   (eval $ac_compile) 2>conftest.er1
10232   ac_status=$?
10233   grep -v '^ *+' conftest.er1 >conftest.err
10234   rm -f conftest.er1
10235   cat conftest.err >&5
10236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10237   (exit $ac_status); } &&
10238          { ac_try='test -z "$ac_c_werror_flag"
10239                          || test ! -s conftest.err'
10240   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10241   (eval $ac_try) 2>&5
10242   ac_status=$?
10243   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10244   (exit $ac_status); }; } &&
10245          { ac_try='test -s conftest.$ac_objext'
10246   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10247   (eval $ac_try) 2>&5
10248   ac_status=$?
10249   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10250   (exit $ac_status); }; }; then
10251   ac_header_compiler=yes
10252 else
10253   echo "$as_me: failed program was:" >&5
10254 sed 's/^/| /' conftest.$ac_ext >&5
10255
10256 ac_header_compiler=no
10257 fi
10258 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10259 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10260 echo "${ECHO_T}$ac_header_compiler" >&6
10261
10262 # Is the header present?
10263 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10264 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10265 cat >conftest.$ac_ext <<_ACEOF
10266 /* confdefs.h.  */
10267 _ACEOF
10268 cat confdefs.h >>conftest.$ac_ext
10269 cat >>conftest.$ac_ext <<_ACEOF
10270 /* end confdefs.h.  */
10271 #include <$ac_header>
10272 _ACEOF
10273 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10274   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10275   ac_status=$?
10276   grep -v '^ *+' conftest.er1 >conftest.err
10277   rm -f conftest.er1
10278   cat conftest.err >&5
10279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10280   (exit $ac_status); } >/dev/null; then
10281   if test -s conftest.err; then
10282     ac_cpp_err=$ac_c_preproc_warn_flag
10283     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10284   else
10285     ac_cpp_err=
10286   fi
10287 else
10288   ac_cpp_err=yes
10289 fi
10290 if test -z "$ac_cpp_err"; then
10291   ac_header_preproc=yes
10292 else
10293   echo "$as_me: failed program was:" >&5
10294 sed 's/^/| /' conftest.$ac_ext >&5
10295
10296   ac_header_preproc=no
10297 fi
10298 rm -f conftest.err conftest.$ac_ext
10299 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10300 echo "${ECHO_T}$ac_header_preproc" >&6
10301
10302 # So?  What about this header?
10303 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10304   yes:no: )
10305     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10306 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10307     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10308 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10309     ac_header_preproc=yes
10310     ;;
10311   no:yes:* )
10312     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10313 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10314     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10315 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10316     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10317 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10318     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10319 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10320     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10321 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10322     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10323 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10324     (
10325       cat <<\_ASBOX
10326 ## ---------------------------------------- ##
10327 ## Report this to pgsql-bugs@postgresql.org ##
10328 ## ---------------------------------------- ##
10329 _ASBOX
10330     ) |
10331       sed "s/^/$as_me: WARNING:     /" >&2
10332     ;;
10333 esac
10334 echo "$as_me:$LINENO: checking for $ac_header" >&5
10335 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10336 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10337   echo $ECHO_N "(cached) $ECHO_C" >&6
10338 else
10339   eval "$as_ac_Header=\$ac_header_preproc"
10340 fi
10341 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10342 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10343
10344 fi
10345 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10346   cat >>confdefs.h <<_ACEOF
10347 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10348 _ACEOF
10349
10350 else
10351   { { echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
10352 echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
10353    { (exit 1); exit 1; }; }
10354 fi
10355
10356 done
10357
10358 fi
10359
10360 done
10361
10362 fi
10363
10364 if test "$with_ldap" = yes ; then
10365   if test "$PORTNAME" != "win32"; then
10366
10367 for ac_header in ldap.h
10368 do
10369 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10370 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10371   echo "$as_me:$LINENO: checking for $ac_header" >&5
10372 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10373 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10374   echo $ECHO_N "(cached) $ECHO_C" >&6
10375 fi
10376 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10377 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10378 else
10379   # Is the header compilable?
10380 echo "$as_me:$LINENO: checking $ac_header usability" >&5
10381 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10382 cat >conftest.$ac_ext <<_ACEOF
10383 /* confdefs.h.  */
10384 _ACEOF
10385 cat confdefs.h >>conftest.$ac_ext
10386 cat >>conftest.$ac_ext <<_ACEOF
10387 /* end confdefs.h.  */
10388 $ac_includes_default
10389 #include <$ac_header>
10390 _ACEOF
10391 rm -f conftest.$ac_objext
10392 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10393   (eval $ac_compile) 2>conftest.er1
10394   ac_status=$?
10395   grep -v '^ *+' conftest.er1 >conftest.err
10396   rm -f conftest.er1
10397   cat conftest.err >&5
10398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10399   (exit $ac_status); } &&
10400          { ac_try='test -z "$ac_c_werror_flag"
10401                          || test ! -s conftest.err'
10402   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10403   (eval $ac_try) 2>&5
10404   ac_status=$?
10405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10406   (exit $ac_status); }; } &&
10407          { ac_try='test -s conftest.$ac_objext'
10408   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10409   (eval $ac_try) 2>&5
10410   ac_status=$?
10411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10412   (exit $ac_status); }; }; then
10413   ac_header_compiler=yes
10414 else
10415   echo "$as_me: failed program was:" >&5
10416 sed 's/^/| /' conftest.$ac_ext >&5
10417
10418 ac_header_compiler=no
10419 fi
10420 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10421 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10422 echo "${ECHO_T}$ac_header_compiler" >&6
10423
10424 # Is the header present?
10425 echo "$as_me:$LINENO: checking $ac_header presence" >&5
10426 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10427 cat >conftest.$ac_ext <<_ACEOF
10428 /* confdefs.h.  */
10429 _ACEOF
10430 cat confdefs.h >>conftest.$ac_ext
10431 cat >>conftest.$ac_ext <<_ACEOF
10432 /* end confdefs.h.  */
10433 #include <$ac_header>
10434 _ACEOF
10435 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10436   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10437   ac_status=$?
10438   grep -v '^ *+' conftest.er1 >conftest.err
10439   rm -f conftest.er1
10440   cat conftest.err >&5
10441   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10442   (exit $ac_status); } >/dev/null; then
10443   if test -s conftest.err; then
10444     ac_cpp_err=$ac_c_preproc_warn_flag
10445     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10446   else
10447     ac_cpp_err=
10448   fi
10449 else
10450   ac_cpp_err=yes
10451 fi
10452 if test -z "$ac_cpp_err"; then
10453   ac_header_preproc=yes
10454 else
10455   echo "$as_me: failed program was:" >&5
10456 sed 's/^/| /' conftest.$ac_ext >&5
10457
10458   ac_header_preproc=no
10459 fi
10460 rm -f conftest.err conftest.$ac_ext
10461 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10462 echo "${ECHO_T}$ac_header_preproc" >&6
10463
10464 # So?  What about this header?
10465 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10466   yes:no: )
10467     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10468 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10469     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10470 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10471     ac_header_preproc=yes
10472     ;;
10473   no:yes:* )
10474     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10475 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10476     { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10477 echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10478     { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10479 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10480     { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10481 echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10482     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10483 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10484     { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10485 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10486     (
10487       cat <<\_ASBOX
10488 ## ---------------------------------------- ##
10489 ## Report this to pgsql-bugs@postgresql.org ##
10490 ## ---------------------------------------- ##
10491 _ASBOX
10492     ) |
10493       sed "s/^/$as_me: WARNING:     /" >&2
10494     ;;
10495 esac
10496 echo "$as_me:$LINENO: checking for $ac_header" >&5
10497 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10498 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10499   echo $ECHO_N "(cached) $ECHO_C" >&6
10500 else
10501   eval "$as_ac_Header=\$ac_header_preproc"
10502 fi
10503 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10504 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10505
10506 fi
10507 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10508   cat >>confdefs.h <<_ACEOF
10509 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10510 _ACEOF
10511
10512 else
10513   { { echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
10514 echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
10515    { (exit 1); exit 1; }; }
10516 fi
10517
10518 done
10519
10520   else
10521
10522 for ac_header in winldap.h
10523 do
10524 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10525 echo "$as_me:$LINENO: checking for $ac_header" >&5
10526 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10527 if eval "test \"\${$as_ac_Header+set}\" = set"; then
10528   echo $ECHO_N "(cached) $ECHO_C" >&6
10529 else
10530   cat >conftest.$ac_ext <<_ACEOF
10531 /* confdefs.h.  */
10532 _ACEOF
10533 cat confdefs.h >>conftest.$ac_ext
10534 cat >>conftest.$ac_ext <<_ACEOF
10535 /* end confdefs.h.  */
10536 $ac_includes_default
10537 #include <windows.h>
10538
10539
10540 #include <$ac_header>
10541 _ACEOF
10542 rm -f conftest.$ac_objext
10543 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10544   (eval $ac_compile) 2>conftest.er1
10545   ac_status=$?
10546   grep -v '^ *+' conftest.er1 >conftest.err
10547   rm -f conftest.er1
10548   cat conftest.err >&5
10549   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10550   (exit $ac_status); } &&
10551          { ac_try='test -z "$ac_c_werror_flag"
10552                          || test ! -s conftest.err'
10553   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10554   (eval $ac_try) 2>&5
10555   ac_status=$?
10556   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10557   (exit $ac_status); }; } &&
10558          { ac_try='test -s conftest.$ac_objext'
10559   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10560   (eval $ac_try) 2>&5
10561   ac_status=$?
10562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10563   (exit $ac_status); }; }; then
10564   eval "$as_ac_Header=yes"
10565 else
10566   echo "$as_me: failed program was:" >&5
10567 sed 's/^/| /' conftest.$ac_ext >&5
10568
10569 eval "$as_ac_Header=no"
10570 fi
10571 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10572 fi
10573 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10574 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10575 if test `eval echo '${'$as_ac_Header'}'` = yes; then
10576   cat >>confdefs.h <<_ACEOF
10577 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10578 _ACEOF
10579
10580 else
10581   { { echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
10582 echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
10583    { (exit 1); exit 1; }; }
10584 fi
10585
10586 done
10587
10588   fi
10589 fi
10590
10591 if test "$with_bonjour" = yes ; then
10592   if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10593   echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
10594 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
10595 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10596   echo $ECHO_N "(cached) $ECHO_C" >&6
10597 fi
10598 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
10599 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
10600 else
10601   # Is the header compilable?
10602 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h usability" >&5
10603 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h usability... $ECHO_C" >&6
10604 cat >conftest.$ac_ext <<_ACEOF
10605 /* confdefs.h.  */
10606 _ACEOF
10607 cat confdefs.h >>conftest.$ac_ext
10608 cat >>conftest.$ac_ext <<_ACEOF
10609 /* end confdefs.h.  */
10610 $ac_includes_default
10611 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
10612 _ACEOF
10613 rm -f conftest.$ac_objext
10614 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10615   (eval $ac_compile) 2>conftest.er1
10616   ac_status=$?
10617   grep -v '^ *+' conftest.er1 >conftest.err
10618   rm -f conftest.er1
10619   cat conftest.err >&5
10620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10621   (exit $ac_status); } &&
10622          { ac_try='test -z "$ac_c_werror_flag"
10623                          || test ! -s conftest.err'
10624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10625   (eval $ac_try) 2>&5
10626   ac_status=$?
10627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10628   (exit $ac_status); }; } &&
10629          { ac_try='test -s conftest.$ac_objext'
10630   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10631   (eval $ac_try) 2>&5
10632   ac_status=$?
10633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10634   (exit $ac_status); }; }; then
10635   ac_header_compiler=yes
10636 else
10637   echo "$as_me: failed program was:" >&5
10638 sed 's/^/| /' conftest.$ac_ext >&5
10639
10640 ac_header_compiler=no
10641 fi
10642 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10643 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10644 echo "${ECHO_T}$ac_header_compiler" >&6
10645
10646 # Is the header present?
10647 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h presence" >&5
10648 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h presence... $ECHO_C" >&6
10649 cat >conftest.$ac_ext <<_ACEOF
10650 /* confdefs.h.  */
10651 _ACEOF
10652 cat confdefs.h >>conftest.$ac_ext
10653 cat >>conftest.$ac_ext <<_ACEOF
10654 /* end confdefs.h.  */
10655 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
10656 _ACEOF
10657 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10658   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10659   ac_status=$?
10660   grep -v '^ *+' conftest.er1 >conftest.err
10661   rm -f conftest.er1
10662   cat conftest.err >&5
10663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10664   (exit $ac_status); } >/dev/null; then
10665   if test -s conftest.err; then
10666     ac_cpp_err=$ac_c_preproc_warn_flag
10667     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
10668   else
10669     ac_cpp_err=
10670   fi
10671 else
10672   ac_cpp_err=yes
10673 fi
10674 if test -z "$ac_cpp_err"; then
10675   ac_header_preproc=yes
10676 else
10677   echo "$as_me: failed program was:" >&5
10678 sed 's/^/| /' conftest.$ac_ext >&5
10679
10680   ac_header_preproc=no
10681 fi
10682 rm -f conftest.err conftest.$ac_ext
10683 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10684 echo "${ECHO_T}$ac_header_preproc" >&6
10685
10686 # So?  What about this header?
10687 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10688   yes:no: )
10689     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&5
10690 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10691     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&5
10692 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the compiler's result" >&2;}
10693     ac_header_preproc=yes
10694     ;;
10695   no:yes:* )
10696     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&5
10697 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&2;}
10698     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&5
10699 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     check for missing prerequisite headers?" >&2;}
10700     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&5
10701 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: see the Autoconf documentation" >&2;}
10702     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&5
10703 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10704     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
10705 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;}
10706     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&5
10707 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: in the future, the compiler will take precedence" >&2;}
10708     (
10709       cat <<\_ASBOX
10710 ## ---------------------------------------- ##
10711 ## Report this to pgsql-bugs@postgresql.org ##
10712 ## ---------------------------------------- ##
10713 _ASBOX
10714     ) |
10715       sed "s/^/$as_me: WARNING:     /" >&2
10716     ;;
10717 esac
10718 echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
10719 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
10720 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
10721   echo $ECHO_N "(cached) $ECHO_C" >&6
10722 else
10723   ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h=$ac_header_preproc
10724 fi
10725 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
10726 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
10727
10728 fi
10729 if test $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h = yes; then
10730   :
10731 else
10732   { { echo "$as_me:$LINENO: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&5
10733 echo "$as_me: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Bonjour" >&2;}
10734    { (exit 1); exit 1; }; }
10735 fi
10736
10737
10738 fi
10739
10740
10741 ##
10742 ## Types, structures, compiler characteristics
10743 ##
10744
10745  echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
10746 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
10747 if test "${ac_cv_c_const+set}" = set; then
10748   echo $ECHO_N "(cached) $ECHO_C" >&6
10749 else
10750   cat >conftest.$ac_ext <<_ACEOF
10751 /* confdefs.h.  */
10752 _ACEOF
10753 cat confdefs.h >>conftest.$ac_ext
10754 cat >>conftest.$ac_ext <<_ACEOF
10755 /* end confdefs.h.  */
10756
10757 int
10758 main ()
10759 {
10760 /* FIXME: Include the comments suggested by Paul. */
10761 #ifndef __cplusplus
10762   /* Ultrix mips cc rejects this.  */
10763   typedef int charset[2];
10764   const charset x;
10765   /* SunOS 4.1.1 cc rejects this.  */
10766   char const *const *ccp;
10767   char **p;
10768   /* NEC SVR4.0.2 mips cc rejects this.  */
10769   struct point {int x, y;};
10770   static struct point const zero = {0,0};
10771   /* AIX XL C 1.02.0.0 rejects this.
10772      It does not let you subtract one const X* pointer from another in
10773      an arm of an if-expression whose if-part is not a constant
10774      expression */
10775   const char *g = "string";
10776   ccp = &g + (g ? g-g : 0);
10777   /* HPUX 7.0 cc rejects these. */
10778   ++ccp;
10779   p = (char**) ccp;
10780   ccp = (char const *const *) p;
10781   { /* SCO 3.2v4 cc rejects this.  */
10782     char *t;
10783     char const *s = 0 ? (char *) 0 : (char const *) 0;
10784
10785     *t++ = 0;
10786   }
10787   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
10788     int x[] = {25, 17};
10789     const int *foo = &x[0];
10790     ++foo;
10791   }
10792   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
10793     typedef const int *iptr;
10794     iptr p = 0;
10795     ++p;
10796   }
10797   { /* AIX XL C 1.02.0.0 rejects this saying
10798        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
10799     struct s { int j; const int *ap[3]; };
10800     struct s *b; b->j = 5;
10801   }
10802   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
10803     const int foo = 10;
10804   }
10805 #endif
10806
10807   ;
10808   return 0;
10809 }
10810 _ACEOF
10811 rm -f conftest.$ac_objext
10812 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10813   (eval $ac_compile) 2>conftest.er1
10814   ac_status=$?
10815   grep -v '^ *+' conftest.er1 >conftest.err
10816   rm -f conftest.er1
10817   cat conftest.err >&5
10818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10819   (exit $ac_status); } &&
10820          { ac_try='test -z "$ac_c_werror_flag"
10821                          || test ! -s conftest.err'
10822   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10823   (eval $ac_try) 2>&5
10824   ac_status=$?
10825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10826   (exit $ac_status); }; } &&
10827          { ac_try='test -s conftest.$ac_objext'
10828   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10829   (eval $ac_try) 2>&5
10830   ac_status=$?
10831   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10832   (exit $ac_status); }; }; then
10833   ac_cv_c_const=yes
10834 else
10835   echo "$as_me: failed program was:" >&5
10836 sed 's/^/| /' conftest.$ac_ext >&5
10837
10838 ac_cv_c_const=no
10839 fi
10840 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10841 fi
10842 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
10843 echo "${ECHO_T}$ac_cv_c_const" >&6
10844 if test $ac_cv_c_const = no; then
10845
10846 cat >>confdefs.h <<\_ACEOF
10847 #define const
10848 _ACEOF
10849
10850 fi
10851
10852
10853 echo "$as_me:$LINENO: checking for inline" >&5
10854 echo $ECHO_N "checking for inline... $ECHO_C" >&6
10855 if test "${ac_cv_c_inline+set}" = set; then
10856   echo $ECHO_N "(cached) $ECHO_C" >&6
10857 else
10858   ac_cv_c_inline=no
10859 for ac_kw in inline __inline__ __inline; do
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 #ifndef __cplusplus
10867 typedef int foo_t;
10868 static $ac_kw foo_t static_foo () {return 0; }
10869 $ac_kw int foo () {return 0; }
10870 #endif
10871
10872 _ACEOF
10873 rm -f conftest.$ac_objext
10874 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10875   (eval $ac_compile) 2>conftest.er1
10876   ac_status=$?
10877   grep -v '^ *+' conftest.er1 >conftest.err
10878   rm -f conftest.er1
10879   cat conftest.err >&5
10880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10881   (exit $ac_status); } &&
10882          { ac_try='test -z "$ac_c_werror_flag"
10883                          || test ! -s conftest.err'
10884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10885   (eval $ac_try) 2>&5
10886   ac_status=$?
10887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10888   (exit $ac_status); }; } &&
10889          { ac_try='test -s conftest.$ac_objext'
10890   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10891   (eval $ac_try) 2>&5
10892   ac_status=$?
10893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10894   (exit $ac_status); }; }; then
10895   ac_cv_c_inline=$ac_kw; break
10896 else
10897   echo "$as_me: failed program was:" >&5
10898 sed 's/^/| /' conftest.$ac_ext >&5
10899
10900 fi
10901 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10902 done
10903
10904 fi
10905 echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
10906 echo "${ECHO_T}$ac_cv_c_inline" >&6
10907 case $ac_cv_c_inline in
10908   inline | yes) ;;
10909   no)
10910 cat >>confdefs.h <<\_ACEOF
10911 #define inline
10912 _ACEOF
10913  ;;
10914   *)  cat >>confdefs.h <<_ACEOF
10915 #define inline $ac_cv_c_inline
10916 _ACEOF
10917  ;;
10918 esac
10919
10920 echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
10921 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6
10922 if test "${ac_cv_c_stringize+set}" = set; then
10923   echo $ECHO_N "(cached) $ECHO_C" >&6
10924 else
10925   cat >conftest.$ac_ext <<_ACEOF
10926 /* confdefs.h.  */
10927 _ACEOF
10928 cat confdefs.h >>conftest.$ac_ext
10929 cat >>conftest.$ac_ext <<_ACEOF
10930 /* end confdefs.h.  */
10931 #define x(y) #y
10932
10933 char *s = x(teststring);
10934 _ACEOF
10935 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10936   $EGREP "#teststring" >/dev/null 2>&1; then
10937   ac_cv_c_stringize=no
10938 else
10939   ac_cv_c_stringize=yes
10940 fi
10941 rm -f conftest*
10942
10943 fi
10944 echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
10945 echo "${ECHO_T}$ac_cv_c_stringize" >&6
10946 if test $ac_cv_c_stringize = yes; then
10947
10948 cat >>confdefs.h <<\_ACEOF
10949 #define HAVE_STRINGIZE 1
10950 _ACEOF
10951
10952 fi
10953
10954 echo "$as_me:$LINENO: checking for signed types" >&5
10955 echo $ECHO_N "checking for signed types... $ECHO_C" >&6
10956 if test "${pgac_cv_c_signed+set}" = set; then
10957   echo $ECHO_N "(cached) $ECHO_C" >&6
10958 else
10959   cat >conftest.$ac_ext <<_ACEOF
10960 /* confdefs.h.  */
10961 _ACEOF
10962 cat confdefs.h >>conftest.$ac_ext
10963 cat >>conftest.$ac_ext <<_ACEOF
10964 /* end confdefs.h.  */
10965
10966 int
10967 main ()
10968 {
10969 signed char c; signed short s; signed int i;
10970   ;
10971   return 0;
10972 }
10973 _ACEOF
10974 rm -f conftest.$ac_objext
10975 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10976   (eval $ac_compile) 2>conftest.er1
10977   ac_status=$?
10978   grep -v '^ *+' conftest.er1 >conftest.err
10979   rm -f conftest.er1
10980   cat conftest.err >&5
10981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10982   (exit $ac_status); } &&
10983          { ac_try='test -z "$ac_c_werror_flag"
10984                          || test ! -s conftest.err'
10985   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10986   (eval $ac_try) 2>&5
10987   ac_status=$?
10988   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10989   (exit $ac_status); }; } &&
10990          { ac_try='test -s conftest.$ac_objext'
10991   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10992   (eval $ac_try) 2>&5
10993   ac_status=$?
10994   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10995   (exit $ac_status); }; }; then
10996   pgac_cv_c_signed=yes
10997 else
10998   echo "$as_me: failed program was:" >&5
10999 sed 's/^/| /' conftest.$ac_ext >&5
11000
11001 pgac_cv_c_signed=no
11002 fi
11003 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11004 fi
11005 echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
11006 echo "${ECHO_T}$pgac_cv_c_signed" >&6
11007 if test x"$pgac_cv_c_signed" = xno ; then
11008
11009 cat >>confdefs.h <<\_ACEOF
11010 #define signed
11011 _ACEOF
11012
11013 fi
11014 echo "$as_me:$LINENO: checking for working volatile" >&5
11015 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
11016 if test "${ac_cv_c_volatile+set}" = set; then
11017   echo $ECHO_N "(cached) $ECHO_C" >&6
11018 else
11019   cat >conftest.$ac_ext <<_ACEOF
11020 /* confdefs.h.  */
11021 _ACEOF
11022 cat confdefs.h >>conftest.$ac_ext
11023 cat >>conftest.$ac_ext <<_ACEOF
11024 /* end confdefs.h.  */
11025
11026 int
11027 main ()
11028 {
11029
11030 volatile int x;
11031 int * volatile y;
11032   ;
11033   return 0;
11034 }
11035 _ACEOF
11036 rm -f conftest.$ac_objext
11037 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11038   (eval $ac_compile) 2>conftest.er1
11039   ac_status=$?
11040   grep -v '^ *+' conftest.er1 >conftest.err
11041   rm -f conftest.er1
11042   cat conftest.err >&5
11043   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11044   (exit $ac_status); } &&
11045          { ac_try='test -z "$ac_c_werror_flag"
11046                          || test ! -s conftest.err'
11047   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11048   (eval $ac_try) 2>&5
11049   ac_status=$?
11050   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11051   (exit $ac_status); }; } &&
11052          { ac_try='test -s conftest.$ac_objext'
11053   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11054   (eval $ac_try) 2>&5
11055   ac_status=$?
11056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11057   (exit $ac_status); }; }; then
11058   ac_cv_c_volatile=yes
11059 else
11060   echo "$as_me: failed program was:" >&5
11061 sed 's/^/| /' conftest.$ac_ext >&5
11062
11063 ac_cv_c_volatile=no
11064 fi
11065 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11066 fi
11067 echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
11068 echo "${ECHO_T}$ac_cv_c_volatile" >&6
11069 if test $ac_cv_c_volatile = no; then
11070
11071 cat >>confdefs.h <<\_ACEOF
11072 #define volatile
11073 _ACEOF
11074
11075 fi
11076
11077 echo "$as_me:$LINENO: checking for __func__" >&5
11078 echo $ECHO_N "checking for __func__... $ECHO_C" >&6
11079 if test "${pgac_cv_funcname_func_support+set}" = set; then
11080   echo $ECHO_N "(cached) $ECHO_C" >&6
11081 else
11082   cat >conftest.$ac_ext <<_ACEOF
11083 /* confdefs.h.  */
11084 _ACEOF
11085 cat confdefs.h >>conftest.$ac_ext
11086 cat >>conftest.$ac_ext <<_ACEOF
11087 /* end confdefs.h.  */
11088 #include <stdio.h>
11089 int
11090 main ()
11091 {
11092 printf("%s\n", __func__);
11093   ;
11094   return 0;
11095 }
11096 _ACEOF
11097 rm -f conftest.$ac_objext
11098 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11099   (eval $ac_compile) 2>conftest.er1
11100   ac_status=$?
11101   grep -v '^ *+' conftest.er1 >conftest.err
11102   rm -f conftest.er1
11103   cat conftest.err >&5
11104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11105   (exit $ac_status); } &&
11106          { ac_try='test -z "$ac_c_werror_flag"
11107                          || test ! -s conftest.err'
11108   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11109   (eval $ac_try) 2>&5
11110   ac_status=$?
11111   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11112   (exit $ac_status); }; } &&
11113          { ac_try='test -s conftest.$ac_objext'
11114   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11115   (eval $ac_try) 2>&5
11116   ac_status=$?
11117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11118   (exit $ac_status); }; }; then
11119   pgac_cv_funcname_func_support=yes
11120 else
11121   echo "$as_me: failed program was:" >&5
11122 sed 's/^/| /' conftest.$ac_ext >&5
11123
11124 pgac_cv_funcname_func_support=no
11125 fi
11126 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11127 fi
11128 echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
11129 echo "${ECHO_T}$pgac_cv_funcname_func_support" >&6
11130 if test x"$pgac_cv_funcname_func_support" = xyes ; then
11131
11132 cat >>confdefs.h <<\_ACEOF
11133 #define HAVE_FUNCNAME__FUNC 1
11134 _ACEOF
11135
11136 else
11137 echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
11138 echo $ECHO_N "checking for __FUNCTION__... $ECHO_C" >&6
11139 if test "${pgac_cv_funcname_function_support+set}" = set; then
11140   echo $ECHO_N "(cached) $ECHO_C" >&6
11141 else
11142   cat >conftest.$ac_ext <<_ACEOF
11143 /* confdefs.h.  */
11144 _ACEOF
11145 cat confdefs.h >>conftest.$ac_ext
11146 cat >>conftest.$ac_ext <<_ACEOF
11147 /* end confdefs.h.  */
11148 #include <stdio.h>
11149 int
11150 main ()
11151 {
11152 printf("%s\n", __FUNCTION__);
11153   ;
11154   return 0;
11155 }
11156 _ACEOF
11157 rm -f conftest.$ac_objext
11158 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11159   (eval $ac_compile) 2>conftest.er1
11160   ac_status=$?
11161   grep -v '^ *+' conftest.er1 >conftest.err
11162   rm -f conftest.er1
11163   cat conftest.err >&5
11164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11165   (exit $ac_status); } &&
11166          { ac_try='test -z "$ac_c_werror_flag"
11167                          || test ! -s conftest.err'
11168   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11169   (eval $ac_try) 2>&5
11170   ac_status=$?
11171   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11172   (exit $ac_status); }; } &&
11173          { ac_try='test -s conftest.$ac_objext'
11174   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11175   (eval $ac_try) 2>&5
11176   ac_status=$?
11177   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11178   (exit $ac_status); }; }; then
11179   pgac_cv_funcname_function_support=yes
11180 else
11181   echo "$as_me: failed program was:" >&5
11182 sed 's/^/| /' conftest.$ac_ext >&5
11183
11184 pgac_cv_funcname_function_support=no
11185 fi
11186 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11187 fi
11188 echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
11189 echo "${ECHO_T}$pgac_cv_funcname_function_support" >&6
11190 if test x"$pgac_cv_funcname_function_support" = xyes ; then
11191
11192 cat >>confdefs.h <<\_ACEOF
11193 #define HAVE_FUNCNAME__FUNCTION 1
11194 _ACEOF
11195
11196 fi
11197 fi
11198 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
11199 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
11200 if test "${ac_cv_struct_tm+set}" = set; then
11201   echo $ECHO_N "(cached) $ECHO_C" >&6
11202 else
11203   cat >conftest.$ac_ext <<_ACEOF
11204 /* confdefs.h.  */
11205 _ACEOF
11206 cat confdefs.h >>conftest.$ac_ext
11207 cat >>conftest.$ac_ext <<_ACEOF
11208 /* end confdefs.h.  */
11209 #include <sys/types.h>
11210 #include <time.h>
11211
11212 int
11213 main ()
11214 {
11215 struct tm *tp; tp->tm_sec;
11216   ;
11217   return 0;
11218 }
11219 _ACEOF
11220 rm -f conftest.$ac_objext
11221 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11222   (eval $ac_compile) 2>conftest.er1
11223   ac_status=$?
11224   grep -v '^ *+' conftest.er1 >conftest.err
11225   rm -f conftest.er1
11226   cat conftest.err >&5
11227   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11228   (exit $ac_status); } &&
11229          { ac_try='test -z "$ac_c_werror_flag"
11230                          || test ! -s conftest.err'
11231   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11232   (eval $ac_try) 2>&5
11233   ac_status=$?
11234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11235   (exit $ac_status); }; } &&
11236          { ac_try='test -s conftest.$ac_objext'
11237   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11238   (eval $ac_try) 2>&5
11239   ac_status=$?
11240   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11241   (exit $ac_status); }; }; then
11242   ac_cv_struct_tm=time.h
11243 else
11244   echo "$as_me: failed program was:" >&5
11245 sed 's/^/| /' conftest.$ac_ext >&5
11246
11247 ac_cv_struct_tm=sys/time.h
11248 fi
11249 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11250 fi
11251 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
11252 echo "${ECHO_T}$ac_cv_struct_tm" >&6
11253 if test $ac_cv_struct_tm = sys/time.h; then
11254
11255 cat >>confdefs.h <<\_ACEOF
11256 #define TM_IN_SYS_TIME 1
11257 _ACEOF
11258
11259 fi
11260
11261 echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
11262 echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
11263 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
11264   echo $ECHO_N "(cached) $ECHO_C" >&6
11265 else
11266   cat >conftest.$ac_ext <<_ACEOF
11267 /* confdefs.h.  */
11268 _ACEOF
11269 cat confdefs.h >>conftest.$ac_ext
11270 cat >>conftest.$ac_ext <<_ACEOF
11271 /* end confdefs.h.  */
11272 #include <sys/types.h>
11273 #include <$ac_cv_struct_tm>
11274
11275
11276 int
11277 main ()
11278 {
11279 static struct tm ac_aggr;
11280 if (ac_aggr.tm_zone)
11281 return 0;
11282   ;
11283   return 0;
11284 }
11285 _ACEOF
11286 rm -f conftest.$ac_objext
11287 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11288   (eval $ac_compile) 2>conftest.er1
11289   ac_status=$?
11290   grep -v '^ *+' conftest.er1 >conftest.err
11291   rm -f conftest.er1
11292   cat conftest.err >&5
11293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11294   (exit $ac_status); } &&
11295          { ac_try='test -z "$ac_c_werror_flag"
11296                          || test ! -s conftest.err'
11297   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11298   (eval $ac_try) 2>&5
11299   ac_status=$?
11300   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11301   (exit $ac_status); }; } &&
11302          { ac_try='test -s conftest.$ac_objext'
11303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11304   (eval $ac_try) 2>&5
11305   ac_status=$?
11306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11307   (exit $ac_status); }; }; then
11308   ac_cv_member_struct_tm_tm_zone=yes
11309 else
11310   echo "$as_me: failed program was:" >&5
11311 sed 's/^/| /' conftest.$ac_ext >&5
11312
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 <$ac_cv_struct_tm>
11321
11322
11323 int
11324 main ()
11325 {
11326 static struct tm ac_aggr;
11327 if (sizeof ac_aggr.tm_zone)
11328 return 0;
11329   ;
11330   return 0;
11331 }
11332 _ACEOF
11333 rm -f conftest.$ac_objext
11334 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11335   (eval $ac_compile) 2>conftest.er1
11336   ac_status=$?
11337   grep -v '^ *+' conftest.er1 >conftest.err
11338   rm -f conftest.er1
11339   cat conftest.err >&5
11340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11341   (exit $ac_status); } &&
11342          { ac_try='test -z "$ac_c_werror_flag"
11343                          || test ! -s conftest.err'
11344   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11345   (eval $ac_try) 2>&5
11346   ac_status=$?
11347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11348   (exit $ac_status); }; } &&
11349          { ac_try='test -s conftest.$ac_objext'
11350   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11351   (eval $ac_try) 2>&5
11352   ac_status=$?
11353   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11354   (exit $ac_status); }; }; then
11355   ac_cv_member_struct_tm_tm_zone=yes
11356 else
11357   echo "$as_me: failed program was:" >&5
11358 sed 's/^/| /' conftest.$ac_ext >&5
11359
11360 ac_cv_member_struct_tm_tm_zone=no
11361 fi
11362 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11363 fi
11364 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11365 fi
11366 echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
11367 echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
11368 if test $ac_cv_member_struct_tm_tm_zone = yes; then
11369
11370 cat >>confdefs.h <<_ACEOF
11371 #define HAVE_STRUCT_TM_TM_ZONE 1
11372 _ACEOF
11373
11374
11375 fi
11376
11377 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
11378
11379 cat >>confdefs.h <<\_ACEOF
11380 #define HAVE_TM_ZONE 1
11381 _ACEOF
11382
11383 fi
11384 echo "$as_me:$LINENO: checking for tzname" >&5
11385 echo $ECHO_N "checking for tzname... $ECHO_C" >&6
11386 if test "${ac_cv_var_tzname+set}" = set; then
11387   echo $ECHO_N "(cached) $ECHO_C" >&6
11388 else
11389   cat >conftest.$ac_ext <<_ACEOF
11390 /* confdefs.h.  */
11391 _ACEOF
11392 cat confdefs.h >>conftest.$ac_ext
11393 cat >>conftest.$ac_ext <<_ACEOF
11394 /* end confdefs.h.  */
11395 #include <time.h>
11396 #ifndef tzname /* For SGI.  */
11397 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
11398 #endif
11399
11400 int
11401 main ()
11402 {
11403 atoi(*tzname);
11404   ;
11405   return 0;
11406 }
11407 _ACEOF
11408 rm -f conftest.$ac_objext conftest$ac_exeext
11409 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11410   (eval $ac_link) 2>conftest.er1
11411   ac_status=$?
11412   grep -v '^ *+' conftest.er1 >conftest.err
11413   rm -f conftest.er1
11414   cat conftest.err >&5
11415   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11416   (exit $ac_status); } &&
11417          { ac_try='test -z "$ac_c_werror_flag"
11418                          || test ! -s conftest.err'
11419   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11420   (eval $ac_try) 2>&5
11421   ac_status=$?
11422   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11423   (exit $ac_status); }; } &&
11424          { ac_try='test -s conftest$ac_exeext'
11425   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11426   (eval $ac_try) 2>&5
11427   ac_status=$?
11428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11429   (exit $ac_status); }; }; then
11430   ac_cv_var_tzname=yes
11431 else
11432   echo "$as_me: failed program was:" >&5
11433 sed 's/^/| /' conftest.$ac_ext >&5
11434
11435 ac_cv_var_tzname=no
11436 fi
11437 rm -f conftest.err conftest.$ac_objext \
11438       conftest$ac_exeext conftest.$ac_ext
11439 fi
11440 echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
11441 echo "${ECHO_T}$ac_cv_var_tzname" >&6
11442 if test $ac_cv_var_tzname = yes; then
11443
11444 cat >>confdefs.h <<\_ACEOF
11445 #define HAVE_TZNAME 1
11446 _ACEOF
11447
11448 fi
11449
11450 echo "$as_me:$LINENO: checking for union semun" >&5
11451 echo $ECHO_N "checking for union semun... $ECHO_C" >&6
11452 if test "${ac_cv_type_union_semun+set}" = set; then
11453   echo $ECHO_N "(cached) $ECHO_C" >&6
11454 else
11455   cat >conftest.$ac_ext <<_ACEOF
11456 /* confdefs.h.  */
11457 _ACEOF
11458 cat confdefs.h >>conftest.$ac_ext
11459 cat >>conftest.$ac_ext <<_ACEOF
11460 /* end confdefs.h.  */
11461 #include <sys/types.h>
11462 #include <sys/ipc.h>
11463 #include <sys/sem.h>
11464
11465 int
11466 main ()
11467 {
11468 if ((union semun *) 0)
11469   return 0;
11470 if (sizeof (union semun))
11471   return 0;
11472   ;
11473   return 0;
11474 }
11475 _ACEOF
11476 rm -f conftest.$ac_objext
11477 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11478   (eval $ac_compile) 2>conftest.er1
11479   ac_status=$?
11480   grep -v '^ *+' conftest.er1 >conftest.err
11481   rm -f conftest.er1
11482   cat conftest.err >&5
11483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11484   (exit $ac_status); } &&
11485          { ac_try='test -z "$ac_c_werror_flag"
11486                          || test ! -s conftest.err'
11487   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11488   (eval $ac_try) 2>&5
11489   ac_status=$?
11490   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11491   (exit $ac_status); }; } &&
11492          { ac_try='test -s conftest.$ac_objext'
11493   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11494   (eval $ac_try) 2>&5
11495   ac_status=$?
11496   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11497   (exit $ac_status); }; }; then
11498   ac_cv_type_union_semun=yes
11499 else
11500   echo "$as_me: failed program was:" >&5
11501 sed 's/^/| /' conftest.$ac_ext >&5
11502
11503 ac_cv_type_union_semun=no
11504 fi
11505 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11506 fi
11507 echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
11508 echo "${ECHO_T}$ac_cv_type_union_semun" >&6
11509 if test $ac_cv_type_union_semun = yes; then
11510
11511 cat >>confdefs.h <<_ACEOF
11512 #define HAVE_UNION_SEMUN 1
11513 _ACEOF
11514
11515
11516 fi
11517
11518 echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
11519 echo $ECHO_N "checking for struct sockaddr_un... $ECHO_C" >&6
11520 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
11521   echo $ECHO_N "(cached) $ECHO_C" >&6
11522 else
11523   cat >conftest.$ac_ext <<_ACEOF
11524 /* confdefs.h.  */
11525 _ACEOF
11526 cat confdefs.h >>conftest.$ac_ext
11527 cat >>conftest.$ac_ext <<_ACEOF
11528 /* end confdefs.h.  */
11529 #include <sys/types.h>
11530 #ifdef HAVE_SYS_UN_H
11531 #include <sys/un.h>
11532 #endif
11533
11534
11535 int
11536 main ()
11537 {
11538 if ((struct sockaddr_un *) 0)
11539   return 0;
11540 if (sizeof (struct sockaddr_un))
11541   return 0;
11542   ;
11543   return 0;
11544 }
11545 _ACEOF
11546 rm -f conftest.$ac_objext
11547 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11548   (eval $ac_compile) 2>conftest.er1
11549   ac_status=$?
11550   grep -v '^ *+' conftest.er1 >conftest.err
11551   rm -f conftest.er1
11552   cat conftest.err >&5
11553   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11554   (exit $ac_status); } &&
11555          { ac_try='test -z "$ac_c_werror_flag"
11556                          || test ! -s conftest.err'
11557   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11558   (eval $ac_try) 2>&5
11559   ac_status=$?
11560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11561   (exit $ac_status); }; } &&
11562          { ac_try='test -s conftest.$ac_objext'
11563   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11564   (eval $ac_try) 2>&5
11565   ac_status=$?
11566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11567   (exit $ac_status); }; }; then
11568   ac_cv_type_struct_sockaddr_un=yes
11569 else
11570   echo "$as_me: failed program was:" >&5
11571 sed 's/^/| /' conftest.$ac_ext >&5
11572
11573 ac_cv_type_struct_sockaddr_un=no
11574 fi
11575 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11576 fi
11577 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
11578 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_un" >&6
11579 if test $ac_cv_type_struct_sockaddr_un = yes; then
11580
11581 cat >>confdefs.h <<_ACEOF
11582 #define HAVE_STRUCT_SOCKADDR_UN 1
11583 _ACEOF
11584
11585
11586 cat >>confdefs.h <<\_ACEOF
11587 #define HAVE_UNIX_SOCKETS 1
11588 _ACEOF
11589
11590 fi
11591
11592 echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
11593 echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6
11594 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
11595   echo $ECHO_N "(cached) $ECHO_C" >&6
11596 else
11597   cat >conftest.$ac_ext <<_ACEOF
11598 /* confdefs.h.  */
11599 _ACEOF
11600 cat confdefs.h >>conftest.$ac_ext
11601 cat >>conftest.$ac_ext <<_ACEOF
11602 /* end confdefs.h.  */
11603 #include <sys/types.h>
11604 #ifdef HAVE_SYS_SOCKET_H
11605 #include <sys/socket.h>
11606 #endif
11607
11608
11609 int
11610 main ()
11611 {
11612 if ((struct sockaddr_storage *) 0)
11613   return 0;
11614 if (sizeof (struct sockaddr_storage))
11615   return 0;
11616   ;
11617   return 0;
11618 }
11619 _ACEOF
11620 rm -f conftest.$ac_objext
11621 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11622   (eval $ac_compile) 2>conftest.er1
11623   ac_status=$?
11624   grep -v '^ *+' conftest.er1 >conftest.err
11625   rm -f conftest.er1
11626   cat conftest.err >&5
11627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11628   (exit $ac_status); } &&
11629          { ac_try='test -z "$ac_c_werror_flag"
11630                          || test ! -s conftest.err'
11631   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11632   (eval $ac_try) 2>&5
11633   ac_status=$?
11634   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11635   (exit $ac_status); }; } &&
11636          { ac_try='test -s conftest.$ac_objext'
11637   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11638   (eval $ac_try) 2>&5
11639   ac_status=$?
11640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11641   (exit $ac_status); }; }; then
11642   ac_cv_type_struct_sockaddr_storage=yes
11643 else
11644   echo "$as_me: failed program was:" >&5
11645 sed 's/^/| /' conftest.$ac_ext >&5
11646
11647 ac_cv_type_struct_sockaddr_storage=no
11648 fi
11649 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11650 fi
11651 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
11652 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_storage" >&6
11653 if test $ac_cv_type_struct_sockaddr_storage = yes; then
11654
11655 cat >>confdefs.h <<_ACEOF
11656 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
11657 _ACEOF
11658
11659
11660 fi
11661
11662 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
11663 echo $ECHO_N "checking for struct sockaddr_storage.ss_family... $ECHO_C" >&6
11664 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
11665   echo $ECHO_N "(cached) $ECHO_C" >&6
11666 else
11667   cat >conftest.$ac_ext <<_ACEOF
11668 /* confdefs.h.  */
11669 _ACEOF
11670 cat confdefs.h >>conftest.$ac_ext
11671 cat >>conftest.$ac_ext <<_ACEOF
11672 /* end confdefs.h.  */
11673 #include <sys/types.h>
11674 #ifdef HAVE_SYS_SOCKET_H
11675 #include <sys/socket.h>
11676 #endif
11677
11678
11679 int
11680 main ()
11681 {
11682 static struct sockaddr_storage ac_aggr;
11683 if (ac_aggr.ss_family)
11684 return 0;
11685   ;
11686   return 0;
11687 }
11688 _ACEOF
11689 rm -f conftest.$ac_objext
11690 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11691   (eval $ac_compile) 2>conftest.er1
11692   ac_status=$?
11693   grep -v '^ *+' conftest.er1 >conftest.err
11694   rm -f conftest.er1
11695   cat conftest.err >&5
11696   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11697   (exit $ac_status); } &&
11698          { ac_try='test -z "$ac_c_werror_flag"
11699                          || test ! -s conftest.err'
11700   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11701   (eval $ac_try) 2>&5
11702   ac_status=$?
11703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11704   (exit $ac_status); }; } &&
11705          { ac_try='test -s conftest.$ac_objext'
11706   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11707   (eval $ac_try) 2>&5
11708   ac_status=$?
11709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11710   (exit $ac_status); }; }; then
11711   ac_cv_member_struct_sockaddr_storage_ss_family=yes
11712 else
11713   echo "$as_me: failed program was:" >&5
11714 sed 's/^/| /' conftest.$ac_ext >&5
11715
11716 cat >conftest.$ac_ext <<_ACEOF
11717 /* confdefs.h.  */
11718 _ACEOF
11719 cat confdefs.h >>conftest.$ac_ext
11720 cat >>conftest.$ac_ext <<_ACEOF
11721 /* end confdefs.h.  */
11722 #include <sys/types.h>
11723 #ifdef HAVE_SYS_SOCKET_H
11724 #include <sys/socket.h>
11725 #endif
11726
11727
11728 int
11729 main ()
11730 {
11731 static struct sockaddr_storage ac_aggr;
11732 if (sizeof ac_aggr.ss_family)
11733 return 0;
11734   ;
11735   return 0;
11736 }
11737 _ACEOF
11738 rm -f conftest.$ac_objext
11739 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11740   (eval $ac_compile) 2>conftest.er1
11741   ac_status=$?
11742   grep -v '^ *+' conftest.er1 >conftest.err
11743   rm -f conftest.er1
11744   cat conftest.err >&5
11745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11746   (exit $ac_status); } &&
11747          { ac_try='test -z "$ac_c_werror_flag"
11748                          || test ! -s conftest.err'
11749   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11750   (eval $ac_try) 2>&5
11751   ac_status=$?
11752   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11753   (exit $ac_status); }; } &&
11754          { ac_try='test -s conftest.$ac_objext'
11755   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11756   (eval $ac_try) 2>&5
11757   ac_status=$?
11758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11759   (exit $ac_status); }; }; then
11760   ac_cv_member_struct_sockaddr_storage_ss_family=yes
11761 else
11762   echo "$as_me: failed program was:" >&5
11763 sed 's/^/| /' conftest.$ac_ext >&5
11764
11765 ac_cv_member_struct_sockaddr_storage_ss_family=no
11766 fi
11767 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11768 fi
11769 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11770 fi
11771 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
11772 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_family" >&6
11773 if test $ac_cv_member_struct_sockaddr_storage_ss_family = yes; then
11774
11775 cat >>confdefs.h <<_ACEOF
11776 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
11777 _ACEOF
11778
11779
11780 fi
11781 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
11782 echo $ECHO_N "checking for struct sockaddr_storage.__ss_family... $ECHO_C" >&6
11783 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
11784   echo $ECHO_N "(cached) $ECHO_C" >&6
11785 else
11786   cat >conftest.$ac_ext <<_ACEOF
11787 /* confdefs.h.  */
11788 _ACEOF
11789 cat confdefs.h >>conftest.$ac_ext
11790 cat >>conftest.$ac_ext <<_ACEOF
11791 /* end confdefs.h.  */
11792 #include <sys/types.h>
11793 #ifdef HAVE_SYS_SOCKET_H
11794 #include <sys/socket.h>
11795 #endif
11796
11797
11798 int
11799 main ()
11800 {
11801 static struct sockaddr_storage ac_aggr;
11802 if (ac_aggr.__ss_family)
11803 return 0;
11804   ;
11805   return 0;
11806 }
11807 _ACEOF
11808 rm -f conftest.$ac_objext
11809 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11810   (eval $ac_compile) 2>conftest.er1
11811   ac_status=$?
11812   grep -v '^ *+' conftest.er1 >conftest.err
11813   rm -f conftest.er1
11814   cat conftest.err >&5
11815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11816   (exit $ac_status); } &&
11817          { ac_try='test -z "$ac_c_werror_flag"
11818                          || test ! -s conftest.err'
11819   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11820   (eval $ac_try) 2>&5
11821   ac_status=$?
11822   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11823   (exit $ac_status); }; } &&
11824          { ac_try='test -s conftest.$ac_objext'
11825   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11826   (eval $ac_try) 2>&5
11827   ac_status=$?
11828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11829   (exit $ac_status); }; }; then
11830   ac_cv_member_struct_sockaddr_storage___ss_family=yes
11831 else
11832   echo "$as_me: failed program was:" >&5
11833 sed 's/^/| /' conftest.$ac_ext >&5
11834
11835 cat >conftest.$ac_ext <<_ACEOF
11836 /* confdefs.h.  */
11837 _ACEOF
11838 cat confdefs.h >>conftest.$ac_ext
11839 cat >>conftest.$ac_ext <<_ACEOF
11840 /* end confdefs.h.  */
11841 #include <sys/types.h>
11842 #ifdef HAVE_SYS_SOCKET_H
11843 #include <sys/socket.h>
11844 #endif
11845
11846
11847 int
11848 main ()
11849 {
11850 static struct sockaddr_storage ac_aggr;
11851 if (sizeof ac_aggr.__ss_family)
11852 return 0;
11853   ;
11854   return 0;
11855 }
11856 _ACEOF
11857 rm -f conftest.$ac_objext
11858 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11859   (eval $ac_compile) 2>conftest.er1
11860   ac_status=$?
11861   grep -v '^ *+' conftest.er1 >conftest.err
11862   rm -f conftest.er1
11863   cat conftest.err >&5
11864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11865   (exit $ac_status); } &&
11866          { ac_try='test -z "$ac_c_werror_flag"
11867                          || test ! -s conftest.err'
11868   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11869   (eval $ac_try) 2>&5
11870   ac_status=$?
11871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11872   (exit $ac_status); }; } &&
11873          { ac_try='test -s conftest.$ac_objext'
11874   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11875   (eval $ac_try) 2>&5
11876   ac_status=$?
11877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11878   (exit $ac_status); }; }; then
11879   ac_cv_member_struct_sockaddr_storage___ss_family=yes
11880 else
11881   echo "$as_me: failed program was:" >&5
11882 sed 's/^/| /' conftest.$ac_ext >&5
11883
11884 ac_cv_member_struct_sockaddr_storage___ss_family=no
11885 fi
11886 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11887 fi
11888 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11889 fi
11890 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
11891 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_family" >&6
11892 if test $ac_cv_member_struct_sockaddr_storage___ss_family = yes; then
11893
11894 cat >>confdefs.h <<_ACEOF
11895 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
11896 _ACEOF
11897
11898
11899 fi
11900 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
11901 echo $ECHO_N "checking for struct sockaddr_storage.ss_len... $ECHO_C" >&6
11902 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
11903   echo $ECHO_N "(cached) $ECHO_C" >&6
11904 else
11905   cat >conftest.$ac_ext <<_ACEOF
11906 /* confdefs.h.  */
11907 _ACEOF
11908 cat confdefs.h >>conftest.$ac_ext
11909 cat >>conftest.$ac_ext <<_ACEOF
11910 /* end confdefs.h.  */
11911 #include <sys/types.h>
11912 #ifdef HAVE_SYS_SOCKET_H
11913 #include <sys/socket.h>
11914 #endif
11915
11916
11917 int
11918 main ()
11919 {
11920 static struct sockaddr_storage ac_aggr;
11921 if (ac_aggr.ss_len)
11922 return 0;
11923   ;
11924   return 0;
11925 }
11926 _ACEOF
11927 rm -f conftest.$ac_objext
11928 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11929   (eval $ac_compile) 2>conftest.er1
11930   ac_status=$?
11931   grep -v '^ *+' conftest.er1 >conftest.err
11932   rm -f conftest.er1
11933   cat conftest.err >&5
11934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11935   (exit $ac_status); } &&
11936          { ac_try='test -z "$ac_c_werror_flag"
11937                          || test ! -s conftest.err'
11938   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11939   (eval $ac_try) 2>&5
11940   ac_status=$?
11941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11942   (exit $ac_status); }; } &&
11943          { ac_try='test -s conftest.$ac_objext'
11944   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11945   (eval $ac_try) 2>&5
11946   ac_status=$?
11947   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11948   (exit $ac_status); }; }; then
11949   ac_cv_member_struct_sockaddr_storage_ss_len=yes
11950 else
11951   echo "$as_me: failed program was:" >&5
11952 sed 's/^/| /' conftest.$ac_ext >&5
11953
11954 cat >conftest.$ac_ext <<_ACEOF
11955 /* confdefs.h.  */
11956 _ACEOF
11957 cat confdefs.h >>conftest.$ac_ext
11958 cat >>conftest.$ac_ext <<_ACEOF
11959 /* end confdefs.h.  */
11960 #include <sys/types.h>
11961 #ifdef HAVE_SYS_SOCKET_H
11962 #include <sys/socket.h>
11963 #endif
11964
11965
11966 int
11967 main ()
11968 {
11969 static struct sockaddr_storage ac_aggr;
11970 if (sizeof ac_aggr.ss_len)
11971 return 0;
11972   ;
11973   return 0;
11974 }
11975 _ACEOF
11976 rm -f conftest.$ac_objext
11977 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11978   (eval $ac_compile) 2>conftest.er1
11979   ac_status=$?
11980   grep -v '^ *+' conftest.er1 >conftest.err
11981   rm -f conftest.er1
11982   cat conftest.err >&5
11983   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11984   (exit $ac_status); } &&
11985          { ac_try='test -z "$ac_c_werror_flag"
11986                          || test ! -s conftest.err'
11987   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11988   (eval $ac_try) 2>&5
11989   ac_status=$?
11990   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11991   (exit $ac_status); }; } &&
11992          { ac_try='test -s conftest.$ac_objext'
11993   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11994   (eval $ac_try) 2>&5
11995   ac_status=$?
11996   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11997   (exit $ac_status); }; }; then
11998   ac_cv_member_struct_sockaddr_storage_ss_len=yes
11999 else
12000   echo "$as_me: failed program was:" >&5
12001 sed 's/^/| /' conftest.$ac_ext >&5
12002
12003 ac_cv_member_struct_sockaddr_storage_ss_len=no
12004 fi
12005 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12006 fi
12007 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12008 fi
12009 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
12010 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_len" >&6
12011 if test $ac_cv_member_struct_sockaddr_storage_ss_len = yes; then
12012
12013 cat >>confdefs.h <<_ACEOF
12014 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
12015 _ACEOF
12016
12017
12018 fi
12019 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
12020 echo $ECHO_N "checking for struct sockaddr_storage.__ss_len... $ECHO_C" >&6
12021 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
12022   echo $ECHO_N "(cached) $ECHO_C" >&6
12023 else
12024   cat >conftest.$ac_ext <<_ACEOF
12025 /* confdefs.h.  */
12026 _ACEOF
12027 cat confdefs.h >>conftest.$ac_ext
12028 cat >>conftest.$ac_ext <<_ACEOF
12029 /* end confdefs.h.  */
12030 #include <sys/types.h>
12031 #ifdef HAVE_SYS_SOCKET_H
12032 #include <sys/socket.h>
12033 #endif
12034
12035
12036 int
12037 main ()
12038 {
12039 static struct sockaddr_storage ac_aggr;
12040 if (ac_aggr.__ss_len)
12041 return 0;
12042   ;
12043   return 0;
12044 }
12045 _ACEOF
12046 rm -f conftest.$ac_objext
12047 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12048   (eval $ac_compile) 2>conftest.er1
12049   ac_status=$?
12050   grep -v '^ *+' conftest.er1 >conftest.err
12051   rm -f conftest.er1
12052   cat conftest.err >&5
12053   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12054   (exit $ac_status); } &&
12055          { ac_try='test -z "$ac_c_werror_flag"
12056                          || test ! -s conftest.err'
12057   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12058   (eval $ac_try) 2>&5
12059   ac_status=$?
12060   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12061   (exit $ac_status); }; } &&
12062          { ac_try='test -s conftest.$ac_objext'
12063   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12064   (eval $ac_try) 2>&5
12065   ac_status=$?
12066   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12067   (exit $ac_status); }; }; then
12068   ac_cv_member_struct_sockaddr_storage___ss_len=yes
12069 else
12070   echo "$as_me: failed program was:" >&5
12071 sed 's/^/| /' conftest.$ac_ext >&5
12072
12073 cat >conftest.$ac_ext <<_ACEOF
12074 /* confdefs.h.  */
12075 _ACEOF
12076 cat confdefs.h >>conftest.$ac_ext
12077 cat >>conftest.$ac_ext <<_ACEOF
12078 /* end confdefs.h.  */
12079 #include <sys/types.h>
12080 #ifdef HAVE_SYS_SOCKET_H
12081 #include <sys/socket.h>
12082 #endif
12083
12084
12085 int
12086 main ()
12087 {
12088 static struct sockaddr_storage ac_aggr;
12089 if (sizeof ac_aggr.__ss_len)
12090 return 0;
12091   ;
12092   return 0;
12093 }
12094 _ACEOF
12095 rm -f conftest.$ac_objext
12096 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12097   (eval $ac_compile) 2>conftest.er1
12098   ac_status=$?
12099   grep -v '^ *+' conftest.er1 >conftest.err
12100   rm -f conftest.er1
12101   cat conftest.err >&5
12102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12103   (exit $ac_status); } &&
12104          { ac_try='test -z "$ac_c_werror_flag"
12105                          || test ! -s conftest.err'
12106   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12107   (eval $ac_try) 2>&5
12108   ac_status=$?
12109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12110   (exit $ac_status); }; } &&
12111          { ac_try='test -s conftest.$ac_objext'
12112   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12113   (eval $ac_try) 2>&5
12114   ac_status=$?
12115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12116   (exit $ac_status); }; }; then
12117   ac_cv_member_struct_sockaddr_storage___ss_len=yes
12118 else
12119   echo "$as_me: failed program was:" >&5
12120 sed 's/^/| /' conftest.$ac_ext >&5
12121
12122 ac_cv_member_struct_sockaddr_storage___ss_len=no
12123 fi
12124 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12125 fi
12126 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12127 fi
12128 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
12129 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_len" >&6
12130 if test $ac_cv_member_struct_sockaddr_storage___ss_len = yes; then
12131
12132 cat >>confdefs.h <<_ACEOF
12133 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
12134 _ACEOF
12135
12136
12137 fi
12138 echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
12139 echo $ECHO_N "checking for struct sockaddr.sa_len... $ECHO_C" >&6
12140 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
12141   echo $ECHO_N "(cached) $ECHO_C" >&6
12142 else
12143   cat >conftest.$ac_ext <<_ACEOF
12144 /* confdefs.h.  */
12145 _ACEOF
12146 cat confdefs.h >>conftest.$ac_ext
12147 cat >>conftest.$ac_ext <<_ACEOF
12148 /* end confdefs.h.  */
12149 #include <sys/types.h>
12150 #ifdef HAVE_SYS_SOCKET_H
12151 #include <sys/socket.h>
12152 #endif
12153
12154
12155 int
12156 main ()
12157 {
12158 static struct sockaddr ac_aggr;
12159 if (ac_aggr.sa_len)
12160 return 0;
12161   ;
12162   return 0;
12163 }
12164 _ACEOF
12165 rm -f conftest.$ac_objext
12166 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12167   (eval $ac_compile) 2>conftest.er1
12168   ac_status=$?
12169   grep -v '^ *+' conftest.er1 >conftest.err
12170   rm -f conftest.er1
12171   cat conftest.err >&5
12172   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12173   (exit $ac_status); } &&
12174          { ac_try='test -z "$ac_c_werror_flag"
12175                          || test ! -s conftest.err'
12176   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12177   (eval $ac_try) 2>&5
12178   ac_status=$?
12179   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12180   (exit $ac_status); }; } &&
12181          { ac_try='test -s conftest.$ac_objext'
12182   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12183   (eval $ac_try) 2>&5
12184   ac_status=$?
12185   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12186   (exit $ac_status); }; }; then
12187   ac_cv_member_struct_sockaddr_sa_len=yes
12188 else
12189   echo "$as_me: failed program was:" >&5
12190 sed 's/^/| /' conftest.$ac_ext >&5
12191
12192 cat >conftest.$ac_ext <<_ACEOF
12193 /* confdefs.h.  */
12194 _ACEOF
12195 cat confdefs.h >>conftest.$ac_ext
12196 cat >>conftest.$ac_ext <<_ACEOF
12197 /* end confdefs.h.  */
12198 #include <sys/types.h>
12199 #ifdef HAVE_SYS_SOCKET_H
12200 #include <sys/socket.h>
12201 #endif
12202
12203
12204 int
12205 main ()
12206 {
12207 static struct sockaddr ac_aggr;
12208 if (sizeof ac_aggr.sa_len)
12209 return 0;
12210   ;
12211   return 0;
12212 }
12213 _ACEOF
12214 rm -f conftest.$ac_objext
12215 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12216   (eval $ac_compile) 2>conftest.er1
12217   ac_status=$?
12218   grep -v '^ *+' conftest.er1 >conftest.err
12219   rm -f conftest.er1
12220   cat conftest.err >&5
12221   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12222   (exit $ac_status); } &&
12223          { ac_try='test -z "$ac_c_werror_flag"
12224                          || test ! -s conftest.err'
12225   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12226   (eval $ac_try) 2>&5
12227   ac_status=$?
12228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12229   (exit $ac_status); }; } &&
12230          { ac_try='test -s conftest.$ac_objext'
12231   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12232   (eval $ac_try) 2>&5
12233   ac_status=$?
12234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12235   (exit $ac_status); }; }; then
12236   ac_cv_member_struct_sockaddr_sa_len=yes
12237 else
12238   echo "$as_me: failed program was:" >&5
12239 sed 's/^/| /' conftest.$ac_ext >&5
12240
12241 ac_cv_member_struct_sockaddr_sa_len=no
12242 fi
12243 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12244 fi
12245 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12246 fi
12247 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
12248 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_sa_len" >&6
12249 if test $ac_cv_member_struct_sockaddr_sa_len = yes; then
12250
12251 cat >>confdefs.h <<_ACEOF
12252 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
12253 _ACEOF
12254
12255
12256 fi
12257
12258 echo "$as_me:$LINENO: checking for struct addrinfo" >&5
12259 echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6
12260 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
12261   echo $ECHO_N "(cached) $ECHO_C" >&6
12262 else
12263   cat >conftest.$ac_ext <<_ACEOF
12264 /* confdefs.h.  */
12265 _ACEOF
12266 cat confdefs.h >>conftest.$ac_ext
12267 cat >>conftest.$ac_ext <<_ACEOF
12268 /* end confdefs.h.  */
12269 #include <sys/types.h>
12270 #include <sys/socket.h>
12271 #include <netdb.h>
12272
12273
12274 int
12275 main ()
12276 {
12277 if ((struct addrinfo *) 0)
12278   return 0;
12279 if (sizeof (struct addrinfo))
12280   return 0;
12281   ;
12282   return 0;
12283 }
12284 _ACEOF
12285 rm -f conftest.$ac_objext
12286 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12287   (eval $ac_compile) 2>conftest.er1
12288   ac_status=$?
12289   grep -v '^ *+' conftest.er1 >conftest.err
12290   rm -f conftest.er1
12291   cat conftest.err >&5
12292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12293   (exit $ac_status); } &&
12294          { ac_try='test -z "$ac_c_werror_flag"
12295                          || test ! -s conftest.err'
12296   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12297   (eval $ac_try) 2>&5
12298   ac_status=$?
12299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12300   (exit $ac_status); }; } &&
12301          { ac_try='test -s conftest.$ac_objext'
12302   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12303   (eval $ac_try) 2>&5
12304   ac_status=$?
12305   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12306   (exit $ac_status); }; }; then
12307   ac_cv_type_struct_addrinfo=yes
12308 else
12309   echo "$as_me: failed program was:" >&5
12310 sed 's/^/| /' conftest.$ac_ext >&5
12311
12312 ac_cv_type_struct_addrinfo=no
12313 fi
12314 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12315 fi
12316 echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
12317 echo "${ECHO_T}$ac_cv_type_struct_addrinfo" >&6
12318 if test $ac_cv_type_struct_addrinfo = yes; then
12319
12320 cat >>confdefs.h <<_ACEOF
12321 #define HAVE_STRUCT_ADDRINFO 1
12322 _ACEOF
12323
12324
12325 fi
12326
12327
12328 echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
12329 echo $ECHO_N "checking for struct cmsgcred... $ECHO_C" >&6
12330 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
12331   echo $ECHO_N "(cached) $ECHO_C" >&6
12332 else
12333   cat >conftest.$ac_ext <<_ACEOF
12334 /* confdefs.h.  */
12335 _ACEOF
12336 cat confdefs.h >>conftest.$ac_ext
12337 cat >>conftest.$ac_ext <<_ACEOF
12338 /* end confdefs.h.  */
12339 #include <sys/param.h>
12340 #include <sys/types.h>
12341 #include <sys/socket.h>
12342 #include <sys/ucred.h>
12343
12344 int
12345 main ()
12346 {
12347 if ((struct cmsgcred *) 0)
12348   return 0;
12349 if (sizeof (struct cmsgcred))
12350   return 0;
12351   ;
12352   return 0;
12353 }
12354 _ACEOF
12355 rm -f conftest.$ac_objext
12356 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12357   (eval $ac_compile) 2>conftest.er1
12358   ac_status=$?
12359   grep -v '^ *+' conftest.er1 >conftest.err
12360   rm -f conftest.er1
12361   cat conftest.err >&5
12362   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12363   (exit $ac_status); } &&
12364          { ac_try='test -z "$ac_c_werror_flag"
12365                          || test ! -s conftest.err'
12366   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12367   (eval $ac_try) 2>&5
12368   ac_status=$?
12369   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12370   (exit $ac_status); }; } &&
12371          { ac_try='test -s conftest.$ac_objext'
12372   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12373   (eval $ac_try) 2>&5
12374   ac_status=$?
12375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12376   (exit $ac_status); }; }; then
12377   ac_cv_type_struct_cmsgcred=yes
12378 else
12379   echo "$as_me: failed program was:" >&5
12380 sed 's/^/| /' conftest.$ac_ext >&5
12381
12382 ac_cv_type_struct_cmsgcred=no
12383 fi
12384 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12385 fi
12386 echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
12387 echo "${ECHO_T}$ac_cv_type_struct_cmsgcred" >&6
12388 if test $ac_cv_type_struct_cmsgcred = yes; then
12389
12390 cat >>confdefs.h <<_ACEOF
12391 #define HAVE_STRUCT_CMSGCRED 1
12392 _ACEOF
12393
12394
12395 fi
12396 echo "$as_me:$LINENO: checking for struct fcred" >&5
12397 echo $ECHO_N "checking for struct fcred... $ECHO_C" >&6
12398 if test "${ac_cv_type_struct_fcred+set}" = set; then
12399   echo $ECHO_N "(cached) $ECHO_C" >&6
12400 else
12401   cat >conftest.$ac_ext <<_ACEOF
12402 /* confdefs.h.  */
12403 _ACEOF
12404 cat confdefs.h >>conftest.$ac_ext
12405 cat >>conftest.$ac_ext <<_ACEOF
12406 /* end confdefs.h.  */
12407 #include <sys/param.h>
12408 #include <sys/types.h>
12409 #include <sys/socket.h>
12410 #include <sys/ucred.h>
12411
12412 int
12413 main ()
12414 {
12415 if ((struct fcred *) 0)
12416   return 0;
12417 if (sizeof (struct fcred))
12418   return 0;
12419   ;
12420   return 0;
12421 }
12422 _ACEOF
12423 rm -f conftest.$ac_objext
12424 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12425   (eval $ac_compile) 2>conftest.er1
12426   ac_status=$?
12427   grep -v '^ *+' conftest.er1 >conftest.err
12428   rm -f conftest.er1
12429   cat conftest.err >&5
12430   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12431   (exit $ac_status); } &&
12432          { ac_try='test -z "$ac_c_werror_flag"
12433                          || test ! -s conftest.err'
12434   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12435   (eval $ac_try) 2>&5
12436   ac_status=$?
12437   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12438   (exit $ac_status); }; } &&
12439          { ac_try='test -s conftest.$ac_objext'
12440   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12441   (eval $ac_try) 2>&5
12442   ac_status=$?
12443   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12444   (exit $ac_status); }; }; then
12445   ac_cv_type_struct_fcred=yes
12446 else
12447   echo "$as_me: failed program was:" >&5
12448 sed 's/^/| /' conftest.$ac_ext >&5
12449
12450 ac_cv_type_struct_fcred=no
12451 fi
12452 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12453 fi
12454 echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
12455 echo "${ECHO_T}$ac_cv_type_struct_fcred" >&6
12456 if test $ac_cv_type_struct_fcred = yes; then
12457
12458 cat >>confdefs.h <<_ACEOF
12459 #define HAVE_STRUCT_FCRED 1
12460 _ACEOF
12461
12462
12463 fi
12464 echo "$as_me:$LINENO: checking for struct sockcred" >&5
12465 echo $ECHO_N "checking for struct sockcred... $ECHO_C" >&6
12466 if test "${ac_cv_type_struct_sockcred+set}" = set; then
12467   echo $ECHO_N "(cached) $ECHO_C" >&6
12468 else
12469   cat >conftest.$ac_ext <<_ACEOF
12470 /* confdefs.h.  */
12471 _ACEOF
12472 cat confdefs.h >>conftest.$ac_ext
12473 cat >>conftest.$ac_ext <<_ACEOF
12474 /* end confdefs.h.  */
12475 #include <sys/param.h>
12476 #include <sys/types.h>
12477 #include <sys/socket.h>
12478 #include <sys/ucred.h>
12479
12480 int
12481 main ()
12482 {
12483 if ((struct sockcred *) 0)
12484   return 0;
12485 if (sizeof (struct sockcred))
12486   return 0;
12487   ;
12488   return 0;
12489 }
12490 _ACEOF
12491 rm -f conftest.$ac_objext
12492 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12493   (eval $ac_compile) 2>conftest.er1
12494   ac_status=$?
12495   grep -v '^ *+' conftest.er1 >conftest.err
12496   rm -f conftest.er1
12497   cat conftest.err >&5
12498   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12499   (exit $ac_status); } &&
12500          { ac_try='test -z "$ac_c_werror_flag"
12501                          || test ! -s conftest.err'
12502   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12503   (eval $ac_try) 2>&5
12504   ac_status=$?
12505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12506   (exit $ac_status); }; } &&
12507          { ac_try='test -s conftest.$ac_objext'
12508   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12509   (eval $ac_try) 2>&5
12510   ac_status=$?
12511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12512   (exit $ac_status); }; }; then
12513   ac_cv_type_struct_sockcred=yes
12514 else
12515   echo "$as_me: failed program was:" >&5
12516 sed 's/^/| /' conftest.$ac_ext >&5
12517
12518 ac_cv_type_struct_sockcred=no
12519 fi
12520 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12521 fi
12522 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
12523 echo "${ECHO_T}$ac_cv_type_struct_sockcred" >&6
12524 if test $ac_cv_type_struct_sockcred = yes; then
12525
12526 cat >>confdefs.h <<_ACEOF
12527 #define HAVE_STRUCT_SOCKCRED 1
12528 _ACEOF
12529
12530
12531 fi
12532
12533
12534 echo "$as_me:$LINENO: checking for struct option" >&5
12535 echo $ECHO_N "checking for struct option... $ECHO_C" >&6
12536 if test "${ac_cv_type_struct_option+set}" = set; then
12537   echo $ECHO_N "(cached) $ECHO_C" >&6
12538 else
12539   cat >conftest.$ac_ext <<_ACEOF
12540 /* confdefs.h.  */
12541 _ACEOF
12542 cat confdefs.h >>conftest.$ac_ext
12543 cat >>conftest.$ac_ext <<_ACEOF
12544 /* end confdefs.h.  */
12545 #ifdef HAVE_GETOPT_H
12546 #include <getopt.h>
12547 #endif
12548
12549 int
12550 main ()
12551 {
12552 if ((struct option *) 0)
12553   return 0;
12554 if (sizeof (struct option))
12555   return 0;
12556   ;
12557   return 0;
12558 }
12559 _ACEOF
12560 rm -f conftest.$ac_objext
12561 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12562   (eval $ac_compile) 2>conftest.er1
12563   ac_status=$?
12564   grep -v '^ *+' conftest.er1 >conftest.err
12565   rm -f conftest.er1
12566   cat conftest.err >&5
12567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12568   (exit $ac_status); } &&
12569          { ac_try='test -z "$ac_c_werror_flag"
12570                          || test ! -s conftest.err'
12571   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12572   (eval $ac_try) 2>&5
12573   ac_status=$?
12574   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12575   (exit $ac_status); }; } &&
12576          { ac_try='test -s conftest.$ac_objext'
12577   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12578   (eval $ac_try) 2>&5
12579   ac_status=$?
12580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12581   (exit $ac_status); }; }; then
12582   ac_cv_type_struct_option=yes
12583 else
12584   echo "$as_me: failed program was:" >&5
12585 sed 's/^/| /' conftest.$ac_ext >&5
12586
12587 ac_cv_type_struct_option=no
12588 fi
12589 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12590 fi
12591 echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
12592 echo "${ECHO_T}$ac_cv_type_struct_option" >&6
12593 if test $ac_cv_type_struct_option = yes; then
12594
12595 cat >>confdefs.h <<_ACEOF
12596 #define HAVE_STRUCT_OPTION 1
12597 _ACEOF
12598
12599
12600 fi
12601
12602
12603 if test "$with_zlib" = yes; then
12604   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
12605   # did not).  While we could work around the lack of z_streamp, it
12606   # seems unwise to encourage people to use such old zlib versions...
12607   echo "$as_me:$LINENO: checking for z_streamp" >&5
12608 echo $ECHO_N "checking for z_streamp... $ECHO_C" >&6
12609 if test "${ac_cv_type_z_streamp+set}" = set; then
12610   echo $ECHO_N "(cached) $ECHO_C" >&6
12611 else
12612   cat >conftest.$ac_ext <<_ACEOF
12613 /* confdefs.h.  */
12614 _ACEOF
12615 cat confdefs.h >>conftest.$ac_ext
12616 cat >>conftest.$ac_ext <<_ACEOF
12617 /* end confdefs.h.  */
12618 #include <zlib.h>
12619
12620 int
12621 main ()
12622 {
12623 if ((z_streamp *) 0)
12624   return 0;
12625 if (sizeof (z_streamp))
12626   return 0;
12627   ;
12628   return 0;
12629 }
12630 _ACEOF
12631 rm -f conftest.$ac_objext
12632 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12633   (eval $ac_compile) 2>conftest.er1
12634   ac_status=$?
12635   grep -v '^ *+' conftest.er1 >conftest.err
12636   rm -f conftest.er1
12637   cat conftest.err >&5
12638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12639   (exit $ac_status); } &&
12640          { ac_try='test -z "$ac_c_werror_flag"
12641                          || test ! -s conftest.err'
12642   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12643   (eval $ac_try) 2>&5
12644   ac_status=$?
12645   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12646   (exit $ac_status); }; } &&
12647          { ac_try='test -s conftest.$ac_objext'
12648   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12649   (eval $ac_try) 2>&5
12650   ac_status=$?
12651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12652   (exit $ac_status); }; }; then
12653   ac_cv_type_z_streamp=yes
12654 else
12655   echo "$as_me: failed program was:" >&5
12656 sed 's/^/| /' conftest.$ac_ext >&5
12657
12658 ac_cv_type_z_streamp=no
12659 fi
12660 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12661 fi
12662 echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
12663 echo "${ECHO_T}$ac_cv_type_z_streamp" >&6
12664 if test $ac_cv_type_z_streamp = yes; then
12665   :
12666 else
12667   { { echo "$as_me:$LINENO: error: zlib version is too old
12668 Use --without-zlib to disable zlib support." >&5
12669 echo "$as_me: error: zlib version is too old
12670 Use --without-zlib to disable zlib support." >&2;}
12671    { (exit 1); exit 1; }; }
12672 fi
12673
12674 fi
12675
12676 if test "$with_krb5" = yes; then
12677 # Check for differences between MIT and Heimdal (KTH) releases
12678   echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
12679 echo $ECHO_N "checking for krb5_ticket.enc_part2... $ECHO_C" >&6
12680 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
12681   echo $ECHO_N "(cached) $ECHO_C" >&6
12682 else
12683   cat >conftest.$ac_ext <<_ACEOF
12684 /* confdefs.h.  */
12685 _ACEOF
12686 cat confdefs.h >>conftest.$ac_ext
12687 cat >>conftest.$ac_ext <<_ACEOF
12688 /* end confdefs.h.  */
12689 #include <krb5.h>
12690
12691 int
12692 main ()
12693 {
12694 static krb5_ticket ac_aggr;
12695 if (ac_aggr.enc_part2)
12696 return 0;
12697   ;
12698   return 0;
12699 }
12700 _ACEOF
12701 rm -f conftest.$ac_objext
12702 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12703   (eval $ac_compile) 2>conftest.er1
12704   ac_status=$?
12705   grep -v '^ *+' conftest.er1 >conftest.err
12706   rm -f conftest.er1
12707   cat conftest.err >&5
12708   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12709   (exit $ac_status); } &&
12710          { ac_try='test -z "$ac_c_werror_flag"
12711                          || test ! -s conftest.err'
12712   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12713   (eval $ac_try) 2>&5
12714   ac_status=$?
12715   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12716   (exit $ac_status); }; } &&
12717          { ac_try='test -s conftest.$ac_objext'
12718   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12719   (eval $ac_try) 2>&5
12720   ac_status=$?
12721   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12722   (exit $ac_status); }; }; then
12723   ac_cv_member_krb5_ticket_enc_part2=yes
12724 else
12725   echo "$as_me: failed program was:" >&5
12726 sed 's/^/| /' conftest.$ac_ext >&5
12727
12728 cat >conftest.$ac_ext <<_ACEOF
12729 /* confdefs.h.  */
12730 _ACEOF
12731 cat confdefs.h >>conftest.$ac_ext
12732 cat >>conftest.$ac_ext <<_ACEOF
12733 /* end confdefs.h.  */
12734 #include <krb5.h>
12735
12736 int
12737 main ()
12738 {
12739 static krb5_ticket ac_aggr;
12740 if (sizeof ac_aggr.enc_part2)
12741 return 0;
12742   ;
12743   return 0;
12744 }
12745 _ACEOF
12746 rm -f conftest.$ac_objext
12747 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12748   (eval $ac_compile) 2>conftest.er1
12749   ac_status=$?
12750   grep -v '^ *+' conftest.er1 >conftest.err
12751   rm -f conftest.er1
12752   cat conftest.err >&5
12753   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12754   (exit $ac_status); } &&
12755          { ac_try='test -z "$ac_c_werror_flag"
12756                          || test ! -s conftest.err'
12757   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12758   (eval $ac_try) 2>&5
12759   ac_status=$?
12760   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12761   (exit $ac_status); }; } &&
12762          { ac_try='test -s conftest.$ac_objext'
12763   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12764   (eval $ac_try) 2>&5
12765   ac_status=$?
12766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12767   (exit $ac_status); }; }; then
12768   ac_cv_member_krb5_ticket_enc_part2=yes
12769 else
12770   echo "$as_me: failed program was:" >&5
12771 sed 's/^/| /' conftest.$ac_ext >&5
12772
12773 ac_cv_member_krb5_ticket_enc_part2=no
12774 fi
12775 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12776 fi
12777 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12778 fi
12779 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
12780 echo "${ECHO_T}$ac_cv_member_krb5_ticket_enc_part2" >&6
12781 if test $ac_cv_member_krb5_ticket_enc_part2 = yes; then
12782
12783 cat >>confdefs.h <<_ACEOF
12784 #define HAVE_KRB5_TICKET_ENC_PART2 1
12785 _ACEOF
12786
12787
12788 else
12789   echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
12790 echo $ECHO_N "checking for krb5_ticket.client... $ECHO_C" >&6
12791 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
12792   echo $ECHO_N "(cached) $ECHO_C" >&6
12793 else
12794   cat >conftest.$ac_ext <<_ACEOF
12795 /* confdefs.h.  */
12796 _ACEOF
12797 cat confdefs.h >>conftest.$ac_ext
12798 cat >>conftest.$ac_ext <<_ACEOF
12799 /* end confdefs.h.  */
12800 #include <krb5.h>
12801
12802 int
12803 main ()
12804 {
12805 static krb5_ticket ac_aggr;
12806 if (ac_aggr.client)
12807 return 0;
12808   ;
12809   return 0;
12810 }
12811 _ACEOF
12812 rm -f conftest.$ac_objext
12813 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12814   (eval $ac_compile) 2>conftest.er1
12815   ac_status=$?
12816   grep -v '^ *+' conftest.er1 >conftest.err
12817   rm -f conftest.er1
12818   cat conftest.err >&5
12819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12820   (exit $ac_status); } &&
12821          { ac_try='test -z "$ac_c_werror_flag"
12822                          || test ! -s conftest.err'
12823   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12824   (eval $ac_try) 2>&5
12825   ac_status=$?
12826   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12827   (exit $ac_status); }; } &&
12828          { ac_try='test -s conftest.$ac_objext'
12829   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12830   (eval $ac_try) 2>&5
12831   ac_status=$?
12832   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12833   (exit $ac_status); }; }; then
12834   ac_cv_member_krb5_ticket_client=yes
12835 else
12836   echo "$as_me: failed program was:" >&5
12837 sed 's/^/| /' conftest.$ac_ext >&5
12838
12839 cat >conftest.$ac_ext <<_ACEOF
12840 /* confdefs.h.  */
12841 _ACEOF
12842 cat confdefs.h >>conftest.$ac_ext
12843 cat >>conftest.$ac_ext <<_ACEOF
12844 /* end confdefs.h.  */
12845 #include <krb5.h>
12846
12847 int
12848 main ()
12849 {
12850 static krb5_ticket ac_aggr;
12851 if (sizeof ac_aggr.client)
12852 return 0;
12853   ;
12854   return 0;
12855 }
12856 _ACEOF
12857 rm -f conftest.$ac_objext
12858 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12859   (eval $ac_compile) 2>conftest.er1
12860   ac_status=$?
12861   grep -v '^ *+' conftest.er1 >conftest.err
12862   rm -f conftest.er1
12863   cat conftest.err >&5
12864   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12865   (exit $ac_status); } &&
12866          { ac_try='test -z "$ac_c_werror_flag"
12867                          || test ! -s conftest.err'
12868   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12869   (eval $ac_try) 2>&5
12870   ac_status=$?
12871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12872   (exit $ac_status); }; } &&
12873          { ac_try='test -s conftest.$ac_objext'
12874   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12875   (eval $ac_try) 2>&5
12876   ac_status=$?
12877   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12878   (exit $ac_status); }; }; then
12879   ac_cv_member_krb5_ticket_client=yes
12880 else
12881   echo "$as_me: failed program was:" >&5
12882 sed 's/^/| /' conftest.$ac_ext >&5
12883
12884 ac_cv_member_krb5_ticket_client=no
12885 fi
12886 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12887 fi
12888 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12889 fi
12890 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
12891 echo "${ECHO_T}$ac_cv_member_krb5_ticket_client" >&6
12892 if test $ac_cv_member_krb5_ticket_client = yes; then
12893
12894 cat >>confdefs.h <<_ACEOF
12895 #define HAVE_KRB5_TICKET_CLIENT 1
12896 _ACEOF
12897
12898
12899 else
12900   { { echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
12901 echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
12902    { (exit 1); exit 1; }; }
12903 fi
12904
12905 fi
12906
12907   echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
12908 echo $ECHO_N "checking for krb5_error.text.data... $ECHO_C" >&6
12909 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
12910   echo $ECHO_N "(cached) $ECHO_C" >&6
12911 else
12912   cat >conftest.$ac_ext <<_ACEOF
12913 /* confdefs.h.  */
12914 _ACEOF
12915 cat confdefs.h >>conftest.$ac_ext
12916 cat >>conftest.$ac_ext <<_ACEOF
12917 /* end confdefs.h.  */
12918 #include <krb5.h>
12919
12920 int
12921 main ()
12922 {
12923 static krb5_error ac_aggr;
12924 if (ac_aggr.text.data)
12925 return 0;
12926   ;
12927   return 0;
12928 }
12929 _ACEOF
12930 rm -f conftest.$ac_objext
12931 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12932   (eval $ac_compile) 2>conftest.er1
12933   ac_status=$?
12934   grep -v '^ *+' conftest.er1 >conftest.err
12935   rm -f conftest.er1
12936   cat conftest.err >&5
12937   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12938   (exit $ac_status); } &&
12939          { ac_try='test -z "$ac_c_werror_flag"
12940                          || test ! -s conftest.err'
12941   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12942   (eval $ac_try) 2>&5
12943   ac_status=$?
12944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12945   (exit $ac_status); }; } &&
12946          { ac_try='test -s conftest.$ac_objext'
12947   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12948   (eval $ac_try) 2>&5
12949   ac_status=$?
12950   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12951   (exit $ac_status); }; }; then
12952   ac_cv_member_krb5_error_text_data=yes
12953 else
12954   echo "$as_me: failed program was:" >&5
12955 sed 's/^/| /' conftest.$ac_ext >&5
12956
12957 cat >conftest.$ac_ext <<_ACEOF
12958 /* confdefs.h.  */
12959 _ACEOF
12960 cat confdefs.h >>conftest.$ac_ext
12961 cat >>conftest.$ac_ext <<_ACEOF
12962 /* end confdefs.h.  */
12963 #include <krb5.h>
12964
12965 int
12966 main ()
12967 {
12968 static krb5_error ac_aggr;
12969 if (sizeof ac_aggr.text.data)
12970 return 0;
12971   ;
12972   return 0;
12973 }
12974 _ACEOF
12975 rm -f conftest.$ac_objext
12976 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12977   (eval $ac_compile) 2>conftest.er1
12978   ac_status=$?
12979   grep -v '^ *+' conftest.er1 >conftest.err
12980   rm -f conftest.er1
12981   cat conftest.err >&5
12982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12983   (exit $ac_status); } &&
12984          { ac_try='test -z "$ac_c_werror_flag"
12985                          || test ! -s conftest.err'
12986   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12987   (eval $ac_try) 2>&5
12988   ac_status=$?
12989   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12990   (exit $ac_status); }; } &&
12991          { ac_try='test -s conftest.$ac_objext'
12992   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12993   (eval $ac_try) 2>&5
12994   ac_status=$?
12995   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12996   (exit $ac_status); }; }; then
12997   ac_cv_member_krb5_error_text_data=yes
12998 else
12999   echo "$as_me: failed program was:" >&5
13000 sed 's/^/| /' conftest.$ac_ext >&5
13001
13002 ac_cv_member_krb5_error_text_data=no
13003 fi
13004 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13005 fi
13006 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13007 fi
13008 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
13009 echo "${ECHO_T}$ac_cv_member_krb5_error_text_data" >&6
13010 if test $ac_cv_member_krb5_error_text_data = yes; then
13011
13012 cat >>confdefs.h <<_ACEOF
13013 #define HAVE_KRB5_ERROR_TEXT_DATA 1
13014 _ACEOF
13015
13016
13017 else
13018   echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
13019 echo $ECHO_N "checking for krb5_error.e_data... $ECHO_C" >&6
13020 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
13021   echo $ECHO_N "(cached) $ECHO_C" >&6
13022 else
13023   cat >conftest.$ac_ext <<_ACEOF
13024 /* confdefs.h.  */
13025 _ACEOF
13026 cat confdefs.h >>conftest.$ac_ext
13027 cat >>conftest.$ac_ext <<_ACEOF
13028 /* end confdefs.h.  */
13029 #include <krb5.h>
13030
13031 int
13032 main ()
13033 {
13034 static krb5_error ac_aggr;
13035 if (ac_aggr.e_data)
13036 return 0;
13037   ;
13038   return 0;
13039 }
13040 _ACEOF
13041 rm -f conftest.$ac_objext
13042 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13043   (eval $ac_compile) 2>conftest.er1
13044   ac_status=$?
13045   grep -v '^ *+' conftest.er1 >conftest.err
13046   rm -f conftest.er1
13047   cat conftest.err >&5
13048   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13049   (exit $ac_status); } &&
13050          { ac_try='test -z "$ac_c_werror_flag"
13051                          || test ! -s conftest.err'
13052   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13053   (eval $ac_try) 2>&5
13054   ac_status=$?
13055   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13056   (exit $ac_status); }; } &&
13057          { ac_try='test -s conftest.$ac_objext'
13058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13059   (eval $ac_try) 2>&5
13060   ac_status=$?
13061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13062   (exit $ac_status); }; }; then
13063   ac_cv_member_krb5_error_e_data=yes
13064 else
13065   echo "$as_me: failed program was:" >&5
13066 sed 's/^/| /' conftest.$ac_ext >&5
13067
13068 cat >conftest.$ac_ext <<_ACEOF
13069 /* confdefs.h.  */
13070 _ACEOF
13071 cat confdefs.h >>conftest.$ac_ext
13072 cat >>conftest.$ac_ext <<_ACEOF
13073 /* end confdefs.h.  */
13074 #include <krb5.h>
13075
13076 int
13077 main ()
13078 {
13079 static krb5_error ac_aggr;
13080 if (sizeof ac_aggr.e_data)
13081 return 0;
13082   ;
13083   return 0;
13084 }
13085 _ACEOF
13086 rm -f conftest.$ac_objext
13087 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13088   (eval $ac_compile) 2>conftest.er1
13089   ac_status=$?
13090   grep -v '^ *+' conftest.er1 >conftest.err
13091   rm -f conftest.er1
13092   cat conftest.err >&5
13093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13094   (exit $ac_status); } &&
13095          { ac_try='test -z "$ac_c_werror_flag"
13096                          || test ! -s conftest.err'
13097   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13098   (eval $ac_try) 2>&5
13099   ac_status=$?
13100   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13101   (exit $ac_status); }; } &&
13102          { ac_try='test -s conftest.$ac_objext'
13103   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13104   (eval $ac_try) 2>&5
13105   ac_status=$?
13106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13107   (exit $ac_status); }; }; then
13108   ac_cv_member_krb5_error_e_data=yes
13109 else
13110   echo "$as_me: failed program was:" >&5
13111 sed 's/^/| /' conftest.$ac_ext >&5
13112
13113 ac_cv_member_krb5_error_e_data=no
13114 fi
13115 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13116 fi
13117 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13118 fi
13119 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
13120 echo "${ECHO_T}$ac_cv_member_krb5_error_e_data" >&6
13121 if test $ac_cv_member_krb5_error_e_data = yes; then
13122
13123 cat >>confdefs.h <<_ACEOF
13124 #define HAVE_KRB5_ERROR_E_DATA 1
13125 _ACEOF
13126
13127
13128 else
13129   { { echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
13130 echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
13131    { (exit 1); exit 1; }; }
13132 fi
13133
13134 fi
13135
13136 fi
13137
13138
13139 ##
13140 ## Functions, global variables
13141 ##
13142
13143 echo "$as_me:$LINENO: checking for int timezone" >&5
13144 echo $ECHO_N "checking for int timezone... $ECHO_C" >&6
13145 if test "${pgac_cv_var_int_timezone+set}" = set; then
13146   echo $ECHO_N "(cached) $ECHO_C" >&6
13147 else
13148   cat >conftest.$ac_ext <<_ACEOF
13149 /* confdefs.h.  */
13150 _ACEOF
13151 cat confdefs.h >>conftest.$ac_ext
13152 cat >>conftest.$ac_ext <<_ACEOF
13153 /* end confdefs.h.  */
13154 #include <time.h>
13155 int res;
13156 int
13157 main ()
13158 {
13159 #ifndef __CYGWIN__
13160 res = timezone / 60;
13161 #else
13162 res = _timezone / 60;
13163 #endif
13164   ;
13165   return 0;
13166 }
13167 _ACEOF
13168 rm -f conftest.$ac_objext conftest$ac_exeext
13169 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13170   (eval $ac_link) 2>conftest.er1
13171   ac_status=$?
13172   grep -v '^ *+' conftest.er1 >conftest.err
13173   rm -f conftest.er1
13174   cat conftest.err >&5
13175   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13176   (exit $ac_status); } &&
13177          { ac_try='test -z "$ac_c_werror_flag"
13178                          || test ! -s conftest.err'
13179   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13180   (eval $ac_try) 2>&5
13181   ac_status=$?
13182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13183   (exit $ac_status); }; } &&
13184          { ac_try='test -s conftest$ac_exeext'
13185   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13186   (eval $ac_try) 2>&5
13187   ac_status=$?
13188   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13189   (exit $ac_status); }; }; then
13190   pgac_cv_var_int_timezone=yes
13191 else
13192   echo "$as_me: failed program was:" >&5
13193 sed 's/^/| /' conftest.$ac_ext >&5
13194
13195 pgac_cv_var_int_timezone=no
13196 fi
13197 rm -f conftest.err conftest.$ac_objext \
13198       conftest$ac_exeext conftest.$ac_ext
13199 fi
13200 echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
13201 echo "${ECHO_T}$pgac_cv_var_int_timezone" >&6
13202 if test x"$pgac_cv_var_int_timezone" = xyes ; then
13203
13204 cat >>confdefs.h <<\_ACEOF
13205 #define HAVE_INT_TIMEZONE
13206 _ACEOF
13207
13208 fi
13209 echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
13210 echo $ECHO_N "checking types of arguments for accept()... $ECHO_C" >&6
13211  if test "${ac_cv_func_accept_return+set}" = set; then
13212   echo $ECHO_N "(cached) $ECHO_C" >&6
13213 else
13214    if test "${ac_cv_func_accept_arg1+set}" = set; then
13215   echo $ECHO_N "(cached) $ECHO_C" >&6
13216 else
13217     if test "${ac_cv_func_accept_arg2+set}" = set; then
13218   echo $ECHO_N "(cached) $ECHO_C" >&6
13219 else
13220      if test "${ac_cv_func_accept_arg3+set}" = set; then
13221   echo $ECHO_N "(cached) $ECHO_C" >&6
13222 else
13223       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
13224       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
13225        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
13226         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
13227          cat >conftest.$ac_ext <<_ACEOF
13228 /* confdefs.h.  */
13229 _ACEOF
13230 cat confdefs.h >>conftest.$ac_ext
13231 cat >>conftest.$ac_ext <<_ACEOF
13232 /* end confdefs.h.  */
13233 #ifdef HAVE_SYS_TYPES_H
13234 #include <sys/types.h>
13235 #endif
13236 #ifdef HAVE_SYS_SOCKET_H
13237 #include <sys/socket.h>
13238 #endif
13239 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
13240 int
13241 main ()
13242 {
13243
13244   ;
13245   return 0;
13246 }
13247 _ACEOF
13248 rm -f conftest.$ac_objext
13249 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13250   (eval $ac_compile) 2>conftest.er1
13251   ac_status=$?
13252   grep -v '^ *+' conftest.er1 >conftest.err
13253   rm -f conftest.er1
13254   cat conftest.err >&5
13255   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13256   (exit $ac_status); } &&
13257          { ac_try='test -z "$ac_c_werror_flag"
13258                          || test ! -s conftest.err'
13259   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13260   (eval $ac_try) 2>&5
13261   ac_status=$?
13262   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13263   (exit $ac_status); }; } &&
13264          { ac_try='test -s conftest.$ac_objext'
13265   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13266   (eval $ac_try) 2>&5
13267   ac_status=$?
13268   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13269   (exit $ac_status); }; }; then
13270   ac_not_found=no; break 4
13271 else
13272   echo "$as_me: failed program was:" >&5
13273 sed 's/^/| /' conftest.$ac_ext >&5
13274
13275 ac_not_found=yes
13276 fi
13277 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13278        done
13279       done
13280      done
13281     done
13282     if test "$ac_not_found" = yes; then
13283       { { echo "$as_me:$LINENO: error: could not determine argument types" >&5
13284 echo "$as_me: error: could not determine argument types" >&2;}
13285    { (exit 1); exit 1; }; }
13286     fi
13287     if test "$ac_cv_func_accept_arg3" = "void"; then
13288       ac_cv_func_accept_arg3=int
13289     fi
13290
13291 fi
13292
13293 fi
13294
13295 fi
13296
13297 fi
13298  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
13299 echo "${ECHO_T}$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6
13300
13301 cat >>confdefs.h <<_ACEOF
13302 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
13303 _ACEOF
13304
13305
13306 cat >>confdefs.h <<_ACEOF
13307 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
13308 _ACEOF
13309
13310
13311 cat >>confdefs.h <<_ACEOF
13312 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
13313 _ACEOF
13314
13315
13316 cat >>confdefs.h <<_ACEOF
13317 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
13318 _ACEOF
13319
13320
13321 echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
13322 echo $ECHO_N "checking whether gettimeofday takes only one argument... $ECHO_C" >&6
13323 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
13324   echo $ECHO_N "(cached) $ECHO_C" >&6
13325 else
13326   cat >conftest.$ac_ext <<_ACEOF
13327 /* confdefs.h.  */
13328 _ACEOF
13329 cat confdefs.h >>conftest.$ac_ext
13330 cat >>conftest.$ac_ext <<_ACEOF
13331 /* end confdefs.h.  */
13332 #include <sys/time.h>
13333 int
13334 main ()
13335 {
13336 struct timeval *tp;
13337 struct timezone *tzp;
13338 gettimeofday(tp,tzp);
13339   ;
13340   return 0;
13341 }
13342 _ACEOF
13343 rm -f conftest.$ac_objext
13344 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13345   (eval $ac_compile) 2>conftest.er1
13346   ac_status=$?
13347   grep -v '^ *+' conftest.er1 >conftest.err
13348   rm -f conftest.er1
13349   cat conftest.err >&5
13350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13351   (exit $ac_status); } &&
13352          { ac_try='test -z "$ac_c_werror_flag"
13353                          || test ! -s conftest.err'
13354   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13355   (eval $ac_try) 2>&5
13356   ac_status=$?
13357   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13358   (exit $ac_status); }; } &&
13359          { ac_try='test -s conftest.$ac_objext'
13360   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13361   (eval $ac_try) 2>&5
13362   ac_status=$?
13363   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13364   (exit $ac_status); }; }; then
13365   pgac_cv_func_gettimeofday_1arg=no
13366 else
13367   echo "$as_me: failed program was:" >&5
13368 sed 's/^/| /' conftest.$ac_ext >&5
13369
13370 pgac_cv_func_gettimeofday_1arg=yes
13371 fi
13372 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13373 fi
13374 echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
13375 echo "${ECHO_T}$pgac_cv_func_gettimeofday_1arg" >&6
13376 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
13377
13378 cat >>confdefs.h <<\_ACEOF
13379 #define GETTIMEOFDAY_1ARG
13380 _ACEOF
13381
13382 fi
13383
13384
13385
13386
13387
13388
13389
13390
13391
13392
13393
13394
13395
13396
13397
13398
13399
13400
13401
13402
13403
13404
13405
13406 for ac_func in cbrt dlopen fcvt fdatasync getpeereid getrlimit memmove poll pstat readlink setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
13407 do
13408 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13409 echo "$as_me:$LINENO: checking for $ac_func" >&5
13410 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13411 if eval "test \"\${$as_ac_var+set}\" = set"; then
13412   echo $ECHO_N "(cached) $ECHO_C" >&6
13413 else
13414   cat >conftest.$ac_ext <<_ACEOF
13415 /* confdefs.h.  */
13416 _ACEOF
13417 cat confdefs.h >>conftest.$ac_ext
13418 cat >>conftest.$ac_ext <<_ACEOF
13419 /* end confdefs.h.  */
13420 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13421    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13422 #define $ac_func innocuous_$ac_func
13423
13424 /* System header to define __stub macros and hopefully few prototypes,
13425     which can conflict with char $ac_func (); below.
13426     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13427     <limits.h> exists even on freestanding compilers.  */
13428
13429 #ifdef __STDC__
13430 # include <limits.h>
13431 #else
13432 # include <assert.h>
13433 #endif
13434
13435 #undef $ac_func
13436
13437 /* Override any gcc2 internal prototype to avoid an error.  */
13438 #ifdef __cplusplus
13439 extern "C"
13440 {
13441 #endif
13442 /* We use char because int might match the return type of a gcc2
13443    builtin and then its argument prototype would still apply.  */
13444 char $ac_func ();
13445 /* The GNU C library defines this for functions which it implements
13446     to always fail with ENOSYS.  Some functions are actually named
13447     something starting with __ and the normal name is an alias.  */
13448 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13449 choke me
13450 #else
13451 char (*f) () = $ac_func;
13452 #endif
13453 #ifdef __cplusplus
13454 }
13455 #endif
13456
13457 int
13458 main ()
13459 {
13460 return f != $ac_func;
13461   ;
13462   return 0;
13463 }
13464 _ACEOF
13465 rm -f conftest.$ac_objext conftest$ac_exeext
13466 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13467   (eval $ac_link) 2>conftest.er1
13468   ac_status=$?
13469   grep -v '^ *+' conftest.er1 >conftest.err
13470   rm -f conftest.er1
13471   cat conftest.err >&5
13472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13473   (exit $ac_status); } &&
13474          { ac_try='test -z "$ac_c_werror_flag"
13475                          || test ! -s conftest.err'
13476   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13477   (eval $ac_try) 2>&5
13478   ac_status=$?
13479   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13480   (exit $ac_status); }; } &&
13481          { ac_try='test -s conftest$ac_exeext'
13482   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13483   (eval $ac_try) 2>&5
13484   ac_status=$?
13485   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13486   (exit $ac_status); }; }; then
13487   eval "$as_ac_var=yes"
13488 else
13489   echo "$as_me: failed program was:" >&5
13490 sed 's/^/| /' conftest.$ac_ext >&5
13491
13492 eval "$as_ac_var=no"
13493 fi
13494 rm -f conftest.err conftest.$ac_objext \
13495       conftest$ac_exeext conftest.$ac_ext
13496 fi
13497 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13498 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13499 if test `eval echo '${'$as_ac_var'}'` = yes; then
13500   cat >>confdefs.h <<_ACEOF
13501 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13502 _ACEOF
13503
13504 fi
13505 done
13506
13507
13508 echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
13509 echo $ECHO_N "checking whether fdatasync is declared... $ECHO_C" >&6
13510 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
13511   echo $ECHO_N "(cached) $ECHO_C" >&6
13512 else
13513   cat >conftest.$ac_ext <<_ACEOF
13514 /* confdefs.h.  */
13515 _ACEOF
13516 cat confdefs.h >>conftest.$ac_ext
13517 cat >>conftest.$ac_ext <<_ACEOF
13518 /* end confdefs.h.  */
13519 #include <unistd.h>
13520
13521 int
13522 main ()
13523 {
13524 #ifndef fdatasync
13525   char *p = (char *) fdatasync;
13526 #endif
13527
13528   ;
13529   return 0;
13530 }
13531 _ACEOF
13532 rm -f conftest.$ac_objext
13533 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13534   (eval $ac_compile) 2>conftest.er1
13535   ac_status=$?
13536   grep -v '^ *+' conftest.er1 >conftest.err
13537   rm -f conftest.er1
13538   cat conftest.err >&5
13539   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13540   (exit $ac_status); } &&
13541          { ac_try='test -z "$ac_c_werror_flag"
13542                          || test ! -s conftest.err'
13543   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13544   (eval $ac_try) 2>&5
13545   ac_status=$?
13546   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13547   (exit $ac_status); }; } &&
13548          { ac_try='test -s conftest.$ac_objext'
13549   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13550   (eval $ac_try) 2>&5
13551   ac_status=$?
13552   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13553   (exit $ac_status); }; }; then
13554   ac_cv_have_decl_fdatasync=yes
13555 else
13556   echo "$as_me: failed program was:" >&5
13557 sed 's/^/| /' conftest.$ac_ext >&5
13558
13559 ac_cv_have_decl_fdatasync=no
13560 fi
13561 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13562 fi
13563 echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
13564 echo "${ECHO_T}$ac_cv_have_decl_fdatasync" >&6
13565 if test $ac_cv_have_decl_fdatasync = yes; then
13566
13567 cat >>confdefs.h <<_ACEOF
13568 #define HAVE_DECL_FDATASYNC 1
13569 _ACEOF
13570
13571
13572 else
13573   cat >>confdefs.h <<_ACEOF
13574 #define HAVE_DECL_FDATASYNC 0
13575 _ACEOF
13576
13577
13578 fi
13579
13580
13581 echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
13582 echo $ECHO_N "checking whether posix_fadvise is declared... $ECHO_C" >&6
13583 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
13584   echo $ECHO_N "(cached) $ECHO_C" >&6
13585 else
13586   cat >conftest.$ac_ext <<_ACEOF
13587 /* confdefs.h.  */
13588 _ACEOF
13589 cat confdefs.h >>conftest.$ac_ext
13590 cat >>conftest.$ac_ext <<_ACEOF
13591 /* end confdefs.h.  */
13592 #include <fcntl.h>
13593
13594 int
13595 main ()
13596 {
13597 #ifndef posix_fadvise
13598   char *p = (char *) posix_fadvise;
13599 #endif
13600
13601   ;
13602   return 0;
13603 }
13604 _ACEOF
13605 rm -f conftest.$ac_objext
13606 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13607   (eval $ac_compile) 2>conftest.er1
13608   ac_status=$?
13609   grep -v '^ *+' conftest.er1 >conftest.err
13610   rm -f conftest.er1
13611   cat conftest.err >&5
13612   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13613   (exit $ac_status); } &&
13614          { ac_try='test -z "$ac_c_werror_flag"
13615                          || test ! -s conftest.err'
13616   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13617   (eval $ac_try) 2>&5
13618   ac_status=$?
13619   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13620   (exit $ac_status); }; } &&
13621          { ac_try='test -s conftest.$ac_objext'
13622   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13623   (eval $ac_try) 2>&5
13624   ac_status=$?
13625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13626   (exit $ac_status); }; }; then
13627   ac_cv_have_decl_posix_fadvise=yes
13628 else
13629   echo "$as_me: failed program was:" >&5
13630 sed 's/^/| /' conftest.$ac_ext >&5
13631
13632 ac_cv_have_decl_posix_fadvise=no
13633 fi
13634 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13635 fi
13636 echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
13637 echo "${ECHO_T}$ac_cv_have_decl_posix_fadvise" >&6
13638 if test $ac_cv_have_decl_posix_fadvise = yes; then
13639
13640 cat >>confdefs.h <<_ACEOF
13641 #define HAVE_DECL_POSIX_FADVISE 1
13642 _ACEOF
13643
13644
13645 else
13646   cat >>confdefs.h <<_ACEOF
13647 #define HAVE_DECL_POSIX_FADVISE 0
13648 _ACEOF
13649
13650
13651 fi
13652
13653
13654 echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
13655 echo $ECHO_N "checking whether strlcpy is declared... $ECHO_C" >&6
13656 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
13657   echo $ECHO_N "(cached) $ECHO_C" >&6
13658 else
13659   cat >conftest.$ac_ext <<_ACEOF
13660 /* confdefs.h.  */
13661 _ACEOF
13662 cat confdefs.h >>conftest.$ac_ext
13663 cat >>conftest.$ac_ext <<_ACEOF
13664 /* end confdefs.h.  */
13665 $ac_includes_default
13666 int
13667 main ()
13668 {
13669 #ifndef strlcpy
13670   char *p = (char *) strlcpy;
13671 #endif
13672
13673   ;
13674   return 0;
13675 }
13676 _ACEOF
13677 rm -f conftest.$ac_objext
13678 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13679   (eval $ac_compile) 2>conftest.er1
13680   ac_status=$?
13681   grep -v '^ *+' conftest.er1 >conftest.err
13682   rm -f conftest.er1
13683   cat conftest.err >&5
13684   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13685   (exit $ac_status); } &&
13686          { ac_try='test -z "$ac_c_werror_flag"
13687                          || test ! -s conftest.err'
13688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13689   (eval $ac_try) 2>&5
13690   ac_status=$?
13691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13692   (exit $ac_status); }; } &&
13693          { ac_try='test -s conftest.$ac_objext'
13694   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13695   (eval $ac_try) 2>&5
13696   ac_status=$?
13697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13698   (exit $ac_status); }; }; then
13699   ac_cv_have_decl_strlcpy=yes
13700 else
13701   echo "$as_me: failed program was:" >&5
13702 sed 's/^/| /' conftest.$ac_ext >&5
13703
13704 ac_cv_have_decl_strlcpy=no
13705 fi
13706 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13707 fi
13708 echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
13709 echo "${ECHO_T}$ac_cv_have_decl_strlcpy" >&6
13710 if test $ac_cv_have_decl_strlcpy = yes; then
13711
13712 cat >>confdefs.h <<_ACEOF
13713 #define HAVE_DECL_STRLCPY 1
13714 _ACEOF
13715
13716
13717 else
13718   cat >>confdefs.h <<_ACEOF
13719 #define HAVE_DECL_STRLCPY 0
13720 _ACEOF
13721
13722
13723 fi
13724
13725
13726 # This is probably only present on Darwin, but may as well check always
13727 echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
13728 echo $ECHO_N "checking whether F_FULLFSYNC is declared... $ECHO_C" >&6
13729 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
13730   echo $ECHO_N "(cached) $ECHO_C" >&6
13731 else
13732   cat >conftest.$ac_ext <<_ACEOF
13733 /* confdefs.h.  */
13734 _ACEOF
13735 cat confdefs.h >>conftest.$ac_ext
13736 cat >>conftest.$ac_ext <<_ACEOF
13737 /* end confdefs.h.  */
13738 #include <fcntl.h>
13739
13740 int
13741 main ()
13742 {
13743 #ifndef F_FULLFSYNC
13744   char *p = (char *) F_FULLFSYNC;
13745 #endif
13746
13747   ;
13748   return 0;
13749 }
13750 _ACEOF
13751 rm -f conftest.$ac_objext
13752 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13753   (eval $ac_compile) 2>conftest.er1
13754   ac_status=$?
13755   grep -v '^ *+' conftest.er1 >conftest.err
13756   rm -f conftest.er1
13757   cat conftest.err >&5
13758   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13759   (exit $ac_status); } &&
13760          { ac_try='test -z "$ac_c_werror_flag"
13761                          || test ! -s conftest.err'
13762   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13763   (eval $ac_try) 2>&5
13764   ac_status=$?
13765   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13766   (exit $ac_status); }; } &&
13767          { ac_try='test -s conftest.$ac_objext'
13768   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13769   (eval $ac_try) 2>&5
13770   ac_status=$?
13771   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13772   (exit $ac_status); }; }; then
13773   ac_cv_have_decl_F_FULLFSYNC=yes
13774 else
13775   echo "$as_me: failed program was:" >&5
13776 sed 's/^/| /' conftest.$ac_ext >&5
13777
13778 ac_cv_have_decl_F_FULLFSYNC=no
13779 fi
13780 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13781 fi
13782 echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
13783 echo "${ECHO_T}$ac_cv_have_decl_F_FULLFSYNC" >&6
13784 if test $ac_cv_have_decl_F_FULLFSYNC = yes; then
13785
13786 cat >>confdefs.h <<_ACEOF
13787 #define HAVE_DECL_F_FULLFSYNC 1
13788 _ACEOF
13789
13790
13791 else
13792   cat >>confdefs.h <<_ACEOF
13793 #define HAVE_DECL_F_FULLFSYNC 0
13794 _ACEOF
13795
13796
13797 fi
13798
13799
13800
13801 HAVE_IPV6=no
13802 echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
13803 echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6
13804 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
13805   echo $ECHO_N "(cached) $ECHO_C" >&6
13806 else
13807   cat >conftest.$ac_ext <<_ACEOF
13808 /* confdefs.h.  */
13809 _ACEOF
13810 cat confdefs.h >>conftest.$ac_ext
13811 cat >>conftest.$ac_ext <<_ACEOF
13812 /* end confdefs.h.  */
13813 $ac_includes_default
13814 #include <netinet/in.h>
13815
13816 int
13817 main ()
13818 {
13819 if ((struct sockaddr_in6 *) 0)
13820   return 0;
13821 if (sizeof (struct sockaddr_in6))
13822   return 0;
13823   ;
13824   return 0;
13825 }
13826 _ACEOF
13827 rm -f conftest.$ac_objext
13828 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13829   (eval $ac_compile) 2>conftest.er1
13830   ac_status=$?
13831   grep -v '^ *+' conftest.er1 >conftest.err
13832   rm -f conftest.er1
13833   cat conftest.err >&5
13834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13835   (exit $ac_status); } &&
13836          { ac_try='test -z "$ac_c_werror_flag"
13837                          || test ! -s conftest.err'
13838   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13839   (eval $ac_try) 2>&5
13840   ac_status=$?
13841   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13842   (exit $ac_status); }; } &&
13843          { ac_try='test -s conftest.$ac_objext'
13844   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13845   (eval $ac_try) 2>&5
13846   ac_status=$?
13847   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13848   (exit $ac_status); }; }; then
13849   ac_cv_type_struct_sockaddr_in6=yes
13850 else
13851   echo "$as_me: failed program was:" >&5
13852 sed 's/^/| /' conftest.$ac_ext >&5
13853
13854 ac_cv_type_struct_sockaddr_in6=no
13855 fi
13856 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
13857 fi
13858 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
13859 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6
13860 if test $ac_cv_type_struct_sockaddr_in6 = yes; then
13861
13862 cat >>confdefs.h <<\_ACEOF
13863 #define HAVE_IPV6 1
13864 _ACEOF
13865
13866          HAVE_IPV6=yes
13867 fi
13868
13869
13870
13871 echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
13872 echo $ECHO_N "checking for PS_STRINGS... $ECHO_C" >&6
13873 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
13874   echo $ECHO_N "(cached) $ECHO_C" >&6
13875 else
13876   cat >conftest.$ac_ext <<_ACEOF
13877 /* confdefs.h.  */
13878 _ACEOF
13879 cat confdefs.h >>conftest.$ac_ext
13880 cat >>conftest.$ac_ext <<_ACEOF
13881 /* end confdefs.h.  */
13882 #include <machine/vmparam.h>
13883 #include <sys/exec.h>
13884
13885 int
13886 main ()
13887 {
13888 PS_STRINGS->ps_nargvstr = 1;
13889 PS_STRINGS->ps_argvstr = "foo";
13890   ;
13891   return 0;
13892 }
13893 _ACEOF
13894 rm -f conftest.$ac_objext conftest$ac_exeext
13895 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13896   (eval $ac_link) 2>conftest.er1
13897   ac_status=$?
13898   grep -v '^ *+' conftest.er1 >conftest.err
13899   rm -f conftest.er1
13900   cat conftest.err >&5
13901   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13902   (exit $ac_status); } &&
13903          { ac_try='test -z "$ac_c_werror_flag"
13904                          || test ! -s conftest.err'
13905   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13906   (eval $ac_try) 2>&5
13907   ac_status=$?
13908   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13909   (exit $ac_status); }; } &&
13910          { ac_try='test -s conftest$ac_exeext'
13911   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13912   (eval $ac_try) 2>&5
13913   ac_status=$?
13914   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13915   (exit $ac_status); }; }; then
13916   pgac_cv_var_PS_STRINGS=yes
13917 else
13918   echo "$as_me: failed program was:" >&5
13919 sed 's/^/| /' conftest.$ac_ext >&5
13920
13921 pgac_cv_var_PS_STRINGS=no
13922 fi
13923 rm -f conftest.err conftest.$ac_objext \
13924       conftest$ac_exeext conftest.$ac_ext
13925 fi
13926 echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
13927 echo "${ECHO_T}$pgac_cv_var_PS_STRINGS" >&6
13928 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
13929
13930 cat >>confdefs.h <<\_ACEOF
13931 #define HAVE_PS_STRINGS
13932 _ACEOF
13933
13934 fi
13935
13936
13937 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
13938 # is missing.  Yes, there are machines that have only one.  We may
13939 # also decide to use snprintf.c if snprintf() is present but does not
13940 # have all the features we need --- see below.
13941
13942 if test "$PORTNAME" = "win32"; then
13943   # Win32 gets snprintf.c built unconditionally.
13944   #
13945   # To properly translate all NLS languages strings, we must support the
13946   # *printf() %$ format, which allows *printf() arguments to be selected
13947   # by position in the translated string.
13948   #
13949   # libintl versions < 0.13 use the native *printf() functions, and Win32
13950   # *printf() doesn't understand %$, so we must use our /port versions,
13951   # which do understand %$. libintl versions >= 0.13 include their own
13952   # *printf versions on Win32.  The libintl 0.13 release note text is:
13953   #
13954   #   C format strings with positions, as they arise when a translator
13955   #   needs to reorder a sentence, are now supported on all platforms.
13956   #   On those few platforms (NetBSD and Woe32) for which the native
13957   #   printf()/fprintf()/... functions don't support such format
13958   #   strings, replacements are provided through <libintl.h>.
13959   #
13960   # We could use libintl >= 0.13's *printf() if we were sure that we had
13961   # a litint >= 0.13 at runtime, but seeing that there is no clean way
13962   # to guarantee that, it is best to just use our own, so we are sure to
13963   # get %$ support. In include/port.h we disable the *printf() macros
13964   # that might have been defined by libintl.
13965   #
13966   # We do this unconditionally whether NLS is used or not so we are sure
13967   # that all Win32 libraries and binaries behave the same.
13968   pgac_need_repl_snprintf=yes
13969 else
13970   pgac_need_repl_snprintf=no
13971
13972 for ac_func in snprintf
13973 do
13974 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13975 echo "$as_me:$LINENO: checking for $ac_func" >&5
13976 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13977 if eval "test \"\${$as_ac_var+set}\" = set"; then
13978   echo $ECHO_N "(cached) $ECHO_C" >&6
13979 else
13980   cat >conftest.$ac_ext <<_ACEOF
13981 /* confdefs.h.  */
13982 _ACEOF
13983 cat confdefs.h >>conftest.$ac_ext
13984 cat >>conftest.$ac_ext <<_ACEOF
13985 /* end confdefs.h.  */
13986 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13987    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13988 #define $ac_func innocuous_$ac_func
13989
13990 /* System header to define __stub macros and hopefully few prototypes,
13991     which can conflict with char $ac_func (); below.
13992     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13993     <limits.h> exists even on freestanding compilers.  */
13994
13995 #ifdef __STDC__
13996 # include <limits.h>
13997 #else
13998 # include <assert.h>
13999 #endif
14000
14001 #undef $ac_func
14002
14003 /* Override any gcc2 internal prototype to avoid an error.  */
14004 #ifdef __cplusplus
14005 extern "C"
14006 {
14007 #endif
14008 /* We use char because int might match the return type of a gcc2
14009    builtin and then its argument prototype would still apply.  */
14010 char $ac_func ();
14011 /* The GNU C library defines this for functions which it implements
14012     to always fail with ENOSYS.  Some functions are actually named
14013     something starting with __ and the normal name is an alias.  */
14014 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14015 choke me
14016 #else
14017 char (*f) () = $ac_func;
14018 #endif
14019 #ifdef __cplusplus
14020 }
14021 #endif
14022
14023 int
14024 main ()
14025 {
14026 return f != $ac_func;
14027   ;
14028   return 0;
14029 }
14030 _ACEOF
14031 rm -f conftest.$ac_objext conftest$ac_exeext
14032 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14033   (eval $ac_link) 2>conftest.er1
14034   ac_status=$?
14035   grep -v '^ *+' conftest.er1 >conftest.err
14036   rm -f conftest.er1
14037   cat conftest.err >&5
14038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14039   (exit $ac_status); } &&
14040          { ac_try='test -z "$ac_c_werror_flag"
14041                          || test ! -s conftest.err'
14042   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14043   (eval $ac_try) 2>&5
14044   ac_status=$?
14045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14046   (exit $ac_status); }; } &&
14047          { ac_try='test -s conftest$ac_exeext'
14048   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14049   (eval $ac_try) 2>&5
14050   ac_status=$?
14051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14052   (exit $ac_status); }; }; then
14053   eval "$as_ac_var=yes"
14054 else
14055   echo "$as_me: failed program was:" >&5
14056 sed 's/^/| /' conftest.$ac_ext >&5
14057
14058 eval "$as_ac_var=no"
14059 fi
14060 rm -f conftest.err conftest.$ac_objext \
14061       conftest$ac_exeext conftest.$ac_ext
14062 fi
14063 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14064 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14065 if test `eval echo '${'$as_ac_var'}'` = yes; then
14066   cat >>confdefs.h <<_ACEOF
14067 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14068 _ACEOF
14069
14070 else
14071   pgac_need_repl_snprintf=yes
14072 fi
14073 done
14074
14075
14076 for ac_func in vsnprintf
14077 do
14078 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14079 echo "$as_me:$LINENO: checking for $ac_func" >&5
14080 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14081 if eval "test \"\${$as_ac_var+set}\" = set"; then
14082   echo $ECHO_N "(cached) $ECHO_C" >&6
14083 else
14084   cat >conftest.$ac_ext <<_ACEOF
14085 /* confdefs.h.  */
14086 _ACEOF
14087 cat confdefs.h >>conftest.$ac_ext
14088 cat >>conftest.$ac_ext <<_ACEOF
14089 /* end confdefs.h.  */
14090 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14091    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14092 #define $ac_func innocuous_$ac_func
14093
14094 /* System header to define __stub macros and hopefully few prototypes,
14095     which can conflict with char $ac_func (); below.
14096     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14097     <limits.h> exists even on freestanding compilers.  */
14098
14099 #ifdef __STDC__
14100 # include <limits.h>
14101 #else
14102 # include <assert.h>
14103 #endif
14104
14105 #undef $ac_func
14106
14107 /* Override any gcc2 internal prototype to avoid an error.  */
14108 #ifdef __cplusplus
14109 extern "C"
14110 {
14111 #endif
14112 /* We use char because int might match the return type of a gcc2
14113    builtin and then its argument prototype would still apply.  */
14114 char $ac_func ();
14115 /* The GNU C library defines this for functions which it implements
14116     to always fail with ENOSYS.  Some functions are actually named
14117     something starting with __ and the normal name is an alias.  */
14118 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14119 choke me
14120 #else
14121 char (*f) () = $ac_func;
14122 #endif
14123 #ifdef __cplusplus
14124 }
14125 #endif
14126
14127 int
14128 main ()
14129 {
14130 return f != $ac_func;
14131   ;
14132   return 0;
14133 }
14134 _ACEOF
14135 rm -f conftest.$ac_objext conftest$ac_exeext
14136 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14137   (eval $ac_link) 2>conftest.er1
14138   ac_status=$?
14139   grep -v '^ *+' conftest.er1 >conftest.err
14140   rm -f conftest.er1
14141   cat conftest.err >&5
14142   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14143   (exit $ac_status); } &&
14144          { ac_try='test -z "$ac_c_werror_flag"
14145                          || test ! -s conftest.err'
14146   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14147   (eval $ac_try) 2>&5
14148   ac_status=$?
14149   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14150   (exit $ac_status); }; } &&
14151          { ac_try='test -s conftest$ac_exeext'
14152   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14153   (eval $ac_try) 2>&5
14154   ac_status=$?
14155   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14156   (exit $ac_status); }; }; then
14157   eval "$as_ac_var=yes"
14158 else
14159   echo "$as_me: failed program was:" >&5
14160 sed 's/^/| /' conftest.$ac_ext >&5
14161
14162 eval "$as_ac_var=no"
14163 fi
14164 rm -f conftest.err conftest.$ac_objext \
14165       conftest$ac_exeext conftest.$ac_ext
14166 fi
14167 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14168 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14169 if test `eval echo '${'$as_ac_var'}'` = yes; then
14170   cat >>confdefs.h <<_ACEOF
14171 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14172 _ACEOF
14173
14174 else
14175   pgac_need_repl_snprintf=yes
14176 fi
14177 done
14178
14179 fi
14180
14181
14182 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
14183 # include/c.h will provide declarations.  Note this is a separate test
14184 # from whether the functions exist in the C library --- there are
14185 # systems that have the functions but don't bother to declare them :-(
14186
14187 echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
14188 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6
14189 if test "${ac_cv_have_decl_snprintf+set}" = set; then
14190   echo $ECHO_N "(cached) $ECHO_C" >&6
14191 else
14192   cat >conftest.$ac_ext <<_ACEOF
14193 /* confdefs.h.  */
14194 _ACEOF
14195 cat confdefs.h >>conftest.$ac_ext
14196 cat >>conftest.$ac_ext <<_ACEOF
14197 /* end confdefs.h.  */
14198 $ac_includes_default
14199 int
14200 main ()
14201 {
14202 #ifndef snprintf
14203   char *p = (char *) snprintf;
14204 #endif
14205
14206   ;
14207   return 0;
14208 }
14209 _ACEOF
14210 rm -f conftest.$ac_objext
14211 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14212   (eval $ac_compile) 2>conftest.er1
14213   ac_status=$?
14214   grep -v '^ *+' conftest.er1 >conftest.err
14215   rm -f conftest.er1
14216   cat conftest.err >&5
14217   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14218   (exit $ac_status); } &&
14219          { ac_try='test -z "$ac_c_werror_flag"
14220                          || test ! -s conftest.err'
14221   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14222   (eval $ac_try) 2>&5
14223   ac_status=$?
14224   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14225   (exit $ac_status); }; } &&
14226          { ac_try='test -s conftest.$ac_objext'
14227   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14228   (eval $ac_try) 2>&5
14229   ac_status=$?
14230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14231   (exit $ac_status); }; }; then
14232   ac_cv_have_decl_snprintf=yes
14233 else
14234   echo "$as_me: failed program was:" >&5
14235 sed 's/^/| /' conftest.$ac_ext >&5
14236
14237 ac_cv_have_decl_snprintf=no
14238 fi
14239 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14240 fi
14241 echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
14242 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6
14243 if test $ac_cv_have_decl_snprintf = yes; then
14244
14245 cat >>confdefs.h <<_ACEOF
14246 #define HAVE_DECL_SNPRINTF 1
14247 _ACEOF
14248
14249
14250 else
14251   cat >>confdefs.h <<_ACEOF
14252 #define HAVE_DECL_SNPRINTF 0
14253 _ACEOF
14254
14255
14256 fi
14257 echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
14258 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6
14259 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
14260   echo $ECHO_N "(cached) $ECHO_C" >&6
14261 else
14262   cat >conftest.$ac_ext <<_ACEOF
14263 /* confdefs.h.  */
14264 _ACEOF
14265 cat confdefs.h >>conftest.$ac_ext
14266 cat >>conftest.$ac_ext <<_ACEOF
14267 /* end confdefs.h.  */
14268 $ac_includes_default
14269 int
14270 main ()
14271 {
14272 #ifndef vsnprintf
14273   char *p = (char *) vsnprintf;
14274 #endif
14275
14276   ;
14277   return 0;
14278 }
14279 _ACEOF
14280 rm -f conftest.$ac_objext
14281 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14282   (eval $ac_compile) 2>conftest.er1
14283   ac_status=$?
14284   grep -v '^ *+' conftest.er1 >conftest.err
14285   rm -f conftest.er1
14286   cat conftest.err >&5
14287   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14288   (exit $ac_status); } &&
14289          { ac_try='test -z "$ac_c_werror_flag"
14290                          || test ! -s conftest.err'
14291   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14292   (eval $ac_try) 2>&5
14293   ac_status=$?
14294   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14295   (exit $ac_status); }; } &&
14296          { ac_try='test -s conftest.$ac_objext'
14297   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14298   (eval $ac_try) 2>&5
14299   ac_status=$?
14300   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14301   (exit $ac_status); }; }; then
14302   ac_cv_have_decl_vsnprintf=yes
14303 else
14304   echo "$as_me: failed program was:" >&5
14305 sed 's/^/| /' conftest.$ac_ext >&5
14306
14307 ac_cv_have_decl_vsnprintf=no
14308 fi
14309 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
14310 fi
14311 echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
14312 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6
14313 if test $ac_cv_have_decl_vsnprintf = yes; then
14314
14315 cat >>confdefs.h <<_ACEOF
14316 #define HAVE_DECL_VSNPRINTF 1
14317 _ACEOF
14318
14319
14320 else
14321   cat >>confdefs.h <<_ACEOF
14322 #define HAVE_DECL_VSNPRINTF 0
14323 _ACEOF
14324
14325
14326 fi
14327
14328
14329
14330
14331 echo "$as_me:$LINENO: checking for isinf" >&5
14332 echo $ECHO_N "checking for isinf... $ECHO_C" >&6
14333 if test "${ac_cv_func_isinf+set}" = set; then
14334   echo $ECHO_N "(cached) $ECHO_C" >&6
14335 else
14336   cat >conftest.$ac_ext <<_ACEOF
14337 /* confdefs.h.  */
14338 _ACEOF
14339 cat confdefs.h >>conftest.$ac_ext
14340 cat >>conftest.$ac_ext <<_ACEOF
14341 /* end confdefs.h.  */
14342
14343 #include <math.h>
14344 double glob_double;
14345
14346 int
14347 main ()
14348 {
14349 return isinf(glob_double) ? 0 : 1;
14350   ;
14351   return 0;
14352 }
14353 _ACEOF
14354 rm -f conftest.$ac_objext conftest$ac_exeext
14355 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14356   (eval $ac_link) 2>conftest.er1
14357   ac_status=$?
14358   grep -v '^ *+' conftest.er1 >conftest.err
14359   rm -f conftest.er1
14360   cat conftest.err >&5
14361   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14362   (exit $ac_status); } &&
14363          { ac_try='test -z "$ac_c_werror_flag"
14364                          || test ! -s conftest.err'
14365   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14366   (eval $ac_try) 2>&5
14367   ac_status=$?
14368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14369   (exit $ac_status); }; } &&
14370          { ac_try='test -s conftest$ac_exeext'
14371   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14372   (eval $ac_try) 2>&5
14373   ac_status=$?
14374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14375   (exit $ac_status); }; }; then
14376   ac_cv_func_isinf=yes
14377 else
14378   echo "$as_me: failed program was:" >&5
14379 sed 's/^/| /' conftest.$ac_ext >&5
14380
14381 ac_cv_func_isinf=no
14382 fi
14383 rm -f conftest.err conftest.$ac_objext \
14384       conftest$ac_exeext conftest.$ac_ext
14385 fi
14386 echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
14387 echo "${ECHO_T}$ac_cv_func_isinf" >&6
14388
14389 if test $ac_cv_func_isinf = yes ; then
14390
14391 cat >>confdefs.h <<\_ACEOF
14392 #define HAVE_ISINF 1
14393 _ACEOF
14394
14395 else
14396   case $LIBOBJS in
14397     "isinf.$ac_objext"   | \
14398   *" isinf.$ac_objext"   | \
14399     "isinf.$ac_objext "* | \
14400   *" isinf.$ac_objext "* ) ;;
14401   *) LIBOBJS="$LIBOBJS isinf.$ac_objext" ;;
14402 esac
14403
14404   # Look for a way to implement a substitute for isinf()
14405
14406
14407
14408
14409 for ac_func in fpclass fp_class fp_class_d class
14410 do
14411 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14412 echo "$as_me:$LINENO: checking for $ac_func" >&5
14413 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14414 if eval "test \"\${$as_ac_var+set}\" = set"; then
14415   echo $ECHO_N "(cached) $ECHO_C" >&6
14416 else
14417   cat >conftest.$ac_ext <<_ACEOF
14418 /* confdefs.h.  */
14419 _ACEOF
14420 cat confdefs.h >>conftest.$ac_ext
14421 cat >>conftest.$ac_ext <<_ACEOF
14422 /* end confdefs.h.  */
14423 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14424    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14425 #define $ac_func innocuous_$ac_func
14426
14427 /* System header to define __stub macros and hopefully few prototypes,
14428     which can conflict with char $ac_func (); below.
14429     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14430     <limits.h> exists even on freestanding compilers.  */
14431
14432 #ifdef __STDC__
14433 # include <limits.h>
14434 #else
14435 # include <assert.h>
14436 #endif
14437
14438 #undef $ac_func
14439
14440 /* Override any gcc2 internal prototype to avoid an error.  */
14441 #ifdef __cplusplus
14442 extern "C"
14443 {
14444 #endif
14445 /* We use char because int might match the return type of a gcc2
14446    builtin and then its argument prototype would still apply.  */
14447 char $ac_func ();
14448 /* The GNU C library defines this for functions which it implements
14449     to always fail with ENOSYS.  Some functions are actually named
14450     something starting with __ and the normal name is an alias.  */
14451 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14452 choke me
14453 #else
14454 char (*f) () = $ac_func;
14455 #endif
14456 #ifdef __cplusplus
14457 }
14458 #endif
14459
14460 int
14461 main ()
14462 {
14463 return f != $ac_func;
14464   ;
14465   return 0;
14466 }
14467 _ACEOF
14468 rm -f conftest.$ac_objext conftest$ac_exeext
14469 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14470   (eval $ac_link) 2>conftest.er1
14471   ac_status=$?
14472   grep -v '^ *+' conftest.er1 >conftest.err
14473   rm -f conftest.er1
14474   cat conftest.err >&5
14475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14476   (exit $ac_status); } &&
14477          { ac_try='test -z "$ac_c_werror_flag"
14478                          || test ! -s conftest.err'
14479   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14480   (eval $ac_try) 2>&5
14481   ac_status=$?
14482   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14483   (exit $ac_status); }; } &&
14484          { ac_try='test -s conftest$ac_exeext'
14485   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14486   (eval $ac_try) 2>&5
14487   ac_status=$?
14488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14489   (exit $ac_status); }; }; then
14490   eval "$as_ac_var=yes"
14491 else
14492   echo "$as_me: failed program was:" >&5
14493 sed 's/^/| /' conftest.$ac_ext >&5
14494
14495 eval "$as_ac_var=no"
14496 fi
14497 rm -f conftest.err conftest.$ac_objext \
14498       conftest$ac_exeext conftest.$ac_ext
14499 fi
14500 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14501 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14502 if test `eval echo '${'$as_ac_var'}'` = yes; then
14503   cat >>confdefs.h <<_ACEOF
14504 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14505 _ACEOF
14506  break
14507 fi
14508 done
14509
14510 fi
14511
14512 # Some versions of libedit contain strlcpy(); so disregard that library while
14513 # checking for these standard libc functions.
14514 pgac_save_LIBS="$LIBS"
14515 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
14516
14517
14518
14519
14520
14521
14522
14523
14524
14525
14526
14527
14528
14529
14530
14531 for ac_func in crypt fseeko getopt getrusage inet_aton random rint srandom strdup strerror strlcpy strtol strtoul unsetenv
14532 do
14533 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14534 echo "$as_me:$LINENO: checking for $ac_func" >&5
14535 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14536 if eval "test \"\${$as_ac_var+set}\" = set"; then
14537   echo $ECHO_N "(cached) $ECHO_C" >&6
14538 else
14539   cat >conftest.$ac_ext <<_ACEOF
14540 /* confdefs.h.  */
14541 _ACEOF
14542 cat confdefs.h >>conftest.$ac_ext
14543 cat >>conftest.$ac_ext <<_ACEOF
14544 /* end confdefs.h.  */
14545 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14546    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14547 #define $ac_func innocuous_$ac_func
14548
14549 /* System header to define __stub macros and hopefully few prototypes,
14550     which can conflict with char $ac_func (); below.
14551     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14552     <limits.h> exists even on freestanding compilers.  */
14553
14554 #ifdef __STDC__
14555 # include <limits.h>
14556 #else
14557 # include <assert.h>
14558 #endif
14559
14560 #undef $ac_func
14561
14562 /* Override any gcc2 internal prototype to avoid an error.  */
14563 #ifdef __cplusplus
14564 extern "C"
14565 {
14566 #endif
14567 /* We use char because int might match the return type of a gcc2
14568    builtin and then its argument prototype would still apply.  */
14569 char $ac_func ();
14570 /* The GNU C library defines this for functions which it implements
14571     to always fail with ENOSYS.  Some functions are actually named
14572     something starting with __ and the normal name is an alias.  */
14573 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14574 choke me
14575 #else
14576 char (*f) () = $ac_func;
14577 #endif
14578 #ifdef __cplusplus
14579 }
14580 #endif
14581
14582 int
14583 main ()
14584 {
14585 return f != $ac_func;
14586   ;
14587   return 0;
14588 }
14589 _ACEOF
14590 rm -f conftest.$ac_objext conftest$ac_exeext
14591 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14592   (eval $ac_link) 2>conftest.er1
14593   ac_status=$?
14594   grep -v '^ *+' conftest.er1 >conftest.err
14595   rm -f conftest.er1
14596   cat conftest.err >&5
14597   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14598   (exit $ac_status); } &&
14599          { ac_try='test -z "$ac_c_werror_flag"
14600                          || test ! -s conftest.err'
14601   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14602   (eval $ac_try) 2>&5
14603   ac_status=$?
14604   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14605   (exit $ac_status); }; } &&
14606          { ac_try='test -s conftest$ac_exeext'
14607   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14608   (eval $ac_try) 2>&5
14609   ac_status=$?
14610   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14611   (exit $ac_status); }; }; then
14612   eval "$as_ac_var=yes"
14613 else
14614   echo "$as_me: failed program was:" >&5
14615 sed 's/^/| /' conftest.$ac_ext >&5
14616
14617 eval "$as_ac_var=no"
14618 fi
14619 rm -f conftest.err conftest.$ac_objext \
14620       conftest$ac_exeext conftest.$ac_ext
14621 fi
14622 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14623 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14624 if test `eval echo '${'$as_ac_var'}'` = yes; then
14625   cat >>confdefs.h <<_ACEOF
14626 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14627 _ACEOF
14628
14629 else
14630   case $LIBOBJS in
14631     "$ac_func.$ac_objext"   | \
14632   *" $ac_func.$ac_objext"   | \
14633     "$ac_func.$ac_objext "* | \
14634   *" $ac_func.$ac_objext "* ) ;;
14635   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14636 esac
14637
14638 fi
14639 done
14640
14641
14642
14643 LIBS="$pgac_save_LIBS"
14644
14645 # System's version of getaddrinfo(), if any, may be used only if we found
14646 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
14647 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
14648 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
14649 # because we want to use our own getaddrinfo.c on Windows anyway.)
14650 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
14651
14652 for ac_func in getaddrinfo
14653 do
14654 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14655 echo "$as_me:$LINENO: checking for $ac_func" >&5
14656 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14657 if eval "test \"\${$as_ac_var+set}\" = set"; then
14658   echo $ECHO_N "(cached) $ECHO_C" >&6
14659 else
14660   cat >conftest.$ac_ext <<_ACEOF
14661 /* confdefs.h.  */
14662 _ACEOF
14663 cat confdefs.h >>conftest.$ac_ext
14664 cat >>conftest.$ac_ext <<_ACEOF
14665 /* end confdefs.h.  */
14666 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14667    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14668 #define $ac_func innocuous_$ac_func
14669
14670 /* System header to define __stub macros and hopefully few prototypes,
14671     which can conflict with char $ac_func (); below.
14672     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14673     <limits.h> exists even on freestanding compilers.  */
14674
14675 #ifdef __STDC__
14676 # include <limits.h>
14677 #else
14678 # include <assert.h>
14679 #endif
14680
14681 #undef $ac_func
14682
14683 /* Override any gcc2 internal prototype to avoid an error.  */
14684 #ifdef __cplusplus
14685 extern "C"
14686 {
14687 #endif
14688 /* We use char because int might match the return type of a gcc2
14689    builtin and then its argument prototype would still apply.  */
14690 char $ac_func ();
14691 /* The GNU C library defines this for functions which it implements
14692     to always fail with ENOSYS.  Some functions are actually named
14693     something starting with __ and the normal name is an alias.  */
14694 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14695 choke me
14696 #else
14697 char (*f) () = $ac_func;
14698 #endif
14699 #ifdef __cplusplus
14700 }
14701 #endif
14702
14703 int
14704 main ()
14705 {
14706 return f != $ac_func;
14707   ;
14708   return 0;
14709 }
14710 _ACEOF
14711 rm -f conftest.$ac_objext conftest$ac_exeext
14712 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14713   (eval $ac_link) 2>conftest.er1
14714   ac_status=$?
14715   grep -v '^ *+' conftest.er1 >conftest.err
14716   rm -f conftest.er1
14717   cat conftest.err >&5
14718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14719   (exit $ac_status); } &&
14720          { ac_try='test -z "$ac_c_werror_flag"
14721                          || test ! -s conftest.err'
14722   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14723   (eval $ac_try) 2>&5
14724   ac_status=$?
14725   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14726   (exit $ac_status); }; } &&
14727          { ac_try='test -s conftest$ac_exeext'
14728   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14729   (eval $ac_try) 2>&5
14730   ac_status=$?
14731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14732   (exit $ac_status); }; }; then
14733   eval "$as_ac_var=yes"
14734 else
14735   echo "$as_me: failed program was:" >&5
14736 sed 's/^/| /' conftest.$ac_ext >&5
14737
14738 eval "$as_ac_var=no"
14739 fi
14740 rm -f conftest.err conftest.$ac_objext \
14741       conftest$ac_exeext conftest.$ac_ext
14742 fi
14743 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14744 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14745 if test `eval echo '${'$as_ac_var'}'` = yes; then
14746   cat >>confdefs.h <<_ACEOF
14747 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14748 _ACEOF
14749
14750 else
14751   case $LIBOBJS in
14752     "$ac_func.$ac_objext"   | \
14753   *" $ac_func.$ac_objext"   | \
14754     "$ac_func.$ac_objext "* | \
14755   *" $ac_func.$ac_objext "* ) ;;
14756   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14757 esac
14758
14759 fi
14760 done
14761
14762
14763 else
14764   case $LIBOBJS in
14765     "getaddrinfo.$ac_objext"   | \
14766   *" getaddrinfo.$ac_objext"   | \
14767     "getaddrinfo.$ac_objext "* | \
14768   *" getaddrinfo.$ac_objext "* ) ;;
14769   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext" ;;
14770 esac
14771
14772 fi
14773
14774 # similarly, use system's getopt_long() only if system provides struct option.
14775 if test x"$ac_cv_type_struct_option" = xyes ; then
14776
14777 for ac_func in getopt_long
14778 do
14779 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14780 echo "$as_me:$LINENO: checking for $ac_func" >&5
14781 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14782 if eval "test \"\${$as_ac_var+set}\" = set"; then
14783   echo $ECHO_N "(cached) $ECHO_C" >&6
14784 else
14785   cat >conftest.$ac_ext <<_ACEOF
14786 /* confdefs.h.  */
14787 _ACEOF
14788 cat confdefs.h >>conftest.$ac_ext
14789 cat >>conftest.$ac_ext <<_ACEOF
14790 /* end confdefs.h.  */
14791 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14792    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14793 #define $ac_func innocuous_$ac_func
14794
14795 /* System header to define __stub macros and hopefully few prototypes,
14796     which can conflict with char $ac_func (); below.
14797     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14798     <limits.h> exists even on freestanding compilers.  */
14799
14800 #ifdef __STDC__
14801 # include <limits.h>
14802 #else
14803 # include <assert.h>
14804 #endif
14805
14806 #undef $ac_func
14807
14808 /* Override any gcc2 internal prototype to avoid an error.  */
14809 #ifdef __cplusplus
14810 extern "C"
14811 {
14812 #endif
14813 /* We use char because int might match the return type of a gcc2
14814    builtin and then its argument prototype would still apply.  */
14815 char $ac_func ();
14816 /* The GNU C library defines this for functions which it implements
14817     to always fail with ENOSYS.  Some functions are actually named
14818     something starting with __ and the normal name is an alias.  */
14819 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14820 choke me
14821 #else
14822 char (*f) () = $ac_func;
14823 #endif
14824 #ifdef __cplusplus
14825 }
14826 #endif
14827
14828 int
14829 main ()
14830 {
14831 return f != $ac_func;
14832   ;
14833   return 0;
14834 }
14835 _ACEOF
14836 rm -f conftest.$ac_objext conftest$ac_exeext
14837 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14838   (eval $ac_link) 2>conftest.er1
14839   ac_status=$?
14840   grep -v '^ *+' conftest.er1 >conftest.err
14841   rm -f conftest.er1
14842   cat conftest.err >&5
14843   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14844   (exit $ac_status); } &&
14845          { ac_try='test -z "$ac_c_werror_flag"
14846                          || test ! -s conftest.err'
14847   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14848   (eval $ac_try) 2>&5
14849   ac_status=$?
14850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14851   (exit $ac_status); }; } &&
14852          { ac_try='test -s conftest$ac_exeext'
14853   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14854   (eval $ac_try) 2>&5
14855   ac_status=$?
14856   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14857   (exit $ac_status); }; }; then
14858   eval "$as_ac_var=yes"
14859 else
14860   echo "$as_me: failed program was:" >&5
14861 sed 's/^/| /' conftest.$ac_ext >&5
14862
14863 eval "$as_ac_var=no"
14864 fi
14865 rm -f conftest.err conftest.$ac_objext \
14866       conftest$ac_exeext conftest.$ac_ext
14867 fi
14868 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14869 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14870 if test `eval echo '${'$as_ac_var'}'` = yes; then
14871   cat >>confdefs.h <<_ACEOF
14872 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14873 _ACEOF
14874
14875 else
14876   case $LIBOBJS in
14877     "$ac_func.$ac_objext"   | \
14878   *" $ac_func.$ac_objext"   | \
14879     "$ac_func.$ac_objext "* | \
14880   *" $ac_func.$ac_objext "* ) ;;
14881   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" ;;
14882 esac
14883
14884 fi
14885 done
14886
14887
14888 else
14889   case $LIBOBJS in
14890     "getopt_long.$ac_objext"   | \
14891   *" getopt_long.$ac_objext"   | \
14892     "getopt_long.$ac_objext "* | \
14893   *" getopt_long.$ac_objext "* ) ;;
14894   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext" ;;
14895 esac
14896
14897 fi
14898
14899 # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
14900 # We override the previous test that said fseeko/ftello didn't exist
14901 # OS tests are also done in include/c.h and port/fseeko.c
14902 case $host_os in bsdi*|netbsd*)
14903 ac_cv_func_fseeko=yes
14904 esac
14905
14906 # Win32 support
14907 if test "$PORTNAME" = "win32"; then
14908 case $LIBOBJS in
14909     "gettimeofday.$ac_objext"   | \
14910   *" gettimeofday.$ac_objext"   | \
14911     "gettimeofday.$ac_objext "* | \
14912   *" gettimeofday.$ac_objext "* ) ;;
14913   *) LIBOBJS="$LIBOBJS gettimeofday.$ac_objext" ;;
14914 esac
14915
14916 case $LIBOBJS in
14917     "kill.$ac_objext"   | \
14918   *" kill.$ac_objext"   | \
14919     "kill.$ac_objext "* | \
14920   *" kill.$ac_objext "* ) ;;
14921   *) LIBOBJS="$LIBOBJS kill.$ac_objext" ;;
14922 esac
14923
14924 case $LIBOBJS in
14925     "open.$ac_objext"   | \
14926   *" open.$ac_objext"   | \
14927     "open.$ac_objext "* | \
14928   *" open.$ac_objext "* ) ;;
14929   *) LIBOBJS="$LIBOBJS open.$ac_objext" ;;
14930 esac
14931
14932 case $LIBOBJS in
14933     "rand.$ac_objext"   | \
14934   *" rand.$ac_objext"   | \
14935     "rand.$ac_objext "* | \
14936   *" rand.$ac_objext "* ) ;;
14937   *) LIBOBJS="$LIBOBJS rand.$ac_objext" ;;
14938 esac
14939
14940 case $LIBOBJS in
14941     "win32error.$ac_objext"   | \
14942   *" win32error.$ac_objext"   | \
14943     "win32error.$ac_objext "* | \
14944   *" win32error.$ac_objext "* ) ;;
14945   *) LIBOBJS="$LIBOBJS win32error.$ac_objext" ;;
14946 esac
14947
14948
14949 cat >>confdefs.h <<\_ACEOF
14950 #define HAVE_SYMLINK 1
14951 _ACEOF
14952
14953 fi
14954
14955 if test "$with_readline" = yes; then
14956   echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
14957 echo $ECHO_N "checking for rl_completion_append_character... $ECHO_C" >&6
14958 cat >conftest.$ac_ext <<_ACEOF
14959 /* confdefs.h.  */
14960 _ACEOF
14961 cat confdefs.h >>conftest.$ac_ext
14962 cat >>conftest.$ac_ext <<_ACEOF
14963 /* end confdefs.h.  */
14964 #include <stdio.h>
14965 #ifdef HAVE_READLINE_READLINE_H
14966 # include <readline/readline.h>
14967 #elif defined(HAVE_READLINE_H)
14968 # include <readline.h>
14969 #endif
14970
14971 int
14972 main ()
14973 {
14974 rl_completion_append_character = 'x';
14975   ;
14976   return 0;
14977 }
14978 _ACEOF
14979 rm -f conftest.$ac_objext conftest$ac_exeext
14980 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14981   (eval $ac_link) 2>conftest.er1
14982   ac_status=$?
14983   grep -v '^ *+' conftest.er1 >conftest.err
14984   rm -f conftest.er1
14985   cat conftest.err >&5
14986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14987   (exit $ac_status); } &&
14988          { ac_try='test -z "$ac_c_werror_flag"
14989                          || test ! -s conftest.err'
14990   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14991   (eval $ac_try) 2>&5
14992   ac_status=$?
14993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14994   (exit $ac_status); }; } &&
14995          { ac_try='test -s conftest$ac_exeext'
14996   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14997   (eval $ac_try) 2>&5
14998   ac_status=$?
14999   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15000   (exit $ac_status); }; }; then
15001   echo "$as_me:$LINENO: result: yes" >&5
15002 echo "${ECHO_T}yes" >&6
15003
15004 cat >>confdefs.h <<\_ACEOF
15005 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
15006 _ACEOF
15007
15008 else
15009   echo "$as_me: failed program was:" >&5
15010 sed 's/^/| /' conftest.$ac_ext >&5
15011
15012 echo "$as_me:$LINENO: result: no" >&5
15013 echo "${ECHO_T}no" >&6
15014 fi
15015 rm -f conftest.err conftest.$ac_objext \
15016       conftest$ac_exeext conftest.$ac_ext
15017
15018
15019 for ac_func in rl_completion_matches rl_filename_completion_function
15020 do
15021 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15022 echo "$as_me:$LINENO: checking for $ac_func" >&5
15023 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15024 if eval "test \"\${$as_ac_var+set}\" = set"; then
15025   echo $ECHO_N "(cached) $ECHO_C" >&6
15026 else
15027   cat >conftest.$ac_ext <<_ACEOF
15028 /* confdefs.h.  */
15029 _ACEOF
15030 cat confdefs.h >>conftest.$ac_ext
15031 cat >>conftest.$ac_ext <<_ACEOF
15032 /* end confdefs.h.  */
15033 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15034    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15035 #define $ac_func innocuous_$ac_func
15036
15037 /* System header to define __stub macros and hopefully few prototypes,
15038     which can conflict with char $ac_func (); below.
15039     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15040     <limits.h> exists even on freestanding compilers.  */
15041
15042 #ifdef __STDC__
15043 # include <limits.h>
15044 #else
15045 # include <assert.h>
15046 #endif
15047
15048 #undef $ac_func
15049
15050 /* Override any gcc2 internal prototype to avoid an error.  */
15051 #ifdef __cplusplus
15052 extern "C"
15053 {
15054 #endif
15055 /* We use char because int might match the return type of a gcc2
15056    builtin and then its argument prototype would still apply.  */
15057 char $ac_func ();
15058 /* The GNU C library defines this for functions which it implements
15059     to always fail with ENOSYS.  Some functions are actually named
15060     something starting with __ and the normal name is an alias.  */
15061 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15062 choke me
15063 #else
15064 char (*f) () = $ac_func;
15065 #endif
15066 #ifdef __cplusplus
15067 }
15068 #endif
15069
15070 int
15071 main ()
15072 {
15073 return f != $ac_func;
15074   ;
15075   return 0;
15076 }
15077 _ACEOF
15078 rm -f conftest.$ac_objext conftest$ac_exeext
15079 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15080   (eval $ac_link) 2>conftest.er1
15081   ac_status=$?
15082   grep -v '^ *+' conftest.er1 >conftest.err
15083   rm -f conftest.er1
15084   cat conftest.err >&5
15085   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15086   (exit $ac_status); } &&
15087          { ac_try='test -z "$ac_c_werror_flag"
15088                          || test ! -s conftest.err'
15089   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15090   (eval $ac_try) 2>&5
15091   ac_status=$?
15092   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15093   (exit $ac_status); }; } &&
15094          { ac_try='test -s conftest$ac_exeext'
15095   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15096   (eval $ac_try) 2>&5
15097   ac_status=$?
15098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15099   (exit $ac_status); }; }; then
15100   eval "$as_ac_var=yes"
15101 else
15102   echo "$as_me: failed program was:" >&5
15103 sed 's/^/| /' conftest.$ac_ext >&5
15104
15105 eval "$as_ac_var=no"
15106 fi
15107 rm -f conftest.err conftest.$ac_objext \
15108       conftest$ac_exeext conftest.$ac_ext
15109 fi
15110 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15111 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15112 if test `eval echo '${'$as_ac_var'}'` = yes; then
15113   cat >>confdefs.h <<_ACEOF
15114 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15115 _ACEOF
15116
15117 fi
15118 done
15119
15120
15121 for ac_func in replace_history_entry
15122 do
15123 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15124 echo "$as_me:$LINENO: checking for $ac_func" >&5
15125 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15126 if eval "test \"\${$as_ac_var+set}\" = set"; then
15127   echo $ECHO_N "(cached) $ECHO_C" >&6
15128 else
15129   cat >conftest.$ac_ext <<_ACEOF
15130 /* confdefs.h.  */
15131 _ACEOF
15132 cat confdefs.h >>conftest.$ac_ext
15133 cat >>conftest.$ac_ext <<_ACEOF
15134 /* end confdefs.h.  */
15135 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15136    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15137 #define $ac_func innocuous_$ac_func
15138
15139 /* System header to define __stub macros and hopefully few prototypes,
15140     which can conflict with char $ac_func (); below.
15141     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15142     <limits.h> exists even on freestanding compilers.  */
15143
15144 #ifdef __STDC__
15145 # include <limits.h>
15146 #else
15147 # include <assert.h>
15148 #endif
15149
15150 #undef $ac_func
15151
15152 /* Override any gcc2 internal prototype to avoid an error.  */
15153 #ifdef __cplusplus
15154 extern "C"
15155 {
15156 #endif
15157 /* We use char because int might match the return type of a gcc2
15158    builtin and then its argument prototype would still apply.  */
15159 char $ac_func ();
15160 /* The GNU C library defines this for functions which it implements
15161     to always fail with ENOSYS.  Some functions are actually named
15162     something starting with __ and the normal name is an alias.  */
15163 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15164 choke me
15165 #else
15166 char (*f) () = $ac_func;
15167 #endif
15168 #ifdef __cplusplus
15169 }
15170 #endif
15171
15172 int
15173 main ()
15174 {
15175 return f != $ac_func;
15176   ;
15177   return 0;
15178 }
15179 _ACEOF
15180 rm -f conftest.$ac_objext conftest$ac_exeext
15181 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15182   (eval $ac_link) 2>conftest.er1
15183   ac_status=$?
15184   grep -v '^ *+' conftest.er1 >conftest.err
15185   rm -f conftest.er1
15186   cat conftest.err >&5
15187   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15188   (exit $ac_status); } &&
15189          { ac_try='test -z "$ac_c_werror_flag"
15190                          || test ! -s conftest.err'
15191   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15192   (eval $ac_try) 2>&5
15193   ac_status=$?
15194   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15195   (exit $ac_status); }; } &&
15196          { ac_try='test -s conftest$ac_exeext'
15197   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15198   (eval $ac_try) 2>&5
15199   ac_status=$?
15200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15201   (exit $ac_status); }; }; then
15202   eval "$as_ac_var=yes"
15203 else
15204   echo "$as_me: failed program was:" >&5
15205 sed 's/^/| /' conftest.$ac_ext >&5
15206
15207 eval "$as_ac_var=no"
15208 fi
15209 rm -f conftest.err conftest.$ac_objext \
15210       conftest$ac_exeext conftest.$ac_ext
15211 fi
15212 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15213 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15214 if test `eval echo '${'$as_ac_var'}'` = yes; then
15215   cat >>confdefs.h <<_ACEOF
15216 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15217 _ACEOF
15218
15219 fi
15220 done
15221
15222 fi
15223
15224
15225 echo "$as_me:$LINENO: checking for finite" >&5
15226 echo $ECHO_N "checking for finite... $ECHO_C" >&6
15227 cat >conftest.$ac_ext <<_ACEOF
15228 /* confdefs.h.  */
15229 _ACEOF
15230 cat confdefs.h >>conftest.$ac_ext
15231 cat >>conftest.$ac_ext <<_ACEOF
15232 /* end confdefs.h.  */
15233
15234 #include <math.h>
15235 double glob_double;
15236
15237 int
15238 main ()
15239 {
15240 return finite(glob_double) ? 0 : 1;
15241   ;
15242   return 0;
15243 }
15244 _ACEOF
15245 rm -f conftest.$ac_objext conftest$ac_exeext
15246 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15247   (eval $ac_link) 2>conftest.er1
15248   ac_status=$?
15249   grep -v '^ *+' conftest.er1 >conftest.err
15250   rm -f conftest.er1
15251   cat conftest.err >&5
15252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15253   (exit $ac_status); } &&
15254          { ac_try='test -z "$ac_c_werror_flag"
15255                          || test ! -s conftest.err'
15256   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15257   (eval $ac_try) 2>&5
15258   ac_status=$?
15259   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15260   (exit $ac_status); }; } &&
15261          { ac_try='test -s conftest$ac_exeext'
15262   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15263   (eval $ac_try) 2>&5
15264   ac_status=$?
15265   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15266   (exit $ac_status); }; }; then
15267
15268 cat >>confdefs.h <<\_ACEOF
15269 #define HAVE_FINITE 1
15270 _ACEOF
15271
15272 echo "$as_me:$LINENO: result: yes" >&5
15273 echo "${ECHO_T}yes" >&6
15274 else
15275   echo "$as_me: failed program was:" >&5
15276 sed 's/^/| /' conftest.$ac_ext >&5
15277
15278 echo "$as_me:$LINENO: result: no" >&5
15279 echo "${ECHO_T}no" >&6
15280 fi
15281 rm -f conftest.err conftest.$ac_objext \
15282       conftest$ac_exeext conftest.$ac_ext
15283
15284 echo "$as_me:$LINENO: checking for sigsetjmp" >&5
15285 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6
15286 cat >conftest.$ac_ext <<_ACEOF
15287 /* confdefs.h.  */
15288 _ACEOF
15289 cat confdefs.h >>conftest.$ac_ext
15290 cat >>conftest.$ac_ext <<_ACEOF
15291 /* end confdefs.h.  */
15292 #include <setjmp.h>
15293 int
15294 main ()
15295 {
15296 sigjmp_buf x; sigsetjmp(x, 1);
15297   ;
15298   return 0;
15299 }
15300 _ACEOF
15301 rm -f conftest.$ac_objext conftest$ac_exeext
15302 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15303   (eval $ac_link) 2>conftest.er1
15304   ac_status=$?
15305   grep -v '^ *+' conftest.er1 >conftest.err
15306   rm -f conftest.er1
15307   cat conftest.err >&5
15308   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15309   (exit $ac_status); } &&
15310          { ac_try='test -z "$ac_c_werror_flag"
15311                          || test ! -s conftest.err'
15312   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15313   (eval $ac_try) 2>&5
15314   ac_status=$?
15315   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15316   (exit $ac_status); }; } &&
15317          { ac_try='test -s conftest$ac_exeext'
15318   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15319   (eval $ac_try) 2>&5
15320   ac_status=$?
15321   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15322   (exit $ac_status); }; }; then
15323
15324 cat >>confdefs.h <<\_ACEOF
15325 #define HAVE_SIGSETJMP 1
15326 _ACEOF
15327
15328 echo "$as_me:$LINENO: result: yes" >&5
15329 echo "${ECHO_T}yes" >&6
15330 else
15331   echo "$as_me: failed program was:" >&5
15332 sed 's/^/| /' conftest.$ac_ext >&5
15333
15334 echo "$as_me:$LINENO: result: no" >&5
15335 echo "${ECHO_T}no" >&6
15336 fi
15337 rm -f conftest.err conftest.$ac_objext \
15338       conftest$ac_exeext conftest.$ac_ext
15339
15340 echo "$as_me:$LINENO: checking for syslog" >&5
15341 echo $ECHO_N "checking for syslog... $ECHO_C" >&6
15342 if test "${ac_cv_func_syslog+set}" = set; then
15343   echo $ECHO_N "(cached) $ECHO_C" >&6
15344 else
15345   cat >conftest.$ac_ext <<_ACEOF
15346 /* confdefs.h.  */
15347 _ACEOF
15348 cat confdefs.h >>conftest.$ac_ext
15349 cat >>conftest.$ac_ext <<_ACEOF
15350 /* end confdefs.h.  */
15351 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
15352    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15353 #define syslog innocuous_syslog
15354
15355 /* System header to define __stub macros and hopefully few prototypes,
15356     which can conflict with char syslog (); below.
15357     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15358     <limits.h> exists even on freestanding compilers.  */
15359
15360 #ifdef __STDC__
15361 # include <limits.h>
15362 #else
15363 # include <assert.h>
15364 #endif
15365
15366 #undef syslog
15367
15368 /* Override any gcc2 internal prototype to avoid an error.  */
15369 #ifdef __cplusplus
15370 extern "C"
15371 {
15372 #endif
15373 /* We use char because int might match the return type of a gcc2
15374    builtin and then its argument prototype would still apply.  */
15375 char syslog ();
15376 /* The GNU C library defines this for functions which it implements
15377     to always fail with ENOSYS.  Some functions are actually named
15378     something starting with __ and the normal name is an alias.  */
15379 #if defined (__stub_syslog) || defined (__stub___syslog)
15380 choke me
15381 #else
15382 char (*f) () = syslog;
15383 #endif
15384 #ifdef __cplusplus
15385 }
15386 #endif
15387
15388 int
15389 main ()
15390 {
15391 return f != syslog;
15392   ;
15393   return 0;
15394 }
15395 _ACEOF
15396 rm -f conftest.$ac_objext conftest$ac_exeext
15397 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15398   (eval $ac_link) 2>conftest.er1
15399   ac_status=$?
15400   grep -v '^ *+' conftest.er1 >conftest.err
15401   rm -f conftest.er1
15402   cat conftest.err >&5
15403   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15404   (exit $ac_status); } &&
15405          { ac_try='test -z "$ac_c_werror_flag"
15406                          || test ! -s conftest.err'
15407   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15408   (eval $ac_try) 2>&5
15409   ac_status=$?
15410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15411   (exit $ac_status); }; } &&
15412          { ac_try='test -s conftest$ac_exeext'
15413   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15414   (eval $ac_try) 2>&5
15415   ac_status=$?
15416   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15417   (exit $ac_status); }; }; then
15418   ac_cv_func_syslog=yes
15419 else
15420   echo "$as_me: failed program was:" >&5
15421 sed 's/^/| /' conftest.$ac_ext >&5
15422
15423 ac_cv_func_syslog=no
15424 fi
15425 rm -f conftest.err conftest.$ac_objext \
15426       conftest$ac_exeext conftest.$ac_ext
15427 fi
15428 echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
15429 echo "${ECHO_T}$ac_cv_func_syslog" >&6
15430 if test $ac_cv_func_syslog = yes; then
15431   if test "${ac_cv_header_syslog_h+set}" = set; then
15432   echo "$as_me:$LINENO: checking for syslog.h" >&5
15433 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
15434 if test "${ac_cv_header_syslog_h+set}" = set; then
15435   echo $ECHO_N "(cached) $ECHO_C" >&6
15436 fi
15437 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
15438 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
15439 else
15440   # Is the header compilable?
15441 echo "$as_me:$LINENO: checking syslog.h usability" >&5
15442 echo $ECHO_N "checking syslog.h usability... $ECHO_C" >&6
15443 cat >conftest.$ac_ext <<_ACEOF
15444 /* confdefs.h.  */
15445 _ACEOF
15446 cat confdefs.h >>conftest.$ac_ext
15447 cat >>conftest.$ac_ext <<_ACEOF
15448 /* end confdefs.h.  */
15449 $ac_includes_default
15450 #include <syslog.h>
15451 _ACEOF
15452 rm -f conftest.$ac_objext
15453 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15454   (eval $ac_compile) 2>conftest.er1
15455   ac_status=$?
15456   grep -v '^ *+' conftest.er1 >conftest.err
15457   rm -f conftest.er1
15458   cat conftest.err >&5
15459   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15460   (exit $ac_status); } &&
15461          { ac_try='test -z "$ac_c_werror_flag"
15462                          || test ! -s conftest.err'
15463   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15464   (eval $ac_try) 2>&5
15465   ac_status=$?
15466   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15467   (exit $ac_status); }; } &&
15468          { ac_try='test -s conftest.$ac_objext'
15469   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15470   (eval $ac_try) 2>&5
15471   ac_status=$?
15472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15473   (exit $ac_status); }; }; then
15474   ac_header_compiler=yes
15475 else
15476   echo "$as_me: failed program was:" >&5
15477 sed 's/^/| /' conftest.$ac_ext >&5
15478
15479 ac_header_compiler=no
15480 fi
15481 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
15482 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
15483 echo "${ECHO_T}$ac_header_compiler" >&6
15484
15485 # Is the header present?
15486 echo "$as_me:$LINENO: checking syslog.h presence" >&5
15487 echo $ECHO_N "checking syslog.h presence... $ECHO_C" >&6
15488 cat >conftest.$ac_ext <<_ACEOF
15489 /* confdefs.h.  */
15490 _ACEOF
15491 cat confdefs.h >>conftest.$ac_ext
15492 cat >>conftest.$ac_ext <<_ACEOF
15493 /* end confdefs.h.  */
15494 #include <syslog.h>
15495 _ACEOF
15496 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
15497   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
15498   ac_status=$?
15499   grep -v '^ *+' conftest.er1 >conftest.err
15500   rm -f conftest.er1
15501   cat conftest.err >&5
15502   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15503   (exit $ac_status); } >/dev/null; then
15504   if test -s conftest.err; then
15505     ac_cpp_err=$ac_c_preproc_warn_flag
15506     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
15507   else
15508     ac_cpp_err=
15509   fi
15510 else
15511   ac_cpp_err=yes
15512 fi
15513 if test -z "$ac_cpp_err"; then
15514   ac_header_preproc=yes
15515 else
15516   echo "$as_me: failed program was:" >&5
15517 sed 's/^/| /' conftest.$ac_ext >&5
15518
15519   ac_header_preproc=no
15520 fi
15521 rm -f conftest.err conftest.$ac_ext
15522 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
15523 echo "${ECHO_T}$ac_header_preproc" >&6
15524
15525 # So?  What about this header?
15526 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
15527   yes:no: )
15528     { echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
15529 echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
15530     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
15531 echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
15532     ac_header_preproc=yes
15533     ;;
15534   no:yes:* )
15535     { echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
15536 echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
15537     { echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
15538 echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
15539     { echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
15540 echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
15541     { echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
15542 echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
15543     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
15544 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
15545     { echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
15546 echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
15547     (
15548       cat <<\_ASBOX
15549 ## ---------------------------------------- ##
15550 ## Report this to pgsql-bugs@postgresql.org ##
15551 ## ---------------------------------------- ##
15552 _ASBOX
15553     ) |
15554       sed "s/^/$as_me: WARNING:     /" >&2
15555     ;;
15556 esac
15557 echo "$as_me:$LINENO: checking for syslog.h" >&5
15558 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
15559 if test "${ac_cv_header_syslog_h+set}" = set; then
15560   echo $ECHO_N "(cached) $ECHO_C" >&6
15561 else
15562   ac_cv_header_syslog_h=$ac_header_preproc
15563 fi
15564 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
15565 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
15566
15567 fi
15568 if test $ac_cv_header_syslog_h = yes; then
15569
15570 cat >>confdefs.h <<\_ACEOF
15571 #define HAVE_SYSLOG 1
15572 _ACEOF
15573
15574 fi
15575
15576
15577 fi
15578
15579
15580 echo "$as_me:$LINENO: checking for optreset" >&5
15581 echo $ECHO_N "checking for optreset... $ECHO_C" >&6
15582 if test "${pgac_cv_var_int_optreset+set}" = set; then
15583   echo $ECHO_N "(cached) $ECHO_C" >&6
15584 else
15585   cat >conftest.$ac_ext <<_ACEOF
15586 /* confdefs.h.  */
15587 _ACEOF
15588 cat confdefs.h >>conftest.$ac_ext
15589 cat >>conftest.$ac_ext <<_ACEOF
15590 /* end confdefs.h.  */
15591 #include <unistd.h>
15592 int
15593 main ()
15594 {
15595 extern int optreset; optreset = 1;
15596   ;
15597   return 0;
15598 }
15599 _ACEOF
15600 rm -f conftest.$ac_objext conftest$ac_exeext
15601 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15602   (eval $ac_link) 2>conftest.er1
15603   ac_status=$?
15604   grep -v '^ *+' conftest.er1 >conftest.err
15605   rm -f conftest.er1
15606   cat conftest.err >&5
15607   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15608   (exit $ac_status); } &&
15609          { ac_try='test -z "$ac_c_werror_flag"
15610                          || test ! -s conftest.err'
15611   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15612   (eval $ac_try) 2>&5
15613   ac_status=$?
15614   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15615   (exit $ac_status); }; } &&
15616          { ac_try='test -s conftest$ac_exeext'
15617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15618   (eval $ac_try) 2>&5
15619   ac_status=$?
15620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15621   (exit $ac_status); }; }; then
15622   pgac_cv_var_int_optreset=yes
15623 else
15624   echo "$as_me: failed program was:" >&5
15625 sed 's/^/| /' conftest.$ac_ext >&5
15626
15627 pgac_cv_var_int_optreset=no
15628 fi
15629 rm -f conftest.err conftest.$ac_objext \
15630       conftest$ac_exeext conftest.$ac_ext
15631 fi
15632 echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
15633 echo "${ECHO_T}$pgac_cv_var_int_optreset" >&6
15634 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
15635
15636 cat >>confdefs.h <<\_ACEOF
15637 #define HAVE_INT_OPTRESET 1
15638 _ACEOF
15639
15640 fi
15641
15642
15643
15644 for ac_func in strtoll strtoq
15645 do
15646 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15647 echo "$as_me:$LINENO: checking for $ac_func" >&5
15648 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15649 if eval "test \"\${$as_ac_var+set}\" = set"; then
15650   echo $ECHO_N "(cached) $ECHO_C" >&6
15651 else
15652   cat >conftest.$ac_ext <<_ACEOF
15653 /* confdefs.h.  */
15654 _ACEOF
15655 cat confdefs.h >>conftest.$ac_ext
15656 cat >>conftest.$ac_ext <<_ACEOF
15657 /* end confdefs.h.  */
15658 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15659    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15660 #define $ac_func innocuous_$ac_func
15661
15662 /* System header to define __stub macros and hopefully few prototypes,
15663     which can conflict with char $ac_func (); below.
15664     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15665     <limits.h> exists even on freestanding compilers.  */
15666
15667 #ifdef __STDC__
15668 # include <limits.h>
15669 #else
15670 # include <assert.h>
15671 #endif
15672
15673 #undef $ac_func
15674
15675 /* Override any gcc2 internal prototype to avoid an error.  */
15676 #ifdef __cplusplus
15677 extern "C"
15678 {
15679 #endif
15680 /* We use char because int might match the return type of a gcc2
15681    builtin and then its argument prototype would still apply.  */
15682 char $ac_func ();
15683 /* The GNU C library defines this for functions which it implements
15684     to always fail with ENOSYS.  Some functions are actually named
15685     something starting with __ and the normal name is an alias.  */
15686 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15687 choke me
15688 #else
15689 char (*f) () = $ac_func;
15690 #endif
15691 #ifdef __cplusplus
15692 }
15693 #endif
15694
15695 int
15696 main ()
15697 {
15698 return f != $ac_func;
15699   ;
15700   return 0;
15701 }
15702 _ACEOF
15703 rm -f conftest.$ac_objext conftest$ac_exeext
15704 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15705   (eval $ac_link) 2>conftest.er1
15706   ac_status=$?
15707   grep -v '^ *+' conftest.er1 >conftest.err
15708   rm -f conftest.er1
15709   cat conftest.err >&5
15710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15711   (exit $ac_status); } &&
15712          { ac_try='test -z "$ac_c_werror_flag"
15713                          || test ! -s conftest.err'
15714   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15715   (eval $ac_try) 2>&5
15716   ac_status=$?
15717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15718   (exit $ac_status); }; } &&
15719          { ac_try='test -s conftest$ac_exeext'
15720   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15721   (eval $ac_try) 2>&5
15722   ac_status=$?
15723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15724   (exit $ac_status); }; }; then
15725   eval "$as_ac_var=yes"
15726 else
15727   echo "$as_me: failed program was:" >&5
15728 sed 's/^/| /' conftest.$ac_ext >&5
15729
15730 eval "$as_ac_var=no"
15731 fi
15732 rm -f conftest.err conftest.$ac_objext \
15733       conftest$ac_exeext conftest.$ac_ext
15734 fi
15735 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15736 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15737 if test `eval echo '${'$as_ac_var'}'` = yes; then
15738   cat >>confdefs.h <<_ACEOF
15739 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15740 _ACEOF
15741  break
15742 fi
15743 done
15744
15745
15746
15747 for ac_func in strtoull strtouq
15748 do
15749 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15750 echo "$as_me:$LINENO: checking for $ac_func" >&5
15751 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15752 if eval "test \"\${$as_ac_var+set}\" = set"; then
15753   echo $ECHO_N "(cached) $ECHO_C" >&6
15754 else
15755   cat >conftest.$ac_ext <<_ACEOF
15756 /* confdefs.h.  */
15757 _ACEOF
15758 cat confdefs.h >>conftest.$ac_ext
15759 cat >>conftest.$ac_ext <<_ACEOF
15760 /* end confdefs.h.  */
15761 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15762    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15763 #define $ac_func innocuous_$ac_func
15764
15765 /* System header to define __stub macros and hopefully few prototypes,
15766     which can conflict with char $ac_func (); below.
15767     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15768     <limits.h> exists even on freestanding compilers.  */
15769
15770 #ifdef __STDC__
15771 # include <limits.h>
15772 #else
15773 # include <assert.h>
15774 #endif
15775
15776 #undef $ac_func
15777
15778 /* Override any gcc2 internal prototype to avoid an error.  */
15779 #ifdef __cplusplus
15780 extern "C"
15781 {
15782 #endif
15783 /* We use char because int might match the return type of a gcc2
15784    builtin and then its argument prototype would still apply.  */
15785 char $ac_func ();
15786 /* The GNU C library defines this for functions which it implements
15787     to always fail with ENOSYS.  Some functions are actually named
15788     something starting with __ and the normal name is an alias.  */
15789 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15790 choke me
15791 #else
15792 char (*f) () = $ac_func;
15793 #endif
15794 #ifdef __cplusplus
15795 }
15796 #endif
15797
15798 int
15799 main ()
15800 {
15801 return f != $ac_func;
15802   ;
15803   return 0;
15804 }
15805 _ACEOF
15806 rm -f conftest.$ac_objext conftest$ac_exeext
15807 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15808   (eval $ac_link) 2>conftest.er1
15809   ac_status=$?
15810   grep -v '^ *+' conftest.er1 >conftest.err
15811   rm -f conftest.er1
15812   cat conftest.err >&5
15813   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15814   (exit $ac_status); } &&
15815          { ac_try='test -z "$ac_c_werror_flag"
15816                          || test ! -s conftest.err'
15817   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15818   (eval $ac_try) 2>&5
15819   ac_status=$?
15820   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15821   (exit $ac_status); }; } &&
15822          { ac_try='test -s conftest$ac_exeext'
15823   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15824   (eval $ac_try) 2>&5
15825   ac_status=$?
15826   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15827   (exit $ac_status); }; }; then
15828   eval "$as_ac_var=yes"
15829 else
15830   echo "$as_me: failed program was:" >&5
15831 sed 's/^/| /' conftest.$ac_ext >&5
15832
15833 eval "$as_ac_var=no"
15834 fi
15835 rm -f conftest.err conftest.$ac_objext \
15836       conftest$ac_exeext conftest.$ac_ext
15837 fi
15838 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15839 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15840 if test `eval echo '${'$as_ac_var'}'` = yes; then
15841   cat >>confdefs.h <<_ACEOF
15842 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15843 _ACEOF
15844  break
15845 fi
15846 done
15847
15848
15849 # Check for one of atexit() or on_exit()
15850
15851 for ac_func in atexit
15852 do
15853 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15854 echo "$as_me:$LINENO: checking for $ac_func" >&5
15855 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15856 if eval "test \"\${$as_ac_var+set}\" = set"; then
15857   echo $ECHO_N "(cached) $ECHO_C" >&6
15858 else
15859   cat >conftest.$ac_ext <<_ACEOF
15860 /* confdefs.h.  */
15861 _ACEOF
15862 cat confdefs.h >>conftest.$ac_ext
15863 cat >>conftest.$ac_ext <<_ACEOF
15864 /* end confdefs.h.  */
15865 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15866    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15867 #define $ac_func innocuous_$ac_func
15868
15869 /* System header to define __stub macros and hopefully few prototypes,
15870     which can conflict with char $ac_func (); below.
15871     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15872     <limits.h> exists even on freestanding compilers.  */
15873
15874 #ifdef __STDC__
15875 # include <limits.h>
15876 #else
15877 # include <assert.h>
15878 #endif
15879
15880 #undef $ac_func
15881
15882 /* Override any gcc2 internal prototype to avoid an error.  */
15883 #ifdef __cplusplus
15884 extern "C"
15885 {
15886 #endif
15887 /* We use char because int might match the return type of a gcc2
15888    builtin and then its argument prototype would still apply.  */
15889 char $ac_func ();
15890 /* The GNU C library defines this for functions which it implements
15891     to always fail with ENOSYS.  Some functions are actually named
15892     something starting with __ and the normal name is an alias.  */
15893 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15894 choke me
15895 #else
15896 char (*f) () = $ac_func;
15897 #endif
15898 #ifdef __cplusplus
15899 }
15900 #endif
15901
15902 int
15903 main ()
15904 {
15905 return f != $ac_func;
15906   ;
15907   return 0;
15908 }
15909 _ACEOF
15910 rm -f conftest.$ac_objext conftest$ac_exeext
15911 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15912   (eval $ac_link) 2>conftest.er1
15913   ac_status=$?
15914   grep -v '^ *+' conftest.er1 >conftest.err
15915   rm -f conftest.er1
15916   cat conftest.err >&5
15917   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15918   (exit $ac_status); } &&
15919          { ac_try='test -z "$ac_c_werror_flag"
15920                          || test ! -s conftest.err'
15921   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15922   (eval $ac_try) 2>&5
15923   ac_status=$?
15924   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15925   (exit $ac_status); }; } &&
15926          { ac_try='test -s conftest$ac_exeext'
15927   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15928   (eval $ac_try) 2>&5
15929   ac_status=$?
15930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15931   (exit $ac_status); }; }; then
15932   eval "$as_ac_var=yes"
15933 else
15934   echo "$as_me: failed program was:" >&5
15935 sed 's/^/| /' conftest.$ac_ext >&5
15936
15937 eval "$as_ac_var=no"
15938 fi
15939 rm -f conftest.err conftest.$ac_objext \
15940       conftest$ac_exeext conftest.$ac_ext
15941 fi
15942 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
15943 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
15944 if test `eval echo '${'$as_ac_var'}'` = yes; then
15945   cat >>confdefs.h <<_ACEOF
15946 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15947 _ACEOF
15948
15949 else
15950
15951 for ac_func in on_exit
15952 do
15953 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15954 echo "$as_me:$LINENO: checking for $ac_func" >&5
15955 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
15956 if eval "test \"\${$as_ac_var+set}\" = set"; then
15957   echo $ECHO_N "(cached) $ECHO_C" >&6
15958 else
15959   cat >conftest.$ac_ext <<_ACEOF
15960 /* confdefs.h.  */
15961 _ACEOF
15962 cat confdefs.h >>conftest.$ac_ext
15963 cat >>conftest.$ac_ext <<_ACEOF
15964 /* end confdefs.h.  */
15965 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15966    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15967 #define $ac_func innocuous_$ac_func
15968
15969 /* System header to define __stub macros and hopefully few prototypes,
15970     which can conflict with char $ac_func (); below.
15971     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15972     <limits.h> exists even on freestanding compilers.  */
15973
15974 #ifdef __STDC__
15975 # include <limits.h>
15976 #else
15977 # include <assert.h>
15978 #endif
15979
15980 #undef $ac_func
15981
15982 /* Override any gcc2 internal prototype to avoid an error.  */
15983 #ifdef __cplusplus
15984 extern "C"
15985 {
15986 #endif
15987 /* We use char because int might match the return type of a gcc2
15988    builtin and then its argument prototype would still apply.  */
15989 char $ac_func ();
15990 /* The GNU C library defines this for functions which it implements
15991     to always fail with ENOSYS.  Some functions are actually named
15992     something starting with __ and the normal name is an alias.  */
15993 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
15994 choke me
15995 #else
15996 char (*f) () = $ac_func;
15997 #endif
15998 #ifdef __cplusplus
15999 }
16000 #endif
16001
16002 int
16003 main ()
16004 {
16005 return f != $ac_func;
16006   ;
16007   return 0;
16008 }
16009 _ACEOF
16010 rm -f conftest.$ac_objext conftest$ac_exeext
16011 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16012   (eval $ac_link) 2>conftest.er1
16013   ac_status=$?
16014   grep -v '^ *+' conftest.er1 >conftest.err
16015   rm -f conftest.er1
16016   cat conftest.err >&5
16017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16018   (exit $ac_status); } &&
16019          { ac_try='test -z "$ac_c_werror_flag"
16020                          || test ! -s conftest.err'
16021   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16022   (eval $ac_try) 2>&5
16023   ac_status=$?
16024   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16025   (exit $ac_status); }; } &&
16026          { ac_try='test -s conftest$ac_exeext'
16027   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16028   (eval $ac_try) 2>&5
16029   ac_status=$?
16030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16031   (exit $ac_status); }; }; then
16032   eval "$as_ac_var=yes"
16033 else
16034   echo "$as_me: failed program was:" >&5
16035 sed 's/^/| /' conftest.$ac_ext >&5
16036
16037 eval "$as_ac_var=no"
16038 fi
16039 rm -f conftest.err conftest.$ac_objext \
16040       conftest$ac_exeext conftest.$ac_ext
16041 fi
16042 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
16043 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
16044 if test `eval echo '${'$as_ac_var'}'` = yes; then
16045   cat >>confdefs.h <<_ACEOF
16046 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16047 _ACEOF
16048
16049 else
16050   { { echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
16051 echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
16052    { (exit 1); exit 1; }; }
16053 fi
16054 done
16055
16056 fi
16057 done
16058
16059
16060 echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
16061 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
16062 if test "${ac_cv_sys_largefile_source+set}" = set; then
16063   echo $ECHO_N "(cached) $ECHO_C" >&6
16064 else
16065   while :; do
16066   ac_cv_sys_largefile_source=no
16067   cat >conftest.$ac_ext <<_ACEOF
16068 /* confdefs.h.  */
16069 _ACEOF
16070 cat confdefs.h >>conftest.$ac_ext
16071 cat >>conftest.$ac_ext <<_ACEOF
16072 /* end confdefs.h.  */
16073 #include <stdio.h>
16074 int
16075 main ()
16076 {
16077 return !fseeko;
16078   ;
16079   return 0;
16080 }
16081 _ACEOF
16082 rm -f conftest.$ac_objext
16083 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16084   (eval $ac_compile) 2>conftest.er1
16085   ac_status=$?
16086   grep -v '^ *+' conftest.er1 >conftest.err
16087   rm -f conftest.er1
16088   cat conftest.err >&5
16089   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16090   (exit $ac_status); } &&
16091          { ac_try='test -z "$ac_c_werror_flag"
16092                          || test ! -s conftest.err'
16093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16094   (eval $ac_try) 2>&5
16095   ac_status=$?
16096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16097   (exit $ac_status); }; } &&
16098          { ac_try='test -s conftest.$ac_objext'
16099   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16100   (eval $ac_try) 2>&5
16101   ac_status=$?
16102   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16103   (exit $ac_status); }; }; then
16104   break
16105 else
16106   echo "$as_me: failed program was:" >&5
16107 sed 's/^/| /' conftest.$ac_ext >&5
16108
16109 fi
16110 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16111   cat >conftest.$ac_ext <<_ACEOF
16112 /* confdefs.h.  */
16113 _ACEOF
16114 cat confdefs.h >>conftest.$ac_ext
16115 cat >>conftest.$ac_ext <<_ACEOF
16116 /* end confdefs.h.  */
16117 #define _LARGEFILE_SOURCE 1
16118 #include <stdio.h>
16119 int
16120 main ()
16121 {
16122 return !fseeko;
16123   ;
16124   return 0;
16125 }
16126 _ACEOF
16127 rm -f conftest.$ac_objext
16128 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16129   (eval $ac_compile) 2>conftest.er1
16130   ac_status=$?
16131   grep -v '^ *+' conftest.er1 >conftest.err
16132   rm -f conftest.er1
16133   cat conftest.err >&5
16134   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16135   (exit $ac_status); } &&
16136          { ac_try='test -z "$ac_c_werror_flag"
16137                          || test ! -s conftest.err'
16138   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16139   (eval $ac_try) 2>&5
16140   ac_status=$?
16141   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16142   (exit $ac_status); }; } &&
16143          { ac_try='test -s conftest.$ac_objext'
16144   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16145   (eval $ac_try) 2>&5
16146   ac_status=$?
16147   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16148   (exit $ac_status); }; }; then
16149   ac_cv_sys_largefile_source=1; break
16150 else
16151   echo "$as_me: failed program was:" >&5
16152 sed 's/^/| /' conftest.$ac_ext >&5
16153
16154 fi
16155 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16156   break
16157 done
16158 fi
16159 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
16160 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
16161 if test "$ac_cv_sys_largefile_source" != no; then
16162
16163 cat >>confdefs.h <<_ACEOF
16164 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
16165 _ACEOF
16166
16167 fi
16168 rm -f conftest*
16169
16170 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
16171 # in glibc 2.1.3, but that breaks too many other things.
16172 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
16173 echo "$as_me:$LINENO: checking for fseeko" >&5
16174 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
16175 if test "${ac_cv_func_fseeko+set}" = set; then
16176   echo $ECHO_N "(cached) $ECHO_C" >&6
16177 else
16178   cat >conftest.$ac_ext <<_ACEOF
16179 /* confdefs.h.  */
16180 _ACEOF
16181 cat confdefs.h >>conftest.$ac_ext
16182 cat >>conftest.$ac_ext <<_ACEOF
16183 /* end confdefs.h.  */
16184 #include <stdio.h>
16185 int
16186 main ()
16187 {
16188 return fseeko && fseeko (stdin, 0, 0);
16189   ;
16190   return 0;
16191 }
16192 _ACEOF
16193 rm -f conftest.$ac_objext conftest$ac_exeext
16194 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16195   (eval $ac_link) 2>conftest.er1
16196   ac_status=$?
16197   grep -v '^ *+' conftest.er1 >conftest.err
16198   rm -f conftest.er1
16199   cat conftest.err >&5
16200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16201   (exit $ac_status); } &&
16202          { ac_try='test -z "$ac_c_werror_flag"
16203                          || test ! -s conftest.err'
16204   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16205   (eval $ac_try) 2>&5
16206   ac_status=$?
16207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16208   (exit $ac_status); }; } &&
16209          { ac_try='test -s conftest$ac_exeext'
16210   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16211   (eval $ac_try) 2>&5
16212   ac_status=$?
16213   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16214   (exit $ac_status); }; }; then
16215   ac_cv_func_fseeko=yes
16216 else
16217   echo "$as_me: failed program was:" >&5
16218 sed 's/^/| /' conftest.$ac_ext >&5
16219
16220 ac_cv_func_fseeko=no
16221 fi
16222 rm -f conftest.err conftest.$ac_objext \
16223       conftest$ac_exeext conftest.$ac_ext
16224 fi
16225 echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
16226 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
16227 if test $ac_cv_func_fseeko = yes; then
16228
16229 cat >>confdefs.h <<\_ACEOF
16230 #define HAVE_FSEEKO 1
16231 _ACEOF
16232
16233 fi
16234
16235
16236 #
16237 # Pthreads
16238 #
16239 # For each platform, we need to know about any special compile and link
16240 # libraries, and whether the normal C function names are thread-safe.
16241 # See the comment at the top of src/port/thread.c for more information.
16242 #
16243 if test "$enable_thread_safety" = yes; then
16244
16245
16246
16247
16248 ac_ext=c
16249 ac_cpp='$CPP $CPPFLAGS'
16250 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16251 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16252 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16253
16254 acx_pthread_ok=no
16255
16256 # We used to check for pthread.h first, but this fails if pthread.h
16257 # requires special compiler flags (e.g. on True64 or Sequent).
16258 # It gets checked for in the link test anyway.
16259
16260 # First of all, check if the user has set any of the PTHREAD_LIBS,
16261 # etcetera environment variables, and if threads linking works using
16262 # them:
16263 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
16264         save_CFLAGS="$CFLAGS"
16265         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16266         save_LIBS="$LIBS"
16267         LIBS="$PTHREAD_LIBS $LIBS"
16268         echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
16269 echo $ECHO_N "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... $ECHO_C" >&6
16270         cat >conftest.$ac_ext <<_ACEOF
16271 /* confdefs.h.  */
16272 _ACEOF
16273 cat confdefs.h >>conftest.$ac_ext
16274 cat >>conftest.$ac_ext <<_ACEOF
16275 /* end confdefs.h.  */
16276
16277 /* Override any gcc2 internal prototype to avoid an error.  */
16278 #ifdef __cplusplus
16279 extern "C"
16280 #endif
16281 /* We use char because int might match the return type of a gcc2
16282    builtin and then its argument prototype would still apply.  */
16283 char pthread_join ();
16284 int
16285 main ()
16286 {
16287 pthread_join ();
16288   ;
16289   return 0;
16290 }
16291 _ACEOF
16292 rm -f conftest.$ac_objext conftest$ac_exeext
16293 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16294   (eval $ac_link) 2>conftest.er1
16295   ac_status=$?
16296   grep -v '^ *+' conftest.er1 >conftest.err
16297   rm -f conftest.er1
16298   cat conftest.err >&5
16299   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16300   (exit $ac_status); } &&
16301          { ac_try='test -z "$ac_c_werror_flag"
16302                          || test ! -s conftest.err'
16303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16304   (eval $ac_try) 2>&5
16305   ac_status=$?
16306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16307   (exit $ac_status); }; } &&
16308          { ac_try='test -s conftest$ac_exeext'
16309   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16310   (eval $ac_try) 2>&5
16311   ac_status=$?
16312   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16313   (exit $ac_status); }; }; then
16314   acx_pthread_ok=yes
16315 else
16316   echo "$as_me: failed program was:" >&5
16317 sed 's/^/| /' conftest.$ac_ext >&5
16318
16319 fi
16320 rm -f conftest.err conftest.$ac_objext \
16321       conftest$ac_exeext conftest.$ac_ext
16322         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
16323 echo "${ECHO_T}$acx_pthread_ok" >&6
16324         if test x"$acx_pthread_ok" = xno; then
16325                 PTHREAD_LIBS=""
16326                 PTHREAD_CFLAGS=""
16327         fi
16328         LIBS="$save_LIBS"
16329         CFLAGS="$save_CFLAGS"
16330 fi
16331
16332 # We must check for the threads library under a number of different
16333 # names; the ordering is very important because some systems
16334 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
16335 # libraries is broken (non-POSIX).
16336
16337 # Create a list of thread flags to try.  Items starting with a "-" are
16338 # C compiler flags, and other items are library names, except for "none"
16339 # which indicates that we try without any flags at all, and "pthread-config"
16340 # which is a program returning the flags for the Pth emulation library.
16341
16342 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
16343
16344 # The ordering *is* (sometimes) important.  Some notes on the
16345 # individual items follow:
16346
16347 # pthreads: AIX (must check this before -lpthread)
16348 # none: in case threads are in libc; should be tried before -Kthread and
16349 #       other compiler flags to prevent continual compiler warnings
16350 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
16351 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
16352 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
16353 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
16354 # -pthreads: Solaris/gcc
16355 # -mthreads: Mingw32/gcc, Lynx/gcc
16356 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
16357 #      doesn't hurt to check since this sometimes defines pthreads too;
16358 #      also defines -D_REENTRANT)
16359 # pthread: Linux, etcetera
16360 # --thread-safe: KAI C++
16361 # pthread-config: use pthread-config program (for GNU Pth library)
16362
16363 case "${host_cpu}-${host_os}" in
16364         *solaris*)
16365
16366         # On Solaris (at least, for some versions), libc contains stubbed
16367         # (non-functional) versions of the pthreads routines, so link-based
16368         # tests will erroneously succeed.  (We need to link with -pthread or
16369         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
16370         # a function called by this macro, so we could check for that, but
16371         # who knows whether they'll stub that too in a future libc.)  So,
16372         # we'll just look for -pthreads and -lpthread first:
16373
16374         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
16375         ;;
16376 esac
16377
16378 if test x"$acx_pthread_ok" = xno; then
16379 for flag in $acx_pthread_flags; do
16380
16381         tryPTHREAD_CFLAGS=""
16382         tryPTHREAD_LIBS=""
16383         case $flag in
16384                 none)
16385                 echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
16386 echo $ECHO_N "checking whether pthreads work without any flags... $ECHO_C" >&6
16387                 ;;
16388
16389                 -*)
16390                 echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
16391 echo $ECHO_N "checking whether pthreads work with $flag... $ECHO_C" >&6
16392                 tryPTHREAD_CFLAGS="$flag"
16393                 ;;
16394
16395                 pthread-config)
16396                 # skip this if we already have flags defined, for PostgreSQL
16397                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
16398                 # Extract the first word of "pthread-config", so it can be a program name with args.
16399 set dummy pthread-config; ac_word=$2
16400 echo "$as_me:$LINENO: checking for $ac_word" >&5
16401 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16402 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
16403   echo $ECHO_N "(cached) $ECHO_C" >&6
16404 else
16405   if test -n "$acx_pthread_config"; then
16406   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
16407 else
16408 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16409 for as_dir in $PATH
16410 do
16411   IFS=$as_save_IFS
16412   test -z "$as_dir" && as_dir=.
16413   for ac_exec_ext in '' $ac_executable_extensions; do
16414   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16415     ac_cv_prog_acx_pthread_config="yes"
16416     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16417     break 2
16418   fi
16419 done
16420 done
16421
16422   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
16423 fi
16424 fi
16425 acx_pthread_config=$ac_cv_prog_acx_pthread_config
16426 if test -n "$acx_pthread_config"; then
16427   echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
16428 echo "${ECHO_T}$acx_pthread_config" >&6
16429 else
16430   echo "$as_me:$LINENO: result: no" >&5
16431 echo "${ECHO_T}no" >&6
16432 fi
16433
16434                 if test x"$acx_pthread_config" = xno; then continue; fi
16435                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
16436                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
16437                 ;;
16438
16439                 *)
16440                 echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
16441 echo $ECHO_N "checking for the pthreads library -l$flag... $ECHO_C" >&6
16442                 tryPTHREAD_LIBS="-l$flag"
16443                 ;;
16444         esac
16445
16446         save_LIBS="$LIBS"
16447         save_CFLAGS="$CFLAGS"
16448         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
16449         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
16450
16451         # Check for various functions.  We must include pthread.h,
16452         # since some functions may be macros.  (On the Sequent, we
16453         # need a special flag -Kthread to make this header compile.)
16454         # We check for pthread_join because it is in -lpthread on IRIX
16455         # while pthread_create is in libc.  We check for pthread_attr_init
16456         # due to DEC craziness with -lpthreads.  We check for
16457         # pthread_cleanup_push because it is one of the few pthread
16458         # functions on Solaris that doesn't have a non-functional libc stub.
16459         # We try pthread_create on general principles.
16460         cat >conftest.$ac_ext <<_ACEOF
16461 /* confdefs.h.  */
16462 _ACEOF
16463 cat confdefs.h >>conftest.$ac_ext
16464 cat >>conftest.$ac_ext <<_ACEOF
16465 /* end confdefs.h.  */
16466 #include <pthread.h>
16467 int
16468 main ()
16469 {
16470 pthread_t th; pthread_join(th, 0);
16471                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
16472                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
16473   ;
16474   return 0;
16475 }
16476 _ACEOF
16477 rm -f conftest.$ac_objext conftest$ac_exeext
16478 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16479   (eval $ac_link) 2>conftest.er1
16480   ac_status=$?
16481   grep -v '^ *+' conftest.er1 >conftest.err
16482   rm -f conftest.er1
16483   cat conftest.err >&5
16484   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16485   (exit $ac_status); } &&
16486          { ac_try='test -z "$ac_c_werror_flag"
16487                          || test ! -s conftest.err'
16488   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16489   (eval $ac_try) 2>&5
16490   ac_status=$?
16491   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16492   (exit $ac_status); }; } &&
16493          { ac_try='test -s conftest$ac_exeext'
16494   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16495   (eval $ac_try) 2>&5
16496   ac_status=$?
16497   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16498   (exit $ac_status); }; }; then
16499   acx_pthread_ok=yes
16500 else
16501   echo "$as_me: failed program was:" >&5
16502 sed 's/^/| /' conftest.$ac_ext >&5
16503
16504 acx_pthread_ok=no
16505 fi
16506 rm -f conftest.err conftest.$ac_objext \
16507       conftest$ac_exeext conftest.$ac_ext
16508
16509         if test "x$acx_pthread_ok" = xyes; then
16510             # Don't use options that are ignored by the compiler.
16511             # We find them by checking stderror.
16512             cat >conftest.$ac_ext <<_ACEOF
16513 int
16514 main (int argc, char **argv)
16515 {
16516   (void) argc;
16517   (void) argv;
16518   return 0;
16519 }
16520 _ACEOF
16521             rm -f conftest.$ac_objext conftest$ac_exeext
16522             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
16523                 # we continue with more flags because Linux needs -lpthread
16524                 # for libpq builds on PostgreSQL.  The test above only
16525                 # tests for building binaries, not shared libraries.
16526                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
16527                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
16528             else   acx_pthread_ok=no
16529             fi
16530         fi
16531
16532         LIBS="$save_LIBS"
16533         CFLAGS="$save_CFLAGS"
16534
16535         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
16536 echo "${ECHO_T}$acx_pthread_ok" >&6
16537 done
16538 fi
16539
16540 # Various other checks:
16541 if test "x$acx_pthread_ok" = xyes; then
16542         save_LIBS="$LIBS"
16543         LIBS="$PTHREAD_LIBS $LIBS"
16544         save_CFLAGS="$CFLAGS"
16545         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16546
16547         # Detect AIX lossage: threads are created detached by default
16548         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
16549         echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
16550 echo $ECHO_N "checking for joinable pthread attribute... $ECHO_C" >&6
16551         cat >conftest.$ac_ext <<_ACEOF
16552 /* confdefs.h.  */
16553 _ACEOF
16554 cat confdefs.h >>conftest.$ac_ext
16555 cat >>conftest.$ac_ext <<_ACEOF
16556 /* end confdefs.h.  */
16557 #include <pthread.h>
16558 int
16559 main ()
16560 {
16561 int attr=PTHREAD_CREATE_JOINABLE;
16562   ;
16563   return 0;
16564 }
16565 _ACEOF
16566 rm -f conftest.$ac_objext conftest$ac_exeext
16567 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16568   (eval $ac_link) 2>conftest.er1
16569   ac_status=$?
16570   grep -v '^ *+' conftest.er1 >conftest.err
16571   rm -f conftest.er1
16572   cat conftest.err >&5
16573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16574   (exit $ac_status); } &&
16575          { ac_try='test -z "$ac_c_werror_flag"
16576                          || test ! -s conftest.err'
16577   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16578   (eval $ac_try) 2>&5
16579   ac_status=$?
16580   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16581   (exit $ac_status); }; } &&
16582          { ac_try='test -s conftest$ac_exeext'
16583   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16584   (eval $ac_try) 2>&5
16585   ac_status=$?
16586   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16587   (exit $ac_status); }; }; then
16588   ok=PTHREAD_CREATE_JOINABLE
16589 else
16590   echo "$as_me: failed program was:" >&5
16591 sed 's/^/| /' conftest.$ac_ext >&5
16592
16593 ok=unknown
16594 fi
16595 rm -f conftest.err conftest.$ac_objext \
16596       conftest$ac_exeext conftest.$ac_ext
16597         if test x"$ok" = xunknown; then
16598                 cat >conftest.$ac_ext <<_ACEOF
16599 /* confdefs.h.  */
16600 _ACEOF
16601 cat confdefs.h >>conftest.$ac_ext
16602 cat >>conftest.$ac_ext <<_ACEOF
16603 /* end confdefs.h.  */
16604 #include <pthread.h>
16605 int
16606 main ()
16607 {
16608 int attr=PTHREAD_CREATE_UNDETACHED;
16609   ;
16610   return 0;
16611 }
16612 _ACEOF
16613 rm -f conftest.$ac_objext conftest$ac_exeext
16614 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16615   (eval $ac_link) 2>conftest.er1
16616   ac_status=$?
16617   grep -v '^ *+' conftest.er1 >conftest.err
16618   rm -f conftest.er1
16619   cat conftest.err >&5
16620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16621   (exit $ac_status); } &&
16622          { ac_try='test -z "$ac_c_werror_flag"
16623                          || test ! -s conftest.err'
16624   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16625   (eval $ac_try) 2>&5
16626   ac_status=$?
16627   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16628   (exit $ac_status); }; } &&
16629          { ac_try='test -s conftest$ac_exeext'
16630   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16631   (eval $ac_try) 2>&5
16632   ac_status=$?
16633   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16634   (exit $ac_status); }; }; then
16635   ok=PTHREAD_CREATE_UNDETACHED
16636 else
16637   echo "$as_me: failed program was:" >&5
16638 sed 's/^/| /' conftest.$ac_ext >&5
16639
16640 ok=unknown
16641 fi
16642 rm -f conftest.err conftest.$ac_objext \
16643       conftest$ac_exeext conftest.$ac_ext
16644         fi
16645         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
16646
16647 cat >>confdefs.h <<\_ACEOF
16648 #define PTHREAD_CREATE_JOINABLE $ok
16649 _ACEOF
16650
16651         fi
16652         echo "$as_me:$LINENO: result: ${ok}" >&5
16653 echo "${ECHO_T}${ok}" >&6
16654         if test x"$ok" = xunknown; then
16655                 { echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
16656 echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
16657         fi
16658
16659         echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
16660 echo $ECHO_N "checking if more special flags are required for pthreads... $ECHO_C" >&6
16661         flag=no
16662 # We always add these in PostgreSQL
16663 #       case "${host_cpu}-${host_os}" in
16664 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
16665 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
16666 #       esac
16667         echo "$as_me:$LINENO: result: ${flag}" >&5
16668 echo "${ECHO_T}${flag}" >&6
16669         if test "x$flag" != xno; then
16670                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
16671         fi
16672
16673         LIBS="$save_LIBS"
16674         CFLAGS="$save_CFLAGS"
16675
16676 # Supporting cc_r would require a special CC in all places that
16677 # use libpq, and that is ugly, so we don't do it.  Users can still
16678 # define their compiler as cc_r to do thread builds of everything.
16679         # More AIX lossage: must compile with cc_r
16680         # Extract the first word of "cc_r", so it can be a program name with args.
16681 set dummy cc_r; ac_word=$2
16682 echo "$as_me:$LINENO: checking for $ac_word" >&5
16683 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
16684 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
16685   echo $ECHO_N "(cached) $ECHO_C" >&6
16686 else
16687   if test -n "$PTHREAD_CC"; then
16688   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
16689 else
16690 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16691 for as_dir in $PATH
16692 do
16693   IFS=$as_save_IFS
16694   test -z "$as_dir" && as_dir=.
16695   for ac_exec_ext in '' $ac_executable_extensions; do
16696   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
16697     ac_cv_prog_PTHREAD_CC="cc_r"
16698     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
16699     break 2
16700   fi
16701 done
16702 done
16703
16704   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
16705 fi
16706 fi
16707 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
16708 if test -n "$PTHREAD_CC"; then
16709   echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
16710 echo "${ECHO_T}$PTHREAD_CC" >&6
16711 else
16712   echo "$as_me:$LINENO: result: no" >&5
16713 echo "${ECHO_T}no" >&6
16714 fi
16715
16716 else
16717         PTHREAD_CC="$CC"
16718 fi
16719
16720
16721
16722
16723
16724 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
16725 if test x"$acx_pthread_ok" = xyes; then
16726
16727 cat >>confdefs.h <<\_ACEOF
16728 #define HAVE_PTHREAD 1
16729 _ACEOF
16730
16731         :
16732 else
16733         acx_pthread_ok=no
16734
16735 fi
16736 ac_ext=c
16737 ac_cpp='$CPP $CPPFLAGS'
16738 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
16739 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
16740 ac_compiler_gnu=$ac_cv_c_compiler_gnu
16741
16742         # set thread flags
16743
16744 # Some platforms use these, so just defineed them.  They can't hurt if they
16745 # are not supported.
16746 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
16747
16748
16749 # At this point, we don't want to muck with the compiler name for threading.
16750 # Let's see who fails, perhaps AIX.  2004-04-23
16751 if test "$PTHREAD_CC" != "$CC"; then
16752 { { echo "$as_me:$LINENO: error:
16753 PostgreSQL does not support platforms that require a special compiler
16754 for thread safety." >&5
16755 echo "$as_me: error:
16756 PostgreSQL does not support platforms that require a special compiler
16757 for thread safety." >&2;}
16758    { (exit 1); exit 1; }; }
16759 fi
16760
16761 if test "$THREAD_SUPPORT" = no; then
16762 { { echo "$as_me:$LINENO: error: cannot enable threads on this platform
16763 This platform is known to not support thread-safe programs.  For details,
16764 compile and run src/bin/pg_thread_test." >&5
16765 echo "$as_me: error: cannot enable threads on this platform
16766 This platform is known to not support thread-safe programs.  For details,
16767 compile and run src/bin/pg_thread_test." >&2;}
16768    { (exit 1); exit 1; }; }
16769 fi
16770
16771 # Check for *_r functions
16772 _CFLAGS="$CFLAGS"
16773 _LIBS="$LIBS"
16774 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
16775 LIBS="$LIBS $PTHREAD_LIBS"
16776
16777 if test "${ac_cv_header_pthread_h+set}" = set; then
16778   echo "$as_me:$LINENO: checking for pthread.h" >&5
16779 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
16780 if test "${ac_cv_header_pthread_h+set}" = set; then
16781   echo $ECHO_N "(cached) $ECHO_C" >&6
16782 fi
16783 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
16784 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
16785 else
16786   # Is the header compilable?
16787 echo "$as_me:$LINENO: checking pthread.h usability" >&5
16788 echo $ECHO_N "checking pthread.h usability... $ECHO_C" >&6
16789 cat >conftest.$ac_ext <<_ACEOF
16790 /* confdefs.h.  */
16791 _ACEOF
16792 cat confdefs.h >>conftest.$ac_ext
16793 cat >>conftest.$ac_ext <<_ACEOF
16794 /* end confdefs.h.  */
16795 $ac_includes_default
16796 #include <pthread.h>
16797 _ACEOF
16798 rm -f conftest.$ac_objext
16799 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16800   (eval $ac_compile) 2>conftest.er1
16801   ac_status=$?
16802   grep -v '^ *+' conftest.er1 >conftest.err
16803   rm -f conftest.er1
16804   cat conftest.err >&5
16805   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16806   (exit $ac_status); } &&
16807          { ac_try='test -z "$ac_c_werror_flag"
16808                          || test ! -s conftest.err'
16809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16810   (eval $ac_try) 2>&5
16811   ac_status=$?
16812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16813   (exit $ac_status); }; } &&
16814          { ac_try='test -s conftest.$ac_objext'
16815   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16816   (eval $ac_try) 2>&5
16817   ac_status=$?
16818   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16819   (exit $ac_status); }; }; then
16820   ac_header_compiler=yes
16821 else
16822   echo "$as_me: failed program was:" >&5
16823 sed 's/^/| /' conftest.$ac_ext >&5
16824
16825 ac_header_compiler=no
16826 fi
16827 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
16828 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16829 echo "${ECHO_T}$ac_header_compiler" >&6
16830
16831 # Is the header present?
16832 echo "$as_me:$LINENO: checking pthread.h presence" >&5
16833 echo $ECHO_N "checking pthread.h presence... $ECHO_C" >&6
16834 cat >conftest.$ac_ext <<_ACEOF
16835 /* confdefs.h.  */
16836 _ACEOF
16837 cat confdefs.h >>conftest.$ac_ext
16838 cat >>conftest.$ac_ext <<_ACEOF
16839 /* end confdefs.h.  */
16840 #include <pthread.h>
16841 _ACEOF
16842 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
16843   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
16844   ac_status=$?
16845   grep -v '^ *+' conftest.er1 >conftest.err
16846   rm -f conftest.er1
16847   cat conftest.err >&5
16848   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16849   (exit $ac_status); } >/dev/null; then
16850   if test -s conftest.err; then
16851     ac_cpp_err=$ac_c_preproc_warn_flag
16852     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
16853   else
16854     ac_cpp_err=
16855   fi
16856 else
16857   ac_cpp_err=yes
16858 fi
16859 if test -z "$ac_cpp_err"; then
16860   ac_header_preproc=yes
16861 else
16862   echo "$as_me: failed program was:" >&5
16863 sed 's/^/| /' conftest.$ac_ext >&5
16864
16865   ac_header_preproc=no
16866 fi
16867 rm -f conftest.err conftest.$ac_ext
16868 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16869 echo "${ECHO_T}$ac_header_preproc" >&6
16870
16871 # So?  What about this header?
16872 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16873   yes:no: )
16874     { echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
16875 echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
16876     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
16877 echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
16878     ac_header_preproc=yes
16879     ;;
16880   no:yes:* )
16881     { echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
16882 echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
16883     { echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
16884 echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
16885     { echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
16886 echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
16887     { echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
16888 echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
16889     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
16890 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
16891     { echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
16892 echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
16893     (
16894       cat <<\_ASBOX
16895 ## ---------------------------------------- ##
16896 ## Report this to pgsql-bugs@postgresql.org ##
16897 ## ---------------------------------------- ##
16898 _ASBOX
16899     ) |
16900       sed "s/^/$as_me: WARNING:     /" >&2
16901     ;;
16902 esac
16903 echo "$as_me:$LINENO: checking for pthread.h" >&5
16904 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
16905 if test "${ac_cv_header_pthread_h+set}" = set; then
16906   echo $ECHO_N "(cached) $ECHO_C" >&6
16907 else
16908   ac_cv_header_pthread_h=$ac_header_preproc
16909 fi
16910 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
16911 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
16912
16913 fi
16914 if test $ac_cv_header_pthread_h = yes; then
16915   :
16916 else
16917   { { echo "$as_me:$LINENO: error: pthread.h not found, required for --enable-thread-safety" >&5
16918 echo "$as_me: error: pthread.h not found, required for --enable-thread-safety" >&2;}
16919    { (exit 1); exit 1; }; }
16920 fi
16921
16922
16923
16924
16925
16926
16927 for ac_func in strerror_r getpwuid_r gethostbyname_r
16928 do
16929 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16930 echo "$as_me:$LINENO: checking for $ac_func" >&5
16931 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
16932 if eval "test \"\${$as_ac_var+set}\" = set"; then
16933   echo $ECHO_N "(cached) $ECHO_C" >&6
16934 else
16935   cat >conftest.$ac_ext <<_ACEOF
16936 /* confdefs.h.  */
16937 _ACEOF
16938 cat confdefs.h >>conftest.$ac_ext
16939 cat >>conftest.$ac_ext <<_ACEOF
16940 /* end confdefs.h.  */
16941 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16942    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16943 #define $ac_func innocuous_$ac_func
16944
16945 /* System header to define __stub macros and hopefully few prototypes,
16946     which can conflict with char $ac_func (); below.
16947     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16948     <limits.h> exists even on freestanding compilers.  */
16949
16950 #ifdef __STDC__
16951 # include <limits.h>
16952 #else
16953 # include <assert.h>
16954 #endif
16955
16956 #undef $ac_func
16957
16958 /* Override any gcc2 internal prototype to avoid an error.  */
16959 #ifdef __cplusplus
16960 extern "C"
16961 {
16962 #endif
16963 /* We use char because int might match the return type of a gcc2
16964    builtin and then its argument prototype would still apply.  */
16965 char $ac_func ();
16966 /* The GNU C library defines this for functions which it implements
16967     to always fail with ENOSYS.  Some functions are actually named
16968     something starting with __ and the normal name is an alias.  */
16969 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
16970 choke me
16971 #else
16972 char (*f) () = $ac_func;
16973 #endif
16974 #ifdef __cplusplus
16975 }
16976 #endif
16977
16978 int
16979 main ()
16980 {
16981 return f != $ac_func;
16982   ;
16983   return 0;
16984 }
16985 _ACEOF
16986 rm -f conftest.$ac_objext conftest$ac_exeext
16987 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16988   (eval $ac_link) 2>conftest.er1
16989   ac_status=$?
16990   grep -v '^ *+' conftest.er1 >conftest.err
16991   rm -f conftest.er1
16992   cat conftest.err >&5
16993   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16994   (exit $ac_status); } &&
16995          { ac_try='test -z "$ac_c_werror_flag"
16996                          || test ! -s conftest.err'
16997   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16998   (eval $ac_try) 2>&5
16999   ac_status=$?
17000   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17001   (exit $ac_status); }; } &&
17002          { ac_try='test -s conftest$ac_exeext'
17003   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17004   (eval $ac_try) 2>&5
17005   ac_status=$?
17006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17007   (exit $ac_status); }; }; then
17008   eval "$as_ac_var=yes"
17009 else
17010   echo "$as_me: failed program was:" >&5
17011 sed 's/^/| /' conftest.$ac_ext >&5
17012
17013 eval "$as_ac_var=no"
17014 fi
17015 rm -f conftest.err conftest.$ac_objext \
17016       conftest$ac_exeext conftest.$ac_ext
17017 fi
17018 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
17019 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
17020 if test `eval echo '${'$as_ac_var'}'` = yes; then
17021   cat >>confdefs.h <<_ACEOF
17022 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17023 _ACEOF
17024
17025 fi
17026 done
17027
17028
17029 # Do test here with the proper thread flags
17030 echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
17031 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6
17032 if test "${pgac_func_getpwuid_r_5arg+set}" = set; then
17033   echo $ECHO_N "(cached) $ECHO_C" >&6
17034 else
17035   cat >conftest.$ac_ext <<_ACEOF
17036 /* confdefs.h.  */
17037 _ACEOF
17038 cat confdefs.h >>conftest.$ac_ext
17039 cat >>conftest.$ac_ext <<_ACEOF
17040 /* end confdefs.h.  */
17041 #include <sys/types.h>
17042 #include <pwd.h>
17043 int
17044 main ()
17045 {
17046 uid_t uid;
17047 struct passwd *space;
17048 char *buf;
17049 size_t bufsize;
17050 struct passwd **result;
17051 getpwuid_r(uid, space, buf, bufsize, result);
17052   ;
17053   return 0;
17054 }
17055 _ACEOF
17056 rm -f conftest.$ac_objext
17057 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17058   (eval $ac_compile) 2>conftest.er1
17059   ac_status=$?
17060   grep -v '^ *+' conftest.er1 >conftest.err
17061   rm -f conftest.er1
17062   cat conftest.err >&5
17063   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17064   (exit $ac_status); } &&
17065          { ac_try='test -z "$ac_c_werror_flag"
17066                          || test ! -s conftest.err'
17067   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17068   (eval $ac_try) 2>&5
17069   ac_status=$?
17070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17071   (exit $ac_status); }; } &&
17072          { ac_try='test -s conftest.$ac_objext'
17073   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17074   (eval $ac_try) 2>&5
17075   ac_status=$?
17076   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17077   (exit $ac_status); }; }; then
17078   pgac_func_getpwuid_r_5arg=yes
17079 else
17080   echo "$as_me: failed program was:" >&5
17081 sed 's/^/| /' conftest.$ac_ext >&5
17082
17083 pgac_func_getpwuid_r_5arg=no
17084 fi
17085 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17086 fi
17087 echo "$as_me:$LINENO: result: $pgac_func_getpwuid_r_5arg" >&5
17088 echo "${ECHO_T}$pgac_func_getpwuid_r_5arg" >&6
17089 if test x"$pgac_func_getpwuid_r_5arg" = xyes ; then
17090
17091 cat >>confdefs.h <<\_ACEOF
17092 #define GETPWUID_R_5ARG
17093 _ACEOF
17094
17095 fi
17096
17097 echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
17098 echo $ECHO_N "checking whether strerror_r returns int... $ECHO_C" >&6
17099 if test "${pgac_func_strerror_r_int+set}" = set; then
17100   echo $ECHO_N "(cached) $ECHO_C" >&6
17101 else
17102   cat >conftest.$ac_ext <<_ACEOF
17103 /* confdefs.h.  */
17104 _ACEOF
17105 cat confdefs.h >>conftest.$ac_ext
17106 cat >>conftest.$ac_ext <<_ACEOF
17107 /* end confdefs.h.  */
17108 #include <string.h>
17109 int
17110 main ()
17111 {
17112 #ifndef _AIX
17113 int strerror_r(int, char *, size_t);
17114 #else
17115 /* Older AIX has 'int' for the third argument so we don't test the args. */
17116 int strerror_r();
17117 #endif
17118   ;
17119   return 0;
17120 }
17121 _ACEOF
17122 rm -f conftest.$ac_objext
17123 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17124   (eval $ac_compile) 2>conftest.er1
17125   ac_status=$?
17126   grep -v '^ *+' conftest.er1 >conftest.err
17127   rm -f conftest.er1
17128   cat conftest.err >&5
17129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17130   (exit $ac_status); } &&
17131          { ac_try='test -z "$ac_c_werror_flag"
17132                          || test ! -s conftest.err'
17133   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17134   (eval $ac_try) 2>&5
17135   ac_status=$?
17136   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17137   (exit $ac_status); }; } &&
17138          { ac_try='test -s conftest.$ac_objext'
17139   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17140   (eval $ac_try) 2>&5
17141   ac_status=$?
17142   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17143   (exit $ac_status); }; }; then
17144   pgac_func_strerror_r_int=yes
17145 else
17146   echo "$as_me: failed program was:" >&5
17147 sed 's/^/| /' conftest.$ac_ext >&5
17148
17149 pgac_func_strerror_r_int=no
17150 fi
17151 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17152 fi
17153 echo "$as_me:$LINENO: result: $pgac_func_strerror_r_int" >&5
17154 echo "${ECHO_T}$pgac_func_strerror_r_int" >&6
17155 if test x"$pgac_func_strerror_r_int" = xyes ; then
17156
17157 cat >>confdefs.h <<\_ACEOF
17158 #define STRERROR_R_INT
17159 _ACEOF
17160
17161 fi
17162
17163
17164 CFLAGS="$_CFLAGS"
17165 LIBS="$_LIBS"
17166
17167 else
17168 # do not use values from template file
17169 PTHREAD_CFLAGS=
17170 PTHREAD_LIBS=
17171 fi
17172
17173
17174
17175
17176
17177 # We can test for libldap_r only after we know PTHREAD_LIBS
17178 if test "$with_ldap" = yes ; then
17179   _LIBS="$LIBS"
17180   if test "$PORTNAME" != "win32"; then
17181
17182 echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
17183 echo $ECHO_N "checking for ldap_bind in -lldap... $ECHO_C" >&6
17184 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
17185   echo $ECHO_N "(cached) $ECHO_C" >&6
17186 else
17187   ac_check_lib_save_LIBS=$LIBS
17188 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
17189 cat >conftest.$ac_ext <<_ACEOF
17190 /* confdefs.h.  */
17191 _ACEOF
17192 cat confdefs.h >>conftest.$ac_ext
17193 cat >>conftest.$ac_ext <<_ACEOF
17194 /* end confdefs.h.  */
17195
17196 /* Override any gcc2 internal prototype to avoid an error.  */
17197 #ifdef __cplusplus
17198 extern "C"
17199 #endif
17200 /* We use char because int might match the return type of a gcc2
17201    builtin and then its argument prototype would still apply.  */
17202 char ldap_bind ();
17203 int
17204 main ()
17205 {
17206 ldap_bind ();
17207   ;
17208   return 0;
17209 }
17210 _ACEOF
17211 rm -f conftest.$ac_objext conftest$ac_exeext
17212 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17213   (eval $ac_link) 2>conftest.er1
17214   ac_status=$?
17215   grep -v '^ *+' conftest.er1 >conftest.err
17216   rm -f conftest.er1
17217   cat conftest.err >&5
17218   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17219   (exit $ac_status); } &&
17220          { ac_try='test -z "$ac_c_werror_flag"
17221                          || test ! -s conftest.err'
17222   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17223   (eval $ac_try) 2>&5
17224   ac_status=$?
17225   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17226   (exit $ac_status); }; } &&
17227          { ac_try='test -s conftest$ac_exeext'
17228   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17229   (eval $ac_try) 2>&5
17230   ac_status=$?
17231   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17232   (exit $ac_status); }; }; then
17233   ac_cv_lib_ldap_ldap_bind=yes
17234 else
17235   echo "$as_me: failed program was:" >&5
17236 sed 's/^/| /' conftest.$ac_ext >&5
17237
17238 ac_cv_lib_ldap_ldap_bind=no
17239 fi
17240 rm -f conftest.err conftest.$ac_objext \
17241       conftest$ac_exeext conftest.$ac_ext
17242 LIBS=$ac_check_lib_save_LIBS
17243 fi
17244 echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
17245 echo "${ECHO_T}$ac_cv_lib_ldap_ldap_bind" >&6
17246 if test $ac_cv_lib_ldap_ldap_bind = yes; then
17247   cat >>confdefs.h <<_ACEOF
17248 #define HAVE_LIBLDAP 1
17249 _ACEOF
17250
17251   LIBS="-lldap $LIBS"
17252
17253 else
17254   { { echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
17255 echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
17256    { (exit 1); exit 1; }; }
17257 fi
17258
17259     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
17260     if test "$enable_thread_safety" = yes; then
17261       # on some platforms ldap_r fails to link without PTHREAD_LIBS
17262
17263 echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
17264 echo $ECHO_N "checking for ldap_simple_bind in -lldap_r... $ECHO_C" >&6
17265 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
17266   echo $ECHO_N "(cached) $ECHO_C" >&6
17267 else
17268   ac_check_lib_save_LIBS=$LIBS
17269 LIBS="-lldap_r $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
17270 cat >conftest.$ac_ext <<_ACEOF
17271 /* confdefs.h.  */
17272 _ACEOF
17273 cat confdefs.h >>conftest.$ac_ext
17274 cat >>conftest.$ac_ext <<_ACEOF
17275 /* end confdefs.h.  */
17276
17277 /* Override any gcc2 internal prototype to avoid an error.  */
17278 #ifdef __cplusplus
17279 extern "C"
17280 #endif
17281 /* We use char because int might match the return type of a gcc2
17282    builtin and then its argument prototype would still apply.  */
17283 char ldap_simple_bind ();
17284 int
17285 main ()
17286 {
17287 ldap_simple_bind ();
17288   ;
17289   return 0;
17290 }
17291 _ACEOF
17292 rm -f conftest.$ac_objext conftest$ac_exeext
17293 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17294   (eval $ac_link) 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_exeext'
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   ac_cv_lib_ldap_r_ldap_simple_bind=yes
17315 else
17316   echo "$as_me: failed program was:" >&5
17317 sed 's/^/| /' conftest.$ac_ext >&5
17318
17319 ac_cv_lib_ldap_r_ldap_simple_bind=no
17320 fi
17321 rm -f conftest.err conftest.$ac_objext \
17322       conftest$ac_exeext conftest.$ac_ext
17323 LIBS=$ac_check_lib_save_LIBS
17324 fi
17325 echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
17326 echo "${ECHO_T}$ac_cv_lib_ldap_r_ldap_simple_bind" >&6
17327 if test $ac_cv_lib_ldap_r_ldap_simple_bind = yes; then
17328   cat >>confdefs.h <<_ACEOF
17329 #define HAVE_LIBLDAP_R 1
17330 _ACEOF
17331
17332   LIBS="-lldap_r $LIBS"
17333
17334 else
17335   { { echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
17336 echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
17337    { (exit 1); exit 1; }; }
17338 fi
17339
17340       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
17341     else
17342       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
17343     fi
17344   else
17345
17346 echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
17347 echo $ECHO_N "checking for ldap_bind in -lwldap32... $ECHO_C" >&6
17348 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
17349   echo $ECHO_N "(cached) $ECHO_C" >&6
17350 else
17351   ac_check_lib_save_LIBS=$LIBS
17352 LIBS="-lwldap32  $LIBS"
17353 cat >conftest.$ac_ext <<_ACEOF
17354 /* confdefs.h.  */
17355 _ACEOF
17356 cat confdefs.h >>conftest.$ac_ext
17357 cat >>conftest.$ac_ext <<_ACEOF
17358 /* end confdefs.h.  */
17359
17360 /* Override any gcc2 internal prototype to avoid an error.  */
17361 #ifdef __cplusplus
17362 extern "C"
17363 #endif
17364 /* We use char because int might match the return type of a gcc2
17365    builtin and then its argument prototype would still apply.  */
17366 char ldap_bind ();
17367 int
17368 main ()
17369 {
17370 ldap_bind ();
17371   ;
17372   return 0;
17373 }
17374 _ACEOF
17375 rm -f conftest.$ac_objext conftest$ac_exeext
17376 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17377   (eval $ac_link) 2>conftest.er1
17378   ac_status=$?
17379   grep -v '^ *+' conftest.er1 >conftest.err
17380   rm -f conftest.er1
17381   cat conftest.err >&5
17382   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17383   (exit $ac_status); } &&
17384          { ac_try='test -z "$ac_c_werror_flag"
17385                          || test ! -s conftest.err'
17386   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17387   (eval $ac_try) 2>&5
17388   ac_status=$?
17389   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17390   (exit $ac_status); }; } &&
17391          { ac_try='test -s conftest$ac_exeext'
17392   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17393   (eval $ac_try) 2>&5
17394   ac_status=$?
17395   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17396   (exit $ac_status); }; }; then
17397   ac_cv_lib_wldap32_ldap_bind=yes
17398 else
17399   echo "$as_me: failed program was:" >&5
17400 sed 's/^/| /' conftest.$ac_ext >&5
17401
17402 ac_cv_lib_wldap32_ldap_bind=no
17403 fi
17404 rm -f conftest.err conftest.$ac_objext \
17405       conftest$ac_exeext conftest.$ac_ext
17406 LIBS=$ac_check_lib_save_LIBS
17407 fi
17408 echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
17409 echo "${ECHO_T}$ac_cv_lib_wldap32_ldap_bind" >&6
17410 if test $ac_cv_lib_wldap32_ldap_bind = yes; then
17411   cat >>confdefs.h <<_ACEOF
17412 #define HAVE_LIBWLDAP32 1
17413 _ACEOF
17414
17415   LIBS="-lwldap32 $LIBS"
17416
17417 else
17418   { { echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
17419 echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
17420    { (exit 1); exit 1; }; }
17421 fi
17422
17423     LDAP_LIBS_FE="-lwldap32"
17424     LDAP_LIBS_BE="-lwldap32"
17425   fi
17426   LIBS="$_LIBS"
17427 fi
17428
17429
17430
17431
17432 # This test makes sure that run tests work at all.  Sometimes a shared
17433 # library is found by the linker, but the runtime linker can't find it.
17434 # This check should come after all modifications of compiler or linker
17435 # variables, and before any other run tests.
17436 echo "$as_me:$LINENO: checking test program" >&5
17437 echo $ECHO_N "checking test program... $ECHO_C" >&6
17438 if test "$cross_compiling" = yes; then
17439   echo "$as_me:$LINENO: result: cross-compiling" >&5
17440 echo "${ECHO_T}cross-compiling" >&6
17441 else
17442   cat >conftest.$ac_ext <<_ACEOF
17443 /* confdefs.h.  */
17444 _ACEOF
17445 cat confdefs.h >>conftest.$ac_ext
17446 cat >>conftest.$ac_ext <<_ACEOF
17447 /* end confdefs.h.  */
17448 int main() { return 0; }
17449 _ACEOF
17450 rm -f conftest$ac_exeext
17451 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17452   (eval $ac_link) 2>&5
17453   ac_status=$?
17454   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17455   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17456   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17457   (eval $ac_try) 2>&5
17458   ac_status=$?
17459   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17460   (exit $ac_status); }; }; then
17461   echo "$as_me:$LINENO: result: ok" >&5
17462 echo "${ECHO_T}ok" >&6
17463 else
17464   echo "$as_me: program exited with status $ac_status" >&5
17465 echo "$as_me: failed program was:" >&5
17466 sed 's/^/| /' conftest.$ac_ext >&5
17467
17468 ( exit $ac_status )
17469 echo "$as_me:$LINENO: result: failed" >&5
17470 echo "${ECHO_T}failed" >&6
17471 { { echo "$as_me:$LINENO: error:
17472 Could not execute a simple test program.  This may be a problem
17473 related to locating shared libraries.  Check the file 'config.log'
17474 for the exact reason." >&5
17475 echo "$as_me: error:
17476 Could not execute a simple test program.  This may be a problem
17477 related to locating shared libraries.  Check the file 'config.log'
17478 for the exact reason." >&2;}
17479    { (exit 1); exit 1; }; }
17480 fi
17481 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17482 fi
17483
17484 # --------------------
17485 # Run tests below here
17486 # --------------------
17487
17488 # Force use of our snprintf if system's doesn't do arg control
17489 # See comment above at snprintf test for details.
17490 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
17491   echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
17492 echo $ECHO_N "checking whether printf supports argument control... $ECHO_C" >&6
17493 if test "${pgac_cv_printf_arg_control+set}" = set; then
17494   echo $ECHO_N "(cached) $ECHO_C" >&6
17495 else
17496   if test "$cross_compiling" = yes; then
17497   pgac_cv_printf_arg_control=cross
17498 else
17499   cat >conftest.$ac_ext <<_ACEOF
17500 /* confdefs.h.  */
17501 _ACEOF
17502 cat confdefs.h >>conftest.$ac_ext
17503 cat >>conftest.$ac_ext <<_ACEOF
17504 /* end confdefs.h.  */
17505 #include <stdio.h>
17506 #include <string.h>
17507
17508 int main()
17509 {
17510   char buf[100];
17511
17512   /* can it swap arguments? */
17513   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
17514   if (strcmp(buf, "4 3") != 0)
17515     return 1;
17516   return 0;
17517 }
17518 _ACEOF
17519 rm -f conftest$ac_exeext
17520 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17521   (eval $ac_link) 2>&5
17522   ac_status=$?
17523   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17524   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17525   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17526   (eval $ac_try) 2>&5
17527   ac_status=$?
17528   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17529   (exit $ac_status); }; }; then
17530   pgac_cv_printf_arg_control=yes
17531 else
17532   echo "$as_me: program exited with status $ac_status" >&5
17533 echo "$as_me: failed program was:" >&5
17534 sed 's/^/| /' conftest.$ac_ext >&5
17535
17536 ( exit $ac_status )
17537 pgac_cv_printf_arg_control=no
17538 fi
17539 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17540 fi
17541
17542 fi
17543 echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
17544 echo "${ECHO_T}$pgac_cv_printf_arg_control" >&6
17545
17546   if test $pgac_cv_printf_arg_control != yes ; then
17547     pgac_need_repl_snprintf=yes
17548   fi
17549 fi
17550
17551
17552
17553 echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
17554 echo $ECHO_N "checking whether long int is 64 bits... $ECHO_C" >&6
17555 if test "${pgac_cv_type_long_int_64+set}" = set; then
17556   echo $ECHO_N "(cached) $ECHO_C" >&6
17557 else
17558   if test "$cross_compiling" = yes; then
17559   # If cross-compiling, check the size reported by the compiler and
17560 # trust that the arithmetic works.
17561 cat >conftest.$ac_ext <<_ACEOF
17562 /* confdefs.h.  */
17563 _ACEOF
17564 cat confdefs.h >>conftest.$ac_ext
17565 cat >>conftest.$ac_ext <<_ACEOF
17566 /* end confdefs.h.  */
17567
17568 int
17569 main ()
17570 {
17571 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
17572 test_array [0] = 0
17573
17574   ;
17575   return 0;
17576 }
17577 _ACEOF
17578 rm -f conftest.$ac_objext
17579 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17580   (eval $ac_compile) 2>conftest.er1
17581   ac_status=$?
17582   grep -v '^ *+' conftest.er1 >conftest.err
17583   rm -f conftest.er1
17584   cat conftest.err >&5
17585   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17586   (exit $ac_status); } &&
17587          { ac_try='test -z "$ac_c_werror_flag"
17588                          || test ! -s conftest.err'
17589   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17590   (eval $ac_try) 2>&5
17591   ac_status=$?
17592   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17593   (exit $ac_status); }; } &&
17594          { ac_try='test -s conftest.$ac_objext'
17595   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17596   (eval $ac_try) 2>&5
17597   ac_status=$?
17598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17599   (exit $ac_status); }; }; then
17600   pgac_cv_type_long_int_64=yes
17601 else
17602   echo "$as_me: failed program was:" >&5
17603 sed 's/^/| /' conftest.$ac_ext >&5
17604
17605 pgac_cv_type_long_int_64=no
17606 fi
17607 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17608 else
17609   cat >conftest.$ac_ext <<_ACEOF
17610 /* confdefs.h.  */
17611 _ACEOF
17612 cat confdefs.h >>conftest.$ac_ext
17613 cat >>conftest.$ac_ext <<_ACEOF
17614 /* end confdefs.h.  */
17615 typedef long int ac_int64;
17616
17617 /*
17618  * These are globals to discourage the compiler from folding all the
17619  * arithmetic tests down to compile-time constants.
17620  */
17621 ac_int64 a = 20000001;
17622 ac_int64 b = 40000005;
17623
17624 int does_int64_work()
17625 {
17626   ac_int64 c,d;
17627
17628   if (sizeof(ac_int64) != 8)
17629     return 0;                   /* definitely not the right size */
17630
17631   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
17632   c = a * b;
17633   d = (c + b) / b;
17634   if (d != a+1)
17635     return 0;
17636   return 1;
17637 }
17638 main() {
17639   exit(! does_int64_work());
17640 }
17641 _ACEOF
17642 rm -f conftest$ac_exeext
17643 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17644   (eval $ac_link) 2>&5
17645   ac_status=$?
17646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17647   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17648   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17649   (eval $ac_try) 2>&5
17650   ac_status=$?
17651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17652   (exit $ac_status); }; }; then
17653   pgac_cv_type_long_int_64=yes
17654 else
17655   echo "$as_me: program exited with status $ac_status" >&5
17656 echo "$as_me: failed program was:" >&5
17657 sed 's/^/| /' conftest.$ac_ext >&5
17658
17659 ( exit $ac_status )
17660 pgac_cv_type_long_int_64=no
17661 fi
17662 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17663 fi
17664 fi
17665 echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
17666 echo "${ECHO_T}$pgac_cv_type_long_int_64" >&6
17667
17668 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
17669 if test x"$pgac_cv_type_long_int_64" = xyes ; then
17670
17671 cat >>confdefs.h <<\_ACEOF
17672 #define HAVE_LONG_INT_64
17673 _ACEOF
17674
17675 fi
17676
17677
17678 if test x"$HAVE_LONG_INT_64" = x"no" ; then
17679   echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
17680 echo $ECHO_N "checking whether long long int is 64 bits... $ECHO_C" >&6
17681 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
17682   echo $ECHO_N "(cached) $ECHO_C" >&6
17683 else
17684   if test "$cross_compiling" = yes; then
17685   # If cross-compiling, check the size reported by the compiler and
17686 # trust that the arithmetic works.
17687 cat >conftest.$ac_ext <<_ACEOF
17688 /* confdefs.h.  */
17689 _ACEOF
17690 cat confdefs.h >>conftest.$ac_ext
17691 cat >>conftest.$ac_ext <<_ACEOF
17692 /* end confdefs.h.  */
17693
17694 int
17695 main ()
17696 {
17697 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
17698 test_array [0] = 0
17699
17700   ;
17701   return 0;
17702 }
17703 _ACEOF
17704 rm -f conftest.$ac_objext
17705 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17706   (eval $ac_compile) 2>conftest.er1
17707   ac_status=$?
17708   grep -v '^ *+' conftest.er1 >conftest.err
17709   rm -f conftest.er1
17710   cat conftest.err >&5
17711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17712   (exit $ac_status); } &&
17713          { ac_try='test -z "$ac_c_werror_flag"
17714                          || test ! -s conftest.err'
17715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17716   (eval $ac_try) 2>&5
17717   ac_status=$?
17718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17719   (exit $ac_status); }; } &&
17720          { ac_try='test -s conftest.$ac_objext'
17721   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17722   (eval $ac_try) 2>&5
17723   ac_status=$?
17724   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17725   (exit $ac_status); }; }; then
17726   pgac_cv_type_long_long_int_64=yes
17727 else
17728   echo "$as_me: failed program was:" >&5
17729 sed 's/^/| /' conftest.$ac_ext >&5
17730
17731 pgac_cv_type_long_long_int_64=no
17732 fi
17733 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17734 else
17735   cat >conftest.$ac_ext <<_ACEOF
17736 /* confdefs.h.  */
17737 _ACEOF
17738 cat confdefs.h >>conftest.$ac_ext
17739 cat >>conftest.$ac_ext <<_ACEOF
17740 /* end confdefs.h.  */
17741 typedef long long int ac_int64;
17742
17743 /*
17744  * These are globals to discourage the compiler from folding all the
17745  * arithmetic tests down to compile-time constants.
17746  */
17747 ac_int64 a = 20000001;
17748 ac_int64 b = 40000005;
17749
17750 int does_int64_work()
17751 {
17752   ac_int64 c,d;
17753
17754   if (sizeof(ac_int64) != 8)
17755     return 0;                   /* definitely not the right size */
17756
17757   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
17758   c = a * b;
17759   d = (c + b) / b;
17760   if (d != a+1)
17761     return 0;
17762   return 1;
17763 }
17764 main() {
17765   exit(! does_int64_work());
17766 }
17767 _ACEOF
17768 rm -f conftest$ac_exeext
17769 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17770   (eval $ac_link) 2>&5
17771   ac_status=$?
17772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17773   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17774   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17775   (eval $ac_try) 2>&5
17776   ac_status=$?
17777   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17778   (exit $ac_status); }; }; then
17779   pgac_cv_type_long_long_int_64=yes
17780 else
17781   echo "$as_me: program exited with status $ac_status" >&5
17782 echo "$as_me: failed program was:" >&5
17783 sed 's/^/| /' conftest.$ac_ext >&5
17784
17785 ( exit $ac_status )
17786 pgac_cv_type_long_long_int_64=no
17787 fi
17788 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17789 fi
17790 fi
17791 echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
17792 echo "${ECHO_T}$pgac_cv_type_long_long_int_64" >&6
17793
17794 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
17795 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
17796
17797 cat >>confdefs.h <<\_ACEOF
17798 #define HAVE_LONG_LONG_INT_64
17799 _ACEOF
17800
17801 fi
17802
17803 fi
17804
17805
17806
17807 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
17808   cat >conftest.$ac_ext <<_ACEOF
17809 /* confdefs.h.  */
17810 _ACEOF
17811 cat confdefs.h >>conftest.$ac_ext
17812 cat >>conftest.$ac_ext <<_ACEOF
17813 /* end confdefs.h.  */
17814
17815 #define INT64CONST(x)  x##LL
17816 long long int foo = INT64CONST(0x1234567890123456);
17817
17818 int
17819 main ()
17820 {
17821
17822   ;
17823   return 0;
17824 }
17825 _ACEOF
17826 rm -f conftest.$ac_objext
17827 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17828   (eval $ac_compile) 2>conftest.er1
17829   ac_status=$?
17830   grep -v '^ *+' conftest.er1 >conftest.err
17831   rm -f conftest.er1
17832   cat conftest.err >&5
17833   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17834   (exit $ac_status); } &&
17835          { ac_try='test -z "$ac_c_werror_flag"
17836                          || test ! -s conftest.err'
17837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17838   (eval $ac_try) 2>&5
17839   ac_status=$?
17840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17841   (exit $ac_status); }; } &&
17842          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
17848
17849 cat >>confdefs.h <<\_ACEOF
17850 #define HAVE_LL_CONSTANTS 1
17851 _ACEOF
17852
17853 else
17854   echo "$as_me: failed program was:" >&5
17855 sed 's/^/| /' conftest.$ac_ext >&5
17856
17857 fi
17858 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
17859 fi
17860
17861
17862 # If we found "long int" is 64 bits, assume snprintf handles it.  If
17863 # we found we need to use "long long int", better check.  We cope with
17864 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
17865 # work, fall back to our own snprintf emulation (which we know uses %lld).
17866
17867 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
17868   if test $pgac_need_repl_snprintf = no; then
17869     echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
17870 echo $ECHO_N "checking snprintf format for long long int... $ECHO_C" >&6
17871 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
17872   echo $ECHO_N "(cached) $ECHO_C" >&6
17873 else
17874   for pgac_format in '%lld' '%qd' '%I64d'; do
17875 if test "$cross_compiling" = yes; then
17876   pgac_cv_snprintf_long_long_int_format=cross; break
17877 else
17878   cat >conftest.$ac_ext <<_ACEOF
17879 /* confdefs.h.  */
17880 _ACEOF
17881 cat confdefs.h >>conftest.$ac_ext
17882 cat >>conftest.$ac_ext <<_ACEOF
17883 /* end confdefs.h.  */
17884 #include <stdio.h>
17885 typedef long long int ac_int64;
17886 #define INT64_FORMAT "$pgac_format"
17887
17888 ac_int64 a = 20000001;
17889 ac_int64 b = 40000005;
17890
17891 int does_int64_snprintf_work()
17892 {
17893   ac_int64 c;
17894   char buf[100];
17895
17896   if (sizeof(ac_int64) != 8)
17897     return 0;                   /* doesn't look like the right size */
17898
17899   c = a * b;
17900   snprintf(buf, 100, INT64_FORMAT, c);
17901   if (strcmp(buf, "800000140000005") != 0)
17902     return 0;                   /* either multiply or snprintf is busted */
17903   return 1;
17904 }
17905 main() {
17906   exit(! does_int64_snprintf_work());
17907 }
17908 _ACEOF
17909 rm -f conftest$ac_exeext
17910 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17911   (eval $ac_link) 2>&5
17912   ac_status=$?
17913   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17914   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17915   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17916   (eval $ac_try) 2>&5
17917   ac_status=$?
17918   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17919   (exit $ac_status); }; }; then
17920   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
17921 else
17922   echo "$as_me: program exited with status $ac_status" >&5
17923 echo "$as_me: failed program was:" >&5
17924 sed 's/^/| /' conftest.$ac_ext >&5
17925
17926 fi
17927 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17928 fi
17929 done
17930 fi
17931
17932 LONG_LONG_INT_FORMAT=''
17933
17934 case $pgac_cv_snprintf_long_long_int_format in
17935   cross) echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
17936 echo "${ECHO_T}cannot test (not on host machine)" >&6;;
17937   ?*)    echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
17938 echo "${ECHO_T}$pgac_cv_snprintf_long_long_int_format" >&6
17939          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
17940   *)     echo "$as_me:$LINENO: result: none" >&5
17941 echo "${ECHO_T}none" >&6;;
17942 esac
17943     if test "$LONG_LONG_INT_FORMAT" = ""; then
17944       # Force usage of our own snprintf, since system snprintf is broken
17945       pgac_need_repl_snprintf=yes
17946       LONG_LONG_INT_FORMAT='%lld'
17947     fi
17948   else
17949     # Here if we previously decided we needed to use our own snprintf
17950     LONG_LONG_INT_FORMAT='%lld'
17951   fi
17952   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
17953   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
17954   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
17955 else
17956   # Here if we are not using 'long long int' at all
17957   INT64_FORMAT='"%ld"'
17958   UINT64_FORMAT='"%lu"'
17959 fi
17960
17961
17962 cat >>confdefs.h <<_ACEOF
17963 #define INT64_FORMAT $INT64_FORMAT
17964 _ACEOF
17965
17966
17967
17968 cat >>confdefs.h <<_ACEOF
17969 #define UINT64_FORMAT $UINT64_FORMAT
17970 _ACEOF
17971
17972
17973 # Now we have checked all the reasons to replace snprintf
17974 if test $pgac_need_repl_snprintf = yes; then
17975
17976 cat >>confdefs.h <<\_ACEOF
17977 #define USE_REPL_SNPRINTF 1
17978 _ACEOF
17979
17980   case $LIBOBJS in
17981     "snprintf.$ac_objext"   | \
17982   *" snprintf.$ac_objext"   | \
17983     "snprintf.$ac_objext "* | \
17984   *" snprintf.$ac_objext "* ) ;;
17985   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" ;;
17986 esac
17987
17988 fi
17989
17990 # Need a #define for the size of Datum (unsigned long)
17991 echo "$as_me:$LINENO: checking for unsigned long" >&5
17992 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6
17993 if test "${ac_cv_type_unsigned_long+set}" = set; then
17994   echo $ECHO_N "(cached) $ECHO_C" >&6
17995 else
17996   cat >conftest.$ac_ext <<_ACEOF
17997 /* confdefs.h.  */
17998 _ACEOF
17999 cat confdefs.h >>conftest.$ac_ext
18000 cat >>conftest.$ac_ext <<_ACEOF
18001 /* end confdefs.h.  */
18002 $ac_includes_default
18003 int
18004 main ()
18005 {
18006 if ((unsigned long *) 0)
18007   return 0;
18008 if (sizeof (unsigned long))
18009   return 0;
18010   ;
18011   return 0;
18012 }
18013 _ACEOF
18014 rm -f conftest.$ac_objext
18015 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18016   (eval $ac_compile) 2>conftest.er1
18017   ac_status=$?
18018   grep -v '^ *+' conftest.er1 >conftest.err
18019   rm -f conftest.er1
18020   cat conftest.err >&5
18021   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18022   (exit $ac_status); } &&
18023          { ac_try='test -z "$ac_c_werror_flag"
18024                          || test ! -s conftest.err'
18025   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18026   (eval $ac_try) 2>&5
18027   ac_status=$?
18028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18029   (exit $ac_status); }; } &&
18030          { ac_try='test -s conftest.$ac_objext'
18031   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18032   (eval $ac_try) 2>&5
18033   ac_status=$?
18034   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18035   (exit $ac_status); }; }; then
18036   ac_cv_type_unsigned_long=yes
18037 else
18038   echo "$as_me: failed program was:" >&5
18039 sed 's/^/| /' conftest.$ac_ext >&5
18040
18041 ac_cv_type_unsigned_long=no
18042 fi
18043 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18044 fi
18045 echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
18046 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6
18047
18048 echo "$as_me:$LINENO: checking size of unsigned long" >&5
18049 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6
18050 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
18051   echo $ECHO_N "(cached) $ECHO_C" >&6
18052 else
18053   if test "$ac_cv_type_unsigned_long" = yes; then
18054   # The cast to unsigned long works around a bug in the HP C Compiler
18055   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18056   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18057   # This bug is HP SR number 8606223364.
18058   if test "$cross_compiling" = yes; then
18059   # Depending upon the size, compute the lo and hi bounds.
18060 cat >conftest.$ac_ext <<_ACEOF
18061 /* confdefs.h.  */
18062 _ACEOF
18063 cat confdefs.h >>conftest.$ac_ext
18064 cat >>conftest.$ac_ext <<_ACEOF
18065 /* end confdefs.h.  */
18066 $ac_includes_default
18067 int
18068 main ()
18069 {
18070 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= 0)];
18071 test_array [0] = 0
18072
18073   ;
18074   return 0;
18075 }
18076 _ACEOF
18077 rm -f conftest.$ac_objext
18078 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18079   (eval $ac_compile) 2>conftest.er1
18080   ac_status=$?
18081   grep -v '^ *+' conftest.er1 >conftest.err
18082   rm -f conftest.er1
18083   cat conftest.err >&5
18084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18085   (exit $ac_status); } &&
18086          { ac_try='test -z "$ac_c_werror_flag"
18087                          || test ! -s conftest.err'
18088   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18089   (eval $ac_try) 2>&5
18090   ac_status=$?
18091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18092   (exit $ac_status); }; } &&
18093          { ac_try='test -s conftest.$ac_objext'
18094   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18095   (eval $ac_try) 2>&5
18096   ac_status=$?
18097   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18098   (exit $ac_status); }; }; then
18099   ac_lo=0 ac_mid=0
18100   while :; do
18101     cat >conftest.$ac_ext <<_ACEOF
18102 /* confdefs.h.  */
18103 _ACEOF
18104 cat confdefs.h >>conftest.$ac_ext
18105 cat >>conftest.$ac_ext <<_ACEOF
18106 /* end confdefs.h.  */
18107 $ac_includes_default
18108 int
18109 main ()
18110 {
18111 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
18112 test_array [0] = 0
18113
18114   ;
18115   return 0;
18116 }
18117 _ACEOF
18118 rm -f conftest.$ac_objext
18119 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18120   (eval $ac_compile) 2>conftest.er1
18121   ac_status=$?
18122   grep -v '^ *+' conftest.er1 >conftest.err
18123   rm -f conftest.er1
18124   cat conftest.err >&5
18125   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18126   (exit $ac_status); } &&
18127          { ac_try='test -z "$ac_c_werror_flag"
18128                          || test ! -s conftest.err'
18129   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18130   (eval $ac_try) 2>&5
18131   ac_status=$?
18132   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18133   (exit $ac_status); }; } &&
18134          { ac_try='test -s conftest.$ac_objext'
18135   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18136   (eval $ac_try) 2>&5
18137   ac_status=$?
18138   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18139   (exit $ac_status); }; }; then
18140   ac_hi=$ac_mid; break
18141 else
18142   echo "$as_me: failed program was:" >&5
18143 sed 's/^/| /' conftest.$ac_ext >&5
18144
18145 ac_lo=`expr $ac_mid + 1`
18146                     if test $ac_lo -le $ac_mid; then
18147                       ac_lo= ac_hi=
18148                       break
18149                     fi
18150                     ac_mid=`expr 2 '*' $ac_mid + 1`
18151 fi
18152 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18153   done
18154 else
18155   echo "$as_me: failed program was:" >&5
18156 sed 's/^/| /' conftest.$ac_ext >&5
18157
18158 cat >conftest.$ac_ext <<_ACEOF
18159 /* confdefs.h.  */
18160 _ACEOF
18161 cat confdefs.h >>conftest.$ac_ext
18162 cat >>conftest.$ac_ext <<_ACEOF
18163 /* end confdefs.h.  */
18164 $ac_includes_default
18165 int
18166 main ()
18167 {
18168 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) < 0)];
18169 test_array [0] = 0
18170
18171   ;
18172   return 0;
18173 }
18174 _ACEOF
18175 rm -f conftest.$ac_objext
18176 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18177   (eval $ac_compile) 2>conftest.er1
18178   ac_status=$?
18179   grep -v '^ *+' conftest.er1 >conftest.err
18180   rm -f conftest.er1
18181   cat conftest.err >&5
18182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18183   (exit $ac_status); } &&
18184          { ac_try='test -z "$ac_c_werror_flag"
18185                          || test ! -s conftest.err'
18186   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18187   (eval $ac_try) 2>&5
18188   ac_status=$?
18189   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18190   (exit $ac_status); }; } &&
18191          { ac_try='test -s conftest.$ac_objext'
18192   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18193   (eval $ac_try) 2>&5
18194   ac_status=$?
18195   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18196   (exit $ac_status); }; }; then
18197   ac_hi=-1 ac_mid=-1
18198   while :; do
18199     cat >conftest.$ac_ext <<_ACEOF
18200 /* confdefs.h.  */
18201 _ACEOF
18202 cat confdefs.h >>conftest.$ac_ext
18203 cat >>conftest.$ac_ext <<_ACEOF
18204 /* end confdefs.h.  */
18205 $ac_includes_default
18206 int
18207 main ()
18208 {
18209 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= $ac_mid)];
18210 test_array [0] = 0
18211
18212   ;
18213   return 0;
18214 }
18215 _ACEOF
18216 rm -f conftest.$ac_objext
18217 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18218   (eval $ac_compile) 2>conftest.er1
18219   ac_status=$?
18220   grep -v '^ *+' conftest.er1 >conftest.err
18221   rm -f conftest.er1
18222   cat conftest.err >&5
18223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18224   (exit $ac_status); } &&
18225          { ac_try='test -z "$ac_c_werror_flag"
18226                          || test ! -s conftest.err'
18227   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18228   (eval $ac_try) 2>&5
18229   ac_status=$?
18230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18231   (exit $ac_status); }; } &&
18232          { ac_try='test -s conftest.$ac_objext'
18233   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18234   (eval $ac_try) 2>&5
18235   ac_status=$?
18236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18237   (exit $ac_status); }; }; then
18238   ac_lo=$ac_mid; break
18239 else
18240   echo "$as_me: failed program was:" >&5
18241 sed 's/^/| /' conftest.$ac_ext >&5
18242
18243 ac_hi=`expr '(' $ac_mid ')' - 1`
18244                        if test $ac_mid -le $ac_hi; then
18245                          ac_lo= ac_hi=
18246                          break
18247                        fi
18248                        ac_mid=`expr 2 '*' $ac_mid`
18249 fi
18250 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18251   done
18252 else
18253   echo "$as_me: failed program was:" >&5
18254 sed 's/^/| /' conftest.$ac_ext >&5
18255
18256 ac_lo= ac_hi=
18257 fi
18258 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18259 fi
18260 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18261 # Binary search between lo and hi bounds.
18262 while test "x$ac_lo" != "x$ac_hi"; do
18263   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18264   cat >conftest.$ac_ext <<_ACEOF
18265 /* confdefs.h.  */
18266 _ACEOF
18267 cat confdefs.h >>conftest.$ac_ext
18268 cat >>conftest.$ac_ext <<_ACEOF
18269 /* end confdefs.h.  */
18270 $ac_includes_default
18271 int
18272 main ()
18273 {
18274 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
18275 test_array [0] = 0
18276
18277   ;
18278   return 0;
18279 }
18280 _ACEOF
18281 rm -f conftest.$ac_objext
18282 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18283   (eval $ac_compile) 2>conftest.er1
18284   ac_status=$?
18285   grep -v '^ *+' conftest.er1 >conftest.err
18286   rm -f conftest.er1
18287   cat conftest.err >&5
18288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18289   (exit $ac_status); } &&
18290          { ac_try='test -z "$ac_c_werror_flag"
18291                          || test ! -s conftest.err'
18292   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18293   (eval $ac_try) 2>&5
18294   ac_status=$?
18295   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18296   (exit $ac_status); }; } &&
18297          { ac_try='test -s conftest.$ac_objext'
18298   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18299   (eval $ac_try) 2>&5
18300   ac_status=$?
18301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18302   (exit $ac_status); }; }; then
18303   ac_hi=$ac_mid
18304 else
18305   echo "$as_me: failed program was:" >&5
18306 sed 's/^/| /' conftest.$ac_ext >&5
18307
18308 ac_lo=`expr '(' $ac_mid ')' + 1`
18309 fi
18310 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18311 done
18312 case $ac_lo in
18313 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
18314 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77
18315 See \`config.log' for more details." >&5
18316 echo "$as_me: error: cannot compute sizeof (unsigned long), 77
18317 See \`config.log' for more details." >&2;}
18318    { (exit 1); exit 1; }; } ;;
18319 esac
18320 else
18321   if test "$cross_compiling" = yes; then
18322   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18323 See \`config.log' for more details." >&5
18324 echo "$as_me: error: cannot run test program while cross compiling
18325 See \`config.log' for more details." >&2;}
18326    { (exit 1); exit 1; }; }
18327 else
18328   cat >conftest.$ac_ext <<_ACEOF
18329 /* confdefs.h.  */
18330 _ACEOF
18331 cat confdefs.h >>conftest.$ac_ext
18332 cat >>conftest.$ac_ext <<_ACEOF
18333 /* end confdefs.h.  */
18334 $ac_includes_default
18335 long longval () { return (long) (sizeof (unsigned long)); }
18336 unsigned long ulongval () { return (long) (sizeof (unsigned long)); }
18337 #include <stdio.h>
18338 #include <stdlib.h>
18339 int
18340 main ()
18341 {
18342
18343   FILE *f = fopen ("conftest.val", "w");
18344   if (! f)
18345     exit (1);
18346   if (((long) (sizeof (unsigned long))) < 0)
18347     {
18348       long i = longval ();
18349       if (i != ((long) (sizeof (unsigned long))))
18350         exit (1);
18351       fprintf (f, "%ld\n", i);
18352     }
18353   else
18354     {
18355       unsigned long i = ulongval ();
18356       if (i != ((long) (sizeof (unsigned long))))
18357         exit (1);
18358       fprintf (f, "%lu\n", i);
18359     }
18360   exit (ferror (f) || fclose (f) != 0);
18361
18362   ;
18363   return 0;
18364 }
18365 _ACEOF
18366 rm -f conftest$ac_exeext
18367 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18368   (eval $ac_link) 2>&5
18369   ac_status=$?
18370   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18371   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18372   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18373   (eval $ac_try) 2>&5
18374   ac_status=$?
18375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18376   (exit $ac_status); }; }; then
18377   ac_cv_sizeof_unsigned_long=`cat conftest.val`
18378 else
18379   echo "$as_me: program exited with status $ac_status" >&5
18380 echo "$as_me: failed program was:" >&5
18381 sed 's/^/| /' conftest.$ac_ext >&5
18382
18383 ( exit $ac_status )
18384 { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77
18385 See \`config.log' for more details." >&5
18386 echo "$as_me: error: cannot compute sizeof (unsigned long), 77
18387 See \`config.log' for more details." >&2;}
18388    { (exit 1); exit 1; }; }
18389 fi
18390 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18391 fi
18392 fi
18393 rm -f conftest.val
18394 else
18395   ac_cv_sizeof_unsigned_long=0
18396 fi
18397 fi
18398 echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
18399 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6
18400 cat >>confdefs.h <<_ACEOF
18401 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
18402 _ACEOF
18403
18404
18405
18406 # And one for the size of size_t (enables tweaks for > 32bit address space)
18407 echo "$as_me:$LINENO: checking for size_t" >&5
18408 echo $ECHO_N "checking for size_t... $ECHO_C" >&6
18409 if test "${ac_cv_type_size_t+set}" = set; then
18410   echo $ECHO_N "(cached) $ECHO_C" >&6
18411 else
18412   cat >conftest.$ac_ext <<_ACEOF
18413 /* confdefs.h.  */
18414 _ACEOF
18415 cat confdefs.h >>conftest.$ac_ext
18416 cat >>conftest.$ac_ext <<_ACEOF
18417 /* end confdefs.h.  */
18418 $ac_includes_default
18419 int
18420 main ()
18421 {
18422 if ((size_t *) 0)
18423   return 0;
18424 if (sizeof (size_t))
18425   return 0;
18426   ;
18427   return 0;
18428 }
18429 _ACEOF
18430 rm -f conftest.$ac_objext
18431 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18432   (eval $ac_compile) 2>conftest.er1
18433   ac_status=$?
18434   grep -v '^ *+' conftest.er1 >conftest.err
18435   rm -f conftest.er1
18436   cat conftest.err >&5
18437   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18438   (exit $ac_status); } &&
18439          { ac_try='test -z "$ac_c_werror_flag"
18440                          || test ! -s conftest.err'
18441   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18442   (eval $ac_try) 2>&5
18443   ac_status=$?
18444   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18445   (exit $ac_status); }; } &&
18446          { ac_try='test -s conftest.$ac_objext'
18447   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18448   (eval $ac_try) 2>&5
18449   ac_status=$?
18450   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18451   (exit $ac_status); }; }; then
18452   ac_cv_type_size_t=yes
18453 else
18454   echo "$as_me: failed program was:" >&5
18455 sed 's/^/| /' conftest.$ac_ext >&5
18456
18457 ac_cv_type_size_t=no
18458 fi
18459 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18460 fi
18461 echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5
18462 echo "${ECHO_T}$ac_cv_type_size_t" >&6
18463
18464 echo "$as_me:$LINENO: checking size of size_t" >&5
18465 echo $ECHO_N "checking size of size_t... $ECHO_C" >&6
18466 if test "${ac_cv_sizeof_size_t+set}" = set; then
18467   echo $ECHO_N "(cached) $ECHO_C" >&6
18468 else
18469   if test "$ac_cv_type_size_t" = yes; then
18470   # The cast to unsigned long works around a bug in the HP C Compiler
18471   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18472   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18473   # This bug is HP SR number 8606223364.
18474   if test "$cross_compiling" = yes; then
18475   # Depending upon the size, compute the lo and hi bounds.
18476 cat >conftest.$ac_ext <<_ACEOF
18477 /* confdefs.h.  */
18478 _ACEOF
18479 cat confdefs.h >>conftest.$ac_ext
18480 cat >>conftest.$ac_ext <<_ACEOF
18481 /* end confdefs.h.  */
18482 $ac_includes_default
18483 int
18484 main ()
18485 {
18486 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) >= 0)];
18487 test_array [0] = 0
18488
18489   ;
18490   return 0;
18491 }
18492 _ACEOF
18493 rm -f conftest.$ac_objext
18494 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18495   (eval $ac_compile) 2>conftest.er1
18496   ac_status=$?
18497   grep -v '^ *+' conftest.er1 >conftest.err
18498   rm -f conftest.er1
18499   cat conftest.err >&5
18500   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18501   (exit $ac_status); } &&
18502          { ac_try='test -z "$ac_c_werror_flag"
18503                          || test ! -s conftest.err'
18504   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18505   (eval $ac_try) 2>&5
18506   ac_status=$?
18507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18508   (exit $ac_status); }; } &&
18509          { ac_try='test -s conftest.$ac_objext'
18510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18511   (eval $ac_try) 2>&5
18512   ac_status=$?
18513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18514   (exit $ac_status); }; }; then
18515   ac_lo=0 ac_mid=0
18516   while :; do
18517     cat >conftest.$ac_ext <<_ACEOF
18518 /* confdefs.h.  */
18519 _ACEOF
18520 cat confdefs.h >>conftest.$ac_ext
18521 cat >>conftest.$ac_ext <<_ACEOF
18522 /* end confdefs.h.  */
18523 $ac_includes_default
18524 int
18525 main ()
18526 {
18527 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) <= $ac_mid)];
18528 test_array [0] = 0
18529
18530   ;
18531   return 0;
18532 }
18533 _ACEOF
18534 rm -f conftest.$ac_objext
18535 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18536   (eval $ac_compile) 2>conftest.er1
18537   ac_status=$?
18538   grep -v '^ *+' conftest.er1 >conftest.err
18539   rm -f conftest.er1
18540   cat conftest.err >&5
18541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18542   (exit $ac_status); } &&
18543          { ac_try='test -z "$ac_c_werror_flag"
18544                          || test ! -s conftest.err'
18545   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18546   (eval $ac_try) 2>&5
18547   ac_status=$?
18548   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18549   (exit $ac_status); }; } &&
18550          { ac_try='test -s conftest.$ac_objext'
18551   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18552   (eval $ac_try) 2>&5
18553   ac_status=$?
18554   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18555   (exit $ac_status); }; }; then
18556   ac_hi=$ac_mid; break
18557 else
18558   echo "$as_me: failed program was:" >&5
18559 sed 's/^/| /' conftest.$ac_ext >&5
18560
18561 ac_lo=`expr $ac_mid + 1`
18562                     if test $ac_lo -le $ac_mid; then
18563                       ac_lo= ac_hi=
18564                       break
18565                     fi
18566                     ac_mid=`expr 2 '*' $ac_mid + 1`
18567 fi
18568 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18569   done
18570 else
18571   echo "$as_me: failed program was:" >&5
18572 sed 's/^/| /' conftest.$ac_ext >&5
18573
18574 cat >conftest.$ac_ext <<_ACEOF
18575 /* confdefs.h.  */
18576 _ACEOF
18577 cat confdefs.h >>conftest.$ac_ext
18578 cat >>conftest.$ac_ext <<_ACEOF
18579 /* end confdefs.h.  */
18580 $ac_includes_default
18581 int
18582 main ()
18583 {
18584 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) < 0)];
18585 test_array [0] = 0
18586
18587   ;
18588   return 0;
18589 }
18590 _ACEOF
18591 rm -f conftest.$ac_objext
18592 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18593   (eval $ac_compile) 2>conftest.er1
18594   ac_status=$?
18595   grep -v '^ *+' conftest.er1 >conftest.err
18596   rm -f conftest.er1
18597   cat conftest.err >&5
18598   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18599   (exit $ac_status); } &&
18600          { ac_try='test -z "$ac_c_werror_flag"
18601                          || test ! -s conftest.err'
18602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18603   (eval $ac_try) 2>&5
18604   ac_status=$?
18605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18606   (exit $ac_status); }; } &&
18607          { ac_try='test -s conftest.$ac_objext'
18608   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18609   (eval $ac_try) 2>&5
18610   ac_status=$?
18611   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18612   (exit $ac_status); }; }; then
18613   ac_hi=-1 ac_mid=-1
18614   while :; do
18615     cat >conftest.$ac_ext <<_ACEOF
18616 /* confdefs.h.  */
18617 _ACEOF
18618 cat confdefs.h >>conftest.$ac_ext
18619 cat >>conftest.$ac_ext <<_ACEOF
18620 /* end confdefs.h.  */
18621 $ac_includes_default
18622 int
18623 main ()
18624 {
18625 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) >= $ac_mid)];
18626 test_array [0] = 0
18627
18628   ;
18629   return 0;
18630 }
18631 _ACEOF
18632 rm -f conftest.$ac_objext
18633 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18634   (eval $ac_compile) 2>conftest.er1
18635   ac_status=$?
18636   grep -v '^ *+' conftest.er1 >conftest.err
18637   rm -f conftest.er1
18638   cat conftest.err >&5
18639   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18640   (exit $ac_status); } &&
18641          { ac_try='test -z "$ac_c_werror_flag"
18642                          || test ! -s conftest.err'
18643   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18644   (eval $ac_try) 2>&5
18645   ac_status=$?
18646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18647   (exit $ac_status); }; } &&
18648          { ac_try='test -s conftest.$ac_objext'
18649   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18650   (eval $ac_try) 2>&5
18651   ac_status=$?
18652   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18653   (exit $ac_status); }; }; then
18654   ac_lo=$ac_mid; break
18655 else
18656   echo "$as_me: failed program was:" >&5
18657 sed 's/^/| /' conftest.$ac_ext >&5
18658
18659 ac_hi=`expr '(' $ac_mid ')' - 1`
18660                        if test $ac_mid -le $ac_hi; then
18661                          ac_lo= ac_hi=
18662                          break
18663                        fi
18664                        ac_mid=`expr 2 '*' $ac_mid`
18665 fi
18666 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18667   done
18668 else
18669   echo "$as_me: failed program was:" >&5
18670 sed 's/^/| /' conftest.$ac_ext >&5
18671
18672 ac_lo= ac_hi=
18673 fi
18674 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18675 fi
18676 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18677 # Binary search between lo and hi bounds.
18678 while test "x$ac_lo" != "x$ac_hi"; do
18679   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18680   cat >conftest.$ac_ext <<_ACEOF
18681 /* confdefs.h.  */
18682 _ACEOF
18683 cat confdefs.h >>conftest.$ac_ext
18684 cat >>conftest.$ac_ext <<_ACEOF
18685 /* end confdefs.h.  */
18686 $ac_includes_default
18687 int
18688 main ()
18689 {
18690 static int test_array [1 - 2 * !(((long) (sizeof (size_t))) <= $ac_mid)];
18691 test_array [0] = 0
18692
18693   ;
18694   return 0;
18695 }
18696 _ACEOF
18697 rm -f conftest.$ac_objext
18698 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18699   (eval $ac_compile) 2>conftest.er1
18700   ac_status=$?
18701   grep -v '^ *+' conftest.er1 >conftest.err
18702   rm -f conftest.er1
18703   cat conftest.err >&5
18704   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18705   (exit $ac_status); } &&
18706          { ac_try='test -z "$ac_c_werror_flag"
18707                          || test ! -s conftest.err'
18708   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18709   (eval $ac_try) 2>&5
18710   ac_status=$?
18711   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18712   (exit $ac_status); }; } &&
18713          { ac_try='test -s conftest.$ac_objext'
18714   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18715   (eval $ac_try) 2>&5
18716   ac_status=$?
18717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18718   (exit $ac_status); }; }; then
18719   ac_hi=$ac_mid
18720 else
18721   echo "$as_me: failed program was:" >&5
18722 sed 's/^/| /' conftest.$ac_ext >&5
18723
18724 ac_lo=`expr '(' $ac_mid ')' + 1`
18725 fi
18726 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18727 done
18728 case $ac_lo in
18729 ?*) ac_cv_sizeof_size_t=$ac_lo;;
18730 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t), 77
18731 See \`config.log' for more details." >&5
18732 echo "$as_me: error: cannot compute sizeof (size_t), 77
18733 See \`config.log' for more details." >&2;}
18734    { (exit 1); exit 1; }; } ;;
18735 esac
18736 else
18737   if test "$cross_compiling" = yes; then
18738   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
18739 See \`config.log' for more details." >&5
18740 echo "$as_me: error: cannot run test program while cross compiling
18741 See \`config.log' for more details." >&2;}
18742    { (exit 1); exit 1; }; }
18743 else
18744   cat >conftest.$ac_ext <<_ACEOF
18745 /* confdefs.h.  */
18746 _ACEOF
18747 cat confdefs.h >>conftest.$ac_ext
18748 cat >>conftest.$ac_ext <<_ACEOF
18749 /* end confdefs.h.  */
18750 $ac_includes_default
18751 long longval () { return (long) (sizeof (size_t)); }
18752 unsigned long ulongval () { return (long) (sizeof (size_t)); }
18753 #include <stdio.h>
18754 #include <stdlib.h>
18755 int
18756 main ()
18757 {
18758
18759   FILE *f = fopen ("conftest.val", "w");
18760   if (! f)
18761     exit (1);
18762   if (((long) (sizeof (size_t))) < 0)
18763     {
18764       long i = longval ();
18765       if (i != ((long) (sizeof (size_t))))
18766         exit (1);
18767       fprintf (f, "%ld\n", i);
18768     }
18769   else
18770     {
18771       unsigned long i = ulongval ();
18772       if (i != ((long) (sizeof (size_t))))
18773         exit (1);
18774       fprintf (f, "%lu\n", i);
18775     }
18776   exit (ferror (f) || fclose (f) != 0);
18777
18778   ;
18779   return 0;
18780 }
18781 _ACEOF
18782 rm -f conftest$ac_exeext
18783 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18784   (eval $ac_link) 2>&5
18785   ac_status=$?
18786   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18787   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18788   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18789   (eval $ac_try) 2>&5
18790   ac_status=$?
18791   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18792   (exit $ac_status); }; }; then
18793   ac_cv_sizeof_size_t=`cat conftest.val`
18794 else
18795   echo "$as_me: program exited with status $ac_status" >&5
18796 echo "$as_me: failed program was:" >&5
18797 sed 's/^/| /' conftest.$ac_ext >&5
18798
18799 ( exit $ac_status )
18800 { { echo "$as_me:$LINENO: error: cannot compute sizeof (size_t), 77
18801 See \`config.log' for more details." >&5
18802 echo "$as_me: error: cannot compute sizeof (size_t), 77
18803 See \`config.log' for more details." >&2;}
18804    { (exit 1); exit 1; }; }
18805 fi
18806 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18807 fi
18808 fi
18809 rm -f conftest.val
18810 else
18811   ac_cv_sizeof_size_t=0
18812 fi
18813 fi
18814 echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
18815 echo "${ECHO_T}$ac_cv_sizeof_size_t" >&6
18816 cat >>confdefs.h <<_ACEOF
18817 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
18818 _ACEOF
18819
18820
18821
18822 # Determine memory alignment requirements for the basic C data types.
18823
18824 echo "$as_me:$LINENO: checking for short" >&5
18825 echo $ECHO_N "checking for short... $ECHO_C" >&6
18826 if test "${ac_cv_type_short+set}" = set; then
18827   echo $ECHO_N "(cached) $ECHO_C" >&6
18828 else
18829   cat >conftest.$ac_ext <<_ACEOF
18830 /* confdefs.h.  */
18831 _ACEOF
18832 cat confdefs.h >>conftest.$ac_ext
18833 cat >>conftest.$ac_ext <<_ACEOF
18834 /* end confdefs.h.  */
18835 $ac_includes_default
18836 int
18837 main ()
18838 {
18839 if ((short *) 0)
18840   return 0;
18841 if (sizeof (short))
18842   return 0;
18843   ;
18844   return 0;
18845 }
18846 _ACEOF
18847 rm -f conftest.$ac_objext
18848 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18849   (eval $ac_compile) 2>conftest.er1
18850   ac_status=$?
18851   grep -v '^ *+' conftest.er1 >conftest.err
18852   rm -f conftest.er1
18853   cat conftest.err >&5
18854   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18855   (exit $ac_status); } &&
18856          { ac_try='test -z "$ac_c_werror_flag"
18857                          || test ! -s conftest.err'
18858   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18859   (eval $ac_try) 2>&5
18860   ac_status=$?
18861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18862   (exit $ac_status); }; } &&
18863          { ac_try='test -s conftest.$ac_objext'
18864   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18865   (eval $ac_try) 2>&5
18866   ac_status=$?
18867   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18868   (exit $ac_status); }; }; then
18869   ac_cv_type_short=yes
18870 else
18871   echo "$as_me: failed program was:" >&5
18872 sed 's/^/| /' conftest.$ac_ext >&5
18873
18874 ac_cv_type_short=no
18875 fi
18876 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18877 fi
18878 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
18879 echo "${ECHO_T}$ac_cv_type_short" >&6
18880
18881 echo "$as_me:$LINENO: checking alignment of short" >&5
18882 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6
18883 if test "${pgac_cv_alignof_short+set}" = set; then
18884   echo $ECHO_N "(cached) $ECHO_C" >&6
18885 else
18886   if test "$ac_cv_type_short" = yes; then
18887   if test "$cross_compiling" = yes; then
18888   # Depending upon the size, compute the lo and hi bounds.
18889 cat >conftest.$ac_ext <<_ACEOF
18890 /* confdefs.h.  */
18891 _ACEOF
18892 cat confdefs.h >>conftest.$ac_ext
18893 cat >>conftest.$ac_ext <<_ACEOF
18894 /* end confdefs.h.  */
18895 $ac_includes_default
18896 struct { char filler; short field; } pgac_struct;
18897 int
18898 main ()
18899 {
18900 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
18901 test_array [0] = 0
18902
18903   ;
18904   return 0;
18905 }
18906 _ACEOF
18907 rm -f conftest.$ac_objext
18908 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18909   (eval $ac_compile) 2>conftest.er1
18910   ac_status=$?
18911   grep -v '^ *+' conftest.er1 >conftest.err
18912   rm -f conftest.er1
18913   cat conftest.err >&5
18914   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18915   (exit $ac_status); } &&
18916          { ac_try='test -z "$ac_c_werror_flag"
18917                          || test ! -s conftest.err'
18918   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18919   (eval $ac_try) 2>&5
18920   ac_status=$?
18921   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18922   (exit $ac_status); }; } &&
18923          { ac_try='test -s conftest.$ac_objext'
18924   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18925   (eval $ac_try) 2>&5
18926   ac_status=$?
18927   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18928   (exit $ac_status); }; }; then
18929   ac_lo=0 ac_mid=0
18930   while :; do
18931     cat >conftest.$ac_ext <<_ACEOF
18932 /* confdefs.h.  */
18933 _ACEOF
18934 cat confdefs.h >>conftest.$ac_ext
18935 cat >>conftest.$ac_ext <<_ACEOF
18936 /* end confdefs.h.  */
18937 $ac_includes_default
18938 struct { char filler; short field; } pgac_struct;
18939 int
18940 main ()
18941 {
18942 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
18943 test_array [0] = 0
18944
18945   ;
18946   return 0;
18947 }
18948 _ACEOF
18949 rm -f conftest.$ac_objext
18950 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18951   (eval $ac_compile) 2>conftest.er1
18952   ac_status=$?
18953   grep -v '^ *+' conftest.er1 >conftest.err
18954   rm -f conftest.er1
18955   cat conftest.err >&5
18956   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18957   (exit $ac_status); } &&
18958          { ac_try='test -z "$ac_c_werror_flag"
18959                          || test ! -s conftest.err'
18960   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18961   (eval $ac_try) 2>&5
18962   ac_status=$?
18963   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18964   (exit $ac_status); }; } &&
18965          { ac_try='test -s conftest.$ac_objext'
18966   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18967   (eval $ac_try) 2>&5
18968   ac_status=$?
18969   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18970   (exit $ac_status); }; }; then
18971   ac_hi=$ac_mid; break
18972 else
18973   echo "$as_me: failed program was:" >&5
18974 sed 's/^/| /' conftest.$ac_ext >&5
18975
18976 ac_lo=`expr $ac_mid + 1`
18977                     if test $ac_lo -le $ac_mid; then
18978                       ac_lo= ac_hi=
18979                       break
18980                     fi
18981                     ac_mid=`expr 2 '*' $ac_mid + 1`
18982 fi
18983 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
18984   done
18985 else
18986   echo "$as_me: failed program was:" >&5
18987 sed 's/^/| /' conftest.$ac_ext >&5
18988
18989 cat >conftest.$ac_ext <<_ACEOF
18990 /* confdefs.h.  */
18991 _ACEOF
18992 cat confdefs.h >>conftest.$ac_ext
18993 cat >>conftest.$ac_ext <<_ACEOF
18994 /* end confdefs.h.  */
18995 $ac_includes_default
18996 struct { char filler; short field; } pgac_struct;
18997 int
18998 main ()
18999 {
19000 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19001 test_array [0] = 0
19002
19003   ;
19004   return 0;
19005 }
19006 _ACEOF
19007 rm -f conftest.$ac_objext
19008 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19009   (eval $ac_compile) 2>conftest.er1
19010   ac_status=$?
19011   grep -v '^ *+' conftest.er1 >conftest.err
19012   rm -f conftest.er1
19013   cat conftest.err >&5
19014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19015   (exit $ac_status); } &&
19016          { ac_try='test -z "$ac_c_werror_flag"
19017                          || test ! -s conftest.err'
19018   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19019   (eval $ac_try) 2>&5
19020   ac_status=$?
19021   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19022   (exit $ac_status); }; } &&
19023          { ac_try='test -s conftest.$ac_objext'
19024   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19025   (eval $ac_try) 2>&5
19026   ac_status=$?
19027   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19028   (exit $ac_status); }; }; then
19029   ac_hi=-1 ac_mid=-1
19030   while :; do
19031     cat >conftest.$ac_ext <<_ACEOF
19032 /* confdefs.h.  */
19033 _ACEOF
19034 cat confdefs.h >>conftest.$ac_ext
19035 cat >>conftest.$ac_ext <<_ACEOF
19036 /* end confdefs.h.  */
19037 $ac_includes_default
19038 struct { char filler; short field; } pgac_struct;
19039 int
19040 main ()
19041 {
19042 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19043 test_array [0] = 0
19044
19045   ;
19046   return 0;
19047 }
19048 _ACEOF
19049 rm -f conftest.$ac_objext
19050 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19051   (eval $ac_compile) 2>conftest.er1
19052   ac_status=$?
19053   grep -v '^ *+' conftest.er1 >conftest.err
19054   rm -f conftest.er1
19055   cat conftest.err >&5
19056   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19057   (exit $ac_status); } &&
19058          { ac_try='test -z "$ac_c_werror_flag"
19059                          || test ! -s conftest.err'
19060   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19061   (eval $ac_try) 2>&5
19062   ac_status=$?
19063   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19064   (exit $ac_status); }; } &&
19065          { ac_try='test -s conftest.$ac_objext'
19066   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19067   (eval $ac_try) 2>&5
19068   ac_status=$?
19069   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19070   (exit $ac_status); }; }; then
19071   ac_lo=$ac_mid; break
19072 else
19073   echo "$as_me: failed program was:" >&5
19074 sed 's/^/| /' conftest.$ac_ext >&5
19075
19076 ac_hi=`expr '(' $ac_mid ')' - 1`
19077                        if test $ac_mid -le $ac_hi; then
19078                          ac_lo= ac_hi=
19079                          break
19080                        fi
19081                        ac_mid=`expr 2 '*' $ac_mid`
19082 fi
19083 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19084   done
19085 else
19086   echo "$as_me: failed program was:" >&5
19087 sed 's/^/| /' conftest.$ac_ext >&5
19088
19089 ac_lo= ac_hi=
19090 fi
19091 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19092 fi
19093 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19094 # Binary search between lo and hi bounds.
19095 while test "x$ac_lo" != "x$ac_hi"; do
19096   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19097   cat >conftest.$ac_ext <<_ACEOF
19098 /* confdefs.h.  */
19099 _ACEOF
19100 cat confdefs.h >>conftest.$ac_ext
19101 cat >>conftest.$ac_ext <<_ACEOF
19102 /* end confdefs.h.  */
19103 $ac_includes_default
19104 struct { char filler; short field; } pgac_struct;
19105 int
19106 main ()
19107 {
19108 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19109 test_array [0] = 0
19110
19111   ;
19112   return 0;
19113 }
19114 _ACEOF
19115 rm -f conftest.$ac_objext
19116 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19117   (eval $ac_compile) 2>conftest.er1
19118   ac_status=$?
19119   grep -v '^ *+' conftest.er1 >conftest.err
19120   rm -f conftest.er1
19121   cat conftest.err >&5
19122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19123   (exit $ac_status); } &&
19124          { ac_try='test -z "$ac_c_werror_flag"
19125                          || test ! -s conftest.err'
19126   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19127   (eval $ac_try) 2>&5
19128   ac_status=$?
19129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19130   (exit $ac_status); }; } &&
19131          { ac_try='test -s conftest.$ac_objext'
19132   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19133   (eval $ac_try) 2>&5
19134   ac_status=$?
19135   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19136   (exit $ac_status); }; }; then
19137   ac_hi=$ac_mid
19138 else
19139   echo "$as_me: failed program was:" >&5
19140 sed 's/^/| /' conftest.$ac_ext >&5
19141
19142 ac_lo=`expr '(' $ac_mid ')' + 1`
19143 fi
19144 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19145 done
19146 case $ac_lo in
19147 ?*) pgac_cv_alignof_short=$ac_lo;;
19148 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
19149 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
19150    { (exit 1); exit 1; }; } ;;
19151 esac
19152 else
19153   if test "$cross_compiling" = yes; then
19154   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19155 See \`config.log' for more details." >&5
19156 echo "$as_me: error: cannot run test program while cross compiling
19157 See \`config.log' for more details." >&2;}
19158    { (exit 1); exit 1; }; }
19159 else
19160   cat >conftest.$ac_ext <<_ACEOF
19161 /* confdefs.h.  */
19162 _ACEOF
19163 cat confdefs.h >>conftest.$ac_ext
19164 cat >>conftest.$ac_ext <<_ACEOF
19165 /* end confdefs.h.  */
19166 $ac_includes_default
19167 struct { char filler; short field; } pgac_struct;
19168 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19169 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19170 #include <stdio.h>
19171 #include <stdlib.h>
19172 int
19173 main ()
19174 {
19175
19176   FILE *f = fopen ("conftest.val", "w");
19177   if (! f)
19178     exit (1);
19179   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
19180     {
19181       long i = longval ();
19182       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19183         exit (1);
19184       fprintf (f, "%ld\n", i);
19185     }
19186   else
19187     {
19188       unsigned long i = ulongval ();
19189       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19190         exit (1);
19191       fprintf (f, "%lu\n", i);
19192     }
19193   exit (ferror (f) || fclose (f) != 0);
19194
19195   ;
19196   return 0;
19197 }
19198 _ACEOF
19199 rm -f conftest$ac_exeext
19200 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19201   (eval $ac_link) 2>&5
19202   ac_status=$?
19203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19204   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19205   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19206   (eval $ac_try) 2>&5
19207   ac_status=$?
19208   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19209   (exit $ac_status); }; }; then
19210   pgac_cv_alignof_short=`cat conftest.val`
19211 else
19212   echo "$as_me: program exited with status $ac_status" >&5
19213 echo "$as_me: failed program was:" >&5
19214 sed 's/^/| /' conftest.$ac_ext >&5
19215
19216 ( exit $ac_status )
19217 { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
19218 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
19219    { (exit 1); exit 1; }; }
19220 fi
19221 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19222 fi
19223 fi
19224 rm -f conftest.val
19225 else
19226   pgac_cv_alignof_short=0
19227 fi
19228 fi
19229 echo "$as_me:$LINENO: result: $pgac_cv_alignof_short" >&5
19230 echo "${ECHO_T}$pgac_cv_alignof_short" >&6
19231 cat >>confdefs.h <<_ACEOF
19232 #define ALIGNOF_SHORT $pgac_cv_alignof_short
19233 _ACEOF
19234
19235
19236 echo "$as_me:$LINENO: checking for int" >&5
19237 echo $ECHO_N "checking for int... $ECHO_C" >&6
19238 if test "${ac_cv_type_int+set}" = set; then
19239   echo $ECHO_N "(cached) $ECHO_C" >&6
19240 else
19241   cat >conftest.$ac_ext <<_ACEOF
19242 /* confdefs.h.  */
19243 _ACEOF
19244 cat confdefs.h >>conftest.$ac_ext
19245 cat >>conftest.$ac_ext <<_ACEOF
19246 /* end confdefs.h.  */
19247 $ac_includes_default
19248 int
19249 main ()
19250 {
19251 if ((int *) 0)
19252   return 0;
19253 if (sizeof (int))
19254   return 0;
19255   ;
19256   return 0;
19257 }
19258 _ACEOF
19259 rm -f conftest.$ac_objext
19260 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19261   (eval $ac_compile) 2>conftest.er1
19262   ac_status=$?
19263   grep -v '^ *+' conftest.er1 >conftest.err
19264   rm -f conftest.er1
19265   cat conftest.err >&5
19266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19267   (exit $ac_status); } &&
19268          { ac_try='test -z "$ac_c_werror_flag"
19269                          || test ! -s conftest.err'
19270   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19271   (eval $ac_try) 2>&5
19272   ac_status=$?
19273   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19274   (exit $ac_status); }; } &&
19275          { ac_try='test -s conftest.$ac_objext'
19276   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19277   (eval $ac_try) 2>&5
19278   ac_status=$?
19279   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19280   (exit $ac_status); }; }; then
19281   ac_cv_type_int=yes
19282 else
19283   echo "$as_me: failed program was:" >&5
19284 sed 's/^/| /' conftest.$ac_ext >&5
19285
19286 ac_cv_type_int=no
19287 fi
19288 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19289 fi
19290 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
19291 echo "${ECHO_T}$ac_cv_type_int" >&6
19292
19293 echo "$as_me:$LINENO: checking alignment of int" >&5
19294 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6
19295 if test "${pgac_cv_alignof_int+set}" = set; then
19296   echo $ECHO_N "(cached) $ECHO_C" >&6
19297 else
19298   if test "$ac_cv_type_int" = yes; then
19299   if test "$cross_compiling" = yes; then
19300   # Depending upon the size, compute the lo and hi bounds.
19301 cat >conftest.$ac_ext <<_ACEOF
19302 /* confdefs.h.  */
19303 _ACEOF
19304 cat confdefs.h >>conftest.$ac_ext
19305 cat >>conftest.$ac_ext <<_ACEOF
19306 /* end confdefs.h.  */
19307 $ac_includes_default
19308 struct { char filler; int field; } pgac_struct;
19309 int
19310 main ()
19311 {
19312 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
19313 test_array [0] = 0
19314
19315   ;
19316   return 0;
19317 }
19318 _ACEOF
19319 rm -f conftest.$ac_objext
19320 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19321   (eval $ac_compile) 2>conftest.er1
19322   ac_status=$?
19323   grep -v '^ *+' conftest.er1 >conftest.err
19324   rm -f conftest.er1
19325   cat conftest.err >&5
19326   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19327   (exit $ac_status); } &&
19328          { ac_try='test -z "$ac_c_werror_flag"
19329                          || test ! -s conftest.err'
19330   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19331   (eval $ac_try) 2>&5
19332   ac_status=$?
19333   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19334   (exit $ac_status); }; } &&
19335          { ac_try='test -s conftest.$ac_objext'
19336   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19337   (eval $ac_try) 2>&5
19338   ac_status=$?
19339   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19340   (exit $ac_status); }; }; then
19341   ac_lo=0 ac_mid=0
19342   while :; do
19343     cat >conftest.$ac_ext <<_ACEOF
19344 /* confdefs.h.  */
19345 _ACEOF
19346 cat confdefs.h >>conftest.$ac_ext
19347 cat >>conftest.$ac_ext <<_ACEOF
19348 /* end confdefs.h.  */
19349 $ac_includes_default
19350 struct { char filler; int field; } pgac_struct;
19351 int
19352 main ()
19353 {
19354 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19355 test_array [0] = 0
19356
19357   ;
19358   return 0;
19359 }
19360 _ACEOF
19361 rm -f conftest.$ac_objext
19362 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19363   (eval $ac_compile) 2>conftest.er1
19364   ac_status=$?
19365   grep -v '^ *+' conftest.er1 >conftest.err
19366   rm -f conftest.er1
19367   cat conftest.err >&5
19368   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19369   (exit $ac_status); } &&
19370          { ac_try='test -z "$ac_c_werror_flag"
19371                          || test ! -s conftest.err'
19372   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19373   (eval $ac_try) 2>&5
19374   ac_status=$?
19375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19376   (exit $ac_status); }; } &&
19377          { ac_try='test -s conftest.$ac_objext'
19378   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19379   (eval $ac_try) 2>&5
19380   ac_status=$?
19381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19382   (exit $ac_status); }; }; then
19383   ac_hi=$ac_mid; break
19384 else
19385   echo "$as_me: failed program was:" >&5
19386 sed 's/^/| /' conftest.$ac_ext >&5
19387
19388 ac_lo=`expr $ac_mid + 1`
19389                     if test $ac_lo -le $ac_mid; then
19390                       ac_lo= ac_hi=
19391                       break
19392                     fi
19393                     ac_mid=`expr 2 '*' $ac_mid + 1`
19394 fi
19395 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19396   done
19397 else
19398   echo "$as_me: failed program was:" >&5
19399 sed 's/^/| /' conftest.$ac_ext >&5
19400
19401 cat >conftest.$ac_ext <<_ACEOF
19402 /* confdefs.h.  */
19403 _ACEOF
19404 cat confdefs.h >>conftest.$ac_ext
19405 cat >>conftest.$ac_ext <<_ACEOF
19406 /* end confdefs.h.  */
19407 $ac_includes_default
19408 struct { char filler; int field; } pgac_struct;
19409 int
19410 main ()
19411 {
19412 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19413 test_array [0] = 0
19414
19415   ;
19416   return 0;
19417 }
19418 _ACEOF
19419 rm -f conftest.$ac_objext
19420 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19421   (eval $ac_compile) 2>conftest.er1
19422   ac_status=$?
19423   grep -v '^ *+' conftest.er1 >conftest.err
19424   rm -f conftest.er1
19425   cat conftest.err >&5
19426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19427   (exit $ac_status); } &&
19428          { ac_try='test -z "$ac_c_werror_flag"
19429                          || test ! -s conftest.err'
19430   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19431   (eval $ac_try) 2>&5
19432   ac_status=$?
19433   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19434   (exit $ac_status); }; } &&
19435          { ac_try='test -s conftest.$ac_objext'
19436   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19437   (eval $ac_try) 2>&5
19438   ac_status=$?
19439   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19440   (exit $ac_status); }; }; then
19441   ac_hi=-1 ac_mid=-1
19442   while :; do
19443     cat >conftest.$ac_ext <<_ACEOF
19444 /* confdefs.h.  */
19445 _ACEOF
19446 cat confdefs.h >>conftest.$ac_ext
19447 cat >>conftest.$ac_ext <<_ACEOF
19448 /* end confdefs.h.  */
19449 $ac_includes_default
19450 struct { char filler; int field; } pgac_struct;
19451 int
19452 main ()
19453 {
19454 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19455 test_array [0] = 0
19456
19457   ;
19458   return 0;
19459 }
19460 _ACEOF
19461 rm -f conftest.$ac_objext
19462 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19463   (eval $ac_compile) 2>conftest.er1
19464   ac_status=$?
19465   grep -v '^ *+' conftest.er1 >conftest.err
19466   rm -f conftest.er1
19467   cat conftest.err >&5
19468   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19469   (exit $ac_status); } &&
19470          { ac_try='test -z "$ac_c_werror_flag"
19471                          || test ! -s conftest.err'
19472   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19473   (eval $ac_try) 2>&5
19474   ac_status=$?
19475   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19476   (exit $ac_status); }; } &&
19477          { ac_try='test -s conftest.$ac_objext'
19478   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19479   (eval $ac_try) 2>&5
19480   ac_status=$?
19481   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19482   (exit $ac_status); }; }; then
19483   ac_lo=$ac_mid; break
19484 else
19485   echo "$as_me: failed program was:" >&5
19486 sed 's/^/| /' conftest.$ac_ext >&5
19487
19488 ac_hi=`expr '(' $ac_mid ')' - 1`
19489                        if test $ac_mid -le $ac_hi; then
19490                          ac_lo= ac_hi=
19491                          break
19492                        fi
19493                        ac_mid=`expr 2 '*' $ac_mid`
19494 fi
19495 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19496   done
19497 else
19498   echo "$as_me: failed program was:" >&5
19499 sed 's/^/| /' conftest.$ac_ext >&5
19500
19501 ac_lo= ac_hi=
19502 fi
19503 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19504 fi
19505 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19506 # Binary search between lo and hi bounds.
19507 while test "x$ac_lo" != "x$ac_hi"; do
19508   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19509   cat >conftest.$ac_ext <<_ACEOF
19510 /* confdefs.h.  */
19511 _ACEOF
19512 cat confdefs.h >>conftest.$ac_ext
19513 cat >>conftest.$ac_ext <<_ACEOF
19514 /* end confdefs.h.  */
19515 $ac_includes_default
19516 struct { char filler; int field; } pgac_struct;
19517 int
19518 main ()
19519 {
19520 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19521 test_array [0] = 0
19522
19523   ;
19524   return 0;
19525 }
19526 _ACEOF
19527 rm -f conftest.$ac_objext
19528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19529   (eval $ac_compile) 2>conftest.er1
19530   ac_status=$?
19531   grep -v '^ *+' conftest.er1 >conftest.err
19532   rm -f conftest.er1
19533   cat conftest.err >&5
19534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19535   (exit $ac_status); } &&
19536          { ac_try='test -z "$ac_c_werror_flag"
19537                          || test ! -s conftest.err'
19538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19539   (eval $ac_try) 2>&5
19540   ac_status=$?
19541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19542   (exit $ac_status); }; } &&
19543          { ac_try='test -s conftest.$ac_objext'
19544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19545   (eval $ac_try) 2>&5
19546   ac_status=$?
19547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19548   (exit $ac_status); }; }; then
19549   ac_hi=$ac_mid
19550 else
19551   echo "$as_me: failed program was:" >&5
19552 sed 's/^/| /' conftest.$ac_ext >&5
19553
19554 ac_lo=`expr '(' $ac_mid ')' + 1`
19555 fi
19556 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19557 done
19558 case $ac_lo in
19559 ?*) pgac_cv_alignof_int=$ac_lo;;
19560 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
19561 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
19562    { (exit 1); exit 1; }; } ;;
19563 esac
19564 else
19565   if test "$cross_compiling" = yes; then
19566   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19567 See \`config.log' for more details." >&5
19568 echo "$as_me: error: cannot run test program while cross compiling
19569 See \`config.log' for more details." >&2;}
19570    { (exit 1); exit 1; }; }
19571 else
19572   cat >conftest.$ac_ext <<_ACEOF
19573 /* confdefs.h.  */
19574 _ACEOF
19575 cat confdefs.h >>conftest.$ac_ext
19576 cat >>conftest.$ac_ext <<_ACEOF
19577 /* end confdefs.h.  */
19578 $ac_includes_default
19579 struct { char filler; int field; } pgac_struct;
19580 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19581 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19582 #include <stdio.h>
19583 #include <stdlib.h>
19584 int
19585 main ()
19586 {
19587
19588   FILE *f = fopen ("conftest.val", "w");
19589   if (! f)
19590     exit (1);
19591   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
19592     {
19593       long i = longval ();
19594       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19595         exit (1);
19596       fprintf (f, "%ld\n", i);
19597     }
19598   else
19599     {
19600       unsigned long i = ulongval ();
19601       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
19602         exit (1);
19603       fprintf (f, "%lu\n", i);
19604     }
19605   exit (ferror (f) || fclose (f) != 0);
19606
19607   ;
19608   return 0;
19609 }
19610 _ACEOF
19611 rm -f conftest$ac_exeext
19612 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19613   (eval $ac_link) 2>&5
19614   ac_status=$?
19615   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19616   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19617   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19618   (eval $ac_try) 2>&5
19619   ac_status=$?
19620   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19621   (exit $ac_status); }; }; then
19622   pgac_cv_alignof_int=`cat conftest.val`
19623 else
19624   echo "$as_me: program exited with status $ac_status" >&5
19625 echo "$as_me: failed program was:" >&5
19626 sed 's/^/| /' conftest.$ac_ext >&5
19627
19628 ( exit $ac_status )
19629 { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
19630 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
19631    { (exit 1); exit 1; }; }
19632 fi
19633 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19634 fi
19635 fi
19636 rm -f conftest.val
19637 else
19638   pgac_cv_alignof_int=0
19639 fi
19640 fi
19641 echo "$as_me:$LINENO: result: $pgac_cv_alignof_int" >&5
19642 echo "${ECHO_T}$pgac_cv_alignof_int" >&6
19643 cat >>confdefs.h <<_ACEOF
19644 #define ALIGNOF_INT $pgac_cv_alignof_int
19645 _ACEOF
19646
19647
19648 echo "$as_me:$LINENO: checking for long" >&5
19649 echo $ECHO_N "checking for long... $ECHO_C" >&6
19650 if test "${ac_cv_type_long+set}" = set; then
19651   echo $ECHO_N "(cached) $ECHO_C" >&6
19652 else
19653   cat >conftest.$ac_ext <<_ACEOF
19654 /* confdefs.h.  */
19655 _ACEOF
19656 cat confdefs.h >>conftest.$ac_ext
19657 cat >>conftest.$ac_ext <<_ACEOF
19658 /* end confdefs.h.  */
19659 $ac_includes_default
19660 int
19661 main ()
19662 {
19663 if ((long *) 0)
19664   return 0;
19665 if (sizeof (long))
19666   return 0;
19667   ;
19668   return 0;
19669 }
19670 _ACEOF
19671 rm -f conftest.$ac_objext
19672 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19673   (eval $ac_compile) 2>conftest.er1
19674   ac_status=$?
19675   grep -v '^ *+' conftest.er1 >conftest.err
19676   rm -f conftest.er1
19677   cat conftest.err >&5
19678   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19679   (exit $ac_status); } &&
19680          { ac_try='test -z "$ac_c_werror_flag"
19681                          || test ! -s conftest.err'
19682   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19683   (eval $ac_try) 2>&5
19684   ac_status=$?
19685   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19686   (exit $ac_status); }; } &&
19687          { ac_try='test -s conftest.$ac_objext'
19688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19689   (eval $ac_try) 2>&5
19690   ac_status=$?
19691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19692   (exit $ac_status); }; }; then
19693   ac_cv_type_long=yes
19694 else
19695   echo "$as_me: failed program was:" >&5
19696 sed 's/^/| /' conftest.$ac_ext >&5
19697
19698 ac_cv_type_long=no
19699 fi
19700 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19701 fi
19702 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
19703 echo "${ECHO_T}$ac_cv_type_long" >&6
19704
19705 echo "$as_me:$LINENO: checking alignment of long" >&5
19706 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6
19707 if test "${pgac_cv_alignof_long+set}" = set; then
19708   echo $ECHO_N "(cached) $ECHO_C" >&6
19709 else
19710   if test "$ac_cv_type_long" = yes; then
19711   if test "$cross_compiling" = yes; then
19712   # Depending upon the size, compute the lo and hi bounds.
19713 cat >conftest.$ac_ext <<_ACEOF
19714 /* confdefs.h.  */
19715 _ACEOF
19716 cat confdefs.h >>conftest.$ac_ext
19717 cat >>conftest.$ac_ext <<_ACEOF
19718 /* end confdefs.h.  */
19719 $ac_includes_default
19720 struct { char filler; long field; } pgac_struct;
19721 int
19722 main ()
19723 {
19724 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
19725 test_array [0] = 0
19726
19727   ;
19728   return 0;
19729 }
19730 _ACEOF
19731 rm -f conftest.$ac_objext
19732 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19733   (eval $ac_compile) 2>conftest.er1
19734   ac_status=$?
19735   grep -v '^ *+' conftest.er1 >conftest.err
19736   rm -f conftest.er1
19737   cat conftest.err >&5
19738   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19739   (exit $ac_status); } &&
19740          { ac_try='test -z "$ac_c_werror_flag"
19741                          || test ! -s conftest.err'
19742   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19743   (eval $ac_try) 2>&5
19744   ac_status=$?
19745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19746   (exit $ac_status); }; } &&
19747          { ac_try='test -s conftest.$ac_objext'
19748   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19749   (eval $ac_try) 2>&5
19750   ac_status=$?
19751   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19752   (exit $ac_status); }; }; then
19753   ac_lo=0 ac_mid=0
19754   while :; do
19755     cat >conftest.$ac_ext <<_ACEOF
19756 /* confdefs.h.  */
19757 _ACEOF
19758 cat confdefs.h >>conftest.$ac_ext
19759 cat >>conftest.$ac_ext <<_ACEOF
19760 /* end confdefs.h.  */
19761 $ac_includes_default
19762 struct { char filler; long field; } pgac_struct;
19763 int
19764 main ()
19765 {
19766 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19767 test_array [0] = 0
19768
19769   ;
19770   return 0;
19771 }
19772 _ACEOF
19773 rm -f conftest.$ac_objext
19774 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19775   (eval $ac_compile) 2>conftest.er1
19776   ac_status=$?
19777   grep -v '^ *+' conftest.er1 >conftest.err
19778   rm -f conftest.er1
19779   cat conftest.err >&5
19780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19781   (exit $ac_status); } &&
19782          { ac_try='test -z "$ac_c_werror_flag"
19783                          || test ! -s conftest.err'
19784   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19785   (eval $ac_try) 2>&5
19786   ac_status=$?
19787   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19788   (exit $ac_status); }; } &&
19789          { ac_try='test -s conftest.$ac_objext'
19790   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19791   (eval $ac_try) 2>&5
19792   ac_status=$?
19793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19794   (exit $ac_status); }; }; then
19795   ac_hi=$ac_mid; break
19796 else
19797   echo "$as_me: failed program was:" >&5
19798 sed 's/^/| /' conftest.$ac_ext >&5
19799
19800 ac_lo=`expr $ac_mid + 1`
19801                     if test $ac_lo -le $ac_mid; then
19802                       ac_lo= ac_hi=
19803                       break
19804                     fi
19805                     ac_mid=`expr 2 '*' $ac_mid + 1`
19806 fi
19807 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19808   done
19809 else
19810   echo "$as_me: failed program was:" >&5
19811 sed 's/^/| /' conftest.$ac_ext >&5
19812
19813 cat >conftest.$ac_ext <<_ACEOF
19814 /* confdefs.h.  */
19815 _ACEOF
19816 cat confdefs.h >>conftest.$ac_ext
19817 cat >>conftest.$ac_ext <<_ACEOF
19818 /* end confdefs.h.  */
19819 $ac_includes_default
19820 struct { char filler; long field; } pgac_struct;
19821 int
19822 main ()
19823 {
19824 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
19825 test_array [0] = 0
19826
19827   ;
19828   return 0;
19829 }
19830 _ACEOF
19831 rm -f conftest.$ac_objext
19832 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19833   (eval $ac_compile) 2>conftest.er1
19834   ac_status=$?
19835   grep -v '^ *+' conftest.er1 >conftest.err
19836   rm -f conftest.er1
19837   cat conftest.err >&5
19838   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19839   (exit $ac_status); } &&
19840          { ac_try='test -z "$ac_c_werror_flag"
19841                          || test ! -s conftest.err'
19842   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19843   (eval $ac_try) 2>&5
19844   ac_status=$?
19845   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19846   (exit $ac_status); }; } &&
19847          { ac_try='test -s conftest.$ac_objext'
19848   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19849   (eval $ac_try) 2>&5
19850   ac_status=$?
19851   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19852   (exit $ac_status); }; }; then
19853   ac_hi=-1 ac_mid=-1
19854   while :; do
19855     cat >conftest.$ac_ext <<_ACEOF
19856 /* confdefs.h.  */
19857 _ACEOF
19858 cat confdefs.h >>conftest.$ac_ext
19859 cat >>conftest.$ac_ext <<_ACEOF
19860 /* end confdefs.h.  */
19861 $ac_includes_default
19862 struct { char filler; long field; } pgac_struct;
19863 int
19864 main ()
19865 {
19866 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
19867 test_array [0] = 0
19868
19869   ;
19870   return 0;
19871 }
19872 _ACEOF
19873 rm -f conftest.$ac_objext
19874 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19875   (eval $ac_compile) 2>conftest.er1
19876   ac_status=$?
19877   grep -v '^ *+' conftest.er1 >conftest.err
19878   rm -f conftest.er1
19879   cat conftest.err >&5
19880   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19881   (exit $ac_status); } &&
19882          { ac_try='test -z "$ac_c_werror_flag"
19883                          || test ! -s conftest.err'
19884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19885   (eval $ac_try) 2>&5
19886   ac_status=$?
19887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19888   (exit $ac_status); }; } &&
19889          { ac_try='test -s conftest.$ac_objext'
19890   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19891   (eval $ac_try) 2>&5
19892   ac_status=$?
19893   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19894   (exit $ac_status); }; }; then
19895   ac_lo=$ac_mid; break
19896 else
19897   echo "$as_me: failed program was:" >&5
19898 sed 's/^/| /' conftest.$ac_ext >&5
19899
19900 ac_hi=`expr '(' $ac_mid ')' - 1`
19901                        if test $ac_mid -le $ac_hi; then
19902                          ac_lo= ac_hi=
19903                          break
19904                        fi
19905                        ac_mid=`expr 2 '*' $ac_mid`
19906 fi
19907 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19908   done
19909 else
19910   echo "$as_me: failed program was:" >&5
19911 sed 's/^/| /' conftest.$ac_ext >&5
19912
19913 ac_lo= ac_hi=
19914 fi
19915 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19916 fi
19917 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19918 # Binary search between lo and hi bounds.
19919 while test "x$ac_lo" != "x$ac_hi"; do
19920   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
19921   cat >conftest.$ac_ext <<_ACEOF
19922 /* confdefs.h.  */
19923 _ACEOF
19924 cat confdefs.h >>conftest.$ac_ext
19925 cat >>conftest.$ac_ext <<_ACEOF
19926 /* end confdefs.h.  */
19927 $ac_includes_default
19928 struct { char filler; long field; } pgac_struct;
19929 int
19930 main ()
19931 {
19932 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
19933 test_array [0] = 0
19934
19935   ;
19936   return 0;
19937 }
19938 _ACEOF
19939 rm -f conftest.$ac_objext
19940 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
19941   (eval $ac_compile) 2>conftest.er1
19942   ac_status=$?
19943   grep -v '^ *+' conftest.er1 >conftest.err
19944   rm -f conftest.er1
19945   cat conftest.err >&5
19946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19947   (exit $ac_status); } &&
19948          { ac_try='test -z "$ac_c_werror_flag"
19949                          || test ! -s conftest.err'
19950   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19951   (eval $ac_try) 2>&5
19952   ac_status=$?
19953   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19954   (exit $ac_status); }; } &&
19955          { ac_try='test -s conftest.$ac_objext'
19956   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19957   (eval $ac_try) 2>&5
19958   ac_status=$?
19959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19960   (exit $ac_status); }; }; then
19961   ac_hi=$ac_mid
19962 else
19963   echo "$as_me: failed program was:" >&5
19964 sed 's/^/| /' conftest.$ac_ext >&5
19965
19966 ac_lo=`expr '(' $ac_mid ')' + 1`
19967 fi
19968 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
19969 done
19970 case $ac_lo in
19971 ?*) pgac_cv_alignof_long=$ac_lo;;
19972 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
19973 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
19974    { (exit 1); exit 1; }; } ;;
19975 esac
19976 else
19977   if test "$cross_compiling" = yes; then
19978   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
19979 See \`config.log' for more details." >&5
19980 echo "$as_me: error: cannot run test program while cross compiling
19981 See \`config.log' for more details." >&2;}
19982    { (exit 1); exit 1; }; }
19983 else
19984   cat >conftest.$ac_ext <<_ACEOF
19985 /* confdefs.h.  */
19986 _ACEOF
19987 cat confdefs.h >>conftest.$ac_ext
19988 cat >>conftest.$ac_ext <<_ACEOF
19989 /* end confdefs.h.  */
19990 $ac_includes_default
19991 struct { char filler; long field; } pgac_struct;
19992 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19993 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
19994 #include <stdio.h>
19995 #include <stdlib.h>
19996 int
19997 main ()
19998 {
19999
20000   FILE *f = fopen ("conftest.val", "w");
20001   if (! f)
20002     exit (1);
20003   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
20004     {
20005       long i = longval ();
20006       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20007         exit (1);
20008       fprintf (f, "%ld\n", i);
20009     }
20010   else
20011     {
20012       unsigned long i = ulongval ();
20013       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20014         exit (1);
20015       fprintf (f, "%lu\n", i);
20016     }
20017   exit (ferror (f) || fclose (f) != 0);
20018
20019   ;
20020   return 0;
20021 }
20022 _ACEOF
20023 rm -f conftest$ac_exeext
20024 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20025   (eval $ac_link) 2>&5
20026   ac_status=$?
20027   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20028   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20029   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20030   (eval $ac_try) 2>&5
20031   ac_status=$?
20032   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20033   (exit $ac_status); }; }; then
20034   pgac_cv_alignof_long=`cat conftest.val`
20035 else
20036   echo "$as_me: program exited with status $ac_status" >&5
20037 echo "$as_me: failed program was:" >&5
20038 sed 's/^/| /' conftest.$ac_ext >&5
20039
20040 ( exit $ac_status )
20041 { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
20042 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
20043    { (exit 1); exit 1; }; }
20044 fi
20045 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20046 fi
20047 fi
20048 rm -f conftest.val
20049 else
20050   pgac_cv_alignof_long=0
20051 fi
20052 fi
20053 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long" >&5
20054 echo "${ECHO_T}$pgac_cv_alignof_long" >&6
20055 cat >>confdefs.h <<_ACEOF
20056 #define ALIGNOF_LONG $pgac_cv_alignof_long
20057 _ACEOF
20058
20059
20060 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
20061   echo "$as_me:$LINENO: checking for long long int" >&5
20062 echo $ECHO_N "checking for long long int... $ECHO_C" >&6
20063 if test "${ac_cv_type_long_long_int+set}" = set; then
20064   echo $ECHO_N "(cached) $ECHO_C" >&6
20065 else
20066   cat >conftest.$ac_ext <<_ACEOF
20067 /* confdefs.h.  */
20068 _ACEOF
20069 cat confdefs.h >>conftest.$ac_ext
20070 cat >>conftest.$ac_ext <<_ACEOF
20071 /* end confdefs.h.  */
20072 $ac_includes_default
20073 int
20074 main ()
20075 {
20076 if ((long long int *) 0)
20077   return 0;
20078 if (sizeof (long long int))
20079   return 0;
20080   ;
20081   return 0;
20082 }
20083 _ACEOF
20084 rm -f conftest.$ac_objext
20085 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20086   (eval $ac_compile) 2>conftest.er1
20087   ac_status=$?
20088   grep -v '^ *+' conftest.er1 >conftest.err
20089   rm -f conftest.er1
20090   cat conftest.err >&5
20091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20092   (exit $ac_status); } &&
20093          { ac_try='test -z "$ac_c_werror_flag"
20094                          || test ! -s conftest.err'
20095   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20096   (eval $ac_try) 2>&5
20097   ac_status=$?
20098   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20099   (exit $ac_status); }; } &&
20100          { ac_try='test -s conftest.$ac_objext'
20101   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20102   (eval $ac_try) 2>&5
20103   ac_status=$?
20104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20105   (exit $ac_status); }; }; then
20106   ac_cv_type_long_long_int=yes
20107 else
20108   echo "$as_me: failed program was:" >&5
20109 sed 's/^/| /' conftest.$ac_ext >&5
20110
20111 ac_cv_type_long_long_int=no
20112 fi
20113 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20114 fi
20115 echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
20116 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6
20117
20118 echo "$as_me:$LINENO: checking alignment of long long int" >&5
20119 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6
20120 if test "${pgac_cv_alignof_long_long_int+set}" = set; then
20121   echo $ECHO_N "(cached) $ECHO_C" >&6
20122 else
20123   if test "$ac_cv_type_long_long_int" = yes; then
20124   if test "$cross_compiling" = yes; then
20125   # Depending upon the size, compute the lo and hi bounds.
20126 cat >conftest.$ac_ext <<_ACEOF
20127 /* confdefs.h.  */
20128 _ACEOF
20129 cat confdefs.h >>conftest.$ac_ext
20130 cat >>conftest.$ac_ext <<_ACEOF
20131 /* end confdefs.h.  */
20132 $ac_includes_default
20133 struct { char filler; long long int field; } pgac_struct;
20134 int
20135 main ()
20136 {
20137 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
20138 test_array [0] = 0
20139
20140   ;
20141   return 0;
20142 }
20143 _ACEOF
20144 rm -f conftest.$ac_objext
20145 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20146   (eval $ac_compile) 2>conftest.er1
20147   ac_status=$?
20148   grep -v '^ *+' conftest.er1 >conftest.err
20149   rm -f conftest.er1
20150   cat conftest.err >&5
20151   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20152   (exit $ac_status); } &&
20153          { ac_try='test -z "$ac_c_werror_flag"
20154                          || test ! -s conftest.err'
20155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20156   (eval $ac_try) 2>&5
20157   ac_status=$?
20158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20159   (exit $ac_status); }; } &&
20160          { ac_try='test -s conftest.$ac_objext'
20161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20162   (eval $ac_try) 2>&5
20163   ac_status=$?
20164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20165   (exit $ac_status); }; }; then
20166   ac_lo=0 ac_mid=0
20167   while :; do
20168     cat >conftest.$ac_ext <<_ACEOF
20169 /* confdefs.h.  */
20170 _ACEOF
20171 cat confdefs.h >>conftest.$ac_ext
20172 cat >>conftest.$ac_ext <<_ACEOF
20173 /* end confdefs.h.  */
20174 $ac_includes_default
20175 struct { char filler; long long int field; } pgac_struct;
20176 int
20177 main ()
20178 {
20179 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
20180 test_array [0] = 0
20181
20182   ;
20183   return 0;
20184 }
20185 _ACEOF
20186 rm -f conftest.$ac_objext
20187 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20188   (eval $ac_compile) 2>conftest.er1
20189   ac_status=$?
20190   grep -v '^ *+' conftest.er1 >conftest.err
20191   rm -f conftest.er1
20192   cat conftest.err >&5
20193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20194   (exit $ac_status); } &&
20195          { ac_try='test -z "$ac_c_werror_flag"
20196                          || test ! -s conftest.err'
20197   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20198   (eval $ac_try) 2>&5
20199   ac_status=$?
20200   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20201   (exit $ac_status); }; } &&
20202          { ac_try='test -s conftest.$ac_objext'
20203   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20204   (eval $ac_try) 2>&5
20205   ac_status=$?
20206   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20207   (exit $ac_status); }; }; then
20208   ac_hi=$ac_mid; break
20209 else
20210   echo "$as_me: failed program was:" >&5
20211 sed 's/^/| /' conftest.$ac_ext >&5
20212
20213 ac_lo=`expr $ac_mid + 1`
20214                     if test $ac_lo -le $ac_mid; then
20215                       ac_lo= ac_hi=
20216                       break
20217                     fi
20218                     ac_mid=`expr 2 '*' $ac_mid + 1`
20219 fi
20220 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20221   done
20222 else
20223   echo "$as_me: failed program was:" >&5
20224 sed 's/^/| /' conftest.$ac_ext >&5
20225
20226 cat >conftest.$ac_ext <<_ACEOF
20227 /* confdefs.h.  */
20228 _ACEOF
20229 cat confdefs.h >>conftest.$ac_ext
20230 cat >>conftest.$ac_ext <<_ACEOF
20231 /* end confdefs.h.  */
20232 $ac_includes_default
20233 struct { char filler; long long int field; } pgac_struct;
20234 int
20235 main ()
20236 {
20237 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
20238 test_array [0] = 0
20239
20240   ;
20241   return 0;
20242 }
20243 _ACEOF
20244 rm -f conftest.$ac_objext
20245 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20246   (eval $ac_compile) 2>conftest.er1
20247   ac_status=$?
20248   grep -v '^ *+' conftest.er1 >conftest.err
20249   rm -f conftest.er1
20250   cat conftest.err >&5
20251   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20252   (exit $ac_status); } &&
20253          { ac_try='test -z "$ac_c_werror_flag"
20254                          || test ! -s conftest.err'
20255   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20256   (eval $ac_try) 2>&5
20257   ac_status=$?
20258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20259   (exit $ac_status); }; } &&
20260          { ac_try='test -s conftest.$ac_objext'
20261   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20262   (eval $ac_try) 2>&5
20263   ac_status=$?
20264   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20265   (exit $ac_status); }; }; then
20266   ac_hi=-1 ac_mid=-1
20267   while :; do
20268     cat >conftest.$ac_ext <<_ACEOF
20269 /* confdefs.h.  */
20270 _ACEOF
20271 cat confdefs.h >>conftest.$ac_ext
20272 cat >>conftest.$ac_ext <<_ACEOF
20273 /* end confdefs.h.  */
20274 $ac_includes_default
20275 struct { char filler; long long int field; } pgac_struct;
20276 int
20277 main ()
20278 {
20279 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
20280 test_array [0] = 0
20281
20282   ;
20283   return 0;
20284 }
20285 _ACEOF
20286 rm -f conftest.$ac_objext
20287 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20288   (eval $ac_compile) 2>conftest.er1
20289   ac_status=$?
20290   grep -v '^ *+' conftest.er1 >conftest.err
20291   rm -f conftest.er1
20292   cat conftest.err >&5
20293   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20294   (exit $ac_status); } &&
20295          { ac_try='test -z "$ac_c_werror_flag"
20296                          || test ! -s conftest.err'
20297   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20298   (eval $ac_try) 2>&5
20299   ac_status=$?
20300   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20301   (exit $ac_status); }; } &&
20302          { ac_try='test -s conftest.$ac_objext'
20303   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20304   (eval $ac_try) 2>&5
20305   ac_status=$?
20306   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20307   (exit $ac_status); }; }; then
20308   ac_lo=$ac_mid; break
20309 else
20310   echo "$as_me: failed program was:" >&5
20311 sed 's/^/| /' conftest.$ac_ext >&5
20312
20313 ac_hi=`expr '(' $ac_mid ')' - 1`
20314                        if test $ac_mid -le $ac_hi; then
20315                          ac_lo= ac_hi=
20316                          break
20317                        fi
20318                        ac_mid=`expr 2 '*' $ac_mid`
20319 fi
20320 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20321   done
20322 else
20323   echo "$as_me: failed program was:" >&5
20324 sed 's/^/| /' conftest.$ac_ext >&5
20325
20326 ac_lo= ac_hi=
20327 fi
20328 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20329 fi
20330 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20331 # Binary search between lo and hi bounds.
20332 while test "x$ac_lo" != "x$ac_hi"; do
20333   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20334   cat >conftest.$ac_ext <<_ACEOF
20335 /* confdefs.h.  */
20336 _ACEOF
20337 cat confdefs.h >>conftest.$ac_ext
20338 cat >>conftest.$ac_ext <<_ACEOF
20339 /* end confdefs.h.  */
20340 $ac_includes_default
20341 struct { char filler; long long int field; } pgac_struct;
20342 int
20343 main ()
20344 {
20345 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
20346 test_array [0] = 0
20347
20348   ;
20349   return 0;
20350 }
20351 _ACEOF
20352 rm -f conftest.$ac_objext
20353 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20354   (eval $ac_compile) 2>conftest.er1
20355   ac_status=$?
20356   grep -v '^ *+' conftest.er1 >conftest.err
20357   rm -f conftest.er1
20358   cat conftest.err >&5
20359   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20360   (exit $ac_status); } &&
20361          { ac_try='test -z "$ac_c_werror_flag"
20362                          || test ! -s conftest.err'
20363   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20364   (eval $ac_try) 2>&5
20365   ac_status=$?
20366   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20367   (exit $ac_status); }; } &&
20368          { ac_try='test -s conftest.$ac_objext'
20369   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20370   (eval $ac_try) 2>&5
20371   ac_status=$?
20372   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20373   (exit $ac_status); }; }; then
20374   ac_hi=$ac_mid
20375 else
20376   echo "$as_me: failed program was:" >&5
20377 sed 's/^/| /' conftest.$ac_ext >&5
20378
20379 ac_lo=`expr '(' $ac_mid ')' + 1`
20380 fi
20381 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20382 done
20383 case $ac_lo in
20384 ?*) pgac_cv_alignof_long_long_int=$ac_lo;;
20385 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
20386 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
20387    { (exit 1); exit 1; }; } ;;
20388 esac
20389 else
20390   if test "$cross_compiling" = yes; then
20391   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
20392 See \`config.log' for more details." >&5
20393 echo "$as_me: error: cannot run test program while cross compiling
20394 See \`config.log' for more details." >&2;}
20395    { (exit 1); exit 1; }; }
20396 else
20397   cat >conftest.$ac_ext <<_ACEOF
20398 /* confdefs.h.  */
20399 _ACEOF
20400 cat confdefs.h >>conftest.$ac_ext
20401 cat >>conftest.$ac_ext <<_ACEOF
20402 /* end confdefs.h.  */
20403 $ac_includes_default
20404 struct { char filler; long long int field; } pgac_struct;
20405 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20406 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20407 #include <stdio.h>
20408 #include <stdlib.h>
20409 int
20410 main ()
20411 {
20412
20413   FILE *f = fopen ("conftest.val", "w");
20414   if (! f)
20415     exit (1);
20416   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
20417     {
20418       long i = longval ();
20419       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20420         exit (1);
20421       fprintf (f, "%ld\n", i);
20422     }
20423   else
20424     {
20425       unsigned long i = ulongval ();
20426       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20427         exit (1);
20428       fprintf (f, "%lu\n", i);
20429     }
20430   exit (ferror (f) || fclose (f) != 0);
20431
20432   ;
20433   return 0;
20434 }
20435 _ACEOF
20436 rm -f conftest$ac_exeext
20437 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20438   (eval $ac_link) 2>&5
20439   ac_status=$?
20440   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20441   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20442   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20443   (eval $ac_try) 2>&5
20444   ac_status=$?
20445   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20446   (exit $ac_status); }; }; then
20447   pgac_cv_alignof_long_long_int=`cat conftest.val`
20448 else
20449   echo "$as_me: program exited with status $ac_status" >&5
20450 echo "$as_me: failed program was:" >&5
20451 sed 's/^/| /' conftest.$ac_ext >&5
20452
20453 ( exit $ac_status )
20454 { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
20455 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
20456    { (exit 1); exit 1; }; }
20457 fi
20458 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20459 fi
20460 fi
20461 rm -f conftest.val
20462 else
20463   pgac_cv_alignof_long_long_int=0
20464 fi
20465 fi
20466 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long_long_int" >&5
20467 echo "${ECHO_T}$pgac_cv_alignof_long_long_int" >&6
20468 cat >>confdefs.h <<_ACEOF
20469 #define ALIGNOF_LONG_LONG_INT $pgac_cv_alignof_long_long_int
20470 _ACEOF
20471
20472
20473 fi
20474 echo "$as_me:$LINENO: checking for double" >&5
20475 echo $ECHO_N "checking for double... $ECHO_C" >&6
20476 if test "${ac_cv_type_double+set}" = set; then
20477   echo $ECHO_N "(cached) $ECHO_C" >&6
20478 else
20479   cat >conftest.$ac_ext <<_ACEOF
20480 /* confdefs.h.  */
20481 _ACEOF
20482 cat confdefs.h >>conftest.$ac_ext
20483 cat >>conftest.$ac_ext <<_ACEOF
20484 /* end confdefs.h.  */
20485 $ac_includes_default
20486 int
20487 main ()
20488 {
20489 if ((double *) 0)
20490   return 0;
20491 if (sizeof (double))
20492   return 0;
20493   ;
20494   return 0;
20495 }
20496 _ACEOF
20497 rm -f conftest.$ac_objext
20498 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20499   (eval $ac_compile) 2>conftest.er1
20500   ac_status=$?
20501   grep -v '^ *+' conftest.er1 >conftest.err
20502   rm -f conftest.er1
20503   cat conftest.err >&5
20504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20505   (exit $ac_status); } &&
20506          { ac_try='test -z "$ac_c_werror_flag"
20507                          || test ! -s conftest.err'
20508   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20509   (eval $ac_try) 2>&5
20510   ac_status=$?
20511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20512   (exit $ac_status); }; } &&
20513          { ac_try='test -s conftest.$ac_objext'
20514   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20515   (eval $ac_try) 2>&5
20516   ac_status=$?
20517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20518   (exit $ac_status); }; }; then
20519   ac_cv_type_double=yes
20520 else
20521   echo "$as_me: failed program was:" >&5
20522 sed 's/^/| /' conftest.$ac_ext >&5
20523
20524 ac_cv_type_double=no
20525 fi
20526 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20527 fi
20528 echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
20529 echo "${ECHO_T}$ac_cv_type_double" >&6
20530
20531 echo "$as_me:$LINENO: checking alignment of double" >&5
20532 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6
20533 if test "${pgac_cv_alignof_double+set}" = set; then
20534   echo $ECHO_N "(cached) $ECHO_C" >&6
20535 else
20536   if test "$ac_cv_type_double" = yes; then
20537   if test "$cross_compiling" = yes; then
20538   # Depending upon the size, compute the lo and hi bounds.
20539 cat >conftest.$ac_ext <<_ACEOF
20540 /* confdefs.h.  */
20541 _ACEOF
20542 cat confdefs.h >>conftest.$ac_ext
20543 cat >>conftest.$ac_ext <<_ACEOF
20544 /* end confdefs.h.  */
20545 $ac_includes_default
20546 struct { char filler; double field; } pgac_struct;
20547 int
20548 main ()
20549 {
20550 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
20551 test_array [0] = 0
20552
20553   ;
20554   return 0;
20555 }
20556 _ACEOF
20557 rm -f conftest.$ac_objext
20558 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20559   (eval $ac_compile) 2>conftest.er1
20560   ac_status=$?
20561   grep -v '^ *+' conftest.er1 >conftest.err
20562   rm -f conftest.er1
20563   cat conftest.err >&5
20564   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20565   (exit $ac_status); } &&
20566          { ac_try='test -z "$ac_c_werror_flag"
20567                          || test ! -s conftest.err'
20568   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20569   (eval $ac_try) 2>&5
20570   ac_status=$?
20571   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20572   (exit $ac_status); }; } &&
20573          { ac_try='test -s conftest.$ac_objext'
20574   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20575   (eval $ac_try) 2>&5
20576   ac_status=$?
20577   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20578   (exit $ac_status); }; }; then
20579   ac_lo=0 ac_mid=0
20580   while :; do
20581     cat >conftest.$ac_ext <<_ACEOF
20582 /* confdefs.h.  */
20583 _ACEOF
20584 cat confdefs.h >>conftest.$ac_ext
20585 cat >>conftest.$ac_ext <<_ACEOF
20586 /* end confdefs.h.  */
20587 $ac_includes_default
20588 struct { char filler; double field; } pgac_struct;
20589 int
20590 main ()
20591 {
20592 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
20593 test_array [0] = 0
20594
20595   ;
20596   return 0;
20597 }
20598 _ACEOF
20599 rm -f conftest.$ac_objext
20600 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20601   (eval $ac_compile) 2>conftest.er1
20602   ac_status=$?
20603   grep -v '^ *+' conftest.er1 >conftest.err
20604   rm -f conftest.er1
20605   cat conftest.err >&5
20606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20607   (exit $ac_status); } &&
20608          { ac_try='test -z "$ac_c_werror_flag"
20609                          || test ! -s conftest.err'
20610   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20611   (eval $ac_try) 2>&5
20612   ac_status=$?
20613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20614   (exit $ac_status); }; } &&
20615          { ac_try='test -s conftest.$ac_objext'
20616   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20617   (eval $ac_try) 2>&5
20618   ac_status=$?
20619   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20620   (exit $ac_status); }; }; then
20621   ac_hi=$ac_mid; break
20622 else
20623   echo "$as_me: failed program was:" >&5
20624 sed 's/^/| /' conftest.$ac_ext >&5
20625
20626 ac_lo=`expr $ac_mid + 1`
20627                     if test $ac_lo -le $ac_mid; then
20628                       ac_lo= ac_hi=
20629                       break
20630                     fi
20631                     ac_mid=`expr 2 '*' $ac_mid + 1`
20632 fi
20633 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20634   done
20635 else
20636   echo "$as_me: failed program was:" >&5
20637 sed 's/^/| /' conftest.$ac_ext >&5
20638
20639 cat >conftest.$ac_ext <<_ACEOF
20640 /* confdefs.h.  */
20641 _ACEOF
20642 cat confdefs.h >>conftest.$ac_ext
20643 cat >>conftest.$ac_ext <<_ACEOF
20644 /* end confdefs.h.  */
20645 $ac_includes_default
20646 struct { char filler; double field; } pgac_struct;
20647 int
20648 main ()
20649 {
20650 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
20651 test_array [0] = 0
20652
20653   ;
20654   return 0;
20655 }
20656 _ACEOF
20657 rm -f conftest.$ac_objext
20658 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20659   (eval $ac_compile) 2>conftest.er1
20660   ac_status=$?
20661   grep -v '^ *+' conftest.er1 >conftest.err
20662   rm -f conftest.er1
20663   cat conftest.err >&5
20664   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20665   (exit $ac_status); } &&
20666          { ac_try='test -z "$ac_c_werror_flag"
20667                          || test ! -s conftest.err'
20668   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20669   (eval $ac_try) 2>&5
20670   ac_status=$?
20671   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20672   (exit $ac_status); }; } &&
20673          { ac_try='test -s conftest.$ac_objext'
20674   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20675   (eval $ac_try) 2>&5
20676   ac_status=$?
20677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20678   (exit $ac_status); }; }; then
20679   ac_hi=-1 ac_mid=-1
20680   while :; do
20681     cat >conftest.$ac_ext <<_ACEOF
20682 /* confdefs.h.  */
20683 _ACEOF
20684 cat confdefs.h >>conftest.$ac_ext
20685 cat >>conftest.$ac_ext <<_ACEOF
20686 /* end confdefs.h.  */
20687 $ac_includes_default
20688 struct { char filler; double field; } pgac_struct;
20689 int
20690 main ()
20691 {
20692 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
20693 test_array [0] = 0
20694
20695   ;
20696   return 0;
20697 }
20698 _ACEOF
20699 rm -f conftest.$ac_objext
20700 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20701   (eval $ac_compile) 2>conftest.er1
20702   ac_status=$?
20703   grep -v '^ *+' conftest.er1 >conftest.err
20704   rm -f conftest.er1
20705   cat conftest.err >&5
20706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20707   (exit $ac_status); } &&
20708          { ac_try='test -z "$ac_c_werror_flag"
20709                          || test ! -s conftest.err'
20710   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20711   (eval $ac_try) 2>&5
20712   ac_status=$?
20713   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20714   (exit $ac_status); }; } &&
20715          { ac_try='test -s conftest.$ac_objext'
20716   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20717   (eval $ac_try) 2>&5
20718   ac_status=$?
20719   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20720   (exit $ac_status); }; }; then
20721   ac_lo=$ac_mid; break
20722 else
20723   echo "$as_me: failed program was:" >&5
20724 sed 's/^/| /' conftest.$ac_ext >&5
20725
20726 ac_hi=`expr '(' $ac_mid ')' - 1`
20727                        if test $ac_mid -le $ac_hi; then
20728                          ac_lo= ac_hi=
20729                          break
20730                        fi
20731                        ac_mid=`expr 2 '*' $ac_mid`
20732 fi
20733 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20734   done
20735 else
20736   echo "$as_me: failed program was:" >&5
20737 sed 's/^/| /' conftest.$ac_ext >&5
20738
20739 ac_lo= ac_hi=
20740 fi
20741 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20742 fi
20743 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20744 # Binary search between lo and hi bounds.
20745 while test "x$ac_lo" != "x$ac_hi"; do
20746   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
20747   cat >conftest.$ac_ext <<_ACEOF
20748 /* confdefs.h.  */
20749 _ACEOF
20750 cat confdefs.h >>conftest.$ac_ext
20751 cat >>conftest.$ac_ext <<_ACEOF
20752 /* end confdefs.h.  */
20753 $ac_includes_default
20754 struct { char filler; double field; } pgac_struct;
20755 int
20756 main ()
20757 {
20758 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
20759 test_array [0] = 0
20760
20761   ;
20762   return 0;
20763 }
20764 _ACEOF
20765 rm -f conftest.$ac_objext
20766 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20767   (eval $ac_compile) 2>conftest.er1
20768   ac_status=$?
20769   grep -v '^ *+' conftest.er1 >conftest.err
20770   rm -f conftest.er1
20771   cat conftest.err >&5
20772   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20773   (exit $ac_status); } &&
20774          { ac_try='test -z "$ac_c_werror_flag"
20775                          || test ! -s conftest.err'
20776   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20777   (eval $ac_try) 2>&5
20778   ac_status=$?
20779   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20780   (exit $ac_status); }; } &&
20781          { ac_try='test -s conftest.$ac_objext'
20782   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20783   (eval $ac_try) 2>&5
20784   ac_status=$?
20785   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20786   (exit $ac_status); }; }; then
20787   ac_hi=$ac_mid
20788 else
20789   echo "$as_me: failed program was:" >&5
20790 sed 's/^/| /' conftest.$ac_ext >&5
20791
20792 ac_lo=`expr '(' $ac_mid ')' + 1`
20793 fi
20794 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20795 done
20796 case $ac_lo in
20797 ?*) pgac_cv_alignof_double=$ac_lo;;
20798 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
20799 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
20800    { (exit 1); exit 1; }; } ;;
20801 esac
20802 else
20803   if test "$cross_compiling" = yes; then
20804   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
20805 See \`config.log' for more details." >&5
20806 echo "$as_me: error: cannot run test program while cross compiling
20807 See \`config.log' for more details." >&2;}
20808    { (exit 1); exit 1; }; }
20809 else
20810   cat >conftest.$ac_ext <<_ACEOF
20811 /* confdefs.h.  */
20812 _ACEOF
20813 cat confdefs.h >>conftest.$ac_ext
20814 cat >>conftest.$ac_ext <<_ACEOF
20815 /* end confdefs.h.  */
20816 $ac_includes_default
20817 struct { char filler; double field; } pgac_struct;
20818 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20819 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
20820 #include <stdio.h>
20821 #include <stdlib.h>
20822 int
20823 main ()
20824 {
20825
20826   FILE *f = fopen ("conftest.val", "w");
20827   if (! f)
20828     exit (1);
20829   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
20830     {
20831       long i = longval ();
20832       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20833         exit (1);
20834       fprintf (f, "%ld\n", i);
20835     }
20836   else
20837     {
20838       unsigned long i = ulongval ();
20839       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
20840         exit (1);
20841       fprintf (f, "%lu\n", i);
20842     }
20843   exit (ferror (f) || fclose (f) != 0);
20844
20845   ;
20846   return 0;
20847 }
20848 _ACEOF
20849 rm -f conftest$ac_exeext
20850 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
20851   (eval $ac_link) 2>&5
20852   ac_status=$?
20853   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20854   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20855   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20856   (eval $ac_try) 2>&5
20857   ac_status=$?
20858   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20859   (exit $ac_status); }; }; then
20860   pgac_cv_alignof_double=`cat conftest.val`
20861 else
20862   echo "$as_me: program exited with status $ac_status" >&5
20863 echo "$as_me: failed program was:" >&5
20864 sed 's/^/| /' conftest.$ac_ext >&5
20865
20866 ( exit $ac_status )
20867 { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
20868 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
20869    { (exit 1); exit 1; }; }
20870 fi
20871 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20872 fi
20873 fi
20874 rm -f conftest.val
20875 else
20876   pgac_cv_alignof_double=0
20877 fi
20878 fi
20879 echo "$as_me:$LINENO: result: $pgac_cv_alignof_double" >&5
20880 echo "${ECHO_T}$pgac_cv_alignof_double" >&6
20881 cat >>confdefs.h <<_ACEOF
20882 #define ALIGNOF_DOUBLE $pgac_cv_alignof_double
20883 _ACEOF
20884
20885
20886
20887 # Compute maximum alignment of any basic type.
20888 # We assume long's alignment is at least as strong as char, short, or int;
20889 # but we must check long long (if it exists) and double.
20890
20891 MAX_ALIGNOF=$pgac_cv_alignof_long
20892 if test $MAX_ALIGNOF -lt $pgac_cv_alignof_double ; then
20893   MAX_ALIGNOF=$pgac_cv_alignof_double
20894 fi
20895 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $pgac_cv_alignof_long_long_int ; then
20896   MAX_ALIGNOF="$pgac_cv_alignof_long_long_int"
20897 fi
20898
20899 cat >>confdefs.h <<_ACEOF
20900 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
20901 _ACEOF
20902
20903
20904
20905 # Some platforms predefine the types int8, int16, etc.  Only check
20906 # a (hopefully) representative subset.
20907 echo "$as_me:$LINENO: checking for int8" >&5
20908 echo $ECHO_N "checking for int8... $ECHO_C" >&6
20909 if test "${ac_cv_type_int8+set}" = set; then
20910   echo $ECHO_N "(cached) $ECHO_C" >&6
20911 else
20912   cat >conftest.$ac_ext <<_ACEOF
20913 /* confdefs.h.  */
20914 _ACEOF
20915 cat confdefs.h >>conftest.$ac_ext
20916 cat >>conftest.$ac_ext <<_ACEOF
20917 /* end confdefs.h.  */
20918 #include <stdio.h>
20919 #ifdef HAVE_SUPPORTDEFS_H
20920 #include <SupportDefs.h>
20921 #endif
20922
20923 int
20924 main ()
20925 {
20926 if ((int8 *) 0)
20927   return 0;
20928 if (sizeof (int8))
20929   return 0;
20930   ;
20931   return 0;
20932 }
20933 _ACEOF
20934 rm -f conftest.$ac_objext
20935 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
20936   (eval $ac_compile) 2>conftest.er1
20937   ac_status=$?
20938   grep -v '^ *+' conftest.er1 >conftest.err
20939   rm -f conftest.er1
20940   cat conftest.err >&5
20941   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20942   (exit $ac_status); } &&
20943          { ac_try='test -z "$ac_c_werror_flag"
20944                          || test ! -s conftest.err'
20945   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20946   (eval $ac_try) 2>&5
20947   ac_status=$?
20948   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20949   (exit $ac_status); }; } &&
20950          { ac_try='test -s conftest.$ac_objext'
20951   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
20952   (eval $ac_try) 2>&5
20953   ac_status=$?
20954   echo "$as_me:$LINENO: \$? = $ac_status" >&5
20955   (exit $ac_status); }; }; then
20956   ac_cv_type_int8=yes
20957 else
20958   echo "$as_me: failed program was:" >&5
20959 sed 's/^/| /' conftest.$ac_ext >&5
20960
20961 ac_cv_type_int8=no
20962 fi
20963 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
20964 fi
20965 echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
20966 echo "${ECHO_T}$ac_cv_type_int8" >&6
20967 if test $ac_cv_type_int8 = yes; then
20968
20969 cat >>confdefs.h <<_ACEOF
20970 #define HAVE_INT8 1
20971 _ACEOF
20972
20973
20974 fi
20975 echo "$as_me:$LINENO: checking for uint8" >&5
20976 echo $ECHO_N "checking for uint8... $ECHO_C" >&6
20977 if test "${ac_cv_type_uint8+set}" = set; then
20978   echo $ECHO_N "(cached) $ECHO_C" >&6
20979 else
20980   cat >conftest.$ac_ext <<_ACEOF
20981 /* confdefs.h.  */
20982 _ACEOF
20983 cat confdefs.h >>conftest.$ac_ext
20984 cat >>conftest.$ac_ext <<_ACEOF
20985 /* end confdefs.h.  */
20986 #include <stdio.h>
20987 #ifdef HAVE_SUPPORTDEFS_H
20988 #include <SupportDefs.h>
20989 #endif
20990
20991 int
20992 main ()
20993 {
20994 if ((uint8 *) 0)
20995   return 0;
20996 if (sizeof (uint8))
20997   return 0;
20998   ;
20999   return 0;
21000 }
21001 _ACEOF
21002 rm -f conftest.$ac_objext
21003 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21004   (eval $ac_compile) 2>conftest.er1
21005   ac_status=$?
21006   grep -v '^ *+' conftest.er1 >conftest.err
21007   rm -f conftest.er1
21008   cat conftest.err >&5
21009   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21010   (exit $ac_status); } &&
21011          { ac_try='test -z "$ac_c_werror_flag"
21012                          || test ! -s conftest.err'
21013   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21014   (eval $ac_try) 2>&5
21015   ac_status=$?
21016   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21017   (exit $ac_status); }; } &&
21018          { ac_try='test -s conftest.$ac_objext'
21019   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21020   (eval $ac_try) 2>&5
21021   ac_status=$?
21022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21023   (exit $ac_status); }; }; then
21024   ac_cv_type_uint8=yes
21025 else
21026   echo "$as_me: failed program was:" >&5
21027 sed 's/^/| /' conftest.$ac_ext >&5
21028
21029 ac_cv_type_uint8=no
21030 fi
21031 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21032 fi
21033 echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
21034 echo "${ECHO_T}$ac_cv_type_uint8" >&6
21035 if test $ac_cv_type_uint8 = yes; then
21036
21037 cat >>confdefs.h <<_ACEOF
21038 #define HAVE_UINT8 1
21039 _ACEOF
21040
21041
21042 fi
21043 echo "$as_me:$LINENO: checking for int64" >&5
21044 echo $ECHO_N "checking for int64... $ECHO_C" >&6
21045 if test "${ac_cv_type_int64+set}" = set; then
21046   echo $ECHO_N "(cached) $ECHO_C" >&6
21047 else
21048   cat >conftest.$ac_ext <<_ACEOF
21049 /* confdefs.h.  */
21050 _ACEOF
21051 cat confdefs.h >>conftest.$ac_ext
21052 cat >>conftest.$ac_ext <<_ACEOF
21053 /* end confdefs.h.  */
21054 #include <stdio.h>
21055 #ifdef HAVE_SUPPORTDEFS_H
21056 #include <SupportDefs.h>
21057 #endif
21058
21059 int
21060 main ()
21061 {
21062 if ((int64 *) 0)
21063   return 0;
21064 if (sizeof (int64))
21065   return 0;
21066   ;
21067   return 0;
21068 }
21069 _ACEOF
21070 rm -f conftest.$ac_objext
21071 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21072   (eval $ac_compile) 2>conftest.er1
21073   ac_status=$?
21074   grep -v '^ *+' conftest.er1 >conftest.err
21075   rm -f conftest.er1
21076   cat conftest.err >&5
21077   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21078   (exit $ac_status); } &&
21079          { ac_try='test -z "$ac_c_werror_flag"
21080                          || test ! -s conftest.err'
21081   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21082   (eval $ac_try) 2>&5
21083   ac_status=$?
21084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21085   (exit $ac_status); }; } &&
21086          { ac_try='test -s conftest.$ac_objext'
21087   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21088   (eval $ac_try) 2>&5
21089   ac_status=$?
21090   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21091   (exit $ac_status); }; }; then
21092   ac_cv_type_int64=yes
21093 else
21094   echo "$as_me: failed program was:" >&5
21095 sed 's/^/| /' conftest.$ac_ext >&5
21096
21097 ac_cv_type_int64=no
21098 fi
21099 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21100 fi
21101 echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
21102 echo "${ECHO_T}$ac_cv_type_int64" >&6
21103 if test $ac_cv_type_int64 = yes; then
21104
21105 cat >>confdefs.h <<_ACEOF
21106 #define HAVE_INT64 1
21107 _ACEOF
21108
21109
21110 fi
21111 echo "$as_me:$LINENO: checking for uint64" >&5
21112 echo $ECHO_N "checking for uint64... $ECHO_C" >&6
21113 if test "${ac_cv_type_uint64+set}" = set; then
21114   echo $ECHO_N "(cached) $ECHO_C" >&6
21115 else
21116   cat >conftest.$ac_ext <<_ACEOF
21117 /* confdefs.h.  */
21118 _ACEOF
21119 cat confdefs.h >>conftest.$ac_ext
21120 cat >>conftest.$ac_ext <<_ACEOF
21121 /* end confdefs.h.  */
21122 #include <stdio.h>
21123 #ifdef HAVE_SUPPORTDEFS_H
21124 #include <SupportDefs.h>
21125 #endif
21126
21127 int
21128 main ()
21129 {
21130 if ((uint64 *) 0)
21131   return 0;
21132 if (sizeof (uint64))
21133   return 0;
21134   ;
21135   return 0;
21136 }
21137 _ACEOF
21138 rm -f conftest.$ac_objext
21139 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21140   (eval $ac_compile) 2>conftest.er1
21141   ac_status=$?
21142   grep -v '^ *+' conftest.er1 >conftest.err
21143   rm -f conftest.er1
21144   cat conftest.err >&5
21145   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21146   (exit $ac_status); } &&
21147          { ac_try='test -z "$ac_c_werror_flag"
21148                          || test ! -s conftest.err'
21149   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21150   (eval $ac_try) 2>&5
21151   ac_status=$?
21152   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21153   (exit $ac_status); }; } &&
21154          { ac_try='test -s conftest.$ac_objext'
21155   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21156   (eval $ac_try) 2>&5
21157   ac_status=$?
21158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21159   (exit $ac_status); }; }; then
21160   ac_cv_type_uint64=yes
21161 else
21162   echo "$as_me: failed program was:" >&5
21163 sed 's/^/| /' conftest.$ac_ext >&5
21164
21165 ac_cv_type_uint64=no
21166 fi
21167 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21168 fi
21169 echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
21170 echo "${ECHO_T}$ac_cv_type_uint64" >&6
21171 if test $ac_cv_type_uint64 = yes; then
21172
21173 cat >>confdefs.h <<_ACEOF
21174 #define HAVE_UINT64 1
21175 _ACEOF
21176
21177
21178 fi
21179
21180
21181 # We also check for sig_atomic_t, which *should* be defined per ANSI
21182 # C, but is missing on some old platforms.
21183 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
21184 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
21185 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
21186   echo $ECHO_N "(cached) $ECHO_C" >&6
21187 else
21188   cat >conftest.$ac_ext <<_ACEOF
21189 /* confdefs.h.  */
21190 _ACEOF
21191 cat confdefs.h >>conftest.$ac_ext
21192 cat >>conftest.$ac_ext <<_ACEOF
21193 /* end confdefs.h.  */
21194 #include <signal.h>
21195
21196 int
21197 main ()
21198 {
21199 if ((sig_atomic_t *) 0)
21200   return 0;
21201 if (sizeof (sig_atomic_t))
21202   return 0;
21203   ;
21204   return 0;
21205 }
21206 _ACEOF
21207 rm -f conftest.$ac_objext
21208 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21209   (eval $ac_compile) 2>conftest.er1
21210   ac_status=$?
21211   grep -v '^ *+' conftest.er1 >conftest.err
21212   rm -f conftest.er1
21213   cat conftest.err >&5
21214   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21215   (exit $ac_status); } &&
21216          { ac_try='test -z "$ac_c_werror_flag"
21217                          || test ! -s conftest.err'
21218   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21219   (eval $ac_try) 2>&5
21220   ac_status=$?
21221   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21222   (exit $ac_status); }; } &&
21223          { ac_try='test -s conftest.$ac_objext'
21224   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21225   (eval $ac_try) 2>&5
21226   ac_status=$?
21227   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21228   (exit $ac_status); }; }; then
21229   ac_cv_type_sig_atomic_t=yes
21230 else
21231   echo "$as_me: failed program was:" >&5
21232 sed 's/^/| /' conftest.$ac_ext >&5
21233
21234 ac_cv_type_sig_atomic_t=no
21235 fi
21236 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21237 fi
21238 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
21239 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
21240 if test $ac_cv_type_sig_atomic_t = yes; then
21241
21242 cat >>confdefs.h <<_ACEOF
21243 #define HAVE_SIG_ATOMIC_T 1
21244 _ACEOF
21245
21246
21247 fi
21248
21249
21250
21251 if test x"$template" != x"win32"
21252 then
21253 echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
21254 echo $ECHO_N "checking for POSIX signal interface... $ECHO_C" >&6
21255 if test "${pgac_cv_func_posix_signals+set}" = set; then
21256   echo $ECHO_N "(cached) $ECHO_C" >&6
21257 else
21258   cat >conftest.$ac_ext <<_ACEOF
21259 /* confdefs.h.  */
21260 _ACEOF
21261 cat confdefs.h >>conftest.$ac_ext
21262 cat >>conftest.$ac_ext <<_ACEOF
21263 /* end confdefs.h.  */
21264 #include <signal.h>
21265
21266 int
21267 main ()
21268 {
21269 struct sigaction act, oact;
21270 sigemptyset(&act.sa_mask);
21271 act.sa_flags = SA_RESTART;
21272 sigaction(0, &act, &oact);
21273   ;
21274   return 0;
21275 }
21276 _ACEOF
21277 rm -f conftest.$ac_objext conftest$ac_exeext
21278 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21279   (eval $ac_link) 2>conftest.er1
21280   ac_status=$?
21281   grep -v '^ *+' conftest.er1 >conftest.err
21282   rm -f conftest.er1
21283   cat conftest.err >&5
21284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21285   (exit $ac_status); } &&
21286          { ac_try='test -z "$ac_c_werror_flag"
21287                          || test ! -s conftest.err'
21288   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21289   (eval $ac_try) 2>&5
21290   ac_status=$?
21291   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21292   (exit $ac_status); }; } &&
21293          { ac_try='test -s conftest$ac_exeext'
21294   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21295   (eval $ac_try) 2>&5
21296   ac_status=$?
21297   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21298   (exit $ac_status); }; }; then
21299   pgac_cv_func_posix_signals=yes
21300 else
21301   echo "$as_me: failed program was:" >&5
21302 sed 's/^/| /' conftest.$ac_ext >&5
21303
21304 pgac_cv_func_posix_signals=no
21305 fi
21306 rm -f conftest.err conftest.$ac_objext \
21307       conftest$ac_exeext conftest.$ac_ext
21308 fi
21309 echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
21310 echo "${ECHO_T}$pgac_cv_func_posix_signals" >&6
21311 if test x"$pgac_cv_func_posix_signals" = xyes ; then
21312
21313 cat >>confdefs.h <<\_ACEOF
21314 #define HAVE_POSIX_SIGNALS
21315 _ACEOF
21316
21317 fi
21318 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
21319
21320 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
21321   { { echo "$as_me:$LINENO: error:
21322 Thread-safety requires POSIX signals, which are not supported by this
21323 operating system." >&5
21324 echo "$as_me: error:
21325 Thread-safety requires POSIX signals, which are not supported by this
21326 operating system." >&2;}
21327    { (exit 1); exit 1; }; }
21328 fi
21329 fi
21330
21331 if test $ac_cv_func_fseeko = yes; then
21332 # Check whether --enable-largefile or --disable-largefile was given.
21333 if test "${enable_largefile+set}" = set; then
21334   enableval="$enable_largefile"
21335
21336 fi;
21337 if test "$enable_largefile" != no; then
21338
21339   echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
21340 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
21341 if test "${ac_cv_sys_largefile_CC+set}" = set; then
21342   echo $ECHO_N "(cached) $ECHO_C" >&6
21343 else
21344   ac_cv_sys_largefile_CC=no
21345      if test "$GCC" != yes; then
21346        ac_save_CC=$CC
21347        while :; do
21348          # IRIX 6.2 and later do not support large files by default,
21349          # so use the C compiler's -n32 option if that helps.
21350          cat >conftest.$ac_ext <<_ACEOF
21351 /* confdefs.h.  */
21352 _ACEOF
21353 cat confdefs.h >>conftest.$ac_ext
21354 cat >>conftest.$ac_ext <<_ACEOF
21355 /* end confdefs.h.  */
21356 #include <sys/types.h>
21357  /* Check that off_t can represent 2**63 - 1 correctly.
21358     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21359     since some C++ compilers masquerading as C compilers
21360     incorrectly reject 9223372036854775807.  */
21361 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21362   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21363                        && LARGE_OFF_T % 2147483647 == 1)
21364                       ? 1 : -1];
21365 int
21366 main ()
21367 {
21368
21369   ;
21370   return 0;
21371 }
21372 _ACEOF
21373          rm -f conftest.$ac_objext
21374 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21375   (eval $ac_compile) 2>conftest.er1
21376   ac_status=$?
21377   grep -v '^ *+' conftest.er1 >conftest.err
21378   rm -f conftest.er1
21379   cat conftest.err >&5
21380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21381   (exit $ac_status); } &&
21382          { ac_try='test -z "$ac_c_werror_flag"
21383                          || test ! -s conftest.err'
21384   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21385   (eval $ac_try) 2>&5
21386   ac_status=$?
21387   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21388   (exit $ac_status); }; } &&
21389          { ac_try='test -s conftest.$ac_objext'
21390   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21391   (eval $ac_try) 2>&5
21392   ac_status=$?
21393   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21394   (exit $ac_status); }; }; then
21395   break
21396 else
21397   echo "$as_me: failed program was:" >&5
21398 sed 's/^/| /' conftest.$ac_ext >&5
21399
21400 fi
21401 rm -f conftest.err conftest.$ac_objext
21402          CC="$CC -n32"
21403          rm -f conftest.$ac_objext
21404 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21405   (eval $ac_compile) 2>conftest.er1
21406   ac_status=$?
21407   grep -v '^ *+' conftest.er1 >conftest.err
21408   rm -f conftest.er1
21409   cat conftest.err >&5
21410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21411   (exit $ac_status); } &&
21412          { ac_try='test -z "$ac_c_werror_flag"
21413                          || test ! -s conftest.err'
21414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21415   (eval $ac_try) 2>&5
21416   ac_status=$?
21417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21418   (exit $ac_status); }; } &&
21419          { ac_try='test -s conftest.$ac_objext'
21420   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21421   (eval $ac_try) 2>&5
21422   ac_status=$?
21423   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21424   (exit $ac_status); }; }; then
21425   ac_cv_sys_largefile_CC=' -n32'; break
21426 else
21427   echo "$as_me: failed program was:" >&5
21428 sed 's/^/| /' conftest.$ac_ext >&5
21429
21430 fi
21431 rm -f conftest.err conftest.$ac_objext
21432          break
21433        done
21434        CC=$ac_save_CC
21435        rm -f conftest.$ac_ext
21436     fi
21437 fi
21438 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
21439 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
21440   if test "$ac_cv_sys_largefile_CC" != no; then
21441     CC=$CC$ac_cv_sys_largefile_CC
21442   fi
21443
21444   echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
21445 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
21446 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
21447   echo $ECHO_N "(cached) $ECHO_C" >&6
21448 else
21449   while :; do
21450   ac_cv_sys_file_offset_bits=no
21451   cat >conftest.$ac_ext <<_ACEOF
21452 /* confdefs.h.  */
21453 _ACEOF
21454 cat confdefs.h >>conftest.$ac_ext
21455 cat >>conftest.$ac_ext <<_ACEOF
21456 /* end confdefs.h.  */
21457 #include <sys/types.h>
21458  /* Check that off_t can represent 2**63 - 1 correctly.
21459     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21460     since some C++ compilers masquerading as C compilers
21461     incorrectly reject 9223372036854775807.  */
21462 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21463   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21464                        && LARGE_OFF_T % 2147483647 == 1)
21465                       ? 1 : -1];
21466 int
21467 main ()
21468 {
21469
21470   ;
21471   return 0;
21472 }
21473 _ACEOF
21474 rm -f conftest.$ac_objext
21475 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21476   (eval $ac_compile) 2>conftest.er1
21477   ac_status=$?
21478   grep -v '^ *+' conftest.er1 >conftest.err
21479   rm -f conftest.er1
21480   cat conftest.err >&5
21481   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21482   (exit $ac_status); } &&
21483          { ac_try='test -z "$ac_c_werror_flag"
21484                          || test ! -s conftest.err'
21485   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21486   (eval $ac_try) 2>&5
21487   ac_status=$?
21488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21489   (exit $ac_status); }; } &&
21490          { ac_try='test -s conftest.$ac_objext'
21491   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21492   (eval $ac_try) 2>&5
21493   ac_status=$?
21494   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21495   (exit $ac_status); }; }; then
21496   break
21497 else
21498   echo "$as_me: failed program was:" >&5
21499 sed 's/^/| /' conftest.$ac_ext >&5
21500
21501 fi
21502 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21503   cat >conftest.$ac_ext <<_ACEOF
21504 /* confdefs.h.  */
21505 _ACEOF
21506 cat confdefs.h >>conftest.$ac_ext
21507 cat >>conftest.$ac_ext <<_ACEOF
21508 /* end confdefs.h.  */
21509 #define _FILE_OFFSET_BITS 64
21510 #include <sys/types.h>
21511  /* Check that off_t can represent 2**63 - 1 correctly.
21512     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21513     since some C++ compilers masquerading as C compilers
21514     incorrectly reject 9223372036854775807.  */
21515 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21516   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21517                        && LARGE_OFF_T % 2147483647 == 1)
21518                       ? 1 : -1];
21519 int
21520 main ()
21521 {
21522
21523   ;
21524   return 0;
21525 }
21526 _ACEOF
21527 rm -f conftest.$ac_objext
21528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21529   (eval $ac_compile) 2>conftest.er1
21530   ac_status=$?
21531   grep -v '^ *+' conftest.er1 >conftest.err
21532   rm -f conftest.er1
21533   cat conftest.err >&5
21534   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21535   (exit $ac_status); } &&
21536          { ac_try='test -z "$ac_c_werror_flag"
21537                          || test ! -s conftest.err'
21538   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21539   (eval $ac_try) 2>&5
21540   ac_status=$?
21541   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21542   (exit $ac_status); }; } &&
21543          { ac_try='test -s conftest.$ac_objext'
21544   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21545   (eval $ac_try) 2>&5
21546   ac_status=$?
21547   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21548   (exit $ac_status); }; }; then
21549   ac_cv_sys_file_offset_bits=64; break
21550 else
21551   echo "$as_me: failed program was:" >&5
21552 sed 's/^/| /' conftest.$ac_ext >&5
21553
21554 fi
21555 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21556   break
21557 done
21558 fi
21559 echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
21560 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
21561 if test "$ac_cv_sys_file_offset_bits" != no; then
21562
21563 cat >>confdefs.h <<_ACEOF
21564 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
21565 _ACEOF
21566
21567 fi
21568 rm -f conftest*
21569   echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
21570 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
21571 if test "${ac_cv_sys_large_files+set}" = set; then
21572   echo $ECHO_N "(cached) $ECHO_C" >&6
21573 else
21574   while :; do
21575   ac_cv_sys_large_files=no
21576   cat >conftest.$ac_ext <<_ACEOF
21577 /* confdefs.h.  */
21578 _ACEOF
21579 cat confdefs.h >>conftest.$ac_ext
21580 cat >>conftest.$ac_ext <<_ACEOF
21581 /* end confdefs.h.  */
21582 #include <sys/types.h>
21583  /* Check that off_t can represent 2**63 - 1 correctly.
21584     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21585     since some C++ compilers masquerading as C compilers
21586     incorrectly reject 9223372036854775807.  */
21587 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21588   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21589                        && LARGE_OFF_T % 2147483647 == 1)
21590                       ? 1 : -1];
21591 int
21592 main ()
21593 {
21594
21595   ;
21596   return 0;
21597 }
21598 _ACEOF
21599 rm -f conftest.$ac_objext
21600 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21601   (eval $ac_compile) 2>conftest.er1
21602   ac_status=$?
21603   grep -v '^ *+' conftest.er1 >conftest.err
21604   rm -f conftest.er1
21605   cat conftest.err >&5
21606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21607   (exit $ac_status); } &&
21608          { ac_try='test -z "$ac_c_werror_flag"
21609                          || test ! -s conftest.err'
21610   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21611   (eval $ac_try) 2>&5
21612   ac_status=$?
21613   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21614   (exit $ac_status); }; } &&
21615          { ac_try='test -s conftest.$ac_objext'
21616   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21617   (eval $ac_try) 2>&5
21618   ac_status=$?
21619   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21620   (exit $ac_status); }; }; then
21621   break
21622 else
21623   echo "$as_me: failed program was:" >&5
21624 sed 's/^/| /' conftest.$ac_ext >&5
21625
21626 fi
21627 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21628   cat >conftest.$ac_ext <<_ACEOF
21629 /* confdefs.h.  */
21630 _ACEOF
21631 cat confdefs.h >>conftest.$ac_ext
21632 cat >>conftest.$ac_ext <<_ACEOF
21633 /* end confdefs.h.  */
21634 #define _LARGE_FILES 1
21635 #include <sys/types.h>
21636  /* Check that off_t can represent 2**63 - 1 correctly.
21637     We can't simply define LARGE_OFF_T to be 9223372036854775807,
21638     since some C++ compilers masquerading as C compilers
21639     incorrectly reject 9223372036854775807.  */
21640 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
21641   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
21642                        && LARGE_OFF_T % 2147483647 == 1)
21643                       ? 1 : -1];
21644 int
21645 main ()
21646 {
21647
21648   ;
21649   return 0;
21650 }
21651 _ACEOF
21652 rm -f conftest.$ac_objext
21653 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21654   (eval $ac_compile) 2>conftest.er1
21655   ac_status=$?
21656   grep -v '^ *+' conftest.er1 >conftest.err
21657   rm -f conftest.er1
21658   cat conftest.err >&5
21659   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21660   (exit $ac_status); } &&
21661          { ac_try='test -z "$ac_c_werror_flag"
21662                          || test ! -s conftest.err'
21663   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21664   (eval $ac_try) 2>&5
21665   ac_status=$?
21666   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21667   (exit $ac_status); }; } &&
21668          { ac_try='test -s conftest.$ac_objext'
21669   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21670   (eval $ac_try) 2>&5
21671   ac_status=$?
21672   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21673   (exit $ac_status); }; }; then
21674   ac_cv_sys_large_files=1; break
21675 else
21676   echo "$as_me: failed program was:" >&5
21677 sed 's/^/| /' conftest.$ac_ext >&5
21678
21679 fi
21680 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
21681   break
21682 done
21683 fi
21684 echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
21685 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
21686 if test "$ac_cv_sys_large_files" != no; then
21687
21688 cat >>confdefs.h <<_ACEOF
21689 #define _LARGE_FILES $ac_cv_sys_large_files
21690 _ACEOF
21691
21692 fi
21693 rm -f conftest*
21694 fi
21695
21696 fi
21697
21698 # SunOS doesn't handle negative byte comparisons properly with +/- return
21699 echo "$as_me:$LINENO: checking for working memcmp" >&5
21700 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
21701 if test "${ac_cv_func_memcmp_working+set}" = set; then
21702   echo $ECHO_N "(cached) $ECHO_C" >&6
21703 else
21704   if test "$cross_compiling" = yes; then
21705   ac_cv_func_memcmp_working=no
21706 else
21707   cat >conftest.$ac_ext <<_ACEOF
21708 /* confdefs.h.  */
21709 _ACEOF
21710 cat confdefs.h >>conftest.$ac_ext
21711 cat >>conftest.$ac_ext <<_ACEOF
21712 /* end confdefs.h.  */
21713 $ac_includes_default
21714 int
21715 main ()
21716 {
21717
21718   /* Some versions of memcmp are not 8-bit clean.  */
21719   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
21720   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
21721     exit (1);
21722
21723   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
21724      or more and with at least one buffer not starting on a 4-byte boundary.
21725      William Lewis provided this test program.   */
21726   {
21727     char foo[21];
21728     char bar[21];
21729     int i;
21730     for (i = 0; i < 4; i++)
21731       {
21732         char *a = foo + i;
21733         char *b = bar + i;
21734         strcpy (a, "--------01111111");
21735         strcpy (b, "--------10000000");
21736         if (memcmp (a, b, 16) >= 0)
21737           exit (1);
21738       }
21739     exit (0);
21740   }
21741
21742   ;
21743   return 0;
21744 }
21745 _ACEOF
21746 rm -f conftest$ac_exeext
21747 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21748   (eval $ac_link) 2>&5
21749   ac_status=$?
21750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21751   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
21752   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21753   (eval $ac_try) 2>&5
21754   ac_status=$?
21755   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21756   (exit $ac_status); }; }; then
21757   ac_cv_func_memcmp_working=yes
21758 else
21759   echo "$as_me: program exited with status $ac_status" >&5
21760 echo "$as_me: failed program was:" >&5
21761 sed 's/^/| /' conftest.$ac_ext >&5
21762
21763 ( exit $ac_status )
21764 ac_cv_func_memcmp_working=no
21765 fi
21766 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21767 fi
21768 fi
21769 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
21770 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
21771 test $ac_cv_func_memcmp_working = no && case $LIBOBJS in
21772     "memcmp.$ac_objext"   | \
21773   *" memcmp.$ac_objext"   | \
21774     "memcmp.$ac_objext "* | \
21775   *" memcmp.$ac_objext "* ) ;;
21776   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" ;;
21777 esac
21778
21779
21780
21781
21782 # Select semaphore implementation type.
21783 if test "$PORTNAME" != "win32"; then
21784   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
21785
21786 cat >>confdefs.h <<\_ACEOF
21787 #define USE_NAMED_POSIX_SEMAPHORES 1
21788 _ACEOF
21789
21790     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21791   else
21792     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
21793
21794 cat >>confdefs.h <<\_ACEOF
21795 #define USE_UNNAMED_POSIX_SEMAPHORES 1
21796 _ACEOF
21797
21798       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
21799     else
21800
21801 cat >>confdefs.h <<\_ACEOF
21802 #define USE_SYSV_SEMAPHORES 1
21803 _ACEOF
21804
21805       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
21806     fi
21807   fi
21808 else
21809
21810 cat >>confdefs.h <<\_ACEOF
21811 #define USE_WIN32_SEMAPHORES 1
21812 _ACEOF
21813
21814   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
21815 fi
21816
21817
21818 # Select shared-memory implementation type.
21819
21820 cat >>confdefs.h <<\_ACEOF
21821 #define USE_SYSV_SHARED_MEMORY 1
21822 _ACEOF
21823
21824 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
21825
21826
21827 # If not set in template file, set bytes to use libc memset()
21828 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
21829   MEMSET_LOOP_LIMIT=1024
21830 fi
21831
21832 cat >>confdefs.h <<_ACEOF
21833 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
21834 _ACEOF
21835
21836
21837
21838 if test "$enable_nls" = yes ; then
21839
21840   echo "$as_me:$LINENO: checking for library containing gettext" >&5
21841 echo $ECHO_N "checking for library containing gettext... $ECHO_C" >&6
21842 if test "${ac_cv_search_gettext+set}" = set; then
21843   echo $ECHO_N "(cached) $ECHO_C" >&6
21844 else
21845   ac_func_search_save_LIBS=$LIBS
21846 ac_cv_search_gettext=no
21847 cat >conftest.$ac_ext <<_ACEOF
21848 /* confdefs.h.  */
21849 _ACEOF
21850 cat confdefs.h >>conftest.$ac_ext
21851 cat >>conftest.$ac_ext <<_ACEOF
21852 /* end confdefs.h.  */
21853
21854 /* Override any gcc2 internal prototype to avoid an error.  */
21855 #ifdef __cplusplus
21856 extern "C"
21857 #endif
21858 /* We use char because int might match the return type of a gcc2
21859    builtin and then its argument prototype would still apply.  */
21860 char gettext ();
21861 int
21862 main ()
21863 {
21864 gettext ();
21865   ;
21866   return 0;
21867 }
21868 _ACEOF
21869 rm -f conftest.$ac_objext conftest$ac_exeext
21870 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21871   (eval $ac_link) 2>conftest.er1
21872   ac_status=$?
21873   grep -v '^ *+' conftest.er1 >conftest.err
21874   rm -f conftest.er1
21875   cat conftest.err >&5
21876   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21877   (exit $ac_status); } &&
21878          { ac_try='test -z "$ac_c_werror_flag"
21879                          || test ! -s conftest.err'
21880   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21881   (eval $ac_try) 2>&5
21882   ac_status=$?
21883   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21884   (exit $ac_status); }; } &&
21885          { ac_try='test -s conftest$ac_exeext'
21886   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21887   (eval $ac_try) 2>&5
21888   ac_status=$?
21889   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21890   (exit $ac_status); }; }; then
21891   ac_cv_search_gettext="none required"
21892 else
21893   echo "$as_me: failed program was:" >&5
21894 sed 's/^/| /' conftest.$ac_ext >&5
21895
21896 fi
21897 rm -f conftest.err conftest.$ac_objext \
21898       conftest$ac_exeext conftest.$ac_ext
21899 if test "$ac_cv_search_gettext" = no; then
21900   for ac_lib in intl; do
21901     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21902     cat >conftest.$ac_ext <<_ACEOF
21903 /* confdefs.h.  */
21904 _ACEOF
21905 cat confdefs.h >>conftest.$ac_ext
21906 cat >>conftest.$ac_ext <<_ACEOF
21907 /* end confdefs.h.  */
21908
21909 /* Override any gcc2 internal prototype to avoid an error.  */
21910 #ifdef __cplusplus
21911 extern "C"
21912 #endif
21913 /* We use char because int might match the return type of a gcc2
21914    builtin and then its argument prototype would still apply.  */
21915 char gettext ();
21916 int
21917 main ()
21918 {
21919 gettext ();
21920   ;
21921   return 0;
21922 }
21923 _ACEOF
21924 rm -f conftest.$ac_objext conftest$ac_exeext
21925 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
21926   (eval $ac_link) 2>conftest.er1
21927   ac_status=$?
21928   grep -v '^ *+' conftest.er1 >conftest.err
21929   rm -f conftest.er1
21930   cat conftest.err >&5
21931   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21932   (exit $ac_status); } &&
21933          { ac_try='test -z "$ac_c_werror_flag"
21934                          || test ! -s conftest.err'
21935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21936   (eval $ac_try) 2>&5
21937   ac_status=$?
21938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21939   (exit $ac_status); }; } &&
21940          { ac_try='test -s conftest$ac_exeext'
21941   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
21942   (eval $ac_try) 2>&5
21943   ac_status=$?
21944   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21945   (exit $ac_status); }; }; then
21946   ac_cv_search_gettext="-l$ac_lib"
21947 break
21948 else
21949   echo "$as_me: failed program was:" >&5
21950 sed 's/^/| /' conftest.$ac_ext >&5
21951
21952 fi
21953 rm -f conftest.err conftest.$ac_objext \
21954       conftest$ac_exeext conftest.$ac_ext
21955   done
21956 fi
21957 LIBS=$ac_func_search_save_LIBS
21958 fi
21959 echo "$as_me:$LINENO: result: $ac_cv_search_gettext" >&5
21960 echo "${ECHO_T}$ac_cv_search_gettext" >&6
21961 if test "$ac_cv_search_gettext" != no; then
21962   test "$ac_cv_search_gettext" = "none required" || LIBS="$ac_cv_search_gettext $LIBS"
21963
21964 else
21965   { { echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
21966 echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
21967    { (exit 1); exit 1; }; }
21968 fi
21969
21970   if test "${ac_cv_header_libintl_h+set}" = set; then
21971   echo "$as_me:$LINENO: checking for libintl.h" >&5
21972 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
21973 if test "${ac_cv_header_libintl_h+set}" = set; then
21974   echo $ECHO_N "(cached) $ECHO_C" >&6
21975 fi
21976 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
21977 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
21978 else
21979   # Is the header compilable?
21980 echo "$as_me:$LINENO: checking libintl.h usability" >&5
21981 echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6
21982 cat >conftest.$ac_ext <<_ACEOF
21983 /* confdefs.h.  */
21984 _ACEOF
21985 cat confdefs.h >>conftest.$ac_ext
21986 cat >>conftest.$ac_ext <<_ACEOF
21987 /* end confdefs.h.  */
21988 $ac_includes_default
21989 #include <libintl.h>
21990 _ACEOF
21991 rm -f conftest.$ac_objext
21992 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
21993   (eval $ac_compile) 2>conftest.er1
21994   ac_status=$?
21995   grep -v '^ *+' conftest.er1 >conftest.err
21996   rm -f conftest.er1
21997   cat conftest.err >&5
21998   echo "$as_me:$LINENO: \$? = $ac_status" >&5
21999   (exit $ac_status); } &&
22000          { ac_try='test -z "$ac_c_werror_flag"
22001                          || test ! -s conftest.err'
22002   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22003   (eval $ac_try) 2>&5
22004   ac_status=$?
22005   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22006   (exit $ac_status); }; } &&
22007          { ac_try='test -s conftest.$ac_objext'
22008   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22009   (eval $ac_try) 2>&5
22010   ac_status=$?
22011   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22012   (exit $ac_status); }; }; then
22013   ac_header_compiler=yes
22014 else
22015   echo "$as_me: failed program was:" >&5
22016 sed 's/^/| /' conftest.$ac_ext >&5
22017
22018 ac_header_compiler=no
22019 fi
22020 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
22021 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22022 echo "${ECHO_T}$ac_header_compiler" >&6
22023
22024 # Is the header present?
22025 echo "$as_me:$LINENO: checking libintl.h presence" >&5
22026 echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6
22027 cat >conftest.$ac_ext <<_ACEOF
22028 /* confdefs.h.  */
22029 _ACEOF
22030 cat confdefs.h >>conftest.$ac_ext
22031 cat >>conftest.$ac_ext <<_ACEOF
22032 /* end confdefs.h.  */
22033 #include <libintl.h>
22034 _ACEOF
22035 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
22036   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22037   ac_status=$?
22038   grep -v '^ *+' conftest.er1 >conftest.err
22039   rm -f conftest.er1
22040   cat conftest.err >&5
22041   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22042   (exit $ac_status); } >/dev/null; then
22043   if test -s conftest.err; then
22044     ac_cpp_err=$ac_c_preproc_warn_flag
22045     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
22046   else
22047     ac_cpp_err=
22048   fi
22049 else
22050   ac_cpp_err=yes
22051 fi
22052 if test -z "$ac_cpp_err"; then
22053   ac_header_preproc=yes
22054 else
22055   echo "$as_me: failed program was:" >&5
22056 sed 's/^/| /' conftest.$ac_ext >&5
22057
22058   ac_header_preproc=no
22059 fi
22060 rm -f conftest.err conftest.$ac_ext
22061 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22062 echo "${ECHO_T}$ac_header_preproc" >&6
22063
22064 # So?  What about this header?
22065 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22066   yes:no: )
22067     { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
22068 echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
22069     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
22070 echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
22071     ac_header_preproc=yes
22072     ;;
22073   no:yes:* )
22074     { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
22075 echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
22076     { echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
22077 echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
22078     { echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
22079 echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
22080     { echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
22081 echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
22082     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
22083 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
22084     { echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
22085 echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
22086     (
22087       cat <<\_ASBOX
22088 ## ---------------------------------------- ##
22089 ## Report this to pgsql-bugs@postgresql.org ##
22090 ## ---------------------------------------- ##
22091 _ASBOX
22092     ) |
22093       sed "s/^/$as_me: WARNING:     /" >&2
22094     ;;
22095 esac
22096 echo "$as_me:$LINENO: checking for libintl.h" >&5
22097 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
22098 if test "${ac_cv_header_libintl_h+set}" = set; then
22099   echo $ECHO_N "(cached) $ECHO_C" >&6
22100 else
22101   ac_cv_header_libintl_h=$ac_header_preproc
22102 fi
22103 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
22104 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
22105
22106 fi
22107 if test $ac_cv_header_libintl_h = yes; then
22108   :
22109 else
22110   { { echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
22111 echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
22112    { (exit 1); exit 1; }; }
22113 fi
22114
22115
22116   for ac_prog in msgfmt
22117 do
22118   # Extract the first word of "$ac_prog", so it can be a program name with args.
22119 set dummy $ac_prog; ac_word=$2
22120 echo "$as_me:$LINENO: checking for $ac_word" >&5
22121 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22122 if test "${ac_cv_prog_MSGFMT+set}" = set; then
22123   echo $ECHO_N "(cached) $ECHO_C" >&6
22124 else
22125   if test -n "$MSGFMT"; then
22126   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
22127 else
22128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22129 for as_dir in $PATH
22130 do
22131   IFS=$as_save_IFS
22132   test -z "$as_dir" && as_dir=.
22133   for ac_exec_ext in '' $ac_executable_extensions; do
22134   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22135     ac_cv_prog_MSGFMT="$ac_prog"
22136     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22137     break 2
22138   fi
22139 done
22140 done
22141
22142 fi
22143 fi
22144 MSGFMT=$ac_cv_prog_MSGFMT
22145 if test -n "$MSGFMT"; then
22146   echo "$as_me:$LINENO: result: $MSGFMT" >&5
22147 echo "${ECHO_T}$MSGFMT" >&6
22148 else
22149   echo "$as_me:$LINENO: result: no" >&5
22150 echo "${ECHO_T}no" >&6
22151 fi
22152
22153   test -n "$MSGFMT" && break
22154 done
22155
22156   if test -z "$MSGFMT"; then
22157     { { echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
22158 echo "$as_me: error: msgfmt is required for NLS" >&2;}
22159    { (exit 1); exit 1; }; }
22160   fi
22161   for ac_prog in msgmerge
22162 do
22163   # Extract the first word of "$ac_prog", so it can be a program name with args.
22164 set dummy $ac_prog; ac_word=$2
22165 echo "$as_me:$LINENO: checking for $ac_word" >&5
22166 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22167 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
22168   echo $ECHO_N "(cached) $ECHO_C" >&6
22169 else
22170   if test -n "$MSGMERGE"; then
22171   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
22172 else
22173 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22174 for as_dir in $PATH
22175 do
22176   IFS=$as_save_IFS
22177   test -z "$as_dir" && as_dir=.
22178   for ac_exec_ext in '' $ac_executable_extensions; do
22179   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22180     ac_cv_prog_MSGMERGE="$ac_prog"
22181     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22182     break 2
22183   fi
22184 done
22185 done
22186
22187 fi
22188 fi
22189 MSGMERGE=$ac_cv_prog_MSGMERGE
22190 if test -n "$MSGMERGE"; then
22191   echo "$as_me:$LINENO: result: $MSGMERGE" >&5
22192 echo "${ECHO_T}$MSGMERGE" >&6
22193 else
22194   echo "$as_me:$LINENO: result: no" >&5
22195 echo "${ECHO_T}no" >&6
22196 fi
22197
22198   test -n "$MSGMERGE" && break
22199 done
22200
22201   for ac_prog in xgettext
22202 do
22203   # Extract the first word of "$ac_prog", so it can be a program name with args.
22204 set dummy $ac_prog; ac_word=$2
22205 echo "$as_me:$LINENO: checking for $ac_word" >&5
22206 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22207 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
22208   echo $ECHO_N "(cached) $ECHO_C" >&6
22209 else
22210   if test -n "$XGETTEXT"; then
22211   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
22212 else
22213 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22214 for as_dir in $PATH
22215 do
22216   IFS=$as_save_IFS
22217   test -z "$as_dir" && as_dir=.
22218   for ac_exec_ext in '' $ac_executable_extensions; do
22219   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22220     ac_cv_prog_XGETTEXT="$ac_prog"
22221     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22222     break 2
22223   fi
22224 done
22225 done
22226
22227 fi
22228 fi
22229 XGETTEXT=$ac_cv_prog_XGETTEXT
22230 if test -n "$XGETTEXT"; then
22231   echo "$as_me:$LINENO: result: $XGETTEXT" >&5
22232 echo "${ECHO_T}$XGETTEXT" >&6
22233 else
22234   echo "$as_me:$LINENO: result: no" >&5
22235 echo "${ECHO_T}no" >&6
22236 fi
22237
22238   test -n "$XGETTEXT" && break
22239 done
22240
22241
22242   # Note: share/locale is always the default, independent of $datadir
22243   localedir='${prefix}/share/locale'
22244
22245
22246 fi
22247
22248 # Check for Tcl configuration script tclConfig.sh
22249 if test "$with_tcl" = yes; then
22250     for ac_prog in tclsh tcl
22251 do
22252   # Extract the first word of "$ac_prog", so it can be a program name with args.
22253 set dummy $ac_prog; ac_word=$2
22254 echo "$as_me:$LINENO: checking for $ac_word" >&5
22255 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22256 if test "${ac_cv_path_TCLSH+set}" = set; then
22257   echo $ECHO_N "(cached) $ECHO_C" >&6
22258 else
22259   case $TCLSH in
22260   [\\/]* | ?:[\\/]*)
22261   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
22262   ;;
22263   *)
22264   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22265 for as_dir in $PATH
22266 do
22267   IFS=$as_save_IFS
22268   test -z "$as_dir" && as_dir=.
22269   for ac_exec_ext in '' $ac_executable_extensions; do
22270   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22271     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
22272     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22273     break 2
22274   fi
22275 done
22276 done
22277
22278   ;;
22279 esac
22280 fi
22281 TCLSH=$ac_cv_path_TCLSH
22282
22283 if test -n "$TCLSH"; then
22284   echo "$as_me:$LINENO: result: $TCLSH" >&5
22285 echo "${ECHO_T}$TCLSH" >&6
22286 else
22287   echo "$as_me:$LINENO: result: no" >&5
22288 echo "${ECHO_T}no" >&6
22289 fi
22290
22291   test -n "$TCLSH" && break
22292 done
22293
22294 echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
22295 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6
22296 # Let user override test
22297 if test -z "$TCL_CONFIG_SH"; then
22298     pgac_test_dirs="$with_tclconfig"
22299
22300     set X $pgac_test_dirs; shift
22301     if test $# -eq 0; then
22302         test -z "$TCLSH" && { { echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
22303 echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
22304    { (exit 1); exit 1; }; }
22305         set X `echo 'puts $auto_path' | $TCLSH`; shift
22306     fi
22307
22308     for pgac_dir do
22309         if test -r "$pgac_dir/tclConfig.sh"; then
22310             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
22311             break
22312         fi
22313     done
22314 fi
22315
22316 if test -z "$TCL_CONFIG_SH"; then
22317     echo "$as_me:$LINENO: result: no" >&5
22318 echo "${ECHO_T}no" >&6
22319     { { echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
22320 echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
22321    { (exit 1); exit 1; }; }
22322 else
22323     echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
22324 echo "${ECHO_T}$TCL_CONFIG_SH" >&6
22325 fi
22326
22327
22328
22329     . "$TCL_CONFIG_SH"
22330 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
22331 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
22332 eval TCL_LIBS=\"$TCL_LIBS\"
22333 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
22334 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
22335
22336         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
22337     ac_save_CPPFLAGS=$CPPFLAGS
22338     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
22339     if test "${ac_cv_header_tcl_h+set}" = set; then
22340   echo "$as_me:$LINENO: checking for tcl.h" >&5
22341 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
22342 if test "${ac_cv_header_tcl_h+set}" = set; then
22343   echo $ECHO_N "(cached) $ECHO_C" >&6
22344 fi
22345 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
22346 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
22347 else
22348   # Is the header compilable?
22349 echo "$as_me:$LINENO: checking tcl.h usability" >&5
22350 echo $ECHO_N "checking tcl.h usability... $ECHO_C" >&6
22351 cat >conftest.$ac_ext <<_ACEOF
22352 /* confdefs.h.  */
22353 _ACEOF
22354 cat confdefs.h >>conftest.$ac_ext
22355 cat >>conftest.$ac_ext <<_ACEOF
22356 /* end confdefs.h.  */
22357 $ac_includes_default
22358 #include <tcl.h>
22359 _ACEOF
22360 rm -f conftest.$ac_objext
22361 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
22362   (eval $ac_compile) 2>conftest.er1
22363   ac_status=$?
22364   grep -v '^ *+' conftest.er1 >conftest.err
22365   rm -f conftest.er1
22366   cat conftest.err >&5
22367   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22368   (exit $ac_status); } &&
22369          { ac_try='test -z "$ac_c_werror_flag"
22370                          || test ! -s conftest.err'
22371   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22372   (eval $ac_try) 2>&5
22373   ac_status=$?
22374   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22375   (exit $ac_status); }; } &&
22376          { ac_try='test -s conftest.$ac_objext'
22377   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22378   (eval $ac_try) 2>&5
22379   ac_status=$?
22380   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22381   (exit $ac_status); }; }; then
22382   ac_header_compiler=yes
22383 else
22384   echo "$as_me: failed program was:" >&5
22385 sed 's/^/| /' conftest.$ac_ext >&5
22386
22387 ac_header_compiler=no
22388 fi
22389 rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
22390 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22391 echo "${ECHO_T}$ac_header_compiler" >&6
22392
22393 # Is the header present?
22394 echo "$as_me:$LINENO: checking tcl.h presence" >&5
22395 echo $ECHO_N "checking tcl.h presence... $ECHO_C" >&6
22396 cat >conftest.$ac_ext <<_ACEOF
22397 /* confdefs.h.  */
22398 _ACEOF
22399 cat confdefs.h >>conftest.$ac_ext
22400 cat >>conftest.$ac_ext <<_ACEOF
22401 /* end confdefs.h.  */
22402 #include <tcl.h>
22403 _ACEOF
22404 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
22405   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
22406   ac_status=$?
22407   grep -v '^ *+' conftest.er1 >conftest.err
22408   rm -f conftest.er1
22409   cat conftest.err >&5
22410   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22411   (exit $ac_status); } >/dev/null; then
22412   if test -s conftest.err; then
22413     ac_cpp_err=$ac_c_preproc_warn_flag
22414     ac_cpp_err=$ac_cpp_err$ac_c_werror_flag
22415   else
22416     ac_cpp_err=
22417   fi
22418 else
22419   ac_cpp_err=yes
22420 fi
22421 if test -z "$ac_cpp_err"; then
22422   ac_header_preproc=yes
22423 else
22424   echo "$as_me: failed program was:" >&5
22425 sed 's/^/| /' conftest.$ac_ext >&5
22426
22427   ac_header_preproc=no
22428 fi
22429 rm -f conftest.err conftest.$ac_ext
22430 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22431 echo "${ECHO_T}$ac_header_preproc" >&6
22432
22433 # So?  What about this header?
22434 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22435   yes:no: )
22436     { echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
22437 echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
22438     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
22439 echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
22440     ac_header_preproc=yes
22441     ;;
22442   no:yes:* )
22443     { echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
22444 echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
22445     { echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
22446 echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
22447     { echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
22448 echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
22449     { echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
22450 echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
22451     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
22452 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
22453     { echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
22454 echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
22455     (
22456       cat <<\_ASBOX
22457 ## ---------------------------------------- ##
22458 ## Report this to pgsql-bugs@postgresql.org ##
22459 ## ---------------------------------------- ##
22460 _ASBOX
22461     ) |
22462       sed "s/^/$as_me: WARNING:     /" >&2
22463     ;;
22464 esac
22465 echo "$as_me:$LINENO: checking for tcl.h" >&5
22466 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
22467 if test "${ac_cv_header_tcl_h+set}" = set; then
22468   echo $ECHO_N "(cached) $ECHO_C" >&6
22469 else
22470   ac_cv_header_tcl_h=$ac_header_preproc
22471 fi
22472 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
22473 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
22474
22475 fi
22476 if test $ac_cv_header_tcl_h = yes; then
22477   :
22478 else
22479   { { echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
22480 echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
22481    { (exit 1); exit 1; }; }
22482 fi
22483
22484
22485     CPPFLAGS=$ac_save_CPPFLAGS
22486 fi
22487
22488 #
22489 # Check for DocBook and tools
22490 #
22491 for ac_prog in onsgmls nsgmls
22492 do
22493   # Extract the first word of "$ac_prog", so it can be a program name with args.
22494 set dummy $ac_prog; ac_word=$2
22495 echo "$as_me:$LINENO: checking for $ac_word" >&5
22496 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22497 if test "${ac_cv_prog_NSGMLS+set}" = set; then
22498   echo $ECHO_N "(cached) $ECHO_C" >&6
22499 else
22500   if test -n "$NSGMLS"; then
22501   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
22502 else
22503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22504 for as_dir in $PATH
22505 do
22506   IFS=$as_save_IFS
22507   test -z "$as_dir" && as_dir=.
22508   for ac_exec_ext in '' $ac_executable_extensions; do
22509   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22510     ac_cv_prog_NSGMLS="$ac_prog"
22511     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22512     break 2
22513   fi
22514 done
22515 done
22516
22517 fi
22518 fi
22519 NSGMLS=$ac_cv_prog_NSGMLS
22520 if test -n "$NSGMLS"; then
22521   echo "$as_me:$LINENO: result: $NSGMLS" >&5
22522 echo "${ECHO_T}$NSGMLS" >&6
22523 else
22524   echo "$as_me:$LINENO: result: no" >&5
22525 echo "${ECHO_T}no" >&6
22526 fi
22527
22528   test -n "$NSGMLS" && break
22529 done
22530
22531 for ac_prog in openjade jade
22532 do
22533   # Extract the first word of "$ac_prog", so it can be a program name with args.
22534 set dummy $ac_prog; ac_word=$2
22535 echo "$as_me:$LINENO: checking for $ac_word" >&5
22536 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22537 if test "${ac_cv_prog_JADE+set}" = set; then
22538   echo $ECHO_N "(cached) $ECHO_C" >&6
22539 else
22540   if test -n "$JADE"; then
22541   ac_cv_prog_JADE="$JADE" # Let the user override the test.
22542 else
22543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22544 for as_dir in $PATH
22545 do
22546   IFS=$as_save_IFS
22547   test -z "$as_dir" && as_dir=.
22548   for ac_exec_ext in '' $ac_executable_extensions; do
22549   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22550     ac_cv_prog_JADE="$ac_prog"
22551     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22552     break 2
22553   fi
22554 done
22555 done
22556
22557 fi
22558 fi
22559 JADE=$ac_cv_prog_JADE
22560 if test -n "$JADE"; then
22561   echo "$as_me:$LINENO: result: $JADE" >&5
22562 echo "${ECHO_T}$JADE" >&6
22563 else
22564   echo "$as_me:$LINENO: result: no" >&5
22565 echo "${ECHO_T}no" >&6
22566 fi
22567
22568   test -n "$JADE" && break
22569 done
22570
22571
22572 echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
22573 echo $ECHO_N "checking for DocBook V4.2... $ECHO_C" >&6
22574 if test "${pgac_cv_check_docbook+set}" = set; then
22575   echo $ECHO_N "(cached) $ECHO_C" >&6
22576 else
22577   cat >conftest.sgml <<EOF
22578 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
22579 <book>
22580  <title>test</title>
22581  <chapter>
22582   <title>random</title>
22583    <sect1>
22584     <title>testsect</title>
22585     <para>text</para>
22586   </sect1>
22587  </chapter>
22588 </book>
22589 EOF
22590
22591 pgac_cv_check_docbook=no
22592
22593 if test -n "$NSGMLS"; then
22594   $NSGMLS -s conftest.sgml 1>&5 2>&1
22595   if test $? -eq 0; then
22596     pgac_cv_check_docbook=yes
22597   fi
22598 fi
22599 rm -f conftest.sgml
22600 fi
22601 echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
22602 echo "${ECHO_T}$pgac_cv_check_docbook" >&6
22603
22604 have_docbook=$pgac_cv_check_docbook
22605
22606
22607 echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
22608 echo $ECHO_N "checking for DocBook stylesheets... $ECHO_C" >&6
22609 if test "${pgac_cv_path_stylesheets+set}" = set; then
22610   echo $ECHO_N "(cached) $ECHO_C" >&6
22611 else
22612   if test -n "$DOCBOOKSTYLE"; then
22613   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
22614 else
22615   for pgac_prefix in /usr /usr/local /opt; do
22616     for pgac_infix in share lib; do
22617       for pgac_postfix in \
22618         sgml/stylesheets/nwalsh-modular \
22619         sgml/stylesheets/docbook \
22620                 sgml/docbook-dsssl \
22621         sgml/docbook/dsssl/modular \
22622         sgml/docbook/stylesheet/dsssl/modular \
22623         sgml/docbook/dsssl-stylesheets
22624       do
22625         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
22626         if test -r "$pgac_candidate/html/docbook.dsl" \
22627            && test -r "$pgac_candidate/print/docbook.dsl"
22628         then
22629           pgac_cv_path_stylesheets=$pgac_candidate
22630           break 3
22631         fi
22632       done
22633     done
22634   done
22635 fi
22636 fi
22637
22638 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
22639
22640 if test -n "$DOCBOOKSTYLE"; then
22641   echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
22642 echo "${ECHO_T}$DOCBOOKSTYLE" >&6
22643 else
22644   echo "$as_me:$LINENO: result: no" >&5
22645 echo "${ECHO_T}no" >&6
22646 fi
22647 if test -n "$DOCBOOKSTYLE"; then
22648   for ac_prog in collateindex.pl
22649 do
22650   # Extract the first word of "$ac_prog", so it can be a program name with args.
22651 set dummy $ac_prog; ac_word=$2
22652 echo "$as_me:$LINENO: checking for $ac_word" >&5
22653 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22654 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
22655   echo $ECHO_N "(cached) $ECHO_C" >&6
22656 else
22657   case $COLLATEINDEX in
22658   [\\/]* | ?:[\\/]*)
22659   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
22660   ;;
22661   *)
22662   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22663 for as_dir in $DOCBOOKSTYLE/bin $PATH
22664 do
22665   IFS=$as_save_IFS
22666   test -z "$as_dir" && as_dir=.
22667   for ac_exec_ext in '' $ac_executable_extensions; do
22668   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22669     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
22670     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22671     break 2
22672   fi
22673 done
22674 done
22675
22676   ;;
22677 esac
22678 fi
22679 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
22680
22681 if test -n "$COLLATEINDEX"; then
22682   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
22683 echo "${ECHO_T}$COLLATEINDEX" >&6
22684 else
22685   echo "$as_me:$LINENO: result: no" >&5
22686 echo "${ECHO_T}no" >&6
22687 fi
22688
22689   test -n "$COLLATEINDEX" && break
22690 done
22691
22692 else
22693   for ac_prog in collateindex.pl
22694 do
22695   # Extract the first word of "$ac_prog", so it can be a program name with args.
22696 set dummy $ac_prog; ac_word=$2
22697 echo "$as_me:$LINENO: checking for $ac_word" >&5
22698 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22699 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
22700   echo $ECHO_N "(cached) $ECHO_C" >&6
22701 else
22702   case $COLLATEINDEX in
22703   [\\/]* | ?:[\\/]*)
22704   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
22705   ;;
22706   *)
22707   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22708 for as_dir in $PATH
22709 do
22710   IFS=$as_save_IFS
22711   test -z "$as_dir" && as_dir=.
22712   for ac_exec_ext in '' $ac_executable_extensions; do
22713   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22714     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
22715     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22716     break 2
22717   fi
22718 done
22719 done
22720
22721   ;;
22722 esac
22723 fi
22724 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
22725
22726 if test -n "$COLLATEINDEX"; then
22727   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
22728 echo "${ECHO_T}$COLLATEINDEX" >&6
22729 else
22730   echo "$as_me:$LINENO: result: no" >&5
22731 echo "${ECHO_T}no" >&6
22732 fi
22733
22734   test -n "$COLLATEINDEX" && break
22735 done
22736
22737 fi
22738 for ac_prog in sgmlspl
22739 do
22740   # Extract the first word of "$ac_prog", so it can be a program name with args.
22741 set dummy $ac_prog; ac_word=$2
22742 echo "$as_me:$LINENO: checking for $ac_word" >&5
22743 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
22744 if test "${ac_cv_prog_SGMLSPL+set}" = set; then
22745   echo $ECHO_N "(cached) $ECHO_C" >&6
22746 else
22747   if test -n "$SGMLSPL"; then
22748   ac_cv_prog_SGMLSPL="$SGMLSPL" # Let the user override the test.
22749 else
22750 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22751 for as_dir in $PATH
22752 do
22753   IFS=$as_save_IFS
22754   test -z "$as_dir" && as_dir=.
22755   for ac_exec_ext in '' $ac_executable_extensions; do
22756   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
22757     ac_cv_prog_SGMLSPL="$ac_prog"
22758     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22759     break 2
22760   fi
22761 done
22762 done
22763
22764 fi
22765 fi
22766 SGMLSPL=$ac_cv_prog_SGMLSPL
22767 if test -n "$SGMLSPL"; then
22768   echo "$as_me:$LINENO: result: $SGMLSPL" >&5
22769 echo "${ECHO_T}$SGMLSPL" >&6
22770 else
22771   echo "$as_me:$LINENO: result: no" >&5
22772 echo "${ECHO_T}no" >&6
22773 fi
22774
22775   test -n "$SGMLSPL" && break
22776 done
22777
22778
22779 # Thread testing
22780
22781 # We have to run the thread test near the end so we have all our symbols
22782 # defined.  Cross compiling throws a warning.
22783 #
22784 if test "$enable_thread_safety_force" = yes; then
22785 if test x"$template" != x"win32"
22786 then
22787   { echo "$as_me:$LINENO: WARNING:
22788 *** Skipping thread test program.  --enable-thread-safety-force was used.
22789 *** Run the program in src/test/thread on the your machine and add proper
22790 *** locking function calls to your applications to guarantee thread safety.
22791 " >&5
22792 echo "$as_me: WARNING:
22793 *** Skipping thread test program.  --enable-thread-safety-force was used.
22794 *** Run the program in src/test/thread on the your machine and add proper
22795 *** locking function calls to your applications to guarantee thread safety.
22796 " >&2;}
22797 else
22798 { echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
22799 echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
22800 fi
22801 elif test "$enable_thread_safety" = yes; then
22802 if test x"$template" != x"win32"
22803 then
22804 echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
22805 echo $ECHO_N "checking thread safety of required library functions... $ECHO_C" >&6
22806
22807 _CFLAGS="$CFLAGS"
22808 _LIBS="$LIBS"
22809 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
22810 LIBS="$LIBS $PTHREAD_LIBS"
22811 if test "$cross_compiling" = yes; then
22812   echo "$as_me:$LINENO: result: maybe" >&5
22813 echo "${ECHO_T}maybe" >&6
22814   { echo "$as_me:$LINENO: WARNING:
22815 *** Skipping thread test program because of cross-compile build.
22816 *** Run the program in src/test/thread on the target machine.
22817 " >&5
22818 echo "$as_me: WARNING:
22819 *** Skipping thread test program because of cross-compile build.
22820 *** Run the program in src/test/thread on the target machine.
22821 " >&2;}
22822 else
22823   cat >conftest.$ac_ext <<_ACEOF
22824 /* confdefs.h.  */
22825 _ACEOF
22826 cat confdefs.h >>conftest.$ac_ext
22827 cat >>conftest.$ac_ext <<_ACEOF
22828 /* end confdefs.h.  */
22829 #include "$srcdir/src/test/thread/thread_test.c"
22830 _ACEOF
22831 rm -f conftest$ac_exeext
22832 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
22833   (eval $ac_link) 2>&5
22834   ac_status=$?
22835   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22836   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
22838   (eval $ac_try) 2>&5
22839   ac_status=$?
22840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
22841   (exit $ac_status); }; }; then
22842   echo "$as_me:$LINENO: result: yes" >&5
22843 echo "${ECHO_T}yes" >&6
22844 else
22845   echo "$as_me: program exited with status $ac_status" >&5
22846 echo "$as_me: failed program was:" >&5
22847 sed 's/^/| /' conftest.$ac_ext >&5
22848
22849 ( exit $ac_status )
22850 echo "$as_me:$LINENO: result: no" >&5
22851 echo "${ECHO_T}no" >&6
22852   { { echo "$as_me:$LINENO: error: thread test program failed
22853 This platform is not thread-safe.  Check the file 'config.log'for the
22854 exact reason.
22855
22856 You can use the configure option --enable-thread-safety-force to force
22857 threads to be enabled.  But you must then run the program in
22858 src/test/thread and add locking function calls to your applications to
22859 guarantee thread safety." >&5
22860 echo "$as_me: error: thread test program failed
22861 This platform is not thread-safe.  Check the file 'config.log'for the
22862 exact reason.
22863
22864 You can use the configure option --enable-thread-safety-force to force
22865 threads to be enabled.  But you must then run the program in
22866 src/test/thread and add locking function calls to your applications to
22867 guarantee thread safety." >&2;}
22868    { (exit 1); exit 1; }; }
22869 fi
22870 rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22871 fi
22872 CFLAGS="$_CFLAGS"
22873 LIBS="$_LIBS"
22874 else
22875 { echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
22876 echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
22877 fi
22878 fi
22879
22880 # prepare build tree if outside source tree
22881 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
22882 # Note 2: /bin/pwd might be better than shell's built-in at getting
22883 #         a symlink-free name.
22884 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
22885   vpath_build=no
22886 else
22887   vpath_build=yes
22888   if test "$no_create" != yes; then
22889     echo $ECHO_N "preparing build tree... $ECHO_C" >&6
22890     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
22891     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
22892       || { { echo "$as_me:$LINENO: error: failed" >&5
22893 echo "$as_me: error: failed" >&2;}
22894    { (exit 1); exit 1; }; }
22895     echo "$as_me:$LINENO: result: done" >&5
22896 echo "${ECHO_T}done" >&6
22897   fi
22898 fi
22899
22900
22901
22902                     ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
22903
22904
22905                                                             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}"
22906
22907
22908 if test "$PORTNAME" = "win32"; then
22909           ac_config_commands="$ac_config_commands check_win32_symlinks"
22910
22911 fi
22912
22913           ac_config_headers="$ac_config_headers src/include/pg_config.h"
22914
22915
22916           ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
22917
22918
22919 cat >confcache <<\_ACEOF
22920 # This file is a shell script that caches the results of configure
22921 # tests run on this system so they can be shared between configure
22922 # scripts and configure runs, see configure's option --config-cache.
22923 # It is not useful on other systems.  If it contains results you don't
22924 # want to keep, you may remove or edit it.
22925 #
22926 # config.status only pays attention to the cache file if you give it
22927 # the --recheck option to rerun configure.
22928 #
22929 # `ac_cv_env_foo' variables (set or unset) will be overridden when
22930 # loading this file, other *unset* `ac_cv_foo' will be assigned the
22931 # following values.
22932
22933 _ACEOF
22934
22935 # The following way of writing the cache mishandles newlines in values,
22936 # but we know of no workaround that is simple, portable, and efficient.
22937 # So, don't put newlines in cache variables' values.
22938 # Ultrix sh set writes to stderr and can't be redirected directly,
22939 # and sets the high bit in the cache file unless we assign to the vars.
22940 {
22941   (set) 2>&1 |
22942     case `(ac_space=' '; set | grep ac_space) 2>&1` in
22943     *ac_space=\ *)
22944       # `set' does not quote correctly, so add quotes (double-quote
22945       # substitution turns \\\\ into \\, and sed turns \\ into \).
22946       sed -n \
22947         "s/'/'\\\\''/g;
22948           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22949       ;;
22950     *)
22951       # `set' quotes correctly as required by POSIX, so do not add quotes.
22952       sed -n \
22953         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
22954       ;;
22955     esac;
22956 } |
22957   sed '
22958      t clear
22959      : clear
22960      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22961      t end
22962      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22963      : end' >>confcache
22964 if diff $cache_file confcache >/dev/null 2>&1; then :; else
22965   if test -w $cache_file; then
22966     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
22967     cat confcache >$cache_file
22968   else
22969     echo "not updating unwritable cache $cache_file"
22970   fi
22971 fi
22972 rm -f confcache
22973
22974 test "x$prefix" = xNONE && prefix=$ac_default_prefix
22975 # Let make expand exec_prefix.
22976 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22977
22978 # VPATH may cause trouble with some makes, so we remove $(srcdir),
22979 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
22980 # trailing colons and then remove the whole line if VPATH becomes empty
22981 # (actually we leave an empty line to preserve line numbers).
22982 if test "x$srcdir" = x.; then
22983   ac_vpsub='/^[  ]*VPATH[        ]*=/{
22984 s/:*\$(srcdir):*/:/;
22985 s/:*\${srcdir}:*/:/;
22986 s/:*@srcdir@:*/:/;
22987 s/^\([^=]*=[     ]*\):*/\1/;
22988 s/:*$//;
22989 s/^[^=]*=[       ]*$//;
22990 }'
22991 fi
22992
22993 DEFS=-DHAVE_CONFIG_H
22994
22995 ac_libobjs=
22996 ac_ltlibobjs=
22997 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
22998   # 1. Remove the extension, and $U if already installed.
22999   ac_i=`echo "$ac_i" |
23000          sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
23001   # 2. Add them.
23002   ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
23003   ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
23004 done
23005 LIBOBJS=$ac_libobjs
23006
23007 LTLIBOBJS=$ac_ltlibobjs
23008
23009
23010
23011 : ${CONFIG_STATUS=./config.status}
23012 ac_clean_files_save=$ac_clean_files
23013 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
23014 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
23015 echo "$as_me: creating $CONFIG_STATUS" >&6;}
23016 cat >$CONFIG_STATUS <<_ACEOF
23017 #! $SHELL
23018 # Generated by $as_me.
23019 # Run this file to recreate the current configuration.
23020 # Compiler output produced by configure, useful for debugging
23021 # configure, is in config.log if it exists.
23022
23023 debug=false
23024 ac_cs_recheck=false
23025 ac_cs_silent=false
23026 SHELL=\${CONFIG_SHELL-$SHELL}
23027 _ACEOF
23028
23029 cat >>$CONFIG_STATUS <<\_ACEOF
23030 ## --------------------- ##
23031 ## M4sh Initialization.  ##
23032 ## --------------------- ##
23033
23034 # Be Bourne compatible
23035 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
23036   emulate sh
23037   NULLCMD=:
23038   # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
23039   # is contrary to our usage.  Disable this feature.
23040   alias -g '${1+"$@"}'='"$@"'
23041 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
23042   set -o posix
23043 fi
23044 DUALCASE=1; export DUALCASE # for MKS sh
23045
23046 # Support unset when possible.
23047 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
23048   as_unset=unset
23049 else
23050   as_unset=false
23051 fi
23052
23053
23054 # Work around bugs in pre-3.0 UWIN ksh.
23055 $as_unset ENV MAIL MAILPATH
23056 PS1='$ '
23057 PS2='> '
23058 PS4='+ '
23059
23060 # NLS nuisances.
23061 for as_var in \
23062   LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
23063   LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
23064   LC_TELEPHONE LC_TIME
23065 do
23066   if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
23067     eval $as_var=C; export $as_var
23068   else
23069     $as_unset $as_var
23070   fi
23071 done
23072
23073 # Required to use basename.
23074 if expr a : '\(a\)' >/dev/null 2>&1; then
23075   as_expr=expr
23076 else
23077   as_expr=false
23078 fi
23079
23080 if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
23081   as_basename=basename
23082 else
23083   as_basename=false
23084 fi
23085
23086
23087 # Name of the executable.
23088 as_me=`$as_basename "$0" ||
23089 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
23090          X"$0" : 'X\(//\)$' \| \
23091          X"$0" : 'X\(/\)$' \| \
23092          .     : '\(.\)' 2>/dev/null ||
23093 echo X/"$0" |
23094     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
23095           /^X\/\(\/\/\)$/{ s//\1/; q; }
23096           /^X\/\(\/\).*/{ s//\1/; q; }
23097           s/.*/./; q'`
23098
23099
23100 # PATH needs CR, and LINENO needs CR and PATH.
23101 # Avoid depending upon Character Ranges.
23102 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
23103 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
23104 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
23105 as_cr_digits='0123456789'
23106 as_cr_alnum=$as_cr_Letters$as_cr_digits
23107
23108 # The user is always right.
23109 if test "${PATH_SEPARATOR+set}" != set; then
23110   echo "#! /bin/sh" >conf$$.sh
23111   echo  "exit 0"   >>conf$$.sh
23112   chmod +x conf$$.sh
23113   if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
23114     PATH_SEPARATOR=';'
23115   else
23116     PATH_SEPARATOR=:
23117   fi
23118   rm -f conf$$.sh
23119 fi
23120
23121
23122   as_lineno_1=$LINENO
23123   as_lineno_2=$LINENO
23124   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
23125   test "x$as_lineno_1" != "x$as_lineno_2" &&
23126   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
23127   # Find who we are.  Look in the path if we contain no path at all
23128   # relative or not.
23129   case $0 in
23130     *[\\/]* ) as_myself=$0 ;;
23131     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23132 for as_dir in $PATH
23133 do
23134   IFS=$as_save_IFS
23135   test -z "$as_dir" && as_dir=.
23136   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
23137 done
23138
23139        ;;
23140   esac
23141   # We did not find ourselves, most probably we were run as `sh COMMAND'
23142   # in which case we are not to be found in the path.
23143   if test "x$as_myself" = x; then
23144     as_myself=$0
23145   fi
23146   if test ! -f "$as_myself"; then
23147     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
23148 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
23149    { (exit 1); exit 1; }; }
23150   fi
23151   case $CONFIG_SHELL in
23152   '')
23153     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23154 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
23155 do
23156   IFS=$as_save_IFS
23157   test -z "$as_dir" && as_dir=.
23158   for as_base in sh bash ksh sh5; do
23159          case $as_dir in
23160          /*)
23161            if ("$as_dir/$as_base" -c '
23162   as_lineno_1=$LINENO
23163   as_lineno_2=$LINENO
23164   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
23165   test "x$as_lineno_1" != "x$as_lineno_2" &&
23166   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
23167              $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
23168              $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
23169              CONFIG_SHELL=$as_dir/$as_base
23170              export CONFIG_SHELL
23171              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
23172            fi;;
23173          esac
23174        done
23175 done
23176 ;;
23177   esac
23178
23179   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
23180   # uniformly replaced by the line number.  The first 'sed' inserts a
23181   # line-number line before each line; the second 'sed' does the real
23182   # work.  The second script uses 'N' to pair each line-number line
23183   # with the numbered line, and appends trailing '-' during
23184   # substitution so that $LINENO is not a special case at line end.
23185   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
23186   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
23187   sed '=' <$as_myself |
23188     sed '
23189       N
23190       s,$,-,
23191       : loop
23192       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
23193       t loop
23194       s,-$,,
23195       s,^['$as_cr_digits']*\n,,
23196     ' >$as_me.lineno &&
23197   chmod +x $as_me.lineno ||
23198     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
23199 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
23200    { (exit 1); exit 1; }; }
23201
23202   # Don't try to exec as it changes $[0], causing all sort of problems
23203   # (the dirname of $[0] is not the place where we might find the
23204   # original and so on.  Autoconf is especially sensible to this).
23205   . ./$as_me.lineno
23206   # Exit status is that of the last command.
23207   exit
23208 }
23209
23210
23211 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
23212   *c*,-n*) ECHO_N= ECHO_C='
23213 ' ECHO_T='      ' ;;
23214   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
23215   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
23216 esac
23217
23218 if expr a : '\(a\)' >/dev/null 2>&1; then
23219   as_expr=expr
23220 else
23221   as_expr=false
23222 fi
23223
23224 rm -f conf$$ conf$$.exe conf$$.file
23225 echo >conf$$.file
23226 if ln -s conf$$.file conf$$ 2>/dev/null; then
23227   # We could just check for DJGPP; but this test a) works b) is more generic
23228   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
23229   if test -f conf$$.exe; then
23230     # Don't use ln at all; we don't have any links
23231     as_ln_s='cp -p'
23232   else
23233     as_ln_s='ln -s'
23234   fi
23235 elif ln conf$$.file conf$$ 2>/dev/null; then
23236   as_ln_s=ln
23237 else
23238   as_ln_s='cp -p'
23239 fi
23240 rm -f conf$$ conf$$.exe conf$$.file
23241
23242 if mkdir -p . 2>/dev/null; then
23243   as_mkdir_p=:
23244 else
23245   test -d ./-p && rmdir ./-p
23246   as_mkdir_p=false
23247 fi
23248
23249 as_executable_p="test -f"
23250
23251 # Sed expression to map a string onto a valid CPP name.
23252 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
23253
23254 # Sed expression to map a string onto a valid variable name.
23255 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
23256
23257
23258 # IFS
23259 # We need space, tab and new line, in precisely that order.
23260 as_nl='
23261 '
23262 IFS="   $as_nl"
23263
23264 # CDPATH.
23265 $as_unset CDPATH
23266
23267 exec 6>&1
23268
23269 # Open the log real soon, to keep \$[0] and so on meaningful, and to
23270 # report actual input values of CONFIG_FILES etc. instead of their
23271 # values after options handling.  Logging --version etc. is OK.
23272 exec 5>>config.log
23273 {
23274   echo
23275   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
23276 ## Running $as_me. ##
23277 _ASBOX
23278 } >&5
23279 cat >&5 <<_CSEOF
23280
23281 This file was extended by PostgreSQL $as_me 8.3devel, which was
23282 generated by GNU Autoconf 2.59.  Invocation command line was
23283
23284   CONFIG_FILES    = $CONFIG_FILES
23285   CONFIG_HEADERS  = $CONFIG_HEADERS
23286   CONFIG_LINKS    = $CONFIG_LINKS
23287   CONFIG_COMMANDS = $CONFIG_COMMANDS
23288   $ $0 $@
23289
23290 _CSEOF
23291 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
23292 echo >&5
23293 _ACEOF
23294
23295 # Files that config.status was made for.
23296 if test -n "$ac_config_files"; then
23297   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
23298 fi
23299
23300 if test -n "$ac_config_headers"; then
23301   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
23302 fi
23303
23304 if test -n "$ac_config_links"; then
23305   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
23306 fi
23307
23308 if test -n "$ac_config_commands"; then
23309   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
23310 fi
23311
23312 cat >>$CONFIG_STATUS <<\_ACEOF
23313
23314 ac_cs_usage="\
23315 \`$as_me' instantiates files from templates according to the
23316 current configuration.
23317
23318 Usage: $0 [OPTIONS] [FILE]...
23319
23320   -h, --help       print this help, then exit
23321   -V, --version    print version number, then exit
23322   -q, --quiet      do not print progress messages
23323   -d, --debug      don't remove temporary files
23324       --recheck    update $as_me by reconfiguring in the same conditions
23325   --file=FILE[:TEMPLATE]
23326                    instantiate the configuration file FILE
23327   --header=FILE[:TEMPLATE]
23328                    instantiate the configuration header FILE
23329
23330 Configuration files:
23331 $config_files
23332
23333 Configuration headers:
23334 $config_headers
23335
23336 Configuration links:
23337 $config_links
23338
23339 Configuration commands:
23340 $config_commands
23341
23342 Report bugs to <bug-autoconf@gnu.org>."
23343 _ACEOF
23344
23345 cat >>$CONFIG_STATUS <<_ACEOF
23346 ac_cs_version="\\
23347 PostgreSQL config.status 8.3devel
23348 configured by $0, generated by GNU Autoconf 2.59,
23349   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
23350
23351 Copyright (C) 2003 Free Software Foundation, Inc.
23352 This config.status script is free software; the Free Software Foundation
23353 gives unlimited permission to copy, distribute and modify it."
23354 srcdir=$srcdir
23355 _ACEOF
23356
23357 cat >>$CONFIG_STATUS <<\_ACEOF
23358 # If no file are specified by the user, then we need to provide default
23359 # value.  By we need to know if files were specified by the user.
23360 ac_need_defaults=:
23361 while test $# != 0
23362 do
23363   case $1 in
23364   --*=*)
23365     ac_option=`expr "x$1" : 'x\([^=]*\)='`
23366     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
23367     ac_shift=:
23368     ;;
23369   -*)
23370     ac_option=$1
23371     ac_optarg=$2
23372     ac_shift=shift
23373     ;;
23374   *) # This is not an option, so the user has probably given explicit
23375      # arguments.
23376      ac_option=$1
23377      ac_need_defaults=false;;
23378   esac
23379
23380   case $ac_option in
23381   # Handling of the options.
23382 _ACEOF
23383 cat >>$CONFIG_STATUS <<\_ACEOF
23384   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
23385     ac_cs_recheck=: ;;
23386   --version | --vers* | -V )
23387     echo "$ac_cs_version"; exit 0 ;;
23388   --he | --h)
23389     # Conflict between --help and --header
23390     { { echo "$as_me:$LINENO: error: ambiguous option: $1
23391 Try \`$0 --help' for more information." >&5
23392 echo "$as_me: error: ambiguous option: $1
23393 Try \`$0 --help' for more information." >&2;}
23394    { (exit 1); exit 1; }; };;
23395   --help | --hel | -h )
23396     echo "$ac_cs_usage"; exit 0 ;;
23397   --debug | --d* | -d )
23398     debug=: ;;
23399   --file | --fil | --fi | --f )
23400     $ac_shift
23401     CONFIG_FILES="$CONFIG_FILES $ac_optarg"
23402     ac_need_defaults=false;;
23403   --header | --heade | --head | --hea )
23404     $ac_shift
23405     CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
23406     ac_need_defaults=false;;
23407   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
23408   | -silent | --silent | --silen | --sile | --sil | --si | --s)
23409     ac_cs_silent=: ;;
23410
23411   # This is an error.
23412   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
23413 Try \`$0 --help' for more information." >&5
23414 echo "$as_me: error: unrecognized option: $1
23415 Try \`$0 --help' for more information." >&2;}
23416    { (exit 1); exit 1; }; } ;;
23417
23418   *) ac_config_targets="$ac_config_targets $1" ;;
23419
23420   esac
23421   shift
23422 done
23423
23424 ac_configure_extra_args=
23425
23426 if $ac_cs_silent; then
23427   exec 6>/dev/null
23428   ac_configure_extra_args="$ac_configure_extra_args --silent"
23429 fi
23430
23431 _ACEOF
23432 cat >>$CONFIG_STATUS <<_ACEOF
23433 if \$ac_cs_recheck; then
23434   echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
23435   exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
23436 fi
23437
23438 _ACEOF
23439
23440
23441
23442
23443
23444 cat >>$CONFIG_STATUS <<\_ACEOF
23445 for ac_config_target in $ac_config_targets
23446 do
23447   case "$ac_config_target" in
23448   # Handling of arguments.
23449   "GNUmakefile" ) CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
23450   "src/Makefile.global" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
23451   "src/backend/port/tas.s" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
23452   "src/backend/port/dynloader.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
23453   "src/backend/port/pg_sema.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
23454   "src/backend/port/pg_shmem.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
23455   "src/include/dynloader.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
23456   "src/include/pg_config_os.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
23457   "src/Makefile.port" ) CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
23458   "check_win32_symlinks" ) CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
23459   "src/include/pg_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
23460   "src/interfaces/ecpg/include/ecpg_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
23461   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
23462 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
23463    { (exit 1); exit 1; }; };;
23464   esac
23465 done
23466
23467 # If the user did not use the arguments to specify the items to instantiate,
23468 # then the envvar interface is used.  Set only those that are not.
23469 # We use the long form for the default assignment because of an extremely
23470 # bizarre bug on SunOS 4.1.3.
23471 if $ac_need_defaults; then
23472   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23473   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23474   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
23475   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
23476 fi
23477
23478 # Have a temporary directory for convenience.  Make it in the build tree
23479 # simply because there is no reason to put it here, and in addition,
23480 # creating and moving files from /tmp can sometimes cause problems.
23481 # Create a temporary directory, and hook for its removal unless debugging.
23482 $debug ||
23483 {
23484   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
23485   trap '{ (exit 1); exit 1; }' 1 2 13 15
23486 }
23487
23488 # Create a (secure) tmp directory for tmp files.
23489
23490 {
23491   tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
23492   test -n "$tmp" && test -d "$tmp"
23493 }  ||
23494 {
23495   tmp=./confstat$$-$RANDOM
23496   (umask 077 && mkdir $tmp)
23497 } ||
23498 {
23499    echo "$me: cannot create a temporary directory in ." >&2
23500    { (exit 1); exit 1; }
23501 }
23502
23503 _ACEOF
23504
23505 cat >>$CONFIG_STATUS <<_ACEOF
23506
23507 #
23508 # CONFIG_FILES section.
23509 #
23510
23511 # No need to generate the scripts if there are no CONFIG_FILES.
23512 # This happens for instance when ./config.status config.h
23513 if test -n "\$CONFIG_FILES"; then
23514   # Protect against being on the right side of a sed subst in config.status.
23515   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
23516    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
23517 s,@SHELL@,$SHELL,;t t
23518 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
23519 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
23520 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
23521 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
23522 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
23523 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
23524 s,@exec_prefix@,$exec_prefix,;t t
23525 s,@prefix@,$prefix,;t t
23526 s,@program_transform_name@,$program_transform_name,;t t
23527 s,@bindir@,$bindir,;t t
23528 s,@sbindir@,$sbindir,;t t
23529 s,@libexecdir@,$libexecdir,;t t
23530 s,@datadir@,$datadir,;t t
23531 s,@sysconfdir@,$sysconfdir,;t t
23532 s,@sharedstatedir@,$sharedstatedir,;t t
23533 s,@localstatedir@,$localstatedir,;t t
23534 s,@libdir@,$libdir,;t t
23535 s,@includedir@,$includedir,;t t
23536 s,@oldincludedir@,$oldincludedir,;t t
23537 s,@infodir@,$infodir,;t t
23538 s,@mandir@,$mandir,;t t
23539 s,@build_alias@,$build_alias,;t t
23540 s,@host_alias@,$host_alias,;t t
23541 s,@target_alias@,$target_alias,;t t
23542 s,@DEFS@,$DEFS,;t t
23543 s,@ECHO_C@,$ECHO_C,;t t
23544 s,@ECHO_N@,$ECHO_N,;t t
23545 s,@ECHO_T@,$ECHO_T,;t t
23546 s,@LIBS@,$LIBS,;t t
23547 s,@configure_args@,$configure_args,;t t
23548 s,@build@,$build,;t t
23549 s,@build_cpu@,$build_cpu,;t t
23550 s,@build_vendor@,$build_vendor,;t t
23551 s,@build_os@,$build_os,;t t
23552 s,@host@,$host,;t t
23553 s,@host_cpu@,$host_cpu,;t t
23554 s,@host_vendor@,$host_vendor,;t t
23555 s,@host_os@,$host_os,;t t
23556 s,@PORTNAME@,$PORTNAME,;t t
23557 s,@docdir@,$docdir,;t t
23558 s,@enable_nls@,$enable_nls,;t t
23559 s,@WANTED_LANGUAGES@,$WANTED_LANGUAGES,;t t
23560 s,@default_port@,$default_port,;t t
23561 s,@enable_shared@,$enable_shared,;t t
23562 s,@enable_rpath@,$enable_rpath,;t t
23563 s,@enable_debug@,$enable_debug,;t t
23564 s,@DTRACE@,$DTRACE,;t t
23565 s,@DTRACEFLAGS@,$DTRACEFLAGS,;t t
23566 s,@enable_dtrace@,$enable_dtrace,;t t
23567 s,@CC@,$CC,;t t
23568 s,@CFLAGS@,$CFLAGS,;t t
23569 s,@LDFLAGS@,$LDFLAGS,;t t
23570 s,@CPPFLAGS@,$CPPFLAGS,;t t
23571 s,@ac_ct_CC@,$ac_ct_CC,;t t
23572 s,@EXEEXT@,$EXEEXT,;t t
23573 s,@OBJEXT@,$OBJEXT,;t t
23574 s,@CPP@,$CPP,;t t
23575 s,@GCC@,$GCC,;t t
23576 s,@TAS@,$TAS,;t t
23577 s,@autodepend@,$autodepend,;t t
23578 s,@INCLUDES@,$INCLUDES,;t t
23579 s,@enable_thread_safety@,$enable_thread_safety,;t t
23580 s,@with_tcl@,$with_tcl,;t t
23581 s,@with_perl@,$with_perl,;t t
23582 s,@with_python@,$with_python,;t t
23583 s,@with_krb5@,$with_krb5,;t t
23584 s,@krb_srvtab@,$krb_srvtab,;t t
23585 s,@with_pam@,$with_pam,;t t
23586 s,@with_ldap@,$with_ldap,;t t
23587 s,@with_bonjour@,$with_bonjour,;t t
23588 s,@with_openssl@,$with_openssl,;t t
23589 s,@with_zlib@,$with_zlib,;t t
23590 s,@EGREP@,$EGREP,;t t
23591 s,@ELF_SYS@,$ELF_SYS,;t t
23592 s,@LDFLAGS_SL@,$LDFLAGS_SL,;t t
23593 s,@AWK@,$AWK,;t t
23594 s,@FLEX@,$FLEX,;t t
23595 s,@FLEXFLAGS@,$FLEXFLAGS,;t t
23596 s,@LN_S@,$LN_S,;t t
23597 s,@LD@,$LD,;t t
23598 s,@with_gnu_ld@,$with_gnu_ld,;t t
23599 s,@ld_R_works@,$ld_R_works,;t t
23600 s,@RANLIB@,$RANLIB,;t t
23601 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
23602 s,@TAR@,$TAR,;t t
23603 s,@STRIP@,$STRIP,;t t
23604 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
23605 s,@STRIP_STATIC_LIB@,$STRIP_STATIC_LIB,;t t
23606 s,@STRIP_SHARED_LIB@,$STRIP_SHARED_LIB,;t t
23607 s,@YACC@,$YACC,;t t
23608 s,@YFLAGS@,$YFLAGS,;t t
23609 s,@PERL@,$PERL,;t t
23610 s,@perl_archlibexp@,$perl_archlibexp,;t t
23611 s,@perl_privlibexp@,$perl_privlibexp,;t t
23612 s,@perl_useshrplib@,$perl_useshrplib,;t t
23613 s,@perl_embed_ldflags@,$perl_embed_ldflags,;t t
23614 s,@PYTHON@,$PYTHON,;t t
23615 s,@python_version@,$python_version,;t t
23616 s,@python_configdir@,$python_configdir,;t t
23617 s,@python_includespec@,$python_includespec,;t t
23618 s,@python_libdir@,$python_libdir,;t t
23619 s,@python_libspec@,$python_libspec,;t t
23620 s,@python_additional_libs@,$python_additional_libs,;t t
23621 s,@HAVE_IPV6@,$HAVE_IPV6,;t t
23622 s,@LIBOBJS@,$LIBOBJS,;t t
23623 s,@acx_pthread_config@,$acx_pthread_config,;t t
23624 s,@PTHREAD_CC@,$PTHREAD_CC,;t t
23625 s,@PTHREAD_LIBS@,$PTHREAD_LIBS,;t t
23626 s,@PTHREAD_CFLAGS@,$PTHREAD_CFLAGS,;t t
23627 s,@LDAP_LIBS_FE@,$LDAP_LIBS_FE,;t t
23628 s,@LDAP_LIBS_BE@,$LDAP_LIBS_BE,;t t
23629 s,@HAVE_POSIX_SIGNALS@,$HAVE_POSIX_SIGNALS,;t t
23630 s,@MSGFMT@,$MSGFMT,;t t
23631 s,@MSGMERGE@,$MSGMERGE,;t t
23632 s,@XGETTEXT@,$XGETTEXT,;t t
23633 s,@localedir@,$localedir,;t t
23634 s,@TCLSH@,$TCLSH,;t t
23635 s,@TCL_CONFIG_SH@,$TCL_CONFIG_SH,;t t
23636 s,@TCL_INCLUDE_SPEC@,$TCL_INCLUDE_SPEC,;t t
23637 s,@TCL_LIB_FILE@,$TCL_LIB_FILE,;t t
23638 s,@TCL_LIBS@,$TCL_LIBS,;t t
23639 s,@TCL_LIB_SPEC@,$TCL_LIB_SPEC,;t t
23640 s,@TCL_SHARED_BUILD@,$TCL_SHARED_BUILD,;t t
23641 s,@TCL_SHLIB_LD_LIBS@,$TCL_SHLIB_LD_LIBS,;t t
23642 s,@NSGMLS@,$NSGMLS,;t t
23643 s,@JADE@,$JADE,;t t
23644 s,@have_docbook@,$have_docbook,;t t
23645 s,@DOCBOOKSTYLE@,$DOCBOOKSTYLE,;t t
23646 s,@COLLATEINDEX@,$COLLATEINDEX,;t t
23647 s,@SGMLSPL@,$SGMLSPL,;t t
23648 s,@vpath_build@,$vpath_build,;t t
23649 s,@LTLIBOBJS@,$LTLIBOBJS,;t t
23650 CEOF
23651
23652 _ACEOF
23653
23654   cat >>$CONFIG_STATUS <<\_ACEOF
23655   # Split the substitutions into bite-sized pieces for seds with
23656   # small command number limits, like on Digital OSF/1 and HP-UX.
23657   ac_max_sed_lines=48
23658   ac_sed_frag=1 # Number of current file.
23659   ac_beg=1 # First line for current file.
23660   ac_end=$ac_max_sed_lines # Line after last line for current file.
23661   ac_more_lines=:
23662   ac_sed_cmds=
23663   while $ac_more_lines; do
23664     if test $ac_beg -gt 1; then
23665       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23666     else
23667       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
23668     fi
23669     if test ! -s $tmp/subs.frag; then
23670       ac_more_lines=false
23671     else
23672       # The purpose of the label and of the branching condition is to
23673       # speed up the sed processing (if there are no `@' at all, there
23674       # is no need to browse any of the substitutions).
23675       # These are the two extra sed commands mentioned above.
23676       (echo ':t
23677   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
23678       if test -z "$ac_sed_cmds"; then
23679         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
23680       else
23681         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
23682       fi
23683       ac_sed_frag=`expr $ac_sed_frag + 1`
23684       ac_beg=$ac_end
23685       ac_end=`expr $ac_end + $ac_max_sed_lines`
23686     fi
23687   done
23688   if test -z "$ac_sed_cmds"; then
23689     ac_sed_cmds=cat
23690   fi
23691 fi # test -n "$CONFIG_FILES"
23692
23693 _ACEOF
23694 cat >>$CONFIG_STATUS <<\_ACEOF
23695 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
23696   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23697   case $ac_file in
23698   - | *:- | *:-:* ) # input from stdin
23699         cat >$tmp/stdin
23700         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23701         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23702   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23703         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23704   * )   ac_file_in=$ac_file.in ;;
23705   esac
23706
23707   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
23708   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
23709 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23710          X"$ac_file" : 'X\(//\)[^/]' \| \
23711          X"$ac_file" : 'X\(//\)$' \| \
23712          X"$ac_file" : 'X\(/\)' \| \
23713          .     : '\(.\)' 2>/dev/null ||
23714 echo X"$ac_file" |
23715     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23716           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23717           /^X\(\/\/\)$/{ s//\1/; q; }
23718           /^X\(\/\).*/{ s//\1/; q; }
23719           s/.*/./; q'`
23720   { if $as_mkdir_p; then
23721     mkdir -p "$ac_dir"
23722   else
23723     as_dir="$ac_dir"
23724     as_dirs=
23725     while test ! -d "$as_dir"; do
23726       as_dirs="$as_dir $as_dirs"
23727       as_dir=`(dirname "$as_dir") 2>/dev/null ||
23728 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23729          X"$as_dir" : 'X\(//\)[^/]' \| \
23730          X"$as_dir" : 'X\(//\)$' \| \
23731          X"$as_dir" : 'X\(/\)' \| \
23732          .     : '\(.\)' 2>/dev/null ||
23733 echo X"$as_dir" |
23734     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
23735           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
23736           /^X\(\/\/\)$/{ s//\1/; q; }
23737           /^X\(\/\).*/{ s//\1/; q; }
23738           s/.*/./; q'`
23739     done
23740     test ! -n "$as_dirs" || mkdir $as_dirs
23741   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
23742 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
23743    { (exit 1); exit 1; }; }; }
23744
23745   ac_builddir=.
23746
23747 if test "$ac_dir" != .; then
23748   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
23749   # A "../" for each directory in $ac_dir_suffix.
23750   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
23751 else
23752   ac_dir_suffix= ac_top_builddir=
23753 fi
23754
23755 case $srcdir in
23756   .)  # No --srcdir option.  We are building in place.
23757     ac_srcdir=.
23758     if test -z "$ac_top_builddir"; then
23759        ac_top_srcdir=.
23760     else
23761        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
23762     fi ;;
23763   [\\/]* | ?:[\\/]* )  # Absolute path.
23764     ac_srcdir=$srcdir$ac_dir_suffix;
23765     ac_top_srcdir=$srcdir ;;
23766   *) # Relative path.
23767     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
23768     ac_top_srcdir=$ac_top_builddir$srcdir ;;
23769 esac
23770
23771 # Do not use `cd foo && pwd` to compute absolute paths, because
23772 # the directories may not exist.
23773 case `pwd` in
23774 .) ac_abs_builddir="$ac_dir";;
23775 *)
23776   case "$ac_dir" in
23777   .) ac_abs_builddir=`pwd`;;
23778   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
23779   *) ac_abs_builddir=`pwd`/"$ac_dir";;
23780   esac;;
23781 esac
23782 case $ac_abs_builddir in
23783 .) ac_abs_top_builddir=${ac_top_builddir}.;;
23784 *)
23785   case ${ac_top_builddir}. in
23786   .) ac_abs_top_builddir=$ac_abs_builddir;;
23787   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
23788   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
23789   esac;;
23790 esac
23791 case $ac_abs_builddir in
23792 .) ac_abs_srcdir=$ac_srcdir;;
23793 *)
23794   case $ac_srcdir in
23795   .) ac_abs_srcdir=$ac_abs_builddir;;
23796   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
23797   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
23798   esac;;
23799 esac
23800 case $ac_abs_builddir in
23801 .) ac_abs_top_srcdir=$ac_top_srcdir;;
23802 *)
23803   case $ac_top_srcdir in
23804   .) ac_abs_top_srcdir=$ac_abs_builddir;;
23805   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
23806   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
23807   esac;;
23808 esac
23809
23810
23811
23812   if test x"$ac_file" != x-; then
23813     { echo "$as_me:$LINENO: creating $ac_file" >&5
23814 echo "$as_me: creating $ac_file" >&6;}
23815     rm -f "$ac_file"
23816   fi
23817   # Let's still pretend it is `configure' which instantiates (i.e., don't
23818   # use $as_me), people would be surprised to read:
23819   #    /* config.h.  Generated by config.status.  */
23820   if test x"$ac_file" = x-; then
23821     configure_input=
23822   else
23823     configure_input="$ac_file.  "
23824   fi
23825   configure_input=$configure_input"Generated from `echo $ac_file_in |
23826                                      sed 's,.*/,,'` by configure."
23827
23828   # First look for the input files in the build tree, otherwise in the
23829   # src tree.
23830   ac_file_inputs=`IFS=:
23831     for f in $ac_file_in; do
23832       case $f in
23833       -) echo $tmp/stdin ;;
23834       [\\/$]*)
23835          # Absolute (can't be DOS-style, as IFS=:)
23836          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23837 echo "$as_me: error: cannot find input file: $f" >&2;}
23838    { (exit 1); exit 1; }; }
23839          echo "$f";;
23840       *) # Relative
23841          if test -f "$f"; then
23842            # Build tree
23843            echo "$f"
23844          elif test -f "$srcdir/$f"; then
23845            # Source tree
23846            echo "$srcdir/$f"
23847          else
23848            # /dev/null tree
23849            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23850 echo "$as_me: error: cannot find input file: $f" >&2;}
23851    { (exit 1); exit 1; }; }
23852          fi;;
23853       esac
23854     done` || { (exit 1); exit 1; }
23855 _ACEOF
23856 cat >>$CONFIG_STATUS <<_ACEOF
23857   sed "$ac_vpsub
23858 $extrasub
23859 _ACEOF
23860 cat >>$CONFIG_STATUS <<\_ACEOF
23861 :t
23862 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23863 s,@configure_input@,$configure_input,;t t
23864 s,@srcdir@,$ac_srcdir,;t t
23865 s,@abs_srcdir@,$ac_abs_srcdir,;t t
23866 s,@top_srcdir@,$ac_top_srcdir,;t t
23867 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
23868 s,@builddir@,$ac_builddir,;t t
23869 s,@abs_builddir@,$ac_abs_builddir,;t t
23870 s,@top_builddir@,$ac_top_builddir,;t t
23871 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
23872 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
23873   rm -f $tmp/stdin
23874   if test x"$ac_file" != x-; then
23875     mv $tmp/out $ac_file
23876   else
23877     cat $tmp/out
23878     rm -f $tmp/out
23879   fi
23880
23881 done
23882 _ACEOF
23883 cat >>$CONFIG_STATUS <<\_ACEOF
23884
23885 #
23886 # CONFIG_HEADER section.
23887 #
23888
23889 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
23890 # NAME is the cpp macro being defined and VALUE is the value it is being given.
23891 #
23892 # ac_d sets the value in "#define NAME VALUE" lines.
23893 ac_dA='s,^\([    ]*\)#\([        ]*define[       ][      ]*\)'
23894 ac_dB='[         ].*$,\1#\2'
23895 ac_dC=' '
23896 ac_dD=',;t'
23897 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
23898 ac_uA='s,^\([    ]*\)#\([        ]*\)undef\([    ][      ]*\)'
23899 ac_uB='$,\1#\2define\3'
23900 ac_uC=' '
23901 ac_uD=',;t'
23902
23903 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
23904   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
23905   case $ac_file in
23906   - | *:- | *:-:* ) # input from stdin
23907         cat >$tmp/stdin
23908         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23909         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23910   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
23911         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
23912   * )   ac_file_in=$ac_file.in ;;
23913   esac
23914
23915   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
23916 echo "$as_me: creating $ac_file" >&6;}
23917
23918   # First look for the input files in the build tree, otherwise in the
23919   # src tree.
23920   ac_file_inputs=`IFS=:
23921     for f in $ac_file_in; do
23922       case $f in
23923       -) echo $tmp/stdin ;;
23924       [\\/$]*)
23925          # Absolute (can't be DOS-style, as IFS=:)
23926          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23927 echo "$as_me: error: cannot find input file: $f" >&2;}
23928    { (exit 1); exit 1; }; }
23929          # Do quote $f, to prevent DOS paths from being IFS'd.
23930          echo "$f";;
23931       *) # Relative
23932          if test -f "$f"; then
23933            # Build tree
23934            echo "$f"
23935          elif test -f "$srcdir/$f"; then
23936            # Source tree
23937            echo "$srcdir/$f"
23938          else
23939            # /dev/null tree
23940            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
23941 echo "$as_me: error: cannot find input file: $f" >&2;}
23942    { (exit 1); exit 1; }; }
23943          fi;;
23944       esac
23945     done` || { (exit 1); exit 1; }
23946   # Remove the trailing spaces.
23947   sed 's/[       ]*$//' $ac_file_inputs >$tmp/in
23948
23949 _ACEOF
23950
23951 # Transform confdefs.h into two sed scripts, `conftest.defines' and
23952 # `conftest.undefs', that substitutes the proper values into
23953 # config.h.in to produce config.h.  The first handles `#define'
23954 # templates, and the second `#undef' templates.
23955 # And first: Protect against being on the right side of a sed subst in
23956 # config.status.  Protect against being in an unquoted here document
23957 # in config.status.
23958 rm -f conftest.defines conftest.undefs
23959 # Using a here document instead of a string reduces the quoting nightmare.
23960 # Putting comments in sed scripts is not portable.
23961 #
23962 # `end' is used to avoid that the second main sed command (meant for
23963 # 0-ary CPP macros) applies to n-ary macro definitions.
23964 # See the Autoconf documentation for `clear'.
23965 cat >confdef2sed.sed <<\_ACEOF
23966 s/[\\&,]/\\&/g
23967 s,[\\$`],\\&,g
23968 t clear
23969 : clear
23970 s,^[     ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
23971 t end
23972 s,^[     ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
23973 : end
23974 _ACEOF
23975 # If some macros were called several times there might be several times
23976 # the same #defines, which is useless.  Nevertheless, we may not want to
23977 # sort them, since we want the *last* AC-DEFINE to be honored.
23978 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
23979 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
23980 rm -f confdef2sed.sed
23981
23982 # This sed command replaces #undef with comments.  This is necessary, for
23983 # example, in the case of _POSIX_SOURCE, which is predefined and required
23984 # on some systems where configure will not decide to define it.
23985 cat >>conftest.undefs <<\_ACEOF
23986 s,^[     ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
23987 _ACEOF
23988
23989 # Break up conftest.defines because some shells have a limit on the size
23990 # of here documents, and old seds have small limits too (100 cmds).
23991 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
23992 echo '  if grep "^[      ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
23993 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
23994 echo '  :' >>$CONFIG_STATUS
23995 rm -f conftest.tail
23996 while grep . conftest.defines >/dev/null
23997 do
23998   # Write a limited-size here document to $tmp/defines.sed.
23999   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
24000   # Speed up: don't consider the non `#define' lines.
24001   echo '/^[      ]*#[    ]*define/!b' >>$CONFIG_STATUS
24002   # Work around the forget-to-reset-the-flag bug.
24003   echo 't clr' >>$CONFIG_STATUS
24004   echo ': clr' >>$CONFIG_STATUS
24005   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
24006   echo 'CEOF
24007   sed -f $tmp/defines.sed $tmp/in >$tmp/out
24008   rm -f $tmp/in
24009   mv $tmp/out $tmp/in
24010 ' >>$CONFIG_STATUS
24011   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
24012   rm -f conftest.defines
24013   mv conftest.tail conftest.defines
24014 done
24015 rm -f conftest.defines
24016 echo '  fi # grep' >>$CONFIG_STATUS
24017 echo >>$CONFIG_STATUS
24018
24019 # Break up conftest.undefs because some shells have a limit on the size
24020 # of here documents, and old seds have small limits too (100 cmds).
24021 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
24022 rm -f conftest.tail
24023 while grep . conftest.undefs >/dev/null
24024 do
24025   # Write a limited-size here document to $tmp/undefs.sed.
24026   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
24027   # Speed up: don't consider the non `#undef'
24028   echo '/^[      ]*#[    ]*undef/!b' >>$CONFIG_STATUS
24029   # Work around the forget-to-reset-the-flag bug.
24030   echo 't clr' >>$CONFIG_STATUS
24031   echo ': clr' >>$CONFIG_STATUS
24032   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
24033   echo 'CEOF
24034   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
24035   rm -f $tmp/in
24036   mv $tmp/out $tmp/in
24037 ' >>$CONFIG_STATUS
24038   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
24039   rm -f conftest.undefs
24040   mv conftest.tail conftest.undefs
24041 done
24042 rm -f conftest.undefs
24043
24044 cat >>$CONFIG_STATUS <<\_ACEOF
24045   # Let's still pretend it is `configure' which instantiates (i.e., don't
24046   # use $as_me), people would be surprised to read:
24047   #    /* config.h.  Generated by config.status.  */
24048   if test x"$ac_file" = x-; then
24049     echo "/* Generated by configure.  */" >$tmp/config.h
24050   else
24051     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
24052   fi
24053   cat $tmp/in >>$tmp/config.h
24054   rm -f $tmp/in
24055   if test x"$ac_file" != x-; then
24056     if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
24057       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
24058 echo "$as_me: $ac_file is unchanged" >&6;}
24059     else
24060       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
24061 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24062          X"$ac_file" : 'X\(//\)[^/]' \| \
24063          X"$ac_file" : 'X\(//\)$' \| \
24064          X"$ac_file" : 'X\(/\)' \| \
24065          .     : '\(.\)' 2>/dev/null ||
24066 echo X"$ac_file" |
24067     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
24068           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
24069           /^X\(\/\/\)$/{ s//\1/; q; }
24070           /^X\(\/\).*/{ s//\1/; q; }
24071           s/.*/./; q'`
24072       { if $as_mkdir_p; then
24073     mkdir -p "$ac_dir"
24074   else
24075     as_dir="$ac_dir"
24076     as_dirs=
24077     while test ! -d "$as_dir"; do
24078       as_dirs="$as_dir $as_dirs"
24079       as_dir=`(dirname "$as_dir") 2>/dev/null ||
24080 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24081          X"$as_dir" : 'X\(//\)[^/]' \| \
24082          X"$as_dir" : 'X\(//\)$' \| \
24083          X"$as_dir" : 'X\(/\)' \| \
24084          .     : '\(.\)' 2>/dev/null ||
24085 echo X"$as_dir" |
24086     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
24087           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
24088           /^X\(\/\/\)$/{ s//\1/; q; }
24089           /^X\(\/\).*/{ s//\1/; q; }
24090           s/.*/./; q'`
24091     done
24092     test ! -n "$as_dirs" || mkdir $as_dirs
24093   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
24094 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
24095    { (exit 1); exit 1; }; }; }
24096
24097       rm -f $ac_file
24098       mv $tmp/config.h $ac_file
24099     fi
24100   else
24101     cat $tmp/config.h
24102     rm -f $tmp/config.h
24103   fi
24104   # Run the commands associated with the file.
24105   case $ac_file in
24106     src/include/pg_config.h )
24107 # Update timestamp for pg_config.h (see Makefile.global)
24108 echo >src/include/stamp-h
24109  ;;
24110   esac
24111 done
24112 _ACEOF
24113 cat >>$CONFIG_STATUS <<\_ACEOF
24114
24115 #
24116 # CONFIG_LINKS section.
24117 #
24118
24119 for ac_file in : $CONFIG_LINKS; do test "x$ac_file" = x: && continue
24120   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
24121   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
24122
24123   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_dest" >&5
24124 echo "$as_me: linking $srcdir/$ac_source to $ac_dest" >&6;}
24125
24126   if test ! -r $srcdir/$ac_source; then
24127     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
24128 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
24129    { (exit 1); exit 1; }; }
24130   fi
24131   rm -f $ac_dest
24132
24133   # Make relative symlinks.
24134   ac_dest_dir=`(dirname "$ac_dest") 2>/dev/null ||
24135 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24136          X"$ac_dest" : 'X\(//\)[^/]' \| \
24137          X"$ac_dest" : 'X\(//\)$' \| \
24138          X"$ac_dest" : 'X\(/\)' \| \
24139          .     : '\(.\)' 2>/dev/null ||
24140 echo X"$ac_dest" |
24141     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
24142           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
24143           /^X\(\/\/\)$/{ s//\1/; q; }
24144           /^X\(\/\).*/{ s//\1/; q; }
24145           s/.*/./; q'`
24146   { if $as_mkdir_p; then
24147     mkdir -p "$ac_dest_dir"
24148   else
24149     as_dir="$ac_dest_dir"
24150     as_dirs=
24151     while test ! -d "$as_dir"; do
24152       as_dirs="$as_dir $as_dirs"
24153       as_dir=`(dirname "$as_dir") 2>/dev/null ||
24154 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24155          X"$as_dir" : 'X\(//\)[^/]' \| \
24156          X"$as_dir" : 'X\(//\)$' \| \
24157          X"$as_dir" : 'X\(/\)' \| \
24158          .     : '\(.\)' 2>/dev/null ||
24159 echo X"$as_dir" |
24160     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
24161           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
24162           /^X\(\/\/\)$/{ s//\1/; q; }
24163           /^X\(\/\).*/{ s//\1/; q; }
24164           s/.*/./; q'`
24165     done
24166     test ! -n "$as_dirs" || mkdir $as_dirs
24167   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dest_dir\"" >&5
24168 echo "$as_me: error: cannot create directory \"$ac_dest_dir\"" >&2;}
24169    { (exit 1); exit 1; }; }; }
24170
24171   ac_builddir=.
24172
24173 if test "$ac_dest_dir" != .; then
24174   ac_dir_suffix=/`echo "$ac_dest_dir" | sed 's,^\.[\\/],,'`
24175   # A "../" for each directory in $ac_dir_suffix.
24176   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
24177 else
24178   ac_dir_suffix= ac_top_builddir=
24179 fi
24180
24181 case $srcdir in
24182   .)  # No --srcdir option.  We are building in place.
24183     ac_srcdir=.
24184     if test -z "$ac_top_builddir"; then
24185        ac_top_srcdir=.
24186     else
24187        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
24188     fi ;;
24189   [\\/]* | ?:[\\/]* )  # Absolute path.
24190     ac_srcdir=$srcdir$ac_dir_suffix;
24191     ac_top_srcdir=$srcdir ;;
24192   *) # Relative path.
24193     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
24194     ac_top_srcdir=$ac_top_builddir$srcdir ;;
24195 esac
24196
24197 # Do not use `cd foo && pwd` to compute absolute paths, because
24198 # the directories may not exist.
24199 case `pwd` in
24200 .) ac_abs_builddir="$ac_dest_dir";;
24201 *)
24202   case "$ac_dest_dir" in
24203   .) ac_abs_builddir=`pwd`;;
24204   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dest_dir";;
24205   *) ac_abs_builddir=`pwd`/"$ac_dest_dir";;
24206   esac;;
24207 esac
24208 case $ac_abs_builddir in
24209 .) ac_abs_top_builddir=${ac_top_builddir}.;;
24210 *)
24211   case ${ac_top_builddir}. in
24212   .) ac_abs_top_builddir=$ac_abs_builddir;;
24213   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
24214   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
24215   esac;;
24216 esac
24217 case $ac_abs_builddir in
24218 .) ac_abs_srcdir=$ac_srcdir;;
24219 *)
24220   case $ac_srcdir in
24221   .) ac_abs_srcdir=$ac_abs_builddir;;
24222   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
24223   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
24224   esac;;
24225 esac
24226 case $ac_abs_builddir in
24227 .) ac_abs_top_srcdir=$ac_top_srcdir;;
24228 *)
24229   case $ac_top_srcdir in
24230   .) ac_abs_top_srcdir=$ac_abs_builddir;;
24231   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
24232   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
24233   esac;;
24234 esac
24235
24236
24237   case $srcdir in
24238   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
24239       *) ac_rel_source=$ac_top_builddir$srcdir/$ac_source ;;
24240   esac
24241
24242   # Try a symlink, then a hard link, then a copy.
24243   ln -s $ac_rel_source $ac_dest 2>/dev/null ||
24244     ln $srcdir/$ac_source $ac_dest 2>/dev/null ||
24245     cp -p $srcdir/$ac_source $ac_dest ||
24246     { { echo "$as_me:$LINENO: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&5
24247 echo "$as_me: error: cannot link or copy $srcdir/$ac_source to $ac_dest" >&2;}
24248    { (exit 1); exit 1; }; }
24249 done
24250 _ACEOF
24251 cat >>$CONFIG_STATUS <<\_ACEOF
24252
24253 #
24254 # CONFIG_COMMANDS section.
24255 #
24256 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
24257   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
24258   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
24259   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
24260 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24261          X"$ac_dest" : 'X\(//\)[^/]' \| \
24262          X"$ac_dest" : 'X\(//\)$' \| \
24263          X"$ac_dest" : 'X\(/\)' \| \
24264          .     : '\(.\)' 2>/dev/null ||
24265 echo X"$ac_dest" |
24266     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
24267           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
24268           /^X\(\/\/\)$/{ s//\1/; q; }
24269           /^X\(\/\).*/{ s//\1/; q; }
24270           s/.*/./; q'`
24271   { if $as_mkdir_p; then
24272     mkdir -p "$ac_dir"
24273   else
24274     as_dir="$ac_dir"
24275     as_dirs=
24276     while test ! -d "$as_dir"; do
24277       as_dirs="$as_dir $as_dirs"
24278       as_dir=`(dirname "$as_dir") 2>/dev/null ||
24279 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24280          X"$as_dir" : 'X\(//\)[^/]' \| \
24281          X"$as_dir" : 'X\(//\)$' \| \
24282          X"$as_dir" : 'X\(/\)' \| \
24283          .     : '\(.\)' 2>/dev/null ||
24284 echo X"$as_dir" |
24285     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
24286           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
24287           /^X\(\/\/\)$/{ s//\1/; q; }
24288           /^X\(\/\).*/{ s//\1/; q; }
24289           s/.*/./; q'`
24290     done
24291     test ! -n "$as_dirs" || mkdir $as_dirs
24292   fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
24293 echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
24294    { (exit 1); exit 1; }; }; }
24295
24296   ac_builddir=.
24297
24298 if test "$ac_dir" != .; then
24299   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
24300   # A "../" for each directory in $ac_dir_suffix.
24301   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
24302 else
24303   ac_dir_suffix= ac_top_builddir=
24304 fi
24305
24306 case $srcdir in
24307   .)  # No --srcdir option.  We are building in place.
24308     ac_srcdir=.
24309     if test -z "$ac_top_builddir"; then
24310        ac_top_srcdir=.
24311     else
24312        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
24313     fi ;;
24314   [\\/]* | ?:[\\/]* )  # Absolute path.
24315     ac_srcdir=$srcdir$ac_dir_suffix;
24316     ac_top_srcdir=$srcdir ;;
24317   *) # Relative path.
24318     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
24319     ac_top_srcdir=$ac_top_builddir$srcdir ;;
24320 esac
24321
24322 # Do not use `cd foo && pwd` to compute absolute paths, because
24323 # the directories may not exist.
24324 case `pwd` in
24325 .) ac_abs_builddir="$ac_dir";;
24326 *)
24327   case "$ac_dir" in
24328   .) ac_abs_builddir=`pwd`;;
24329   [\\/]* | ?:[\\/]* ) ac_abs_builddir="$ac_dir";;
24330   *) ac_abs_builddir=`pwd`/"$ac_dir";;
24331   esac;;
24332 esac
24333 case $ac_abs_builddir in
24334 .) ac_abs_top_builddir=${ac_top_builddir}.;;
24335 *)
24336   case ${ac_top_builddir}. in
24337   .) ac_abs_top_builddir=$ac_abs_builddir;;
24338   [\\/]* | ?:[\\/]* ) ac_abs_top_builddir=${ac_top_builddir}.;;
24339   *) ac_abs_top_builddir=$ac_abs_builddir/${ac_top_builddir}.;;
24340   esac;;
24341 esac
24342 case $ac_abs_builddir in
24343 .) ac_abs_srcdir=$ac_srcdir;;
24344 *)
24345   case $ac_srcdir in
24346   .) ac_abs_srcdir=$ac_abs_builddir;;
24347   [\\/]* | ?:[\\/]* ) ac_abs_srcdir=$ac_srcdir;;
24348   *) ac_abs_srcdir=$ac_abs_builddir/$ac_srcdir;;
24349   esac;;
24350 esac
24351 case $ac_abs_builddir in
24352 .) ac_abs_top_srcdir=$ac_top_srcdir;;
24353 *)
24354   case $ac_top_srcdir in
24355   .) ac_abs_top_srcdir=$ac_abs_builddir;;
24356   [\\/]* | ?:[\\/]* ) ac_abs_top_srcdir=$ac_top_srcdir;;
24357   *) ac_abs_top_srcdir=$ac_abs_builddir/$ac_top_srcdir;;
24358   esac;;
24359 esac
24360
24361
24362   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
24363 echo "$as_me: executing $ac_dest commands" >&6;}
24364   case $ac_dest in
24365     check_win32_symlinks )
24366 # Links sometimes fail undetected on Mingw -
24367 # so here we detect it and warn the user
24368 for FILE in $CONFIG_LINKS
24369  do
24370         # test -e works for symlinks in the MinGW console
24371         test -e `expr "$FILE" : '\([^:]*\)'` || { echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
24372 echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
24373  done
24374  ;;
24375   esac
24376 done
24377 _ACEOF
24378
24379 cat >>$CONFIG_STATUS <<\_ACEOF
24380
24381 { (exit 0); exit 0; }
24382 _ACEOF
24383 chmod +x $CONFIG_STATUS
24384 ac_clean_files=$ac_clean_files_save
24385
24386
24387 # configure is writing to config.log, and then calls config.status.
24388 # config.status does its own redirection, appending to config.log.
24389 # Unfortunately, on DOS this fails, as config.log is still kept open
24390 # by configure, so config.status won't be able to write to it; its
24391 # output is simply discarded.  So we exec the FD to /dev/null,
24392 # effectively closing config.log, so it can be properly (re)opened and
24393 # appended to by config.status.  When coming back to configure, we
24394 # need to make the FD available again.
24395 if test "$no_create" != yes; then
24396   ac_cs_success=:
24397   ac_config_status_args=
24398   test "$silent" = yes &&
24399     ac_config_status_args="$ac_config_status_args --quiet"
24400   exec 5>/dev/null
24401   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
24402   exec 5>>config.log
24403   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24404   # would make configure fail if this is the last instruction.
24405   $ac_cs_success || { (exit 1); exit 1; }
24406 fi
24407
24408
24409 # Warn about unknown options
24410 for pgac_var in `set | sed 's/=.*//' | $EGREP 'with_|enable_'`; do
24411   for pgac_arg in $pgac_args with_gnu_ld; do
24412     if test "$pgac_var" = "$pgac_arg"; then
24413       continue 2
24414     fi
24415   done
24416   pgac_txt=`echo $pgac_var | sed 's/_/-/g'`
24417   { echo "$as_me:$LINENO: WARNING: option ignored: --$pgac_txt" >&5
24418 echo "$as_me: WARNING: option ignored: --$pgac_txt" >&2;}
24419 done