]> granicus.if.org Git - postgresql/blob - configure
On Win32, libintl replaces snprintf() with its own version that
[postgresql] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.53 for PostgreSQL 8.1devel.
4 #
5 # Report bugs to <pgsql-bugs@postgresql.org>.
6 #
7 # Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
8 # Free Software Foundation, Inc.
9 # This configure script is free software; the Free Software Foundation
10 # gives unlimited permission to copy, distribute and modify it.
11 #
12 # Copyright (c) 1996-2005, PostgreSQL Global Development Group
13
14 if expr a : '\(a\)' >/dev/null 2>&1; then
15   as_expr=expr
16 else
17   as_expr=false
18 fi
19
20
21 ## --------------------- ##
22 ## M4sh Initialization.  ##
23 ## --------------------- ##
24
25 # Be Bourne compatible
26 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
27   emulate sh
28   NULLCMD=:
29 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
30   set -o posix
31 fi
32
33 # NLS nuisances.
34 # Support unset when possible.
35 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
36   as_unset=unset
37 else
38   as_unset=false
39 fi
40
41 (set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
42     { $as_unset LANG || test "${LANG+set}" != set; } ||
43       { LANG=C; export LANG; }
44 (set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
45     { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
46       { LC_ALL=C; export LC_ALL; }
47 (set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
48     { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
49       { LC_TIME=C; export LC_TIME; }
50 (set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
51     { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
52       { LC_CTYPE=C; export LC_CTYPE; }
53 (set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
54     { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
55       { LANGUAGE=C; export LANGUAGE; }
56 (set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
57     { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
58       { LC_COLLATE=C; export LC_COLLATE; }
59 (set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
60     { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
61       { LC_NUMERIC=C; export LC_NUMERIC; }
62 (set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
63     { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
64       { LC_MESSAGES=C; export LC_MESSAGES; }
65
66
67 # Name of the executable.
68 as_me=`(basename "$0") 2>/dev/null ||
69 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
70          X"$0" : 'X\(//\)$' \| \
71          X"$0" : 'X\(/\)$' \| \
72          .     : '\(.\)' 2>/dev/null ||
73 echo X/"$0" |
74     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
75           /^X\/\(\/\/\)$/{ s//\1/; q; }
76           /^X\/\(\/\).*/{ s//\1/; q; }
77           s/.*/./; q'`
78
79 # PATH needs CR, and LINENO needs CR and PATH.
80 # Avoid depending upon Character Ranges.
81 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
82 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
83 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
84 as_cr_digits='0123456789'
85 as_cr_alnum=$as_cr_Letters$as_cr_digits
86
87 # The user is always right.
88 if test "${PATH_SEPARATOR+set}" != set; then
89   echo "#! /bin/sh" >conftest.sh
90   echo  "exit 0"   >>conftest.sh
91   chmod +x conftest.sh
92   if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
93     PATH_SEPARATOR=';'
94   else
95     PATH_SEPARATOR=:
96   fi
97   rm -f conftest.sh
98 fi
99
100
101   as_lineno_1=$LINENO
102   as_lineno_2=$LINENO
103   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
104   test "x$as_lineno_1" != "x$as_lineno_2" &&
105   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
106   # Find who we are.  Look in the path if we contain no path at all
107   # relative or not.
108   case $0 in
109     *[\\/]* ) as_myself=$0 ;;
110     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
111 for as_dir in $PATH
112 do
113   IFS=$as_save_IFS
114   test -z "$as_dir" && as_dir=.
115   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
116 done
117
118        ;;
119   esac
120   # We did not find ourselves, most probably we were run as `sh COMMAND'
121   # in which case we are not to be found in the path.
122   if test "x$as_myself" = x; then
123     as_myself=$0
124   fi
125   if test ! -f "$as_myself"; then
126     { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
127    { (exit 1); exit 1; }; }
128   fi
129   case $CONFIG_SHELL in
130   '')
131     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
132 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
133 do
134   IFS=$as_save_IFS
135   test -z "$as_dir" && as_dir=.
136   for as_base in sh bash ksh sh5; do
137          case $as_dir in
138          /*)
139            if ("$as_dir/$as_base" -c '
140   as_lineno_1=$LINENO
141   as_lineno_2=$LINENO
142   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
143   test "x$as_lineno_1" != "x$as_lineno_2" &&
144   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
145              CONFIG_SHELL=$as_dir/$as_base
146              export CONFIG_SHELL
147              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
148            fi;;
149          esac
150        done
151 done
152 ;;
153   esac
154
155   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
156   # uniformly replaced by the line number.  The first 'sed' inserts a
157   # line-number line before each line; the second 'sed' does the real
158   # work.  The second script uses 'N' to pair each line-number line
159   # with the numbered line, and appends trailing '-' during
160   # substitution so that $LINENO is not a special case at line end.
161   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
162   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
163   sed '=' <$as_myself |
164     sed '
165       N
166       s,$,-,
167       : loop
168       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
169       t loop
170       s,-$,,
171       s,^['$as_cr_digits']*\n,,
172     ' >$as_me.lineno &&
173   chmod +x $as_me.lineno ||
174     { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
175    { (exit 1); exit 1; }; }
176
177   # Don't try to exec as it changes $[0], causing all sort of problems
178   # (the dirname of $[0] is not the place where we might find the
179   # original and so on.  Autoconf is especially sensible to this).
180   . ./$as_me.lineno
181   # Exit status is that of the last command.
182   exit
183 }
184
185
186 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
187   *c*,-n*) ECHO_N= ECHO_C='
188 ' ECHO_T='      ' ;;
189   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
190   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
191 esac
192
193 if expr a : '\(a\)' >/dev/null 2>&1; then
194   as_expr=expr
195 else
196   as_expr=false
197 fi
198
199 rm -f conf$$ conf$$.exe conf$$.file
200 echo >conf$$.file
201 if ln -s conf$$.file conf$$ 2>/dev/null; then
202   # We could just check for DJGPP; but this test a) works b) is more generic
203   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
204   if test -f conf$$.exe; then
205     # Don't use ln at all; we don't have any links
206     as_ln_s='cp -p'
207   else
208     as_ln_s='ln -s'
209   fi
210 elif ln conf$$.file conf$$ 2>/dev/null; then
211   as_ln_s=ln
212 else
213   as_ln_s='cp -p'
214 fi
215 rm -f conf$$ conf$$.exe conf$$.file
216
217 as_executable_p="test -f"
218
219 # Sed expression to map a string onto a valid CPP name.
220 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
221
222 # Sed expression to map a string onto a valid variable name.
223 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
224
225
226 # IFS
227 # We need space, tab and new line, in precisely that order.
228 as_nl='
229 '
230 IFS="   $as_nl"
231
232 # CDPATH.
233 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
234
235
236 # Name of the host.
237 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
238 # so uname gets run too.
239 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
240
241 exec 6>&1
242
243 #
244 # Initializations.
245 #
246 ac_default_prefix=/usr/local
247 cross_compiling=no
248 subdirs=
249 MFLAGS=
250 MAKEFLAGS=
251 SHELL=${CONFIG_SHELL-/bin/sh}
252
253 # Maximum number of lines to put in a shell here document.
254 # This variable seems obsolete.  It should probably be removed, and
255 # only ac_max_sed_lines should be used.
256 : ${ac_max_here_lines=38}
257
258 # Identity of this package.
259 PACKAGE_NAME='PostgreSQL'
260 PACKAGE_TARNAME='postgresql'
261 PACKAGE_VERSION='8.1devel'
262 PACKAGE_STRING='PostgreSQL 8.1devel'
263 PACKAGE_BUGREPORT='pgsql-bugs@postgresql.org'
264
265 ac_unique_file="src/backend/access/common/heaptuple.c"
266 ac_default_prefix=/usr/local/pgsql
267 # Factoring default headers for most tests.
268 ac_includes_default="\
269 #include <stdio.h>
270 #if HAVE_SYS_TYPES_H
271 # include <sys/types.h>
272 #endif
273 #if HAVE_SYS_STAT_H
274 # include <sys/stat.h>
275 #endif
276 #if STDC_HEADERS
277 # include <stdlib.h>
278 # include <stddef.h>
279 #else
280 # if HAVE_STDLIB_H
281 #  include <stdlib.h>
282 # endif
283 #endif
284 #if HAVE_STRING_H
285 # if !STDC_HEADERS && HAVE_MEMORY_H
286 #  include <memory.h>
287 # endif
288 # include <string.h>
289 #endif
290 #if HAVE_STRINGS_H
291 # include <strings.h>
292 #endif
293 #if HAVE_INTTYPES_H
294 # include <inttypes.h>
295 #else
296 # if HAVE_STDINT_H
297 #  include <stdint.h>
298 # endif
299 #endif
300 #if HAVE_UNISTD_H
301 # include <unistd.h>
302 #endif"
303
304
305 # Initialize some variables set by options.
306 ac_init_help=
307 ac_init_version=false
308 # The variables have the same names as the options, with
309 # dashes changed to underlines.
310 cache_file=/dev/null
311 exec_prefix=NONE
312 no_create=
313 no_recursion=
314 prefix=NONE
315 program_prefix=NONE
316 program_suffix=NONE
317 program_transform_name=s,x,x,
318 silent=
319 site=
320 srcdir=
321 verbose=
322 x_includes=NONE
323 x_libraries=NONE
324
325 # Installation directory options.
326 # These are left unexpanded so users can "make install exec_prefix=/foo"
327 # and all the variables that are supposed to be based on exec_prefix
328 # by default will actually change.
329 # Use braces instead of parens because sh, perl, etc. also accept them.
330 bindir='${exec_prefix}/bin'
331 sbindir='${exec_prefix}/sbin'
332 libexecdir='${exec_prefix}/libexec'
333 datadir='${prefix}/share'
334 sysconfdir='${prefix}/etc'
335 sharedstatedir='${prefix}/com'
336 localstatedir='${prefix}/var'
337 libdir='${exec_prefix}/lib'
338 includedir='${prefix}/include'
339 oldincludedir='/usr/include'
340 infodir='${prefix}/info'
341 mandir='${prefix}/man'
342
343 ac_prev=
344 for ac_option
345 do
346   # If the previous option needs an argument, assign it.
347   if test -n "$ac_prev"; then
348     eval "$ac_prev=\$ac_option"
349     ac_prev=
350     continue
351   fi
352
353   ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
354
355   # Accept the important Cygnus configure options, so we can diagnose typos.
356
357   case $ac_option in
358
359   -bindir | --bindir | --bindi | --bind | --bin | --bi)
360     ac_prev=bindir ;;
361   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
362     bindir=$ac_optarg ;;
363
364   -build | --build | --buil | --bui | --bu)
365     ac_prev=build_alias ;;
366   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
367     build_alias=$ac_optarg ;;
368
369   -cache-file | --cache-file | --cache-fil | --cache-fi \
370   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
371     ac_prev=cache_file ;;
372   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
373   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
374     cache_file=$ac_optarg ;;
375
376   --config-cache | -C)
377     cache_file=config.cache ;;
378
379   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
380     ac_prev=datadir ;;
381   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
382   | --da=*)
383     datadir=$ac_optarg ;;
384
385   -disable-* | --disable-*)
386     ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
387     # Reject names that are not valid shell variable names.
388     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
389       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
390    { (exit 1); exit 1; }; }
391     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
392     eval "enable_$ac_feature=no" ;;
393
394   -enable-* | --enable-*)
395     ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
396     # Reject names that are not valid shell variable names.
397     expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
398       { echo "$as_me: error: invalid feature name: $ac_feature" >&2
399    { (exit 1); exit 1; }; }
400     ac_feature=`echo $ac_feature | sed 's/-/_/g'`
401     case $ac_option in
402       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
403       *) ac_optarg=yes ;;
404     esac
405     eval "enable_$ac_feature='$ac_optarg'" ;;
406
407   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
408   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
409   | --exec | --exe | --ex)
410     ac_prev=exec_prefix ;;
411   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
412   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
413   | --exec=* | --exe=* | --ex=*)
414     exec_prefix=$ac_optarg ;;
415
416   -gas | --gas | --ga | --g)
417     # Obsolete; use --with-gas.
418     with_gas=yes ;;
419
420   -help | --help | --hel | --he | -h)
421     ac_init_help=long ;;
422   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
423     ac_init_help=recursive ;;
424   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
425     ac_init_help=short ;;
426
427   -host | --host | --hos | --ho)
428     ac_prev=host_alias ;;
429   -host=* | --host=* | --hos=* | --ho=*)
430     host_alias=$ac_optarg ;;
431
432   -includedir | --includedir | --includedi | --included | --include \
433   | --includ | --inclu | --incl | --inc)
434     ac_prev=includedir ;;
435   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
436   | --includ=* | --inclu=* | --incl=* | --inc=*)
437     includedir=$ac_optarg ;;
438
439   -infodir | --infodir | --infodi | --infod | --info | --inf)
440     ac_prev=infodir ;;
441   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
442     infodir=$ac_optarg ;;
443
444   -libdir | --libdir | --libdi | --libd)
445     ac_prev=libdir ;;
446   -libdir=* | --libdir=* | --libdi=* | --libd=*)
447     libdir=$ac_optarg ;;
448
449   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
450   | --libexe | --libex | --libe)
451     ac_prev=libexecdir ;;
452   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
453   | --libexe=* | --libex=* | --libe=*)
454     libexecdir=$ac_optarg ;;
455
456   -localstatedir | --localstatedir | --localstatedi | --localstated \
457   | --localstate | --localstat | --localsta | --localst \
458   | --locals | --local | --loca | --loc | --lo)
459     ac_prev=localstatedir ;;
460   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
461   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
462   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
463     localstatedir=$ac_optarg ;;
464
465   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
466     ac_prev=mandir ;;
467   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
468     mandir=$ac_optarg ;;
469
470   -nfp | --nfp | --nf)
471     # Obsolete; use --without-fp.
472     with_fp=no ;;
473
474   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
475   | --no-cr | --no-c | -n)
476     no_create=yes ;;
477
478   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
479   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
480     no_recursion=yes ;;
481
482   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
483   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
484   | --oldin | --oldi | --old | --ol | --o)
485     ac_prev=oldincludedir ;;
486   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
487   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
488   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
489     oldincludedir=$ac_optarg ;;
490
491   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
492     ac_prev=prefix ;;
493   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
494     prefix=$ac_optarg ;;
495
496   -program-prefix | --program-prefix | --program-prefi | --program-pref \
497   | --program-pre | --program-pr | --program-p)
498     ac_prev=program_prefix ;;
499   -program-prefix=* | --program-prefix=* | --program-prefi=* \
500   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
501     program_prefix=$ac_optarg ;;
502
503   -program-suffix | --program-suffix | --program-suffi | --program-suff \
504   | --program-suf | --program-su | --program-s)
505     ac_prev=program_suffix ;;
506   -program-suffix=* | --program-suffix=* | --program-suffi=* \
507   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
508     program_suffix=$ac_optarg ;;
509
510   -program-transform-name | --program-transform-name \
511   | --program-transform-nam | --program-transform-na \
512   | --program-transform-n | --program-transform- \
513   | --program-transform | --program-transfor \
514   | --program-transfo | --program-transf \
515   | --program-trans | --program-tran \
516   | --progr-tra | --program-tr | --program-t)
517     ac_prev=program_transform_name ;;
518   -program-transform-name=* | --program-transform-name=* \
519   | --program-transform-nam=* | --program-transform-na=* \
520   | --program-transform-n=* | --program-transform-=* \
521   | --program-transform=* | --program-transfor=* \
522   | --program-transfo=* | --program-transf=* \
523   | --program-trans=* | --program-tran=* \
524   | --progr-tra=* | --program-tr=* | --program-t=*)
525     program_transform_name=$ac_optarg ;;
526
527   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
528   | -silent | --silent | --silen | --sile | --sil)
529     silent=yes ;;
530
531   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
532     ac_prev=sbindir ;;
533   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
534   | --sbi=* | --sb=*)
535     sbindir=$ac_optarg ;;
536
537   -sharedstatedir | --sharedstatedir | --sharedstatedi \
538   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
539   | --sharedst | --shareds | --shared | --share | --shar \
540   | --sha | --sh)
541     ac_prev=sharedstatedir ;;
542   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
543   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
544   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
545   | --sha=* | --sh=*)
546     sharedstatedir=$ac_optarg ;;
547
548   -site | --site | --sit)
549     ac_prev=site ;;
550   -site=* | --site=* | --sit=*)
551     site=$ac_optarg ;;
552
553   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
554     ac_prev=srcdir ;;
555   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
556     srcdir=$ac_optarg ;;
557
558   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
559   | --syscon | --sysco | --sysc | --sys | --sy)
560     ac_prev=sysconfdir ;;
561   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
562   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
563     sysconfdir=$ac_optarg ;;
564
565   -target | --target | --targe | --targ | --tar | --ta | --t)
566     ac_prev=target_alias ;;
567   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
568     target_alias=$ac_optarg ;;
569
570   -v | -verbose | --verbose | --verbos | --verbo | --verb)
571     verbose=yes ;;
572
573   -version | --version | --versio | --versi | --vers | -V)
574     ac_init_version=: ;;
575
576   -with-* | --with-*)
577     ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
578     # Reject names that are not valid shell variable names.
579     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
580       { echo "$as_me: error: invalid package name: $ac_package" >&2
581    { (exit 1); exit 1; }; }
582     ac_package=`echo $ac_package| sed 's/-/_/g'`
583     case $ac_option in
584       *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
585       *) ac_optarg=yes ;;
586     esac
587     eval "with_$ac_package='$ac_optarg'" ;;
588
589   -without-* | --without-*)
590     ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
591     # Reject names that are not valid shell variable names.
592     expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
593       { echo "$as_me: error: invalid package name: $ac_package" >&2
594    { (exit 1); exit 1; }; }
595     ac_package=`echo $ac_package | sed 's/-/_/g'`
596     eval "with_$ac_package=no" ;;
597
598   --x)
599     # Obsolete; use --with-x.
600     with_x=yes ;;
601
602   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
603   | --x-incl | --x-inc | --x-in | --x-i)
604     ac_prev=x_includes ;;
605   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
606   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
607     x_includes=$ac_optarg ;;
608
609   -x-libraries | --x-libraries | --x-librarie | --x-librari \
610   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
611     ac_prev=x_libraries ;;
612   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
613   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
614     x_libraries=$ac_optarg ;;
615
616   -*) { echo "$as_me: error: unrecognized option: $ac_option
617 Try \`$0 --help' for more information." >&2
618    { (exit 1); exit 1; }; }
619     ;;
620
621   *=*)
622     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
623     # Reject names that are not valid shell variable names.
624     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
625       { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
626    { (exit 1); exit 1; }; }
627     ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
628     eval "$ac_envvar='$ac_optarg'"
629     export $ac_envvar ;;
630
631   *)
632     # FIXME: should be removed in autoconf 3.0.
633     echo "$as_me: WARNING: you should use --build, --host, --target" >&2
634     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
635       echo "$as_me: WARNING: invalid host type: $ac_option" >&2
636     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
637     ;;
638
639   esac
640 done
641
642 if test -n "$ac_prev"; then
643   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
644   { echo "$as_me: error: missing argument to $ac_option" >&2
645    { (exit 1); exit 1; }; }
646 fi
647
648 # Be sure to have absolute paths.
649 for ac_var in exec_prefix prefix
650 do
651   eval ac_val=$`echo $ac_var`
652   case $ac_val in
653     [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
654     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
655    { (exit 1); exit 1; }; };;
656   esac
657 done
658
659 # Be sure to have absolute paths.
660 for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
661               localstatedir libdir includedir oldincludedir infodir mandir
662 do
663   eval ac_val=$`echo $ac_var`
664   case $ac_val in
665     [\\/$]* | ?:[\\/]* ) ;;
666     *)  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
667    { (exit 1); exit 1; }; };;
668   esac
669 done
670
671 # There might be people who depend on the old broken behavior: `$host'
672 # used to hold the argument of --host etc.
673 # FIXME: To remove some day.
674 build=$build_alias
675 host=$host_alias
676 target=$target_alias
677
678 # FIXME: To remove some day.
679 if test "x$host_alias" != x; then
680   if test "x$build_alias" = x; then
681     cross_compiling=maybe
682     echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
683     If a cross compiler is detected then cross compile mode will be used." >&2
684   elif test "x$build_alias" != "x$host_alias"; then
685     cross_compiling=yes
686   fi
687 fi
688
689 ac_tool_prefix=
690 test -n "$host_alias" && ac_tool_prefix=$host_alias-
691
692 test "$silent" = yes && exec 6>/dev/null
693
694
695 # Find the source files, if location was not specified.
696 if test -z "$srcdir"; then
697   ac_srcdir_defaulted=yes
698   # Try the directory containing this script, then its parent.
699   ac_confdir=`(dirname "$0") 2>/dev/null ||
700 $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
701          X"$0" : 'X\(//\)[^/]' \| \
702          X"$0" : 'X\(//\)$' \| \
703          X"$0" : 'X\(/\)' \| \
704          .     : '\(.\)' 2>/dev/null ||
705 echo X"$0" |
706     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
707           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
708           /^X\(\/\/\)$/{ s//\1/; q; }
709           /^X\(\/\).*/{ s//\1/; q; }
710           s/.*/./; q'`
711   srcdir=$ac_confdir
712   if test ! -r $srcdir/$ac_unique_file; then
713     srcdir=..
714   fi
715 else
716   ac_srcdir_defaulted=no
717 fi
718 if test ! -r $srcdir/$ac_unique_file; then
719   if test "$ac_srcdir_defaulted" = yes; then
720     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
721    { (exit 1); exit 1; }; }
722   else
723     { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
724    { (exit 1); exit 1; }; }
725   fi
726 fi
727 srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
728 ac_env_build_alias_set=${build_alias+set}
729 ac_env_build_alias_value=$build_alias
730 ac_cv_env_build_alias_set=${build_alias+set}
731 ac_cv_env_build_alias_value=$build_alias
732 ac_env_host_alias_set=${host_alias+set}
733 ac_env_host_alias_value=$host_alias
734 ac_cv_env_host_alias_set=${host_alias+set}
735 ac_cv_env_host_alias_value=$host_alias
736 ac_env_target_alias_set=${target_alias+set}
737 ac_env_target_alias_value=$target_alias
738 ac_cv_env_target_alias_set=${target_alias+set}
739 ac_cv_env_target_alias_value=$target_alias
740 ac_env_CC_set=${CC+set}
741 ac_env_CC_value=$CC
742 ac_cv_env_CC_set=${CC+set}
743 ac_cv_env_CC_value=$CC
744 ac_env_CFLAGS_set=${CFLAGS+set}
745 ac_env_CFLAGS_value=$CFLAGS
746 ac_cv_env_CFLAGS_set=${CFLAGS+set}
747 ac_cv_env_CFLAGS_value=$CFLAGS
748 ac_env_LDFLAGS_set=${LDFLAGS+set}
749 ac_env_LDFLAGS_value=$LDFLAGS
750 ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
751 ac_cv_env_LDFLAGS_value=$LDFLAGS
752 ac_env_CPPFLAGS_set=${CPPFLAGS+set}
753 ac_env_CPPFLAGS_value=$CPPFLAGS
754 ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
755 ac_cv_env_CPPFLAGS_value=$CPPFLAGS
756 ac_env_CPP_set=${CPP+set}
757 ac_env_CPP_value=$CPP
758 ac_cv_env_CPP_set=${CPP+set}
759 ac_cv_env_CPP_value=$CPP
760 ac_env_LDFLAGS_SL_set=${LDFLAGS_SL+set}
761 ac_env_LDFLAGS_SL_value=$LDFLAGS_SL
762 ac_cv_env_LDFLAGS_SL_set=${LDFLAGS_SL+set}
763 ac_cv_env_LDFLAGS_SL_value=$LDFLAGS_SL
764 ac_env_DOCBOOKSTYLE_set=${DOCBOOKSTYLE+set}
765 ac_env_DOCBOOKSTYLE_value=$DOCBOOKSTYLE
766 ac_cv_env_DOCBOOKSTYLE_set=${DOCBOOKSTYLE+set}
767 ac_cv_env_DOCBOOKSTYLE_value=$DOCBOOKSTYLE
768
769 #
770 # Report the --help message.
771 #
772 if test "$ac_init_help" = "long"; then
773   # Omit some internal or obsolete options to make the list less imposing.
774   # This message is too long to be a string in the A/UX 3.1 sh.
775   cat <<_ACEOF
776 \`configure' configures PostgreSQL 8.1devel to adapt to many kinds of systems.
777
778 Usage: $0 [OPTION]... [VAR=VALUE]...
779
780 To assign environment variables (e.g., CC, CFLAGS...), specify them as
781 VAR=VALUE.  See below for descriptions of some of the useful variables.
782
783 Defaults for the options are specified in brackets.
784
785 Configuration:
786   -h, --help              display this help and exit
787       --help=short        display options specific to this package
788       --help=recursive    display the short help of all the included packages
789   -V, --version           display version information and exit
790   -q, --quiet, --silent   do not print \`checking...' messages
791       --cache-file=FILE   cache test results in FILE [disabled]
792   -C, --config-cache      alias for \`--cache-file=config.cache'
793   -n, --no-create         do not create output files
794       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
795
796 _ACEOF
797
798   cat <<_ACEOF
799 Installation directories:
800   --prefix=PREFIX         install architecture-independent files in PREFIX
801                           [$ac_default_prefix]
802   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
803                           [PREFIX]
804
805 By default, \`make install' will install all the files in
806 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
807 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
808 for instance \`--prefix=\$HOME'.
809
810 For better control, use the options below.
811
812 Fine tuning of the installation directories:
813   --bindir=DIR           user executables [EPREFIX/bin]
814   --sbindir=DIR          system admin executables [EPREFIX/sbin]
815   --libexecdir=DIR       program executables [EPREFIX/libexec]
816   --datadir=DIR          read-only architecture-independent data [PREFIX/share]
817   --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
818   --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
819   --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
820   --libdir=DIR           object code libraries [EPREFIX/lib]
821   --includedir=DIR       C header files [PREFIX/include]
822   --oldincludedir=DIR    C header files for non-gcc [/usr/include]
823   --infodir=DIR          info documentation [PREFIX/info]
824   --mandir=DIR           man documentation [PREFIX/man]
825 _ACEOF
826
827   cat <<\_ACEOF
828
829 System types:
830   --build=BUILD     configure for building on BUILD [guessed]
831   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
832 _ACEOF
833 fi
834
835 if test -n "$ac_init_help"; then
836   case $ac_init_help in
837      short | recursive ) echo "Configuration of PostgreSQL 8.1devel:";;
838    esac
839   cat <<\_ACEOF
840
841 Optional Features:
842   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
843   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
844   --enable-integer-datetimes  enable 64-bit integer date/time support
845   --enable-nls[=LANGUAGES]  enable Native Language Support
846   --disable-shared        do not build shared libraries
847   --disable-rpath         do not embed shared library search path in executables
848   --disable-spinlocks     do not use spinlocks
849   --enable-debug          build with debugging symbols (-g)
850   --enable-depend         turn on automatic dependency tracking
851   --enable-cassert        enable assertion checks (for debugging)
852   --enable-thread-safety  make client libraries thread-safe
853   --enable-thread-safety-force  force thread-safety in spite of thread test failure
854   --disable-largefile     omit support for large files
855
856 Optional Packages:
857   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
858   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
859
860   --with-docdir=DIR       install the documentation in DIR [PREFIX/doc]
861   --without-docdir        do not install the documentation
862   --with-includes=DIRS    look for additional header files in DIRS
863   --with-libraries=DIRS   look for additional libraries in DIRS
864   --with-libs=DIRS        alternative spelling of --with-libraries
865   --with-pgport=PORTNUM   change default port number 5432
866   --with-tcl              build Tcl modules (PL/Tcl)
867   --with-tclconfig=DIR    tclConfig.sh is in DIR
868   --with-perl             build Perl modules (PL/Perl)
869   --with-python           build Python modules (PL/Python)
870   --with-krb4             build with Kerberos 4 support
871   --with-krb5             build with Kerberos 5 support
872   --with-krb-srvnam=NAME  name of the service principal in Kerberos [postgres]
873   --with-pam              build with PAM support
874   --with-rendezvous       build with Rendezvous support
875   --with-openssl          build with OpenSSL support
876   --without-readline      do not use Readline
877   --without-zlib          do not use Zlib
878   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
879
880 Some influential environment variables:
881   CC          C compiler command
882   CFLAGS      C compiler flags
883   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
884               nonstandard directory <lib dir>
885   CPPFLAGS    C/C++ preprocessor flags, e.g. -I<include dir> if you have
886               headers in a nonstandard directory <include dir>
887   CPP         C preprocessor
888   LDFLAGS_SL
889   DOCBOOKSTYLE
890               location of DocBook stylesheets
891
892 Use these variables to override the choices made by `configure' or to help
893 it to find libraries and programs with nonstandard names/locations.
894
895 Report bugs to <pgsql-bugs@postgresql.org>.
896 _ACEOF
897 fi
898
899 if test "$ac_init_help" = "recursive"; then
900   # If there are subdirs, report their specific --help.
901   ac_popdir=`pwd`
902   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
903     test -d $ac_dir || continue
904     ac_builddir=.
905
906 if test "$ac_dir" != .; then
907   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
908   # A "../" for each directory in $ac_dir_suffix.
909   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
910 else
911   ac_dir_suffix= ac_top_builddir=
912 fi
913
914 case $srcdir in
915   .)  # No --srcdir option.  We are building in place.
916     ac_srcdir=.
917     if test -z "$ac_top_builddir"; then
918        ac_top_srcdir=.
919     else
920        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
921     fi ;;
922   [\\/]* | ?:[\\/]* )  # Absolute path.
923     ac_srcdir=$srcdir$ac_dir_suffix;
924     ac_top_srcdir=$srcdir ;;
925   *) # Relative path.
926     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
927     ac_top_srcdir=$ac_top_builddir$srcdir ;;
928 esac
929 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
930 # absolute.
931 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
932 ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
933 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
934 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
935
936     cd $ac_dir
937     # Check for guested configure; otherwise get Cygnus style configure.
938     if test -f $ac_srcdir/configure.gnu; then
939       echo
940       $SHELL $ac_srcdir/configure.gnu  --help=recursive
941     elif test -f $ac_srcdir/configure; then
942       echo
943       $SHELL $ac_srcdir/configure  --help=recursive
944     elif test -f $ac_srcdir/configure.ac ||
945            test -f $ac_srcdir/configure.in; then
946       echo
947       $ac_configure --help
948     else
949       echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
950     fi
951     cd $ac_popdir
952   done
953 fi
954
955 test -n "$ac_init_help" && exit 0
956 if $ac_init_version; then
957   cat <<\_ACEOF
958 PostgreSQL configure 8.1devel
959 generated by GNU Autoconf 2.53
960
961 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
962 Free Software Foundation, Inc.
963 This configure script is free software; the Free Software Foundation
964 gives unlimited permission to copy, distribute and modify it.
965
966 Copyright (c) 1996-2005, PostgreSQL Global Development Group
967 _ACEOF
968   exit 0
969 fi
970 exec 5>config.log
971 cat >&5 <<_ACEOF
972 This file contains any messages produced by compilers while
973 running configure, to aid debugging if configure makes a mistake.
974
975 It was created by PostgreSQL $as_me 8.1devel, which was
976 generated by GNU Autoconf 2.53.  Invocation command line was
977
978   $ $0 $@
979
980 _ACEOF
981 {
982 cat <<_ASUNAME
983 ## --------- ##
984 ## Platform. ##
985 ## --------- ##
986
987 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
988 uname -m = `(uname -m) 2>/dev/null || echo unknown`
989 uname -r = `(uname -r) 2>/dev/null || echo unknown`
990 uname -s = `(uname -s) 2>/dev/null || echo unknown`
991 uname -v = `(uname -v) 2>/dev/null || echo unknown`
992
993 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
994 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
995
996 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
997 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
998 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
999 hostinfo               = `(hostinfo) 2>/dev/null               || echo unknown`
1000 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1001 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1002 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1003
1004 _ASUNAME
1005
1006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1007 for as_dir in $PATH
1008 do
1009   IFS=$as_save_IFS
1010   test -z "$as_dir" && as_dir=.
1011   echo "PATH: $as_dir"
1012 done
1013
1014 } >&5
1015
1016 cat >&5 <<_ACEOF
1017
1018
1019 ## ----------- ##
1020 ## Core tests. ##
1021 ## ----------- ##
1022
1023 _ACEOF
1024
1025
1026 # Keep a trace of the command line.
1027 # Strip out --no-create and --no-recursion so they do not pile up.
1028 # Also quote any args containing shell meta-characters.
1029 ac_configure_args=
1030 ac_sep=
1031 for ac_arg
1032 do
1033   case $ac_arg in
1034   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1035   | --no-cr | --no-c | -n ) continue ;;
1036   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1037   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1038     continue ;;
1039   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1040     ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1041   esac
1042   case " $ac_configure_args " in
1043     *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1044     *) ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
1045        ac_sep=" " ;;
1046   esac
1047   # Get rid of the leading space.
1048 done
1049
1050 # When interrupted or exit'd, cleanup temporary files, and complete
1051 # config.log.  We remove comments because anyway the quotes in there
1052 # would cause problems or look ugly.
1053 # WARNING: Be sure not to use single quotes in there, as some shells,
1054 # such as our DU 5.0 friend, will then `close' the trap.
1055 trap 'exit_status=$?
1056   # Save into config.log some information that might help in debugging.
1057   {
1058     echo
1059     cat <<\_ASBOX
1060 ## ---------------- ##
1061 ## Cache variables. ##
1062 ## ---------------- ##
1063 _ASBOX
1064     echo
1065     # The following way of writing the cache mishandles newlines in values,
1066 {
1067   (set) 2>&1 |
1068     case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
1069     *ac_space=\ *)
1070       sed -n \
1071         "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
1072           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
1073       ;;
1074     *)
1075       sed -n \
1076         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
1077       ;;
1078     esac;
1079 }
1080     echo
1081     if test -s confdefs.h; then
1082       cat <<\_ASBOX
1083 ## ----------- ##
1084 ## confdefs.h. ##
1085 ## ----------- ##
1086 _ASBOX
1087       echo
1088       sed "/^$/d" confdefs.h
1089       echo
1090     fi
1091     test "$ac_signal" != 0 &&
1092       echo "$as_me: caught signal $ac_signal"
1093     echo "$as_me: exit $exit_status"
1094   } >&5
1095   rm -f core core.* *.core &&
1096   rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
1097     exit $exit_status
1098      ' 0
1099 for ac_signal in 1 2 13 15; do
1100   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1101 done
1102 ac_signal=0
1103
1104 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1105 rm -rf conftest* confdefs.h
1106 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
1107 echo >confdefs.h
1108
1109 # Predefined preprocessor variables.
1110
1111 cat >>confdefs.h <<_ACEOF
1112 #define PACKAGE_NAME "$PACKAGE_NAME"
1113 _ACEOF
1114
1115
1116 cat >>confdefs.h <<_ACEOF
1117 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1118 _ACEOF
1119
1120
1121 cat >>confdefs.h <<_ACEOF
1122 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1123 _ACEOF
1124
1125
1126 cat >>confdefs.h <<_ACEOF
1127 #define PACKAGE_STRING "$PACKAGE_STRING"
1128 _ACEOF
1129
1130
1131 cat >>confdefs.h <<_ACEOF
1132 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1133 _ACEOF
1134
1135
1136 # Let the site file select an alternate cache file if it wants to.
1137 # Prefer explicitly selected file to automatically selected ones.
1138 if test -z "$CONFIG_SITE"; then
1139   if test "x$prefix" != xNONE; then
1140     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
1141   else
1142     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
1143   fi
1144 fi
1145 for ac_site_file in $CONFIG_SITE; do
1146   if test -r "$ac_site_file"; then
1147     { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1148 echo "$as_me: loading site script $ac_site_file" >&6;}
1149     sed 's/^/| /' "$ac_site_file" >&5
1150     . "$ac_site_file"
1151   fi
1152 done
1153
1154 if test -r "$cache_file"; then
1155   # Some versions of bash will fail to source /dev/null (special
1156   # files actually), so we avoid doing that.
1157   if test -f "$cache_file"; then
1158     { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1159 echo "$as_me: loading cache $cache_file" >&6;}
1160     case $cache_file in
1161       [\\/]* | ?:[\\/]* ) . $cache_file;;
1162       *)                      . ./$cache_file;;
1163     esac
1164   fi
1165 else
1166   { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1167 echo "$as_me: creating cache $cache_file" >&6;}
1168   >$cache_file
1169 fi
1170
1171 # Check that the precious variables saved in the cache have kept the same
1172 # value.
1173 ac_cache_corrupted=false
1174 for ac_var in `(set) 2>&1 |
1175                sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
1176   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1177   eval ac_new_set=\$ac_env_${ac_var}_set
1178   eval ac_old_val="\$ac_cv_env_${ac_var}_value"
1179   eval ac_new_val="\$ac_env_${ac_var}_value"
1180   case $ac_old_set,$ac_new_set in
1181     set,)
1182       { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1183 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1184       ac_cache_corrupted=: ;;
1185     ,set)
1186       { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1187 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1188       ac_cache_corrupted=: ;;
1189     ,);;
1190     *)
1191       if test "x$ac_old_val" != "x$ac_new_val"; then
1192         { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1193 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1194         { echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1195 echo "$as_me:   former value:  $ac_old_val" >&2;}
1196         { echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1197 echo "$as_me:   current value: $ac_new_val" >&2;}
1198         ac_cache_corrupted=:
1199       fi;;
1200   esac
1201   # Pass precious variables to config.status.
1202   if test "$ac_new_set" = set; then
1203     case $ac_new_val in
1204     *" "*|*"    "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
1205       ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1206     *) ac_arg=$ac_var=$ac_new_val ;;
1207     esac
1208     case " $ac_configure_args " in
1209       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1210       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1211     esac
1212   fi
1213 done
1214 if $ac_cache_corrupted; then
1215   { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1216 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1217   { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1218 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1219    { (exit 1); exit 1; }; }
1220 fi
1221
1222 ac_ext=c
1223 ac_cpp='$CPP $CPPFLAGS'
1224 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1225 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1226 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257 ac_aux_dir=
1258 for ac_dir in config $srcdir/config; do
1259   if test -f $ac_dir/install-sh; then
1260     ac_aux_dir=$ac_dir
1261     ac_install_sh="$ac_aux_dir/install-sh -c"
1262     break
1263   elif test -f $ac_dir/install.sh; then
1264     ac_aux_dir=$ac_dir
1265     ac_install_sh="$ac_aux_dir/install.sh -c"
1266     break
1267   elif test -f $ac_dir/shtool; then
1268     ac_aux_dir=$ac_dir
1269     ac_install_sh="$ac_aux_dir/shtool install -c"
1270     break
1271   fi
1272 done
1273 if test -z "$ac_aux_dir"; then
1274   { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config $srcdir/config" >&5
1275 echo "$as_me: error: cannot find install-sh or install.sh in config $srcdir/config" >&2;}
1276    { (exit 1); exit 1; }; }
1277 fi
1278 ac_config_guess="$SHELL $ac_aux_dir/config.guess"
1279 ac_config_sub="$SHELL $ac_aux_dir/config.sub"
1280 ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
1281
1282
1283 configure_args=$ac_configure_args
1284
1285
1286
1287 cat >>confdefs.h <<_ACEOF
1288 #define PG_VERSION "$PACKAGE_VERSION"
1289 _ACEOF
1290
1291
1292 # Make sure we can run config.sub.
1293 $ac_config_sub sun4 >/dev/null 2>&1 ||
1294   { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
1295 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
1296    { (exit 1); exit 1; }; }
1297
1298 echo "$as_me:$LINENO: checking build system type" >&5
1299 echo $ECHO_N "checking build system type... $ECHO_C" >&6
1300 if test "${ac_cv_build+set}" = set; then
1301   echo $ECHO_N "(cached) $ECHO_C" >&6
1302 else
1303   ac_cv_build_alias=$build_alias
1304 test -z "$ac_cv_build_alias" &&
1305   ac_cv_build_alias=`$ac_config_guess`
1306 test -z "$ac_cv_build_alias" &&
1307   { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
1308 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
1309    { (exit 1); exit 1; }; }
1310 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
1311   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
1312 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
1313    { (exit 1); exit 1; }; }
1314
1315 fi
1316 echo "$as_me:$LINENO: result: $ac_cv_build" >&5
1317 echo "${ECHO_T}$ac_cv_build" >&6
1318 build=$ac_cv_build
1319 build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1320 build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1321 build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1322
1323
1324 echo "$as_me:$LINENO: checking host system type" >&5
1325 echo $ECHO_N "checking host system type... $ECHO_C" >&6
1326 if test "${ac_cv_host+set}" = set; then
1327   echo $ECHO_N "(cached) $ECHO_C" >&6
1328 else
1329   ac_cv_host_alias=$host_alias
1330 test -z "$ac_cv_host_alias" &&
1331   ac_cv_host_alias=$ac_cv_build_alias
1332 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
1333   { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
1334 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
1335    { (exit 1); exit 1; }; }
1336
1337 fi
1338 echo "$as_me:$LINENO: result: $ac_cv_host" >&5
1339 echo "${ECHO_T}$ac_cv_host" >&6
1340 host=$ac_cv_host
1341 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
1342 host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
1343 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
1344
1345
1346
1347 template=
1348 echo "$as_me:$LINENO: checking which template to use" >&5
1349 echo $ECHO_N "checking which template to use... $ECHO_C" >&6
1350
1351
1352
1353
1354 # Check whether --with-template or --without-template was given.
1355 if test "${with_template+set}" = set; then
1356   withval="$with_template"
1357
1358   case $withval in
1359     yes)
1360       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1361 echo "$as_me: error: argument required for --with-template option" >&2;}
1362    { (exit 1); exit 1; }; }
1363       ;;
1364     no)
1365       { { echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
1366 echo "$as_me: error: argument required for --with-template option" >&2;}
1367    { (exit 1); exit 1; }; }
1368       ;;
1369     *)
1370
1371   case $withval in
1372     list)   echo; ls "$srcdir/src/template"; exit;;
1373     *)      if test -f "$srcdir/src/template/$with_template" ; then
1374               template=$withval
1375             else
1376               { { echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
1377 echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
1378    { (exit 1); exit 1; }; }
1379             fi;;
1380   esac
1381
1382       ;;
1383   esac
1384
1385 else
1386
1387 # --with-template not given
1388
1389 case $host_os in
1390      aix*) template=aix ;;
1391     beos*) template=beos ;;
1392     bsdi*) template=bsdi ;;
1393   cygwin*) template=cygwin ;;
1394   darwin*) template=darwin ;;
1395     dgux*) template=dgux ;;
1396  freebsd*) template=freebsd ;;
1397     hpux*) template=hpux ;;
1398     irix*) template=irix ;;
1399  linux*|gnu*|k*bsd*-gnu)
1400            template=linux ;;
1401    mingw*) template=win32 ;;
1402   netbsd*) template=netbsd ;;
1403 nextstep*) template=nextstep ;;
1404  openbsd*) template=openbsd ;;
1405      osf*) template=osf ;;
1406      qnx*) template=qnx4 ;;
1407      sco*) template=sco ;;
1408  solaris*) template=solaris ;;
1409    sunos*) template=sunos4 ;;
1410  sysv4.2*)
1411         case $host_vendor in
1412           univel) template=univel ;;
1413         esac ;;
1414    sysv4*) template=svr4 ;;
1415    sysv5*) template=unixware ;;
1416   ultrix*) template=ultrix4 ;;
1417 esac
1418
1419   if test x"$template" = x"" ; then
1420     { { echo "$as_me:$LINENO: error:
1421 *******************************************************************
1422 PostgreSQL has apparently not been ported to your platform yet.
1423 To try a manual configuration, look into the src/template directory
1424 for a similar platform and use the '--with-template=' option.
1425
1426 Please also contact <pgsql-ports@postgresql.org> to see about
1427 rectifying this.  Include the above 'checking host system type...'
1428 line.
1429 *******************************************************************
1430 " >&5
1431 echo "$as_me: error:
1432 *******************************************************************
1433 PostgreSQL has apparently not been ported to your platform yet.
1434 To try a manual configuration, look into the src/template directory
1435 for a similar platform and use the '--with-template=' option.
1436
1437 Please also contact <pgsql-ports@postgresql.org> to see about
1438 rectifying this.  Include the above 'checking host system type...'
1439 line.
1440 *******************************************************************
1441 " >&2;}
1442    { (exit 1); exit 1; }; }
1443   fi
1444
1445
1446 fi;
1447
1448
1449 echo "$as_me:$LINENO: result: $template" >&5
1450 echo "${ECHO_T}$template" >&6
1451
1452 PORTNAME=$template
1453
1454
1455 # Initialize default assumption that we do not need separate assembly code
1456 # for TAS (test-and-set).  This can be overridden by the template file
1457 # when it's executed.
1458 need_tas=no
1459 tas_file=dummy.s
1460
1461
1462
1463 ##
1464 ## Command line options
1465 ##
1466
1467 #
1468 # Installation directory for documentation
1469 #
1470
1471
1472
1473 # Check whether --with-docdir or --without-docdir was given.
1474 if test "${with_docdir+set}" = set; then
1475   withval="$with_docdir"
1476
1477   case $withval in
1478     yes)
1479       { { echo "$as_me:$LINENO: error: option --with-docdir requires an argument" >&5
1480 echo "$as_me: error: option --with-docdir requires an argument" >&2;}
1481    { (exit 1); exit 1; }; }
1482       ;;
1483     no)
1484       docdir=
1485       ;;
1486     *)
1487       docdir=$withval
1488       ;;
1489   esac
1490
1491 else
1492   docdir='${prefix}/doc'
1493 fi;
1494
1495
1496
1497
1498 #
1499 # Add non-standard directories to the include path
1500 #
1501
1502
1503
1504 # Check whether --with-includes or --without-includes was given.
1505 if test "${with_includes+set}" = set; then
1506   withval="$with_includes"
1507
1508   case $withval in
1509     yes)
1510       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1511 echo "$as_me: error: argument required for --with-includes option" >&2;}
1512    { (exit 1); exit 1; }; }
1513       ;;
1514     no)
1515       { { echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
1516 echo "$as_me: error: argument required for --with-includes option" >&2;}
1517    { (exit 1); exit 1; }; }
1518       ;;
1519     *)
1520
1521       ;;
1522   esac
1523
1524 fi;
1525
1526
1527
1528 #
1529 # Add non-standard directories to the library search path
1530 #
1531
1532
1533
1534 # Check whether --with-libraries or --without-libraries was given.
1535 if test "${with_libraries+set}" = set; then
1536   withval="$with_libraries"
1537
1538   case $withval in
1539     yes)
1540       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
1541 echo "$as_me: error: argument required for --with-libraries option" >&2;}
1542    { (exit 1); exit 1; }; }
1543       ;;
1544     no)
1545       { { echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
1546 echo "$as_me: error: argument required for --with-libraries option" >&2;}
1547    { (exit 1); exit 1; }; }
1548       ;;
1549     *)
1550       LIBRARY_DIRS=$withval
1551       ;;
1552   esac
1553
1554 fi;
1555
1556
1557
1558
1559
1560 # Check whether --with-libs or --without-libs was given.
1561 if test "${with_libs+set}" = set; then
1562   withval="$with_libs"
1563
1564   case $withval in
1565     yes)
1566       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1567 echo "$as_me: error: argument required for --with-libs option" >&2;}
1568    { (exit 1); exit 1; }; }
1569       ;;
1570     no)
1571       { { echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
1572 echo "$as_me: error: argument required for --with-libs option" >&2;}
1573    { (exit 1); exit 1; }; }
1574       ;;
1575     *)
1576       LIBRARY_DIRS=$withval
1577       ;;
1578   esac
1579
1580 fi;
1581
1582
1583
1584 #
1585 # 64-bit integer date/time storage (--enable-integer-datetimes)
1586 #
1587 echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
1588 echo $ECHO_N "checking whether to build with 64-bit integer date/time support... $ECHO_C" >&6
1589
1590
1591 # Check whether --enable-integer-datetimes or --disable-integer-datetimes was given.
1592 if test "${enable_integer_datetimes+set}" = set; then
1593   enableval="$enable_integer_datetimes"
1594
1595   case $enableval in
1596     yes)
1597
1598 cat >>confdefs.h <<\_ACEOF
1599 #define USE_INTEGER_DATETIMES 1
1600 _ACEOF
1601
1602       ;;
1603     no)
1604       :
1605       ;;
1606     *)
1607       { { echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
1608 echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
1609    { (exit 1); exit 1; }; }
1610       ;;
1611   esac
1612
1613 else
1614   enable_integer_datetimes=no
1615
1616 fi;
1617
1618 echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
1619 echo "${ECHO_T}$enable_integer_datetimes" >&6
1620
1621
1622 #
1623 # NLS
1624 #
1625 echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
1626 echo $ECHO_N "checking whether NLS is wanted... $ECHO_C" >&6
1627
1628
1629 # Check whether --enable-nls or --disable-nls was given.
1630 if test "${enable_nls+set}" = set; then
1631   enableval="$enable_nls"
1632
1633   case $enableval in
1634     yes)
1635       :
1636       ;;
1637     no)
1638       :
1639       ;;
1640     *)
1641       enable_nls=yes
1642 WANTED_LANGUAGES=$enableval
1643       ;;
1644   esac
1645
1646 else
1647   enable_nls=no
1648 fi;
1649
1650
1651 if test "$enable_nls" = yes; then
1652
1653 cat >>confdefs.h <<\_ACEOF
1654 #define ENABLE_NLS 1
1655 _ACEOF
1656
1657 fi
1658
1659 echo "$as_me:$LINENO: result: $enable_nls" >&5
1660 echo "${ECHO_T}$enable_nls" >&6
1661
1662
1663
1664 #
1665 # Default port number (--with-pgport), default 5432
1666 #
1667 echo "$as_me:$LINENO: checking for default port number" >&5
1668 echo $ECHO_N "checking for default port number... $ECHO_C" >&6
1669
1670
1671
1672 # Check whether --with-pgport or --without-pgport was given.
1673 if test "${with_pgport+set}" = set; then
1674   withval="$with_pgport"
1675
1676   case $withval in
1677     yes)
1678       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1679 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1680    { (exit 1); exit 1; }; }
1681       ;;
1682     no)
1683       { { echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
1684 echo "$as_me: error: argument required for --with-pgport option" >&2;}
1685    { (exit 1); exit 1; }; }
1686       ;;
1687     *)
1688       default_port=$withval
1689       ;;
1690   esac
1691
1692 else
1693   default_port=5432
1694 fi;
1695
1696 echo "$as_me:$LINENO: result: $default_port" >&5
1697 echo "${ECHO_T}$default_port" >&6
1698 # Need both of these because some places want an integer and some a string
1699
1700 cat >>confdefs.h <<_ACEOF
1701 #define DEF_PGPORT ${default_port}
1702 _ACEOF
1703
1704
1705 cat >>confdefs.h <<_ACEOF
1706 #define DEF_PGPORT_STR "${default_port}"
1707 _ACEOF
1708
1709
1710
1711 #
1712 # Option to disable shared libraries
1713 #
1714
1715
1716 # Check whether --enable-shared or --disable-shared was given.
1717 if test "${enable_shared+set}" = set; then
1718   enableval="$enable_shared"
1719
1720   case $enableval in
1721     yes)
1722       :
1723       ;;
1724     no)
1725       :
1726       ;;
1727     *)
1728       { { echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
1729 echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
1730    { (exit 1); exit 1; }; }
1731       ;;
1732   esac
1733
1734 else
1735   enable_shared=yes
1736
1737 fi;
1738
1739
1740
1741 #
1742 # '-rpath'-like feature can be disabled
1743 #
1744
1745
1746 # Check whether --enable-rpath or --disable-rpath was given.
1747 if test "${enable_rpath+set}" = set; then
1748   enableval="$enable_rpath"
1749
1750   case $enableval in
1751     yes)
1752       :
1753       ;;
1754     no)
1755       :
1756       ;;
1757     *)
1758       { { echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
1759 echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
1760    { (exit 1); exit 1; }; }
1761       ;;
1762   esac
1763
1764 else
1765   enable_rpath=yes
1766
1767 fi;
1768
1769
1770
1771 #
1772 # Spinlocks
1773 #
1774
1775
1776 # Check whether --enable-spinlocks or --disable-spinlocks was given.
1777 if test "${enable_spinlocks+set}" = set; then
1778   enableval="$enable_spinlocks"
1779
1780   case $enableval in
1781     yes)
1782       :
1783       ;;
1784     no)
1785       :
1786       ;;
1787     *)
1788       { { echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
1789 echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
1790    { (exit 1); exit 1; }; }
1791       ;;
1792   esac
1793
1794 else
1795   enable_spinlocks=yes
1796
1797 fi;
1798
1799
1800 #
1801 # --enable-debug adds -g to compiler flags
1802 #
1803
1804
1805 # Check whether --enable-debug or --disable-debug was given.
1806 if test "${enable_debug+set}" = set; then
1807   enableval="$enable_debug"
1808
1809   case $enableval in
1810     yes)
1811       :
1812       ;;
1813     no)
1814       :
1815       ;;
1816     *)
1817       { { echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
1818 echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
1819    { (exit 1); exit 1; }; }
1820       ;;
1821   esac
1822
1823 else
1824   enable_debug=no
1825
1826 fi;
1827
1828
1829
1830 #
1831 # C compiler
1832 #
1833
1834 # For historical reasons you can also use --with-CC to specify the C compiler
1835 # to use, although the standard way to do this is to set the CC environment
1836 # variable.
1837
1838
1839
1840 # Check whether --with-CC or --without-CC was given.
1841 if test "${with_CC+set}" = set; then
1842   withval="$with_CC"
1843
1844   case $withval in
1845     yes)
1846       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
1847 echo "$as_me: error: argument required for --with-CC option" >&2;}
1848    { (exit 1); exit 1; }; }
1849       ;;
1850     no)
1851       { { echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
1852 echo "$as_me: error: argument required for --with-CC option" >&2;}
1853    { (exit 1); exit 1; }; }
1854       ;;
1855     *)
1856       CC=$with_CC
1857       ;;
1858   esac
1859
1860 fi;
1861
1862
1863 case $template in
1864   aix) pgac_cc_list="gcc xlc";;
1865  irix) pgac_cc_list="cc";; # no gcc
1866     *) pgac_cc_list="gcc cc";;
1867 esac
1868
1869 ac_ext=c
1870 ac_cpp='$CPP $CPPFLAGS'
1871 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1872 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1873 ac_compiler_gnu=$ac_cv_c_compiler_gnu
1874 if test -n "$ac_tool_prefix"; then
1875   for ac_prog in $pgac_cc_list
1876   do
1877     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
1878 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
1879 echo "$as_me:$LINENO: checking for $ac_word" >&5
1880 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1881 if test "${ac_cv_prog_CC+set}" = set; then
1882   echo $ECHO_N "(cached) $ECHO_C" >&6
1883 else
1884   if test -n "$CC"; then
1885   ac_cv_prog_CC="$CC" # Let the user override the test.
1886 else
1887 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1888 for as_dir in $PATH
1889 do
1890   IFS=$as_save_IFS
1891   test -z "$as_dir" && as_dir=.
1892   for ac_exec_ext in '' $ac_executable_extensions; do
1893   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1894     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
1895     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1896     break 2
1897   fi
1898 done
1899 done
1900
1901 fi
1902 fi
1903 CC=$ac_cv_prog_CC
1904 if test -n "$CC"; then
1905   echo "$as_me:$LINENO: result: $CC" >&5
1906 echo "${ECHO_T}$CC" >&6
1907 else
1908   echo "$as_me:$LINENO: result: no" >&5
1909 echo "${ECHO_T}no" >&6
1910 fi
1911
1912     test -n "$CC" && break
1913   done
1914 fi
1915 if test -z "$CC"; then
1916   ac_ct_CC=$CC
1917   for ac_prog in $pgac_cc_list
1918 do
1919   # Extract the first word of "$ac_prog", so it can be a program name with args.
1920 set dummy $ac_prog; ac_word=$2
1921 echo "$as_me:$LINENO: checking for $ac_word" >&5
1922 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
1923 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1924   echo $ECHO_N "(cached) $ECHO_C" >&6
1925 else
1926   if test -n "$ac_ct_CC"; then
1927   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1928 else
1929 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1930 for as_dir in $PATH
1931 do
1932   IFS=$as_save_IFS
1933   test -z "$as_dir" && as_dir=.
1934   for ac_exec_ext in '' $ac_executable_extensions; do
1935   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
1936     ac_cv_prog_ac_ct_CC="$ac_prog"
1937     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1938     break 2
1939   fi
1940 done
1941 done
1942
1943 fi
1944 fi
1945 ac_ct_CC=$ac_cv_prog_ac_ct_CC
1946 if test -n "$ac_ct_CC"; then
1947   echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1948 echo "${ECHO_T}$ac_ct_CC" >&6
1949 else
1950   echo "$as_me:$LINENO: result: no" >&5
1951 echo "${ECHO_T}no" >&6
1952 fi
1953
1954   test -n "$ac_ct_CC" && break
1955 done
1956
1957   CC=$ac_ct_CC
1958 fi
1959
1960
1961 test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH" >&5
1962 echo "$as_me: error: no acceptable C compiler found in \$PATH" >&2;}
1963    { (exit 1); exit 1; }; }
1964
1965 # Provide some information about the compiler.
1966 echo "$as_me:$LINENO:" \
1967      "checking for C compiler version" >&5
1968 ac_compiler=`set X $ac_compile; echo $2`
1969 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
1970   (eval $ac_compiler --version </dev/null >&5) 2>&5
1971   ac_status=$?
1972   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1973   (exit $ac_status); }
1974 { (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
1975   (eval $ac_compiler -v </dev/null >&5) 2>&5
1976   ac_status=$?
1977   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1978   (exit $ac_status); }
1979 { (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
1980   (eval $ac_compiler -V </dev/null >&5) 2>&5
1981   ac_status=$?
1982   echo "$as_me:$LINENO: \$? = $ac_status" >&5
1983   (exit $ac_status); }
1984
1985 cat >conftest.$ac_ext <<_ACEOF
1986 #line $LINENO "configure"
1987 #include "confdefs.h"
1988
1989 #ifdef F77_DUMMY_MAIN
1990 #  ifdef __cplusplus
1991      extern "C"
1992 #  endif
1993    int F77_DUMMY_MAIN() { return 1; }
1994 #endif
1995 int
1996 main ()
1997 {
1998
1999   ;
2000   return 0;
2001 }
2002 _ACEOF
2003 ac_clean_files_save=$ac_clean_files
2004 ac_clean_files="$ac_clean_files a.out a.exe"
2005 # Try to create an executable without -o first, disregard a.out.
2006 # It will help us diagnose broken compilers, and finding out an intuition
2007 # of exeext.
2008 echo "$as_me:$LINENO: checking for C compiler default output" >&5
2009 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
2010 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2011 if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
2012   (eval $ac_link_default) 2>&5
2013   ac_status=$?
2014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2015   (exit $ac_status); }; then
2016   # Find the output, starting from the most likely.  This scheme is
2017 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
2018 # resort.
2019
2020 # Be careful to initialize this variable, since it used to be cached.
2021 # Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
2022 ac_cv_exeext=
2023 for ac_file in `ls a_out.exe a.exe conftest.exe 2>/dev/null;
2024                 ls a.out conftest 2>/dev/null;
2025                 ls a.* conftest.* 2>/dev/null`; do
2026   case $ac_file in
2027     *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb | *.xSYM ) ;;
2028     a.out ) # We found the default executable, but exeext='' is most
2029             # certainly right.
2030             break;;
2031     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2032           # FIXME: I believe we export ac_cv_exeext for Libtool --akim.
2033           export ac_cv_exeext
2034           break;;
2035     * ) break;;
2036   esac
2037 done
2038 else
2039   echo "$as_me: failed program was:" >&5
2040 cat conftest.$ac_ext >&5
2041 { { echo "$as_me:$LINENO: error: C compiler cannot create executables" >&5
2042 echo "$as_me: error: C compiler cannot create executables" >&2;}
2043    { (exit 77); exit 77; }; }
2044 fi
2045
2046 ac_exeext=$ac_cv_exeext
2047 echo "$as_me:$LINENO: result: $ac_file" >&5
2048 echo "${ECHO_T}$ac_file" >&6
2049
2050 # Check the compiler produces executables we can run.  If not, either
2051 # the compiler is broken, or we cross compile.
2052 echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2053 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
2054 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2055 # If not cross compiling, check that we can run a simple program.
2056 if test "$cross_compiling" != yes; then
2057   if { ac_try='./$ac_file'
2058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2059   (eval $ac_try) 2>&5
2060   ac_status=$?
2061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2062   (exit $ac_status); }; }; then
2063     cross_compiling=no
2064   else
2065     if test "$cross_compiling" = maybe; then
2066         cross_compiling=yes
2067     else
2068         { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2069 If you meant to cross compile, use \`--host'." >&5
2070 echo "$as_me: error: cannot run C compiled programs.
2071 If you meant to cross compile, use \`--host'." >&2;}
2072    { (exit 1); exit 1; }; }
2073     fi
2074   fi
2075 fi
2076 echo "$as_me:$LINENO: result: yes" >&5
2077 echo "${ECHO_T}yes" >&6
2078
2079 rm -f a.out a.exe conftest$ac_cv_exeext
2080 ac_clean_files=$ac_clean_files_save
2081 # Check the compiler produces executables we can run.  If not, either
2082 # the compiler is broken, or we cross compile.
2083 echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2084 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
2085 echo "$as_me:$LINENO: result: $cross_compiling" >&5
2086 echo "${ECHO_T}$cross_compiling" >&6
2087
2088 echo "$as_me:$LINENO: checking for suffix of executables" >&5
2089 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
2090 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2091   (eval $ac_link) 2>&5
2092   ac_status=$?
2093   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2094   (exit $ac_status); }; then
2095   # If both `conftest.exe' and `conftest' are `present' (well, observable)
2096 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
2097 # work properly (i.e., refer to `conftest.exe'), while it won't with
2098 # `rm'.
2099 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
2100   case $ac_file in
2101     *.$ac_ext | *.o | *.obj | *.xcoff | *.tds | *.d | *.pdb ) ;;
2102     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2103           export ac_cv_exeext
2104           break;;
2105     * ) break;;
2106   esac
2107 done
2108 else
2109   { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link" >&5
2110 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link" >&2;}
2111    { (exit 1); exit 1; }; }
2112 fi
2113
2114 rm -f conftest$ac_cv_exeext
2115 echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2116 echo "${ECHO_T}$ac_cv_exeext" >&6
2117
2118 rm -f conftest.$ac_ext
2119 EXEEXT=$ac_cv_exeext
2120 ac_exeext=$EXEEXT
2121 echo "$as_me:$LINENO: checking for suffix of object files" >&5
2122 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
2123 if test "${ac_cv_objext+set}" = set; then
2124   echo $ECHO_N "(cached) $ECHO_C" >&6
2125 else
2126   cat >conftest.$ac_ext <<_ACEOF
2127 #line $LINENO "configure"
2128 #include "confdefs.h"
2129
2130 #ifdef F77_DUMMY_MAIN
2131 #  ifdef __cplusplus
2132      extern "C"
2133 #  endif
2134    int F77_DUMMY_MAIN() { return 1; }
2135 #endif
2136 int
2137 main ()
2138 {
2139
2140   ;
2141   return 0;
2142 }
2143 _ACEOF
2144 rm -f conftest.o conftest.obj
2145 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2146   (eval $ac_compile) 2>&5
2147   ac_status=$?
2148   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2149   (exit $ac_status); }; then
2150   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
2151   case $ac_file in
2152     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb ) ;;
2153     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2154        break;;
2155   esac
2156 done
2157 else
2158   echo "$as_me: failed program was:" >&5
2159 cat conftest.$ac_ext >&5
2160 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile" >&5
2161 echo "$as_me: error: cannot compute suffix of object files: cannot compile" >&2;}
2162    { (exit 1); exit 1; }; }
2163 fi
2164
2165 rm -f conftest.$ac_cv_objext conftest.$ac_ext
2166 fi
2167 echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2168 echo "${ECHO_T}$ac_cv_objext" >&6
2169 OBJEXT=$ac_cv_objext
2170 ac_objext=$OBJEXT
2171 echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2172 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
2173 if test "${ac_cv_c_compiler_gnu+set}" = set; then
2174   echo $ECHO_N "(cached) $ECHO_C" >&6
2175 else
2176   cat >conftest.$ac_ext <<_ACEOF
2177 #line $LINENO "configure"
2178 #include "confdefs.h"
2179
2180 #ifdef F77_DUMMY_MAIN
2181 #  ifdef __cplusplus
2182      extern "C"
2183 #  endif
2184    int F77_DUMMY_MAIN() { return 1; }
2185 #endif
2186 int
2187 main ()
2188 {
2189 #ifndef __GNUC__
2190        choke me
2191 #endif
2192
2193   ;
2194   return 0;
2195 }
2196 _ACEOF
2197 rm -f conftest.$ac_objext
2198 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2199   (eval $ac_compile) 2>&5
2200   ac_status=$?
2201   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2202   (exit $ac_status); } &&
2203          { ac_try='test -s conftest.$ac_objext'
2204   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2205   (eval $ac_try) 2>&5
2206   ac_status=$?
2207   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2208   (exit $ac_status); }; }; then
2209   ac_compiler_gnu=yes
2210 else
2211   echo "$as_me: failed program was:" >&5
2212 cat conftest.$ac_ext >&5
2213 ac_compiler_gnu=no
2214 fi
2215 rm -f conftest.$ac_objext conftest.$ac_ext
2216 ac_cv_c_compiler_gnu=$ac_compiler_gnu
2217
2218 fi
2219 echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2220 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
2221 GCC=`test $ac_compiler_gnu = yes && echo yes`
2222 ac_test_CFLAGS=${CFLAGS+set}
2223 ac_save_CFLAGS=$CFLAGS
2224 CFLAGS="-g"
2225 echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2226 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
2227 if test "${ac_cv_prog_cc_g+set}" = set; then
2228   echo $ECHO_N "(cached) $ECHO_C" >&6
2229 else
2230   cat >conftest.$ac_ext <<_ACEOF
2231 #line $LINENO "configure"
2232 #include "confdefs.h"
2233
2234 #ifdef F77_DUMMY_MAIN
2235 #  ifdef __cplusplus
2236      extern "C"
2237 #  endif
2238    int F77_DUMMY_MAIN() { return 1; }
2239 #endif
2240 int
2241 main ()
2242 {
2243
2244   ;
2245   return 0;
2246 }
2247 _ACEOF
2248 rm -f conftest.$ac_objext
2249 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2250   (eval $ac_compile) 2>&5
2251   ac_status=$?
2252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2253   (exit $ac_status); } &&
2254          { ac_try='test -s conftest.$ac_objext'
2255   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2256   (eval $ac_try) 2>&5
2257   ac_status=$?
2258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2259   (exit $ac_status); }; }; then
2260   ac_cv_prog_cc_g=yes
2261 else
2262   echo "$as_me: failed program was:" >&5
2263 cat conftest.$ac_ext >&5
2264 ac_cv_prog_cc_g=no
2265 fi
2266 rm -f conftest.$ac_objext conftest.$ac_ext
2267 fi
2268 echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2269 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
2270 if test "$ac_test_CFLAGS" = set; then
2271   CFLAGS=$ac_save_CFLAGS
2272 elif test $ac_cv_prog_cc_g = yes; then
2273   if test "$GCC" = yes; then
2274     CFLAGS="-g -O2"
2275   else
2276     CFLAGS="-g"
2277   fi
2278 else
2279   if test "$GCC" = yes; then
2280     CFLAGS="-O2"
2281   else
2282     CFLAGS=
2283   fi
2284 fi
2285 # Some people use a C++ compiler to compile C.  Since we use `exit',
2286 # in C++ we need to declare it.  In case someone uses the same compiler
2287 # for both compiling C and C++ we need to have the C++ compiler decide
2288 # the declaration of exit, since it's the most demanding environment.
2289 cat >conftest.$ac_ext <<_ACEOF
2290 #ifndef __cplusplus
2291   choke me
2292 #endif
2293 _ACEOF
2294 rm -f conftest.$ac_objext
2295 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2296   (eval $ac_compile) 2>&5
2297   ac_status=$?
2298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2299   (exit $ac_status); } &&
2300          { ac_try='test -s conftest.$ac_objext'
2301   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2302   (eval $ac_try) 2>&5
2303   ac_status=$?
2304   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2305   (exit $ac_status); }; }; then
2306   for ac_declaration in \
2307    ''\
2308    '#include <stdlib.h>' \
2309    'extern "C" void std::exit (int) throw (); using std::exit;' \
2310    'extern "C" void std::exit (int); using std::exit;' \
2311    'extern "C" void exit (int) throw ();' \
2312    'extern "C" void exit (int);' \
2313    'void exit (int);'
2314 do
2315   cat >conftest.$ac_ext <<_ACEOF
2316 #line $LINENO "configure"
2317 #include "confdefs.h"
2318 #include <stdlib.h>
2319 $ac_declaration
2320 #ifdef F77_DUMMY_MAIN
2321 #  ifdef __cplusplus
2322      extern "C"
2323 #  endif
2324    int F77_DUMMY_MAIN() { return 1; }
2325 #endif
2326 int
2327 main ()
2328 {
2329 exit (42);
2330   ;
2331   return 0;
2332 }
2333 _ACEOF
2334 rm -f conftest.$ac_objext
2335 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2336   (eval $ac_compile) 2>&5
2337   ac_status=$?
2338   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2339   (exit $ac_status); } &&
2340          { ac_try='test -s conftest.$ac_objext'
2341   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2342   (eval $ac_try) 2>&5
2343   ac_status=$?
2344   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2345   (exit $ac_status); }; }; then
2346   :
2347 else
2348   echo "$as_me: failed program was:" >&5
2349 cat conftest.$ac_ext >&5
2350 continue
2351 fi
2352 rm -f conftest.$ac_objext conftest.$ac_ext
2353   cat >conftest.$ac_ext <<_ACEOF
2354 #line $LINENO "configure"
2355 #include "confdefs.h"
2356 $ac_declaration
2357 #ifdef F77_DUMMY_MAIN
2358 #  ifdef __cplusplus
2359      extern "C"
2360 #  endif
2361    int F77_DUMMY_MAIN() { return 1; }
2362 #endif
2363 int
2364 main ()
2365 {
2366 exit (42);
2367   ;
2368   return 0;
2369 }
2370 _ACEOF
2371 rm -f conftest.$ac_objext
2372 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2373   (eval $ac_compile) 2>&5
2374   ac_status=$?
2375   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2376   (exit $ac_status); } &&
2377          { ac_try='test -s conftest.$ac_objext'
2378   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2379   (eval $ac_try) 2>&5
2380   ac_status=$?
2381   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2382   (exit $ac_status); }; }; then
2383   break
2384 else
2385   echo "$as_me: failed program was:" >&5
2386 cat conftest.$ac_ext >&5
2387 fi
2388 rm -f conftest.$ac_objext conftest.$ac_ext
2389 done
2390 rm -f conftest*
2391 if test -n "$ac_declaration"; then
2392   echo '#ifdef __cplusplus' >>confdefs.h
2393   echo $ac_declaration      >>confdefs.h
2394   echo '#endif'             >>confdefs.h
2395 fi
2396
2397 else
2398   echo "$as_me: failed program was:" >&5
2399 cat conftest.$ac_ext >&5
2400 fi
2401 rm -f conftest.$ac_objext conftest.$ac_ext
2402 ac_ext=c
2403 ac_cpp='$CPP $CPPFLAGS'
2404 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2405 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2406 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2407
2408
2409 unset CFLAGS
2410
2411 #
2412 # Read the template
2413 #
2414 . "$srcdir/src/template/$template" || exit
2415
2416 # CFLAGS are selected so:
2417 # If the user specifies something in the environment, that is used.
2418 # else:  If the template file set something, that is used.
2419 # else:  If the compiler is GCC, then we use -O2.
2420 # else:  If the compiler is something else, then we use -0.
2421
2422 if test "$ac_env_CFLAGS_set" = set; then
2423   CFLAGS=$ac_env_CFLAGS_value
2424 elif test "${CFLAGS+set}" = set; then
2425   : # (keep what template set)
2426 elif test "$GCC" = yes; then
2427   CFLAGS="-O2"
2428 else
2429   # if the user selected debug mode, don't use -O
2430   if test "$enable_debug" != yes; then
2431     CFLAGS="-O"
2432   fi
2433 fi
2434
2435 if test "$GCC" = yes; then
2436   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
2437
2438   # Some versions of GCC support some additional useful warning flags.
2439   # Check whether they are supported, and add them to CFLAGS if so.
2440   echo "$as_me:$LINENO: checking if $CC supports -Wdeclaration-after-statement" >&5
2441 echo $ECHO_N "checking if $CC supports -Wdeclaration-after-statement... $ECHO_C" >&6
2442 pgac_save_CFLAGS=$CFLAGS
2443 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
2444 cat >conftest.$ac_ext <<_ACEOF
2445 #line $LINENO "configure"
2446 #include "confdefs.h"
2447
2448 #ifdef F77_DUMMY_MAIN
2449 #  ifdef __cplusplus
2450      extern "C"
2451 #  endif
2452    int F77_DUMMY_MAIN() { return 1; }
2453 #endif
2454 int
2455 main ()
2456 {
2457
2458   ;
2459   return 0;
2460 }
2461 _ACEOF
2462 rm -f conftest.$ac_objext
2463 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2464   (eval $ac_compile) 2>&5
2465   ac_status=$?
2466   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2467   (exit $ac_status); } &&
2468          { ac_try='test -s conftest.$ac_objext'
2469   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2470   (eval $ac_try) 2>&5
2471   ac_status=$?
2472   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2473   (exit $ac_status); }; }; then
2474   echo "$as_me:$LINENO: result: yes" >&5
2475 echo "${ECHO_T}yes" >&6
2476 else
2477   echo "$as_me: failed program was:" >&5
2478 cat conftest.$ac_ext >&5
2479 CFLAGS="$pgac_save_CFLAGS"
2480                     echo "$as_me:$LINENO: result: no" >&5
2481 echo "${ECHO_T}no" >&6
2482 fi
2483 rm -f conftest.$ac_objext conftest.$ac_ext
2484
2485   echo "$as_me:$LINENO: checking if $CC supports -Wold-style-definition" >&5
2486 echo $ECHO_N "checking if $CC supports -Wold-style-definition... $ECHO_C" >&6
2487 pgac_save_CFLAGS=$CFLAGS
2488 CFLAGS="$pgac_save_CFLAGS -Wold-style-definition"
2489 cat >conftest.$ac_ext <<_ACEOF
2490 #line $LINENO "configure"
2491 #include "confdefs.h"
2492
2493 #ifdef F77_DUMMY_MAIN
2494 #  ifdef __cplusplus
2495      extern "C"
2496 #  endif
2497    int F77_DUMMY_MAIN() { return 1; }
2498 #endif
2499 int
2500 main ()
2501 {
2502
2503   ;
2504   return 0;
2505 }
2506 _ACEOF
2507 rm -f conftest.$ac_objext
2508 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2509   (eval $ac_compile) 2>&5
2510   ac_status=$?
2511   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2512   (exit $ac_status); } &&
2513          { ac_try='test -s conftest.$ac_objext'
2514   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2515   (eval $ac_try) 2>&5
2516   ac_status=$?
2517   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2518   (exit $ac_status); }; }; then
2519   echo "$as_me:$LINENO: result: yes" >&5
2520 echo "${ECHO_T}yes" >&6
2521 else
2522   echo "$as_me: failed program was:" >&5
2523 cat conftest.$ac_ext >&5
2524 CFLAGS="$pgac_save_CFLAGS"
2525                     echo "$as_me:$LINENO: result: no" >&5
2526 echo "${ECHO_T}no" >&6
2527 fi
2528 rm -f conftest.$ac_objext conftest.$ac_ext
2529
2530   echo "$as_me:$LINENO: checking if $CC supports -Wendif-labels" >&5
2531 echo $ECHO_N "checking if $CC supports -Wendif-labels... $ECHO_C" >&6
2532 pgac_save_CFLAGS=$CFLAGS
2533 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
2534 cat >conftest.$ac_ext <<_ACEOF
2535 #line $LINENO "configure"
2536 #include "confdefs.h"
2537
2538 #ifdef F77_DUMMY_MAIN
2539 #  ifdef __cplusplus
2540      extern "C"
2541 #  endif
2542    int F77_DUMMY_MAIN() { return 1; }
2543 #endif
2544 int
2545 main ()
2546 {
2547
2548   ;
2549   return 0;
2550 }
2551 _ACEOF
2552 rm -f conftest.$ac_objext
2553 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2554   (eval $ac_compile) 2>&5
2555   ac_status=$?
2556   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2557   (exit $ac_status); } &&
2558          { ac_try='test -s conftest.$ac_objext'
2559   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2560   (eval $ac_try) 2>&5
2561   ac_status=$?
2562   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2563   (exit $ac_status); }; }; then
2564   echo "$as_me:$LINENO: result: yes" >&5
2565 echo "${ECHO_T}yes" >&6
2566 else
2567   echo "$as_me: failed program was:" >&5
2568 cat conftest.$ac_ext >&5
2569 CFLAGS="$pgac_save_CFLAGS"
2570                     echo "$as_me:$LINENO: result: no" >&5
2571 echo "${ECHO_T}no" >&6
2572 fi
2573 rm -f conftest.$ac_objext conftest.$ac_ext
2574
2575
2576   # Disable strict-aliasing rules; needed for gcc 3.3+
2577   echo "$as_me:$LINENO: checking if $CC supports -fno-strict-aliasing" >&5
2578 echo $ECHO_N "checking if $CC supports -fno-strict-aliasing... $ECHO_C" >&6
2579 pgac_save_CFLAGS=$CFLAGS
2580 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
2581 cat >conftest.$ac_ext <<_ACEOF
2582 #line $LINENO "configure"
2583 #include "confdefs.h"
2584
2585 #ifdef F77_DUMMY_MAIN
2586 #  ifdef __cplusplus
2587      extern "C"
2588 #  endif
2589    int F77_DUMMY_MAIN() { return 1; }
2590 #endif
2591 int
2592 main ()
2593 {
2594
2595   ;
2596   return 0;
2597 }
2598 _ACEOF
2599 rm -f conftest.$ac_objext
2600 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2601   (eval $ac_compile) 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   echo "$as_me:$LINENO: result: yes" >&5
2612 echo "${ECHO_T}yes" >&6
2613 else
2614   echo "$as_me: failed program was:" >&5
2615 cat conftest.$ac_ext >&5
2616 CFLAGS="$pgac_save_CFLAGS"
2617                     echo "$as_me:$LINENO: result: no" >&5
2618 echo "${ECHO_T}no" >&6
2619 fi
2620 rm -f conftest.$ac_objext conftest.$ac_ext
2621
2622 fi
2623
2624 # supply -g if --enable-debug
2625 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
2626   CFLAGS="$CFLAGS -g"
2627 fi
2628
2629 { echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
2630 echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
2631
2632 # We already have this in Makefile.win32, but configure needs it too
2633 if test "$PORTNAME" = "win32"; then
2634   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
2635 fi
2636
2637 # Check if the compiler still works with the template settings
2638 echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
2639 echo $ECHO_N "checking whether the C compiler still works... $ECHO_C" >&6
2640
2641 cat >conftest.$ac_ext <<_ACEOF
2642 #line $LINENO "configure"
2643 #include "confdefs.h"
2644
2645 #ifdef F77_DUMMY_MAIN
2646 #  ifdef __cplusplus
2647      extern "C"
2648 #  endif
2649    int F77_DUMMY_MAIN() { return 1; }
2650 #endif
2651 int
2652 main ()
2653 {
2654 return 0;
2655   ;
2656   return 0;
2657 }
2658 _ACEOF
2659 rm -f conftest.$ac_objext conftest$ac_exeext
2660 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
2661   (eval $ac_link) 2>&5
2662   ac_status=$?
2663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2664   (exit $ac_status); } &&
2665          { ac_try='test -s conftest$ac_exeext'
2666   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2667   (eval $ac_try) 2>&5
2668   ac_status=$?
2669   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2670   (exit $ac_status); }; }; then
2671   echo "$as_me:$LINENO: result: yes" >&5
2672 echo "${ECHO_T}yes" >&6
2673 else
2674   echo "$as_me: failed program was:" >&5
2675 cat conftest.$ac_ext >&5
2676 echo "$as_me:$LINENO: result: no" >&5
2677 echo "${ECHO_T}no" >&6
2678    { { echo "$as_me:$LINENO: error: cannot proceed" >&5
2679 echo "$as_me: error: cannot proceed" >&2;}
2680    { (exit 1); exit 1; }; }
2681 fi
2682 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
2683
2684 # Defend against gcc -ffast-math
2685 if test "$GCC" = yes; then
2686 cat >conftest.$ac_ext <<_ACEOF
2687 #line $LINENO "configure"
2688 #include "confdefs.h"
2689
2690 #ifdef F77_DUMMY_MAIN
2691 #  ifdef __cplusplus
2692      extern "C"
2693 #  endif
2694    int F77_DUMMY_MAIN() { return 1; }
2695 #endif
2696 int
2697 main ()
2698 {
2699 #ifdef __FAST_MATH__
2700 choke me
2701 #endif
2702   ;
2703   return 0;
2704 }
2705 _ACEOF
2706 rm -f conftest.$ac_objext
2707 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
2708   (eval $ac_compile) 2>&5
2709   ac_status=$?
2710   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2711   (exit $ac_status); } &&
2712          { ac_try='test -s conftest.$ac_objext'
2713   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
2714   (eval $ac_try) 2>&5
2715   ac_status=$?
2716   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2717   (exit $ac_status); }; }; then
2718   :
2719 else
2720   echo "$as_me: failed program was:" >&5
2721 cat conftest.$ac_ext >&5
2722 { { echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
2723 echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
2724    { (exit 1); exit 1; }; }
2725 fi
2726 rm -f conftest.$ac_objext conftest.$ac_ext
2727 fi
2728
2729 ac_ext=c
2730 ac_cpp='$CPP $CPPFLAGS'
2731 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2732 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2733 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2734 echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2735 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
2736 # On Suns, sometimes $CPP names a directory.
2737 if test -n "$CPP" && test -d "$CPP"; then
2738   CPP=
2739 fi
2740 if test -z "$CPP"; then
2741   if test "${ac_cv_prog_CPP+set}" = set; then
2742   echo $ECHO_N "(cached) $ECHO_C" >&6
2743 else
2744       # Double quotes because CPP needs to be expanded
2745     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2746     do
2747       ac_preproc_ok=false
2748 for ac_c_preproc_warn_flag in '' yes
2749 do
2750   # Use a header file that comes with gcc, so configuring glibc
2751   # with a fresh cross-compiler works.
2752   # On the NeXT, cc -E runs the code through the compiler's parser,
2753   # not just through cpp. "Syntax error" is here to catch this case.
2754   cat >conftest.$ac_ext <<_ACEOF
2755 #line $LINENO "configure"
2756 #include "confdefs.h"
2757 #include <assert.h>
2758                      Syntax error
2759 _ACEOF
2760 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2761   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2762   ac_status=$?
2763   egrep -v '^ *\+' conftest.er1 >conftest.err
2764   rm -f conftest.er1
2765   cat conftest.err >&5
2766   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2767   (exit $ac_status); } >/dev/null; then
2768   if test -s conftest.err; then
2769     ac_cpp_err=$ac_c_preproc_warn_flag
2770   else
2771     ac_cpp_err=
2772   fi
2773 else
2774   ac_cpp_err=yes
2775 fi
2776 if test -z "$ac_cpp_err"; then
2777   :
2778 else
2779   echo "$as_me: failed program was:" >&5
2780   cat conftest.$ac_ext >&5
2781   # Broken: fails on valid input.
2782 continue
2783 fi
2784 rm -f conftest.err conftest.$ac_ext
2785
2786   # OK, works on sane cases.  Now check whether non-existent headers
2787   # can be detected and how.
2788   cat >conftest.$ac_ext <<_ACEOF
2789 #line $LINENO "configure"
2790 #include "confdefs.h"
2791 #include <ac_nonexistent.h>
2792 _ACEOF
2793 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2794   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2795   ac_status=$?
2796   egrep -v '^ *\+' conftest.er1 >conftest.err
2797   rm -f conftest.er1
2798   cat conftest.err >&5
2799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2800   (exit $ac_status); } >/dev/null; then
2801   if test -s conftest.err; then
2802     ac_cpp_err=$ac_c_preproc_warn_flag
2803   else
2804     ac_cpp_err=
2805   fi
2806 else
2807   ac_cpp_err=yes
2808 fi
2809 if test -z "$ac_cpp_err"; then
2810   # Broken: success on invalid input.
2811 continue
2812 else
2813   echo "$as_me: failed program was:" >&5
2814   cat conftest.$ac_ext >&5
2815   # Passes both tests.
2816 ac_preproc_ok=:
2817 break
2818 fi
2819 rm -f conftest.err conftest.$ac_ext
2820
2821 done
2822 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2823 rm -f conftest.err conftest.$ac_ext
2824 if $ac_preproc_ok; then
2825   break
2826 fi
2827
2828     done
2829     ac_cv_prog_CPP=$CPP
2830
2831 fi
2832   CPP=$ac_cv_prog_CPP
2833 else
2834   ac_cv_prog_CPP=$CPP
2835 fi
2836 echo "$as_me:$LINENO: result: $CPP" >&5
2837 echo "${ECHO_T}$CPP" >&6
2838 ac_preproc_ok=false
2839 for ac_c_preproc_warn_flag in '' yes
2840 do
2841   # Use a header file that comes with gcc, so configuring glibc
2842   # with a fresh cross-compiler works.
2843   # On the NeXT, cc -E runs the code through the compiler's parser,
2844   # not just through cpp. "Syntax error" is here to catch this case.
2845   cat >conftest.$ac_ext <<_ACEOF
2846 #line $LINENO "configure"
2847 #include "confdefs.h"
2848 #include <assert.h>
2849                      Syntax error
2850 _ACEOF
2851 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2852   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2853   ac_status=$?
2854   egrep -v '^ *\+' conftest.er1 >conftest.err
2855   rm -f conftest.er1
2856   cat conftest.err >&5
2857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2858   (exit $ac_status); } >/dev/null; then
2859   if test -s conftest.err; then
2860     ac_cpp_err=$ac_c_preproc_warn_flag
2861   else
2862     ac_cpp_err=
2863   fi
2864 else
2865   ac_cpp_err=yes
2866 fi
2867 if test -z "$ac_cpp_err"; then
2868   :
2869 else
2870   echo "$as_me: failed program was:" >&5
2871   cat conftest.$ac_ext >&5
2872   # Broken: fails on valid input.
2873 continue
2874 fi
2875 rm -f conftest.err conftest.$ac_ext
2876
2877   # OK, works on sane cases.  Now check whether non-existent headers
2878   # can be detected and how.
2879   cat >conftest.$ac_ext <<_ACEOF
2880 #line $LINENO "configure"
2881 #include "confdefs.h"
2882 #include <ac_nonexistent.h>
2883 _ACEOF
2884 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
2885   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
2886   ac_status=$?
2887   egrep -v '^ *\+' conftest.er1 >conftest.err
2888   rm -f conftest.er1
2889   cat conftest.err >&5
2890   echo "$as_me:$LINENO: \$? = $ac_status" >&5
2891   (exit $ac_status); } >/dev/null; then
2892   if test -s conftest.err; then
2893     ac_cpp_err=$ac_c_preproc_warn_flag
2894   else
2895     ac_cpp_err=
2896   fi
2897 else
2898   ac_cpp_err=yes
2899 fi
2900 if test -z "$ac_cpp_err"; then
2901   # Broken: success on invalid input.
2902 continue
2903 else
2904   echo "$as_me: failed program was:" >&5
2905   cat conftest.$ac_ext >&5
2906   # Passes both tests.
2907 ac_preproc_ok=:
2908 break
2909 fi
2910 rm -f conftest.err conftest.$ac_ext
2911
2912 done
2913 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2914 rm -f conftest.err conftest.$ac_ext
2915 if $ac_preproc_ok; then
2916   :
2917 else
2918   { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check" >&5
2919 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
2920    { (exit 1); exit 1; }; }
2921 fi
2922
2923 ac_ext=c
2924 ac_cpp='$CPP $CPPFLAGS'
2925 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2926 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2927 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2928
2929
2930
2931 # Create compiler version string
2932 if test x"$GCC" = x"yes" ; then
2933   cc_string="GCC `${CC} --version | sed q`"
2934 else
2935   cc_string=$CC
2936 fi
2937
2938 cat >>confdefs.h <<_ACEOF
2939 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string"
2940 _ACEOF
2941
2942
2943
2944 #
2945 # Set up TAS assembly code if needed; the template file has now had its
2946 # chance to request this.
2947 #
2948 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
2949
2950
2951 if test "$need_tas" = yes ; then
2952   TAS=tas.o
2953 else
2954   TAS=""
2955 fi
2956
2957
2958
2959 #
2960 # Automatic dependency tracking
2961 #
2962
2963
2964 # Check whether --enable-depend or --disable-depend was given.
2965 if test "${enable_depend+set}" = set; then
2966   enableval="$enable_depend"
2967
2968   case $enableval in
2969     yes)
2970       autodepend=yes
2971       ;;
2972     no)
2973       :
2974       ;;
2975     *)
2976       { { echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
2977 echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
2978    { (exit 1); exit 1; }; }
2979       ;;
2980   esac
2981
2982 else
2983   enable_depend=no
2984
2985 fi;
2986
2987
2988
2989
2990 #
2991 # Enable assert checks
2992 #
2993
2994
2995 # Check whether --enable-cassert or --disable-cassert was given.
2996 if test "${enable_cassert+set}" = set; then
2997   enableval="$enable_cassert"
2998
2999   case $enableval in
3000     yes)
3001
3002 cat >>confdefs.h <<\_ACEOF
3003 #define USE_ASSERT_CHECKING 1
3004 _ACEOF
3005
3006       ;;
3007     no)
3008       :
3009       ;;
3010     *)
3011       { { echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
3012 echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
3013    { (exit 1); exit 1; }; }
3014       ;;
3015   esac
3016
3017 else
3018   enable_cassert=no
3019
3020 fi;
3021
3022
3023
3024 #
3025 # Include directories
3026 #
3027 ac_save_IFS=$IFS
3028 IFS="${IFS}${PATH_SEPARATOR}"
3029 # SRCH_INC comes from the template file
3030 for dir in $with_includes $SRCH_INC; do
3031   if test -d "$dir"; then
3032     INCLUDES="$INCLUDES -I$dir"
3033   else
3034     { echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
3035 echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
3036   fi
3037 done
3038 IFS=$ac_save_IFS
3039
3040
3041
3042 #
3043 # Library directories
3044 #
3045 ac_save_IFS=$IFS
3046 IFS="${IFS}${PATH_SEPARATOR}"
3047 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
3048 for dir in $LIBRARY_DIRS $SRCH_LIB; do
3049   if test -d "$dir"; then
3050     LIBDIRS="$LIBDIRS -L$dir"
3051   else
3052     { echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
3053 echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
3054   fi
3055 done
3056 IFS=$ac_save_IFS
3057
3058 #
3059 # Enable thread-safe client libraries
3060 #
3061 echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
3062 echo $ECHO_N "checking allow thread-safe client libraries... $ECHO_C" >&6
3063
3064
3065 # Check whether --enable-thread-safety or --disable-thread-safety was given.
3066 if test "${enable_thread_safety+set}" = set; then
3067   enableval="$enable_thread_safety"
3068
3069   case $enableval in
3070     yes)
3071       :
3072       ;;
3073     no)
3074       :
3075       ;;
3076     *)
3077       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
3078 echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
3079    { (exit 1); exit 1; }; }
3080       ;;
3081   esac
3082
3083 else
3084   enable_thread_safety=no
3085
3086 fi;
3087
3088
3089
3090 # Check whether --enable-thread-safety-force or --disable-thread-safety-force was given.
3091 if test "${enable_thread_safety_force+set}" = set; then
3092   enableval="$enable_thread_safety_force"
3093
3094   case $enableval in
3095     yes)
3096       :
3097       ;;
3098     no)
3099       :
3100       ;;
3101     *)
3102       { { echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety-force option" >&5
3103 echo "$as_me: error: no argument expected for --enable-thread-safety-force option" >&2;}
3104    { (exit 1); exit 1; }; }
3105       ;;
3106   esac
3107
3108 else
3109   enable_thread_safety_force=no
3110
3111 fi;
3112
3113 if test "$enable_thread_safety" = yes -o \
3114         "$enable_thread_safety_force" = yes; then
3115   enable_thread_safety="yes"    # for 'force'
3116
3117 cat >>confdefs.h <<\_ACEOF
3118 #define ENABLE_THREAD_SAFETY 1
3119 _ACEOF
3120
3121 fi
3122 echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
3123 echo "${ECHO_T}$enable_thread_safety" >&6
3124
3125
3126 #
3127 # Optionally build Tcl modules (PL/Tcl)
3128 #
3129 echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
3130 echo $ECHO_N "checking whether to build with Tcl... $ECHO_C" >&6
3131
3132
3133
3134 # Check whether --with-tcl or --without-tcl was given.
3135 if test "${with_tcl+set}" = set; then
3136   withval="$with_tcl"
3137
3138   case $withval in
3139     yes)
3140       :
3141       ;;
3142     no)
3143       :
3144       ;;
3145     *)
3146       { { echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
3147 echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
3148    { (exit 1); exit 1; }; }
3149       ;;
3150   esac
3151
3152 else
3153   with_tcl=no
3154
3155 fi;
3156
3157 echo "$as_me:$LINENO: result: $with_tcl" >&5
3158 echo "${ECHO_T}$with_tcl" >&6
3159
3160
3161 # We see if the path to the Tcl/Tk configuration scripts is specified.
3162 # This will override the use of tclsh to find the paths to search.
3163
3164
3165
3166
3167 # Check whether --with-tclconfig or --without-tclconfig was given.
3168 if test "${with_tclconfig+set}" = set; then
3169   withval="$with_tclconfig"
3170
3171   case $withval in
3172     yes)
3173       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3174 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3175    { (exit 1); exit 1; }; }
3176       ;;
3177     no)
3178       { { echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
3179 echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
3180    { (exit 1); exit 1; }; }
3181       ;;
3182     *)
3183
3184       ;;
3185   esac
3186
3187 fi;
3188
3189
3190 #
3191 # Optionally build Perl modules (PL/Perl)
3192 #
3193 echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
3194 echo $ECHO_N "checking whether to build Perl modules... $ECHO_C" >&6
3195
3196
3197
3198 # Check whether --with-perl or --without-perl was given.
3199 if test "${with_perl+set}" = set; then
3200   withval="$with_perl"
3201
3202   case $withval in
3203     yes)
3204       :
3205       ;;
3206     no)
3207       :
3208       ;;
3209     *)
3210       { { echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
3211 echo "$as_me: error: no argument expected for --with-perl option" >&2;}
3212    { (exit 1); exit 1; }; }
3213       ;;
3214   esac
3215
3216 else
3217   with_perl=no
3218
3219 fi;
3220
3221 echo "$as_me:$LINENO: result: $with_perl" >&5
3222 echo "${ECHO_T}$with_perl" >&6
3223
3224
3225 #
3226 # Optionally build Python modules (PL/Python)
3227 #
3228 echo "$as_me:$LINENO: checking whether to build Python modules" >&5
3229 echo $ECHO_N "checking whether to build Python modules... $ECHO_C" >&6
3230
3231
3232
3233 # Check whether --with-python or --without-python was given.
3234 if test "${with_python+set}" = set; then
3235   withval="$with_python"
3236
3237   case $withval in
3238     yes)
3239       :
3240       ;;
3241     no)
3242       :
3243       ;;
3244     *)
3245       { { echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
3246 echo "$as_me: error: no argument expected for --with-python option" >&2;}
3247    { (exit 1); exit 1; }; }
3248       ;;
3249   esac
3250
3251 else
3252   with_python=no
3253
3254 fi;
3255
3256 echo "$as_me:$LINENO: result: $with_python" >&5
3257 echo "${ECHO_T}$with_python" >&6
3258
3259
3260 #
3261 # Kerberos 4
3262 #
3263 echo "$as_me:$LINENO: checking whether to build with Kerberos 4 support" >&5
3264 echo $ECHO_N "checking whether to build with Kerberos 4 support... $ECHO_C" >&6
3265
3266
3267
3268 # Check whether --with-krb4 or --without-krb4 was given.
3269 if test "${with_krb4+set}" = set; then
3270   withval="$with_krb4"
3271
3272   case $withval in
3273     yes)
3274
3275
3276 cat >>confdefs.h <<\_ACEOF
3277 #define KRB4 1
3278 _ACEOF
3279
3280   krb_srvtab="/etc/srvtab"
3281
3282       ;;
3283     no)
3284       :
3285       ;;
3286     *)
3287       { { echo "$as_me:$LINENO: error: no argument expected for --with-krb4 option" >&5
3288 echo "$as_me: error: no argument expected for --with-krb4 option" >&2;}
3289    { (exit 1); exit 1; }; }
3290       ;;
3291   esac
3292
3293 else
3294   with_krb4=no
3295
3296 fi;
3297
3298 echo "$as_me:$LINENO: result: $with_krb4" >&5
3299 echo "${ECHO_T}$with_krb4" >&6
3300
3301
3302
3303 #
3304 # Kerberos 5
3305 #
3306 echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
3307 echo $ECHO_N "checking whether to build with Kerberos 5 support... $ECHO_C" >&6
3308
3309
3310
3311 # Check whether --with-krb5 or --without-krb5 was given.
3312 if test "${with_krb5+set}" = set; then
3313   withval="$with_krb5"
3314
3315   case $withval in
3316     yes)
3317
3318
3319 cat >>confdefs.h <<\_ACEOF
3320 #define KRB5 1
3321 _ACEOF
3322
3323   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
3324
3325       ;;
3326     no)
3327       :
3328       ;;
3329     *)
3330       { { echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
3331 echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
3332    { (exit 1); exit 1; }; }
3333       ;;
3334   esac
3335
3336 else
3337   with_krb5=no
3338
3339 fi;
3340
3341 echo "$as_me:$LINENO: result: $with_krb5" >&5
3342 echo "${ECHO_T}$with_krb5" >&6
3343
3344
3345
3346 # Using both Kerberos 4 and Kerberos 5 at the same time isn't going to work.
3347 if test "$with_krb4" = yes && test "$with_krb5" = yes ; then
3348   { { echo "$as_me:$LINENO: error: Kerberos 4 and Kerberos 5 support cannot be combined" >&5
3349 echo "$as_me: error: Kerberos 4 and Kerberos 5 support cannot be combined" >&2;}
3350    { (exit 1); exit 1; }; }
3351 fi
3352
3353
3354
3355
3356 #
3357 # Kerberos configuration parameters
3358 #
3359
3360
3361
3362 # Check whether --with-krb-srvnam or --without-krb-srvnam was given.
3363 if test "${with_krb_srvnam+set}" = set; then
3364   withval="$with_krb_srvnam"
3365
3366   case $withval in
3367     yes)
3368       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3369 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3370    { (exit 1); exit 1; }; }
3371       ;;
3372     no)
3373       { { echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
3374 echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
3375    { (exit 1); exit 1; }; }
3376       ;;
3377     *)
3378
3379       ;;
3380   esac
3381
3382 else
3383   with_krb_srvnam="postgres"
3384 fi;
3385
3386
3387 cat >>confdefs.h <<_ACEOF
3388 #define PG_KRB_SRVNAM "$with_krb_srvnam"
3389 _ACEOF
3390
3391
3392
3393 #
3394 # PAM
3395 #
3396 echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
3397 echo $ECHO_N "checking whether to build with PAM support... $ECHO_C" >&6
3398
3399
3400
3401 # Check whether --with-pam or --without-pam was given.
3402 if test "${with_pam+set}" = set; then
3403   withval="$with_pam"
3404
3405   case $withval in
3406     yes)
3407
3408 cat >>confdefs.h <<\_ACEOF
3409 #define USE_PAM 1
3410 _ACEOF
3411
3412       ;;
3413     no)
3414       :
3415       ;;
3416     *)
3417       { { echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
3418 echo "$as_me: error: no argument expected for --with-pam option" >&2;}
3419    { (exit 1); exit 1; }; }
3420       ;;
3421   esac
3422
3423 else
3424   with_pam=no
3425
3426 fi;
3427
3428 echo "$as_me:$LINENO: result: $with_pam" >&5
3429 echo "${ECHO_T}$with_pam" >&6
3430
3431
3432
3433 #
3434 # Rendezvous
3435 #
3436 echo "$as_me:$LINENO: checking whether to build with Rendezvous support" >&5
3437 echo $ECHO_N "checking whether to build with Rendezvous support... $ECHO_C" >&6
3438
3439
3440
3441 # Check whether --with-rendezvous or --without-rendezvous was given.
3442 if test "${with_rendezvous+set}" = set; then
3443   withval="$with_rendezvous"
3444
3445   case $withval in
3446     yes)
3447
3448 cat >>confdefs.h <<\_ACEOF
3449 #define USE_RENDEZVOUS 1
3450 _ACEOF
3451
3452       ;;
3453     no)
3454       :
3455       ;;
3456     *)
3457       { { echo "$as_me:$LINENO: error: no argument expected for --with-rendezvous option" >&5
3458 echo "$as_me: error: no argument expected for --with-rendezvous option" >&2;}
3459    { (exit 1); exit 1; }; }
3460       ;;
3461   esac
3462
3463 else
3464   with_rendezvous=no
3465
3466 fi;
3467
3468 echo "$as_me:$LINENO: result: $with_rendezvous" >&5
3469 echo "${ECHO_T}$with_rendezvous" >&6
3470
3471
3472
3473 #
3474 # OpenSSL
3475 #
3476 echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
3477 echo $ECHO_N "checking whether to build with OpenSSL support... $ECHO_C" >&6
3478
3479
3480
3481 # Check whether --with-openssl or --without-openssl was given.
3482 if test "${with_openssl+set}" = set; then
3483   withval="$with_openssl"
3484
3485   case $withval in
3486     yes)
3487
3488 cat >>confdefs.h <<\_ACEOF
3489 #define USE_SSL 1
3490 _ACEOF
3491
3492       ;;
3493     no)
3494       :
3495       ;;
3496     *)
3497       { { echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
3498 echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
3499    { (exit 1); exit 1; }; }
3500       ;;
3501   esac
3502
3503 else
3504   with_openssl=no
3505
3506 fi;
3507
3508 echo "$as_me:$LINENO: result: $with_openssl" >&5
3509 echo "${ECHO_T}$with_openssl" >&6
3510
3511
3512
3513 #
3514 # Readline
3515 #
3516
3517
3518
3519 # Check whether --with-readline or --without-readline was given.
3520 if test "${with_readline+set}" = set; then
3521   withval="$with_readline"
3522
3523   case $withval in
3524     yes)
3525       :
3526       ;;
3527     no)
3528       :
3529       ;;
3530     *)
3531       { { echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
3532 echo "$as_me: error: no argument expected for --with-readline option" >&2;}
3533    { (exit 1); exit 1; }; }
3534       ;;
3535   esac
3536
3537 else
3538   with_readline=yes
3539
3540 fi;
3541
3542 # readline on MinGW has problems with backslashes in psql and other bugs.
3543 # This is particularly a problem with non-US code pages.
3544 # Therefore disable its use until we understand the cause. 2004-07-20
3545 if test "$PORTNAME" = "win32"; then
3546   if test "$with_readline" = yes; then
3547     { echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
3548 echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
3549     with_readline=no
3550   fi
3551 fi
3552
3553
3554 #
3555 # Zlib
3556 #
3557
3558
3559
3560 # Check whether --with-zlib or --without-zlib was given.
3561 if test "${with_zlib+set}" = set; then
3562   withval="$with_zlib"
3563
3564   case $withval in
3565     yes)
3566       :
3567       ;;
3568     no)
3569       :
3570       ;;
3571     *)
3572       { { echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
3573 echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
3574    { (exit 1); exit 1; }; }
3575       ;;
3576   esac
3577
3578 else
3579   with_zlib=yes
3580
3581 fi;
3582
3583
3584 #
3585 # Elf
3586 #
3587
3588 # Assume system is ELF if it predefines __ELF__ as 1,
3589 # otherwise believe host_os based default.
3590 case $host_os in
3591     freebsd1*|freebsd2*) elf=no;;
3592     freebsd3*|freebsd4*) elf=yes;;
3593 esac
3594
3595
3596 cat >conftest.$ac_ext <<_ACEOF
3597 #line $LINENO "configure"
3598 #include "confdefs.h"
3599 #if __ELF__
3600   yes
3601 #endif
3602
3603 _ACEOF
3604 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3605   egrep "yes" >/dev/null 2>&1; then
3606   ELF_SYS=true
3607 else
3608   if test "X$elf" = "Xyes" ; then
3609   ELF_SYS=true
3610 else
3611   ELF_SYS=
3612 fi
3613 fi
3614 rm -f conftest*
3615
3616
3617
3618 #
3619 # Assignments
3620 #
3621
3622 CPPFLAGS="$CPPFLAGS $INCLUDES"
3623 LDFLAGS="$LDFLAGS $LIBDIRS"
3624
3625
3626
3627 for ac_prog in gawk mawk nawk awk
3628 do
3629   # Extract the first word of "$ac_prog", so it can be a program name with args.
3630 set dummy $ac_prog; ac_word=$2
3631 echo "$as_me:$LINENO: checking for $ac_word" >&5
3632 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3633 if test "${ac_cv_prog_AWK+set}" = set; then
3634   echo $ECHO_N "(cached) $ECHO_C" >&6
3635 else
3636   if test -n "$AWK"; then
3637   ac_cv_prog_AWK="$AWK" # Let the user override the test.
3638 else
3639 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3640 for as_dir in $PATH
3641 do
3642   IFS=$as_save_IFS
3643   test -z "$as_dir" && as_dir=.
3644   for ac_exec_ext in '' $ac_executable_extensions; do
3645   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3646     ac_cv_prog_AWK="$ac_prog"
3647     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3648     break 2
3649   fi
3650 done
3651 done
3652
3653 fi
3654 fi
3655 AWK=$ac_cv_prog_AWK
3656 if test -n "$AWK"; then
3657   echo "$as_me:$LINENO: result: $AWK" >&5
3658 echo "${ECHO_T}$AWK" >&6
3659 else
3660   echo "$as_me:$LINENO: result: no" >&5
3661 echo "${ECHO_T}no" >&6
3662 fi
3663
3664   test -n "$AWK" && break
3665 done
3666
3667 echo "$as_me:$LINENO: checking for flex" >&5
3668 echo $ECHO_N "checking for flex... $ECHO_C" >&6
3669 if test "${pgac_cv_path_flex+set}" = set; then
3670   echo $ECHO_N "(cached) $ECHO_C" >&6
3671 else
3672   # Let the user override the test
3673 if test -n "$FLEX"; then
3674   pgac_cv_path_flex=$FLEX
3675 else
3676   pgac_save_IFS=$IFS
3677   IFS=$PATH_SEPARATOR
3678   for pgac_dir in $PATH; do
3679     IFS=$pgac_save_IFS
3680     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
3681       pgac_dir=`pwd`
3682     fi
3683     for pgac_prog in flex lex; do
3684       pgac_candidate="$pgac_dir/$pgac_prog"
3685       if test -f "$pgac_candidate" \
3686         && $pgac_candidate --version </dev/null >/dev/null 2>&1
3687       then
3688         echo '%%'  > conftest.l
3689         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
3690           if $pgac_candidate --version | grep ' 2\.5\.3$' >/dev/null 2>&1; then
3691             pgac_broken_flex=$pgac_candidate
3692             continue
3693           fi
3694
3695           pgac_cv_path_flex=$pgac_candidate
3696           break 2
3697         fi
3698       fi
3699     done
3700   done
3701   rm -f conftest.l lex.yy.c
3702   : ${pgac_cv_path_flex=no}
3703 fi
3704
3705 fi
3706 echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
3707 echo "${ECHO_T}$pgac_cv_path_flex" >&6
3708 if test x"$pgac_cv_path_flex" = x"no"; then
3709   if test -n "$pgac_broken_flex"; then
3710     { echo "$as_me:$LINENO: WARNING:
3711 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
3712 *** should get version 2.5.4 or later." >&5
3713 echo "$as_me: WARNING:
3714 *** The Flex version 2.5.3 you have at $pgac_broken_flex contains a bug. You
3715 *** should get version 2.5.4 or later." >&2;}
3716   fi
3717
3718   { echo "$as_me:$LINENO: WARNING:
3719 *** Without Flex you will not be able to build PostgreSQL from CVS or
3720 *** change any of the scanner definition files.  You can obtain Flex from
3721 *** a GNU mirror site.  (If you are using the official distribution of
3722 *** PostgreSQL then you do not need to worry about this because the Flex
3723 *** output is pre-generated.)" >&5
3724 echo "$as_me: WARNING:
3725 *** Without Flex you will not be able to build PostgreSQL from CVS or
3726 *** change any of the scanner definition files.  You can obtain Flex from
3727 *** a GNU mirror site.  (If you are using the official distribution of
3728 *** PostgreSQL then you do not need to worry about this because the Flex
3729 *** output is pre-generated.)" >&2;}
3730 fi
3731
3732 if test x"$pgac_cv_path_flex" = x"no"; then
3733   FLEX=
3734 else
3735   FLEX=$pgac_cv_path_flex
3736 fi
3737
3738
3739
3740
3741 echo "$as_me:$LINENO: checking whether ln -s works" >&5
3742 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
3743 LN_S=$as_ln_s
3744 if test "$LN_S" = "ln -s"; then
3745   echo "$as_me:$LINENO: result: yes" >&5
3746 echo "${ECHO_T}yes" >&6
3747 else
3748   echo "$as_me:$LINENO: result: no, using $LN_S" >&5
3749 echo "${ECHO_T}no, using $LN_S" >&6
3750 fi
3751
3752
3753 # Check whether --with-gnu-ld or --without-gnu-ld was given.
3754 if test "${with_gnu_ld+set}" = set; then
3755   withval="$with_gnu_ld"
3756   test "$withval" = no || with_gnu_ld=yes
3757 else
3758   with_gnu_ld=no
3759 fi;
3760 ac_prog=ld
3761 if test "$GCC" = yes; then
3762   # Check if gcc -print-prog-name=ld gives a path.
3763   echo "$as_me:$LINENO: checking for ld used by GCC" >&5
3764 echo $ECHO_N "checking for ld used by GCC... $ECHO_C" >&6
3765   case $host in
3766   *-*-mingw*)
3767     # gcc leaves a trailing carriage return which upsets mingw
3768     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
3769   *)
3770     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
3771   esac
3772   case "$ac_prog" in
3773     # Accept absolute paths.
3774     [\\/]* | [A-Za-z]:[\\/]*)
3775       re_direlt='/[^/][^/]*/\.\./'
3776       # Canonicalize the path of ld
3777       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
3778       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
3779         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
3780       done
3781       test -z "$LD" && LD="$ac_prog"
3782       ;;
3783   "")
3784     # If it fails, then pretend we aren't using GCC.
3785     ac_prog=ld
3786     ;;
3787   *)
3788     # If it is relative, then search for the first ld in PATH.
3789     with_gnu_ld=unknown
3790     ;;
3791   esac
3792 elif test "$with_gnu_ld" = yes; then
3793   echo "$as_me:$LINENO: checking for GNU ld" >&5
3794 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6
3795 else
3796   echo "$as_me:$LINENO: checking for non-GNU ld" >&5
3797 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6
3798 fi
3799 if test "${ac_cv_path_LD+set}" = set; then
3800   echo $ECHO_N "(cached) $ECHO_C" >&6
3801 else
3802   if test -z "$LD"; then
3803   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
3804   for ac_dir in $PATH; do
3805     test -z "$ac_dir" && ac_dir=.
3806     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
3807       ac_cv_path_LD="$ac_dir/$ac_prog"
3808       # Check to see if the program is GNU ld.  I'd rather use --version,
3809       # but apparently some GNU ld's only accept -v.
3810       # Break only if it was the GNU/non-GNU ld that we prefer.
3811       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
3812         test "$with_gnu_ld" != no && break
3813       else
3814         test "$with_gnu_ld" != yes && break
3815       fi
3816     fi
3817   done
3818   IFS="$ac_save_ifs"
3819 else
3820   ac_cv_path_LD="$LD" # Let the user override the test with a path.
3821 fi
3822 fi
3823
3824 LD="$ac_cv_path_LD"
3825 if test -n "$LD"; then
3826   echo "$as_me:$LINENO: result: $LD" >&5
3827 echo "${ECHO_T}$LD" >&6
3828 else
3829   echo "$as_me:$LINENO: result: no" >&5
3830 echo "${ECHO_T}no" >&6
3831 fi
3832 test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
3833 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
3834    { (exit 1); exit 1; }; }
3835 echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
3836 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6
3837 if test "${ac_cv_prog_gnu_ld+set}" = set; then
3838   echo $ECHO_N "(cached) $ECHO_C" >&6
3839 else
3840   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
3841 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
3842   ac_cv_prog_gnu_ld=yes
3843 else
3844   ac_cv_prog_gnu_ld=no
3845 fi
3846 fi
3847 echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
3848 echo "${ECHO_T}$ac_cv_prog_gnu_ld" >&6
3849 with_gnu_ld=$ac_cv_prog_gnu_ld
3850
3851
3852
3853
3854
3855 case $host_os in sysv5*)
3856   echo "$as_me:$LINENO: checking whether ld -R works" >&5
3857 echo $ECHO_N "checking whether ld -R works... $ECHO_C" >&6
3858 if test "${pgac_cv_prog_ld_R+set}" = set; then
3859   echo $ECHO_N "(cached) $ECHO_C" >&6
3860 else
3861
3862     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
3863     cat >conftest.$ac_ext <<_ACEOF
3864 #line $LINENO "configure"
3865 #include "confdefs.h"
3866
3867 #ifdef F77_DUMMY_MAIN
3868 #  ifdef __cplusplus
3869      extern "C"
3870 #  endif
3871    int F77_DUMMY_MAIN() { return 1; }
3872 #endif
3873 int
3874 main ()
3875 {
3876
3877   ;
3878   return 0;
3879 }
3880 _ACEOF
3881 rm -f conftest.$ac_objext conftest$ac_exeext
3882 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3883   (eval $ac_link) 2>&5
3884   ac_status=$?
3885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3886   (exit $ac_status); } &&
3887          { ac_try='test -s conftest$ac_exeext'
3888   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3889   (eval $ac_try) 2>&5
3890   ac_status=$?
3891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3892   (exit $ac_status); }; }; then
3893   pgac_cv_prog_ld_R=yes
3894 else
3895   echo "$as_me: failed program was:" >&5
3896 cat conftest.$ac_ext >&5
3897 pgac_cv_prog_ld_R=no
3898 fi
3899 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3900     LDFLAGS=$pgac_save_LDFLAGS
3901
3902 fi
3903 echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
3904 echo "${ECHO_T}$pgac_cv_prog_ld_R" >&6
3905   ld_R_works=$pgac_cv_prog_ld_R
3906
3907 esac
3908
3909 # To simplify the build system, we specify the maximal set of
3910 # libraries to link against when building any executable. The linker
3911 # on some platforms optionally allows unused link arguments to be
3912 # elided from the resulting executable, so enable that capability if
3913 # it exists.
3914 # XXX: currently we only support GNU ld; do any other linkers support
3915 # an equivalent feature?
3916 if test "$with_gnu_ld"; then
3917   echo "$as_me:$LINENO: checking whether ld --as-needed works" >&5
3918 echo $ECHO_N "checking whether ld --as-needed works... $ECHO_C" >&6
3919 if test "${pgac_cv_prog_ld_as_needed+set}" = set; then
3920   echo $ECHO_N "(cached) $ECHO_C" >&6
3921 else
3922
3923     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,--as-needed"
3924     cat >conftest.$ac_ext <<_ACEOF
3925 #line $LINENO "configure"
3926 #include "confdefs.h"
3927
3928 #ifdef F77_DUMMY_MAIN
3929 #  ifdef __cplusplus
3930      extern "C"
3931 #  endif
3932    int F77_DUMMY_MAIN() { return 1; }
3933 #endif
3934 int
3935 main ()
3936 {
3937
3938   ;
3939   return 0;
3940 }
3941 _ACEOF
3942 rm -f conftest.$ac_objext conftest$ac_exeext
3943 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
3944   (eval $ac_link) 2>&5
3945   ac_status=$?
3946   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3947   (exit $ac_status); } &&
3948          { ac_try='test -s conftest$ac_exeext'
3949   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
3950   (eval $ac_try) 2>&5
3951   ac_status=$?
3952   echo "$as_me:$LINENO: \$? = $ac_status" >&5
3953   (exit $ac_status); }; }; then
3954   pgac_cv_prog_ld_as_needed=yes
3955 else
3956   echo "$as_me: failed program was:" >&5
3957 cat conftest.$ac_ext >&5
3958 pgac_cv_prog_ld_as_needed=no
3959 fi
3960 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
3961    if test x"$pgac_cv_prog_ld_as_needed" = x"no"; then
3962      LDFLAGS=$pgac_save_LDFLAGS
3963    fi
3964
3965 fi
3966 echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_as_needed" >&5
3967 echo "${ECHO_T}$pgac_cv_prog_ld_as_needed" >&6
3968 fi
3969
3970 if test -n "$ac_tool_prefix"; then
3971   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3972 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
3973 echo "$as_me:$LINENO: checking for $ac_word" >&5
3974 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
3975 if test "${ac_cv_prog_RANLIB+set}" = set; then
3976   echo $ECHO_N "(cached) $ECHO_C" >&6
3977 else
3978   if test -n "$RANLIB"; then
3979   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
3980 else
3981 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3982 for as_dir in $PATH
3983 do
3984   IFS=$as_save_IFS
3985   test -z "$as_dir" && as_dir=.
3986   for ac_exec_ext in '' $ac_executable_extensions; do
3987   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
3988     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
3989     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3990     break 2
3991   fi
3992 done
3993 done
3994
3995 fi
3996 fi
3997 RANLIB=$ac_cv_prog_RANLIB
3998 if test -n "$RANLIB"; then
3999   echo "$as_me:$LINENO: result: $RANLIB" >&5
4000 echo "${ECHO_T}$RANLIB" >&6
4001 else
4002   echo "$as_me:$LINENO: result: no" >&5
4003 echo "${ECHO_T}no" >&6
4004 fi
4005
4006 fi
4007 if test -z "$ac_cv_prog_RANLIB"; then
4008   ac_ct_RANLIB=$RANLIB
4009   # Extract the first word of "ranlib", so it can be a program name with args.
4010 set dummy ranlib; ac_word=$2
4011 echo "$as_me:$LINENO: checking for $ac_word" >&5
4012 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4013 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4014   echo $ECHO_N "(cached) $ECHO_C" >&6
4015 else
4016   if test -n "$ac_ct_RANLIB"; then
4017   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4018 else
4019 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4020 for as_dir in $PATH
4021 do
4022   IFS=$as_save_IFS
4023   test -z "$as_dir" && as_dir=.
4024   for ac_exec_ext in '' $ac_executable_extensions; do
4025   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4026     ac_cv_prog_ac_ct_RANLIB="ranlib"
4027     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4028     break 2
4029   fi
4030 done
4031 done
4032
4033   test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
4034 fi
4035 fi
4036 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4037 if test -n "$ac_ct_RANLIB"; then
4038   echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
4039 echo "${ECHO_T}$ac_ct_RANLIB" >&6
4040 else
4041   echo "$as_me:$LINENO: result: no" >&5
4042 echo "${ECHO_T}no" >&6
4043 fi
4044
4045   RANLIB=$ac_ct_RANLIB
4046 else
4047   RANLIB="$ac_cv_prog_RANLIB"
4048 fi
4049
4050 for ac_prog in lorder
4051 do
4052   # Extract the first word of "$ac_prog", so it can be a program name with args.
4053 set dummy $ac_prog; ac_word=$2
4054 echo "$as_me:$LINENO: checking for $ac_word" >&5
4055 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4056 if test "${ac_cv_prog_LORDER+set}" = set; then
4057   echo $ECHO_N "(cached) $ECHO_C" >&6
4058 else
4059   if test -n "$LORDER"; then
4060   ac_cv_prog_LORDER="$LORDER" # Let the user override the test.
4061 else
4062 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4063 for as_dir in $PATH
4064 do
4065   IFS=$as_save_IFS
4066   test -z "$as_dir" && as_dir=.
4067   for ac_exec_ext in '' $ac_executable_extensions; do
4068   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4069     ac_cv_prog_LORDER="$ac_prog"
4070     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4071     break 2
4072   fi
4073 done
4074 done
4075
4076 fi
4077 fi
4078 LORDER=$ac_cv_prog_LORDER
4079 if test -n "$LORDER"; then
4080   echo "$as_me:$LINENO: result: $LORDER" >&5
4081 echo "${ECHO_T}$LORDER" >&6
4082 else
4083   echo "$as_me:$LINENO: result: no" >&5
4084 echo "${ECHO_T}no" >&6
4085 fi
4086
4087   test -n "$LORDER" && break
4088 done
4089
4090 # Extract the first word of "tar", so it can be a program name with args.
4091 set dummy tar; ac_word=$2
4092 echo "$as_me:$LINENO: checking for $ac_word" >&5
4093 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4094 if test "${ac_cv_path_TAR+set}" = set; then
4095   echo $ECHO_N "(cached) $ECHO_C" >&6
4096 else
4097   case $TAR in
4098   [\\/]* | ?:[\\/]*)
4099   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
4100   ;;
4101   *)
4102   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4103 for as_dir in $PATH
4104 do
4105   IFS=$as_save_IFS
4106   test -z "$as_dir" && as_dir=.
4107   for ac_exec_ext in '' $ac_executable_extensions; do
4108   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4109     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
4110     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4111     break 2
4112   fi
4113 done
4114 done
4115
4116   ;;
4117 esac
4118 fi
4119 TAR=$ac_cv_path_TAR
4120
4121 if test -n "$TAR"; then
4122   echo "$as_me:$LINENO: result: $TAR" >&5
4123 echo "${ECHO_T}$TAR" >&6
4124 else
4125   echo "$as_me:$LINENO: result: no" >&5
4126 echo "${ECHO_T}no" >&6
4127 fi
4128
4129
4130   if test -n "$ac_tool_prefix"; then
4131   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
4132 set dummy ${ac_tool_prefix}strip; ac_word=$2
4133 echo "$as_me:$LINENO: checking for $ac_word" >&5
4134 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4135 if test "${ac_cv_prog_STRIP+set}" = set; then
4136   echo $ECHO_N "(cached) $ECHO_C" >&6
4137 else
4138   if test -n "$STRIP"; then
4139   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
4140 else
4141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4142 for as_dir in $PATH
4143 do
4144   IFS=$as_save_IFS
4145   test -z "$as_dir" && as_dir=.
4146   for ac_exec_ext in '' $ac_executable_extensions; do
4147   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4148     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
4149     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4150     break 2
4151   fi
4152 done
4153 done
4154
4155 fi
4156 fi
4157 STRIP=$ac_cv_prog_STRIP
4158 if test -n "$STRIP"; then
4159   echo "$as_me:$LINENO: result: $STRIP" >&5
4160 echo "${ECHO_T}$STRIP" >&6
4161 else
4162   echo "$as_me:$LINENO: result: no" >&5
4163 echo "${ECHO_T}no" >&6
4164 fi
4165
4166 fi
4167 if test -z "$ac_cv_prog_STRIP"; then
4168   ac_ct_STRIP=$STRIP
4169   # Extract the first word of "strip", so it can be a program name with args.
4170 set dummy strip; ac_word=$2
4171 echo "$as_me:$LINENO: checking for $ac_word" >&5
4172 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4173 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
4174   echo $ECHO_N "(cached) $ECHO_C" >&6
4175 else
4176   if test -n "$ac_ct_STRIP"; then
4177   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
4178 else
4179 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4180 for as_dir in $PATH
4181 do
4182   IFS=$as_save_IFS
4183   test -z "$as_dir" && as_dir=.
4184   for ac_exec_ext in '' $ac_executable_extensions; do
4185   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4186     ac_cv_prog_ac_ct_STRIP="strip"
4187     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4188     break 2
4189   fi
4190 done
4191 done
4192
4193   test -z "$ac_cv_prog_ac_ct_STRIP" && ac_cv_prog_ac_ct_STRIP=":"
4194 fi
4195 fi
4196 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
4197 if test -n "$ac_ct_STRIP"; then
4198   echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
4199 echo "${ECHO_T}$ac_ct_STRIP" >&6
4200 else
4201   echo "$as_me:$LINENO: result: no" >&5
4202 echo "${ECHO_T}no" >&6
4203 fi
4204
4205   STRIP=$ac_ct_STRIP
4206 else
4207   STRIP="$ac_cv_prog_STRIP"
4208 fi
4209
4210
4211   echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
4212 echo $ECHO_N "checking whether it is possible to strip libraries... $ECHO_C" >&6
4213   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
4214     STRIP_STATIC_LIB="$STRIP -x"
4215     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
4216     echo "$as_me:$LINENO: result: yes" >&5
4217 echo "${ECHO_T}yes" >&6
4218   else
4219     STRIP_STATIC_LIB=:
4220     STRIP_SHARED_LIB=:
4221     echo "$as_me:$LINENO: result: no" >&5
4222 echo "${ECHO_T}no" >&6
4223   fi
4224
4225
4226
4227
4228 { echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
4229 echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
4230 { echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
4231 echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
4232
4233 for ac_prog in 'bison -y'
4234 do
4235   # Extract the first word of "$ac_prog", so it can be a program name with args.
4236 set dummy $ac_prog; ac_word=$2
4237 echo "$as_me:$LINENO: checking for $ac_word" >&5
4238 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4239 if test "${ac_cv_prog_YACC+set}" = set; then
4240   echo $ECHO_N "(cached) $ECHO_C" >&6
4241 else
4242   if test -n "$YACC"; then
4243   ac_cv_prog_YACC="$YACC" # Let the user override the test.
4244 else
4245 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4246 for as_dir in $PATH
4247 do
4248   IFS=$as_save_IFS
4249   test -z "$as_dir" && as_dir=.
4250   for ac_exec_ext in '' $ac_executable_extensions; do
4251   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4252     ac_cv_prog_YACC="$ac_prog"
4253     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4254     break 2
4255   fi
4256 done
4257 done
4258
4259 fi
4260 fi
4261 YACC=$ac_cv_prog_YACC
4262 if test -n "$YACC"; then
4263   echo "$as_me:$LINENO: result: $YACC" >&5
4264 echo "${ECHO_T}$YACC" >&6
4265 else
4266   echo "$as_me:$LINENO: result: no" >&5
4267 echo "${ECHO_T}no" >&6
4268 fi
4269
4270   test -n "$YACC" && break
4271 done
4272
4273
4274 if test "$YACC"; then
4275   if $YACC --version | sed q | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'; then
4276     { echo "$as_me:$LINENO: WARNING:
4277 *** If you are going to modify the grammar files or build from CVS, the installed
4278 *** version of Bison is too old.  Bison version 1.875 or later is required." >&5
4279 echo "$as_me: WARNING:
4280 *** If you are going to modify the grammar files or build from CVS, the installed
4281 *** version of Bison is too old.  Bison version 1.875 or later is required." >&2;}
4282   fi
4283 fi
4284
4285 if test -z "$YACC"; then
4286   { echo "$as_me:$LINENO: WARNING:
4287 *** Without Bison you will not be able to build PostgreSQL from CVS or
4288 *** change any of the parser definition files.  You can obtain Bison from
4289 *** a GNU mirror site.  (If you are using the official distribution of
4290 *** PostgreSQL then you do not need to worry about this because the Bison
4291 *** output is pre-generated.)  To use a different yacc program (possible,
4292 *** but not recommended), set the environment variable YACC before running
4293 *** 'configure'." >&5
4294 echo "$as_me: WARNING:
4295 *** Without Bison you will not be able to build PostgreSQL from CVS or
4296 *** change any of the parser definition files.  You can obtain Bison from
4297 *** a GNU mirror site.  (If you are using the official distribution of
4298 *** PostgreSQL then you do not need to worry about this because the Bison
4299 *** output is pre-generated.)  To use a different yacc program (possible,
4300 *** but not recommended), set the environment variable YACC before running
4301 *** 'configure'." >&2;}
4302 fi
4303
4304
4305 # Extract the first word of "perl", so it can be a program name with args.
4306 set dummy perl; ac_word=$2
4307 echo "$as_me:$LINENO: checking for $ac_word" >&5
4308 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4309 if test "${ac_cv_path_PERL+set}" = set; then
4310   echo $ECHO_N "(cached) $ECHO_C" >&6
4311 else
4312   case $PERL in
4313   [\\/]* | ?:[\\/]*)
4314   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
4315   ;;
4316   *)
4317   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4318 for as_dir in $PATH
4319 do
4320   IFS=$as_save_IFS
4321   test -z "$as_dir" && as_dir=.
4322   for ac_exec_ext in '' $ac_executable_extensions; do
4323   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4324     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
4325     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4326     break 2
4327   fi
4328 done
4329 done
4330
4331   ;;
4332 esac
4333 fi
4334 PERL=$ac_cv_path_PERL
4335
4336 if test -n "$PERL"; then
4337   echo "$as_me:$LINENO: result: $PERL" >&5
4338 echo "${ECHO_T}$PERL" >&6
4339 else
4340   echo "$as_me:$LINENO: result: no" >&5
4341 echo "${ECHO_T}no" >&6
4342 fi
4343
4344 if test "$with_perl" = yes; then
4345
4346 echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
4347 echo $ECHO_N "checking for Perl archlibexp... $ECHO_C" >&6
4348 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
4349 echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
4350 echo "${ECHO_T}$perl_archlibexp" >&6
4351 echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
4352 echo $ECHO_N "checking for Perl privlibexp... $ECHO_C" >&6
4353 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
4354 echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
4355 echo "${ECHO_T}$perl_privlibexp" >&6
4356 echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
4357 echo $ECHO_N "checking for Perl useshrplib... $ECHO_C" >&6
4358 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
4359 echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
4360 echo "${ECHO_T}$perl_useshrplib" >&6
4361
4362 echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
4363 echo $ECHO_N "checking for flags to link embedded Perl... $ECHO_C" >&6
4364 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
4365 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
4366 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed "s/^X//;s%$pgac_tmp2%%"`
4367 echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
4368 echo "${ECHO_T}$perl_embed_ldflags" >&6
4369 fi
4370
4371 if test "$with_python" = yes; then
4372   # Extract the first word of "python", so it can be a program name with args.
4373 set dummy python; ac_word=$2
4374 echo "$as_me:$LINENO: checking for $ac_word" >&5
4375 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
4376 if test "${ac_cv_path_PYTHON+set}" = set; then
4377   echo $ECHO_N "(cached) $ECHO_C" >&6
4378 else
4379   case $PYTHON in
4380   [\\/]* | ?:[\\/]*)
4381   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
4382   ;;
4383   *)
4384   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4385 for as_dir in $PATH
4386 do
4387   IFS=$as_save_IFS
4388   test -z "$as_dir" && as_dir=.
4389   for ac_exec_ext in '' $ac_executable_extensions; do
4390   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
4391     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
4392     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4393     break 2
4394   fi
4395 done
4396 done
4397
4398   ;;
4399 esac
4400 fi
4401 PYTHON=$ac_cv_path_PYTHON
4402
4403 if test -n "$PYTHON"; then
4404   echo "$as_me:$LINENO: result: $PYTHON" >&5
4405 echo "${ECHO_T}$PYTHON" >&6
4406 else
4407   echo "$as_me:$LINENO: result: no" >&5
4408 echo "${ECHO_T}no" >&6
4409 fi
4410
4411 if test x"$PYTHON" = x""; then
4412   { { echo "$as_me:$LINENO: error: Python not found" >&5
4413 echo "$as_me: error: Python not found" >&2;}
4414    { (exit 1); exit 1; }; }
4415 fi
4416
4417
4418 echo "$as_me:$LINENO: checking for Python distutils module" >&5
4419 echo $ECHO_N "checking for Python distutils module... $ECHO_C" >&6
4420 if "${PYTHON}" 2>&- -c 'import distutils'
4421 then
4422     echo "$as_me:$LINENO: result: yes" >&5
4423 echo "${ECHO_T}yes" >&6
4424 else
4425     echo "$as_me:$LINENO: result: no" >&5
4426 echo "${ECHO_T}no" >&6
4427     { { echo "$as_me:$LINENO: error: distutils module not found" >&5
4428 echo "$as_me: error: distutils module not found" >&2;}
4429    { (exit 1); exit 1; }; }
4430 fi
4431 echo "$as_me:$LINENO: checking Python configuration directory" >&5
4432 echo $ECHO_N "checking Python configuration directory... $ECHO_C" >&6
4433 python_version=`${PYTHON} -c "import sys; print sys.version[:3]"`
4434 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')"`
4435 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print '-I'+distutils.sysconfig.get_python_inc()"`
4436
4437 # This should be enough of a message.
4438 echo "$as_me:$LINENO: result: $python_configdir" >&5
4439 echo "${ECHO_T}$python_configdir" >&6
4440
4441
4442 echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
4443 echo $ECHO_N "checking how to link an embedded Python application... $ECHO_C" >&6
4444
4445 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR')))"`
4446 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY')))"`
4447 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('SO')))"`
4448 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
4449
4450 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
4451 then
4452         # New way: use the official shared library
4453         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
4454         python_libspec="-L${python_libdir} -l${ldlibrary}"
4455 else
4456         # Old way: use libpython from python_configdir
4457         python_libdir="${python_configdir}"
4458         python_libspec="-L${python_libdir} -lpython${python_version}"
4459 fi
4460
4461 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print string.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','LOCALMODLIBS','BASEMODLIBS')))"`
4462
4463 echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
4464 echo "${ECHO_T}${python_libspec} ${python_additional_libs}" >&6
4465
4466
4467 fi
4468
4469
4470 ##
4471 ## Libraries
4472 ##
4473
4474 if test "$PORTNAME" != "aix" -a "$PORTNAME" != "alpha"
4475 then
4476
4477 echo "$as_me:$LINENO: checking for main in -lbsd" >&5
4478 echo $ECHO_N "checking for main in -lbsd... $ECHO_C" >&6
4479 if test "${ac_cv_lib_bsd_main+set}" = set; then
4480   echo $ECHO_N "(cached) $ECHO_C" >&6
4481 else
4482   ac_check_lib_save_LIBS=$LIBS
4483 LIBS="-lbsd  $LIBS"
4484 cat >conftest.$ac_ext <<_ACEOF
4485 #line $LINENO "configure"
4486 #include "confdefs.h"
4487
4488
4489 #ifdef F77_DUMMY_MAIN
4490 #  ifdef __cplusplus
4491      extern "C"
4492 #  endif
4493    int F77_DUMMY_MAIN() { return 1; }
4494 #endif
4495 int
4496 main ()
4497 {
4498 main ();
4499   ;
4500   return 0;
4501 }
4502 _ACEOF
4503 rm -f conftest.$ac_objext conftest$ac_exeext
4504 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4505   (eval $ac_link) 2>&5
4506   ac_status=$?
4507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4508   (exit $ac_status); } &&
4509          { ac_try='test -s conftest$ac_exeext'
4510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4511   (eval $ac_try) 2>&5
4512   ac_status=$?
4513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4514   (exit $ac_status); }; }; then
4515   ac_cv_lib_bsd_main=yes
4516 else
4517   echo "$as_me: failed program was:" >&5
4518 cat conftest.$ac_ext >&5
4519 ac_cv_lib_bsd_main=no
4520 fi
4521 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4522 LIBS=$ac_check_lib_save_LIBS
4523 fi
4524 echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_main" >&5
4525 echo "${ECHO_T}$ac_cv_lib_bsd_main" >&6
4526 if test $ac_cv_lib_bsd_main = yes; then
4527   cat >>confdefs.h <<_ACEOF
4528 #define HAVE_LIBBSD 1
4529 _ACEOF
4530
4531   LIBS="-lbsd $LIBS"
4532
4533 fi
4534
4535 fi
4536
4537 echo "$as_me:$LINENO: checking for setproctitle in -lutil" >&5
4538 echo $ECHO_N "checking for setproctitle in -lutil... $ECHO_C" >&6
4539 if test "${ac_cv_lib_util_setproctitle+set}" = set; then
4540   echo $ECHO_N "(cached) $ECHO_C" >&6
4541 else
4542   ac_check_lib_save_LIBS=$LIBS
4543 LIBS="-lutil  $LIBS"
4544 cat >conftest.$ac_ext <<_ACEOF
4545 #line $LINENO "configure"
4546 #include "confdefs.h"
4547
4548 /* Override any gcc2 internal prototype to avoid an error.  */
4549 #ifdef __cplusplus
4550 extern "C"
4551 #endif
4552 /* We use char because int might match the return type of a gcc2
4553    builtin and then its argument prototype would still apply.  */
4554 char setproctitle ();
4555 #ifdef F77_DUMMY_MAIN
4556 #  ifdef __cplusplus
4557      extern "C"
4558 #  endif
4559    int F77_DUMMY_MAIN() { return 1; }
4560 #endif
4561 int
4562 main ()
4563 {
4564 setproctitle ();
4565   ;
4566   return 0;
4567 }
4568 _ACEOF
4569 rm -f conftest.$ac_objext conftest$ac_exeext
4570 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4571   (eval $ac_link) 2>&5
4572   ac_status=$?
4573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4574   (exit $ac_status); } &&
4575          { ac_try='test -s conftest$ac_exeext'
4576   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4577   (eval $ac_try) 2>&5
4578   ac_status=$?
4579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4580   (exit $ac_status); }; }; then
4581   ac_cv_lib_util_setproctitle=yes
4582 else
4583   echo "$as_me: failed program was:" >&5
4584 cat conftest.$ac_ext >&5
4585 ac_cv_lib_util_setproctitle=no
4586 fi
4587 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4588 LIBS=$ac_check_lib_save_LIBS
4589 fi
4590 echo "$as_me:$LINENO: result: $ac_cv_lib_util_setproctitle" >&5
4591 echo "${ECHO_T}$ac_cv_lib_util_setproctitle" >&6
4592 if test $ac_cv_lib_util_setproctitle = yes; then
4593   cat >>confdefs.h <<_ACEOF
4594 #define HAVE_LIBUTIL 1
4595 _ACEOF
4596
4597   LIBS="-lutil $LIBS"
4598
4599 fi
4600
4601
4602 echo "$as_me:$LINENO: checking for main in -lm" >&5
4603 echo $ECHO_N "checking for main in -lm... $ECHO_C" >&6
4604 if test "${ac_cv_lib_m_main+set}" = set; then
4605   echo $ECHO_N "(cached) $ECHO_C" >&6
4606 else
4607   ac_check_lib_save_LIBS=$LIBS
4608 LIBS="-lm  $LIBS"
4609 cat >conftest.$ac_ext <<_ACEOF
4610 #line $LINENO "configure"
4611 #include "confdefs.h"
4612
4613
4614 #ifdef F77_DUMMY_MAIN
4615 #  ifdef __cplusplus
4616      extern "C"
4617 #  endif
4618    int F77_DUMMY_MAIN() { return 1; }
4619 #endif
4620 int
4621 main ()
4622 {
4623 main ();
4624   ;
4625   return 0;
4626 }
4627 _ACEOF
4628 rm -f conftest.$ac_objext conftest$ac_exeext
4629 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4630   (eval $ac_link) 2>&5
4631   ac_status=$?
4632   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4633   (exit $ac_status); } &&
4634          { ac_try='test -s conftest$ac_exeext'
4635   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4636   (eval $ac_try) 2>&5
4637   ac_status=$?
4638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4639   (exit $ac_status); }; }; then
4640   ac_cv_lib_m_main=yes
4641 else
4642   echo "$as_me: failed program was:" >&5
4643 cat conftest.$ac_ext >&5
4644 ac_cv_lib_m_main=no
4645 fi
4646 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4647 LIBS=$ac_check_lib_save_LIBS
4648 fi
4649 echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
4650 echo "${ECHO_T}$ac_cv_lib_m_main" >&6
4651 if test $ac_cv_lib_m_main = yes; then
4652   cat >>confdefs.h <<_ACEOF
4653 #define HAVE_LIBM 1
4654 _ACEOF
4655
4656   LIBS="-lm $LIBS"
4657
4658 fi
4659
4660
4661 echo "$as_me:$LINENO: checking for main in -ldl" >&5
4662 echo $ECHO_N "checking for main in -ldl... $ECHO_C" >&6
4663 if test "${ac_cv_lib_dl_main+set}" = set; then
4664   echo $ECHO_N "(cached) $ECHO_C" >&6
4665 else
4666   ac_check_lib_save_LIBS=$LIBS
4667 LIBS="-ldl  $LIBS"
4668 cat >conftest.$ac_ext <<_ACEOF
4669 #line $LINENO "configure"
4670 #include "confdefs.h"
4671
4672
4673 #ifdef F77_DUMMY_MAIN
4674 #  ifdef __cplusplus
4675      extern "C"
4676 #  endif
4677    int F77_DUMMY_MAIN() { return 1; }
4678 #endif
4679 int
4680 main ()
4681 {
4682 main ();
4683   ;
4684   return 0;
4685 }
4686 _ACEOF
4687 rm -f conftest.$ac_objext conftest$ac_exeext
4688 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4689   (eval $ac_link) 2>&5
4690   ac_status=$?
4691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4692   (exit $ac_status); } &&
4693          { ac_try='test -s conftest$ac_exeext'
4694   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4695   (eval $ac_try) 2>&5
4696   ac_status=$?
4697   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4698   (exit $ac_status); }; }; then
4699   ac_cv_lib_dl_main=yes
4700 else
4701   echo "$as_me: failed program was:" >&5
4702 cat conftest.$ac_ext >&5
4703 ac_cv_lib_dl_main=no
4704 fi
4705 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4706 LIBS=$ac_check_lib_save_LIBS
4707 fi
4708 echo "$as_me:$LINENO: result: $ac_cv_lib_dl_main" >&5
4709 echo "${ECHO_T}$ac_cv_lib_dl_main" >&6
4710 if test $ac_cv_lib_dl_main = yes; then
4711   cat >>confdefs.h <<_ACEOF
4712 #define HAVE_LIBDL 1
4713 _ACEOF
4714
4715   LIBS="-ldl $LIBS"
4716
4717 fi
4718
4719
4720 echo "$as_me:$LINENO: checking for main in -lnsl" >&5
4721 echo $ECHO_N "checking for main in -lnsl... $ECHO_C" >&6
4722 if test "${ac_cv_lib_nsl_main+set}" = set; then
4723   echo $ECHO_N "(cached) $ECHO_C" >&6
4724 else
4725   ac_check_lib_save_LIBS=$LIBS
4726 LIBS="-lnsl  $LIBS"
4727 cat >conftest.$ac_ext <<_ACEOF
4728 #line $LINENO "configure"
4729 #include "confdefs.h"
4730
4731
4732 #ifdef F77_DUMMY_MAIN
4733 #  ifdef __cplusplus
4734      extern "C"
4735 #  endif
4736    int F77_DUMMY_MAIN() { return 1; }
4737 #endif
4738 int
4739 main ()
4740 {
4741 main ();
4742   ;
4743   return 0;
4744 }
4745 _ACEOF
4746 rm -f conftest.$ac_objext conftest$ac_exeext
4747 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4748   (eval $ac_link) 2>&5
4749   ac_status=$?
4750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4751   (exit $ac_status); } &&
4752          { ac_try='test -s conftest$ac_exeext'
4753   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4754   (eval $ac_try) 2>&5
4755   ac_status=$?
4756   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4757   (exit $ac_status); }; }; then
4758   ac_cv_lib_nsl_main=yes
4759 else
4760   echo "$as_me: failed program was:" >&5
4761 cat conftest.$ac_ext >&5
4762 ac_cv_lib_nsl_main=no
4763 fi
4764 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4765 LIBS=$ac_check_lib_save_LIBS
4766 fi
4767 echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_main" >&5
4768 echo "${ECHO_T}$ac_cv_lib_nsl_main" >&6
4769 if test $ac_cv_lib_nsl_main = yes; then
4770   cat >>confdefs.h <<_ACEOF
4771 #define HAVE_LIBNSL 1
4772 _ACEOF
4773
4774   LIBS="-lnsl $LIBS"
4775
4776 fi
4777
4778
4779 echo "$as_me:$LINENO: checking for main in -lsocket" >&5
4780 echo $ECHO_N "checking for main in -lsocket... $ECHO_C" >&6
4781 if test "${ac_cv_lib_socket_main+set}" = set; then
4782   echo $ECHO_N "(cached) $ECHO_C" >&6
4783 else
4784   ac_check_lib_save_LIBS=$LIBS
4785 LIBS="-lsocket  $LIBS"
4786 cat >conftest.$ac_ext <<_ACEOF
4787 #line $LINENO "configure"
4788 #include "confdefs.h"
4789
4790
4791 #ifdef F77_DUMMY_MAIN
4792 #  ifdef __cplusplus
4793      extern "C"
4794 #  endif
4795    int F77_DUMMY_MAIN() { return 1; }
4796 #endif
4797 int
4798 main ()
4799 {
4800 main ();
4801   ;
4802   return 0;
4803 }
4804 _ACEOF
4805 rm -f conftest.$ac_objext conftest$ac_exeext
4806 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4807   (eval $ac_link) 2>&5
4808   ac_status=$?
4809   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4810   (exit $ac_status); } &&
4811          { ac_try='test -s conftest$ac_exeext'
4812   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4813   (eval $ac_try) 2>&5
4814   ac_status=$?
4815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4816   (exit $ac_status); }; }; then
4817   ac_cv_lib_socket_main=yes
4818 else
4819   echo "$as_me: failed program was:" >&5
4820 cat conftest.$ac_ext >&5
4821 ac_cv_lib_socket_main=no
4822 fi
4823 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4824 LIBS=$ac_check_lib_save_LIBS
4825 fi
4826 echo "$as_me:$LINENO: result: $ac_cv_lib_socket_main" >&5
4827 echo "${ECHO_T}$ac_cv_lib_socket_main" >&6
4828 if test $ac_cv_lib_socket_main = yes; then
4829   cat >>confdefs.h <<_ACEOF
4830 #define HAVE_LIBSOCKET 1
4831 _ACEOF
4832
4833   LIBS="-lsocket $LIBS"
4834
4835 fi
4836
4837
4838 echo "$as_me:$LINENO: checking for main in -lipc" >&5
4839 echo $ECHO_N "checking for main in -lipc... $ECHO_C" >&6
4840 if test "${ac_cv_lib_ipc_main+set}" = set; then
4841   echo $ECHO_N "(cached) $ECHO_C" >&6
4842 else
4843   ac_check_lib_save_LIBS=$LIBS
4844 LIBS="-lipc  $LIBS"
4845 cat >conftest.$ac_ext <<_ACEOF
4846 #line $LINENO "configure"
4847 #include "confdefs.h"
4848
4849
4850 #ifdef F77_DUMMY_MAIN
4851 #  ifdef __cplusplus
4852      extern "C"
4853 #  endif
4854    int F77_DUMMY_MAIN() { return 1; }
4855 #endif
4856 int
4857 main ()
4858 {
4859 main ();
4860   ;
4861   return 0;
4862 }
4863 _ACEOF
4864 rm -f conftest.$ac_objext conftest$ac_exeext
4865 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4866   (eval $ac_link) 2>&5
4867   ac_status=$?
4868   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4869   (exit $ac_status); } &&
4870          { ac_try='test -s conftest$ac_exeext'
4871   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4872   (eval $ac_try) 2>&5
4873   ac_status=$?
4874   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4875   (exit $ac_status); }; }; then
4876   ac_cv_lib_ipc_main=yes
4877 else
4878   echo "$as_me: failed program was:" >&5
4879 cat conftest.$ac_ext >&5
4880 ac_cv_lib_ipc_main=no
4881 fi
4882 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4883 LIBS=$ac_check_lib_save_LIBS
4884 fi
4885 echo "$as_me:$LINENO: result: $ac_cv_lib_ipc_main" >&5
4886 echo "${ECHO_T}$ac_cv_lib_ipc_main" >&6
4887 if test $ac_cv_lib_ipc_main = yes; then
4888   cat >>confdefs.h <<_ACEOF
4889 #define HAVE_LIBIPC 1
4890 _ACEOF
4891
4892   LIBS="-lipc $LIBS"
4893
4894 fi
4895
4896
4897 echo "$as_me:$LINENO: checking for main in -lIPC" >&5
4898 echo $ECHO_N "checking for main in -lIPC... $ECHO_C" >&6
4899 if test "${ac_cv_lib_IPC_main+set}" = set; then
4900   echo $ECHO_N "(cached) $ECHO_C" >&6
4901 else
4902   ac_check_lib_save_LIBS=$LIBS
4903 LIBS="-lIPC  $LIBS"
4904 cat >conftest.$ac_ext <<_ACEOF
4905 #line $LINENO "configure"
4906 #include "confdefs.h"
4907
4908
4909 #ifdef F77_DUMMY_MAIN
4910 #  ifdef __cplusplus
4911      extern "C"
4912 #  endif
4913    int F77_DUMMY_MAIN() { return 1; }
4914 #endif
4915 int
4916 main ()
4917 {
4918 main ();
4919   ;
4920   return 0;
4921 }
4922 _ACEOF
4923 rm -f conftest.$ac_objext conftest$ac_exeext
4924 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4925   (eval $ac_link) 2>&5
4926   ac_status=$?
4927   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4928   (exit $ac_status); } &&
4929          { ac_try='test -s conftest$ac_exeext'
4930   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4931   (eval $ac_try) 2>&5
4932   ac_status=$?
4933   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4934   (exit $ac_status); }; }; then
4935   ac_cv_lib_IPC_main=yes
4936 else
4937   echo "$as_me: failed program was:" >&5
4938 cat conftest.$ac_ext >&5
4939 ac_cv_lib_IPC_main=no
4940 fi
4941 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
4942 LIBS=$ac_check_lib_save_LIBS
4943 fi
4944 echo "$as_me:$LINENO: result: $ac_cv_lib_IPC_main" >&5
4945 echo "${ECHO_T}$ac_cv_lib_IPC_main" >&6
4946 if test $ac_cv_lib_IPC_main = yes; then
4947   cat >>confdefs.h <<_ACEOF
4948 #define HAVE_LIBIPC 1
4949 _ACEOF
4950
4951   LIBS="-lIPC $LIBS"
4952
4953 fi
4954
4955
4956 echo "$as_me:$LINENO: checking for main in -llc" >&5
4957 echo $ECHO_N "checking for main in -llc... $ECHO_C" >&6
4958 if test "${ac_cv_lib_lc_main+set}" = set; then
4959   echo $ECHO_N "(cached) $ECHO_C" >&6
4960 else
4961   ac_check_lib_save_LIBS=$LIBS
4962 LIBS="-llc  $LIBS"
4963 cat >conftest.$ac_ext <<_ACEOF
4964 #line $LINENO "configure"
4965 #include "confdefs.h"
4966
4967
4968 #ifdef F77_DUMMY_MAIN
4969 #  ifdef __cplusplus
4970      extern "C"
4971 #  endif
4972    int F77_DUMMY_MAIN() { return 1; }
4973 #endif
4974 int
4975 main ()
4976 {
4977 main ();
4978   ;
4979   return 0;
4980 }
4981 _ACEOF
4982 rm -f conftest.$ac_objext conftest$ac_exeext
4983 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
4984   (eval $ac_link) 2>&5
4985   ac_status=$?
4986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4987   (exit $ac_status); } &&
4988          { ac_try='test -s conftest$ac_exeext'
4989   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
4990   (eval $ac_try) 2>&5
4991   ac_status=$?
4992   echo "$as_me:$LINENO: \$? = $ac_status" >&5
4993   (exit $ac_status); }; }; then
4994   ac_cv_lib_lc_main=yes
4995 else
4996   echo "$as_me: failed program was:" >&5
4997 cat conftest.$ac_ext >&5
4998 ac_cv_lib_lc_main=no
4999 fi
5000 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5001 LIBS=$ac_check_lib_save_LIBS
5002 fi
5003 echo "$as_me:$LINENO: result: $ac_cv_lib_lc_main" >&5
5004 echo "${ECHO_T}$ac_cv_lib_lc_main" >&6
5005 if test $ac_cv_lib_lc_main = yes; then
5006   cat >>confdefs.h <<_ACEOF
5007 #define HAVE_LIBLC 1
5008 _ACEOF
5009
5010   LIBS="-llc $LIBS"
5011
5012 fi
5013
5014
5015 echo "$as_me:$LINENO: checking for main in -ldld" >&5
5016 echo $ECHO_N "checking for main in -ldld... $ECHO_C" >&6
5017 if test "${ac_cv_lib_dld_main+set}" = set; then
5018   echo $ECHO_N "(cached) $ECHO_C" >&6
5019 else
5020   ac_check_lib_save_LIBS=$LIBS
5021 LIBS="-ldld  $LIBS"
5022 cat >conftest.$ac_ext <<_ACEOF
5023 #line $LINENO "configure"
5024 #include "confdefs.h"
5025
5026
5027 #ifdef F77_DUMMY_MAIN
5028 #  ifdef __cplusplus
5029      extern "C"
5030 #  endif
5031    int F77_DUMMY_MAIN() { return 1; }
5032 #endif
5033 int
5034 main ()
5035 {
5036 main ();
5037   ;
5038   return 0;
5039 }
5040 _ACEOF
5041 rm -f conftest.$ac_objext conftest$ac_exeext
5042 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5043   (eval $ac_link) 2>&5
5044   ac_status=$?
5045   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5046   (exit $ac_status); } &&
5047          { ac_try='test -s conftest$ac_exeext'
5048   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5049   (eval $ac_try) 2>&5
5050   ac_status=$?
5051   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5052   (exit $ac_status); }; }; then
5053   ac_cv_lib_dld_main=yes
5054 else
5055   echo "$as_me: failed program was:" >&5
5056 cat conftest.$ac_ext >&5
5057 ac_cv_lib_dld_main=no
5058 fi
5059 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5060 LIBS=$ac_check_lib_save_LIBS
5061 fi
5062 echo "$as_me:$LINENO: result: $ac_cv_lib_dld_main" >&5
5063 echo "${ECHO_T}$ac_cv_lib_dld_main" >&6
5064 if test $ac_cv_lib_dld_main = yes; then
5065   cat >>confdefs.h <<_ACEOF
5066 #define HAVE_LIBDLD 1
5067 _ACEOF
5068
5069   LIBS="-ldld $LIBS"
5070
5071 fi
5072
5073
5074 echo "$as_me:$LINENO: checking for main in -lld" >&5
5075 echo $ECHO_N "checking for main in -lld... $ECHO_C" >&6
5076 if test "${ac_cv_lib_ld_main+set}" = set; then
5077   echo $ECHO_N "(cached) $ECHO_C" >&6
5078 else
5079   ac_check_lib_save_LIBS=$LIBS
5080 LIBS="-lld  $LIBS"
5081 cat >conftest.$ac_ext <<_ACEOF
5082 #line $LINENO "configure"
5083 #include "confdefs.h"
5084
5085
5086 #ifdef F77_DUMMY_MAIN
5087 #  ifdef __cplusplus
5088      extern "C"
5089 #  endif
5090    int F77_DUMMY_MAIN() { return 1; }
5091 #endif
5092 int
5093 main ()
5094 {
5095 main ();
5096   ;
5097   return 0;
5098 }
5099 _ACEOF
5100 rm -f conftest.$ac_objext conftest$ac_exeext
5101 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5102   (eval $ac_link) 2>&5
5103   ac_status=$?
5104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5105   (exit $ac_status); } &&
5106          { ac_try='test -s conftest$ac_exeext'
5107   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5108   (eval $ac_try) 2>&5
5109   ac_status=$?
5110   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5111   (exit $ac_status); }; }; then
5112   ac_cv_lib_ld_main=yes
5113 else
5114   echo "$as_me: failed program was:" >&5
5115 cat conftest.$ac_ext >&5
5116 ac_cv_lib_ld_main=no
5117 fi
5118 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5119 LIBS=$ac_check_lib_save_LIBS
5120 fi
5121 echo "$as_me:$LINENO: result: $ac_cv_lib_ld_main" >&5
5122 echo "${ECHO_T}$ac_cv_lib_ld_main" >&6
5123 if test $ac_cv_lib_ld_main = yes; then
5124   cat >>confdefs.h <<_ACEOF
5125 #define HAVE_LIBLD 1
5126 _ACEOF
5127
5128   LIBS="-lld $LIBS"
5129
5130 fi
5131
5132
5133 echo "$as_me:$LINENO: checking for main in -lcompat" >&5
5134 echo $ECHO_N "checking for main in -lcompat... $ECHO_C" >&6
5135 if test "${ac_cv_lib_compat_main+set}" = set; then
5136   echo $ECHO_N "(cached) $ECHO_C" >&6
5137 else
5138   ac_check_lib_save_LIBS=$LIBS
5139 LIBS="-lcompat  $LIBS"
5140 cat >conftest.$ac_ext <<_ACEOF
5141 #line $LINENO "configure"
5142 #include "confdefs.h"
5143
5144
5145 #ifdef F77_DUMMY_MAIN
5146 #  ifdef __cplusplus
5147      extern "C"
5148 #  endif
5149    int F77_DUMMY_MAIN() { return 1; }
5150 #endif
5151 int
5152 main ()
5153 {
5154 main ();
5155   ;
5156   return 0;
5157 }
5158 _ACEOF
5159 rm -f conftest.$ac_objext conftest$ac_exeext
5160 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5161   (eval $ac_link) 2>&5
5162   ac_status=$?
5163   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5164   (exit $ac_status); } &&
5165          { ac_try='test -s conftest$ac_exeext'
5166   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5167   (eval $ac_try) 2>&5
5168   ac_status=$?
5169   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5170   (exit $ac_status); }; }; then
5171   ac_cv_lib_compat_main=yes
5172 else
5173   echo "$as_me: failed program was:" >&5
5174 cat conftest.$ac_ext >&5
5175 ac_cv_lib_compat_main=no
5176 fi
5177 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5178 LIBS=$ac_check_lib_save_LIBS
5179 fi
5180 echo "$as_me:$LINENO: result: $ac_cv_lib_compat_main" >&5
5181 echo "${ECHO_T}$ac_cv_lib_compat_main" >&6
5182 if test $ac_cv_lib_compat_main = yes; then
5183   cat >>confdefs.h <<_ACEOF
5184 #define HAVE_LIBCOMPAT 1
5185 _ACEOF
5186
5187   LIBS="-lcompat $LIBS"
5188
5189 fi
5190
5191
5192 echo "$as_me:$LINENO: checking for main in -lBSD" >&5
5193 echo $ECHO_N "checking for main in -lBSD... $ECHO_C" >&6
5194 if test "${ac_cv_lib_BSD_main+set}" = set; then
5195   echo $ECHO_N "(cached) $ECHO_C" >&6
5196 else
5197   ac_check_lib_save_LIBS=$LIBS
5198 LIBS="-lBSD  $LIBS"
5199 cat >conftest.$ac_ext <<_ACEOF
5200 #line $LINENO "configure"
5201 #include "confdefs.h"
5202
5203
5204 #ifdef F77_DUMMY_MAIN
5205 #  ifdef __cplusplus
5206      extern "C"
5207 #  endif
5208    int F77_DUMMY_MAIN() { return 1; }
5209 #endif
5210 int
5211 main ()
5212 {
5213 main ();
5214   ;
5215   return 0;
5216 }
5217 _ACEOF
5218 rm -f conftest.$ac_objext conftest$ac_exeext
5219 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5220   (eval $ac_link) 2>&5
5221   ac_status=$?
5222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5223   (exit $ac_status); } &&
5224          { ac_try='test -s conftest$ac_exeext'
5225   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5226   (eval $ac_try) 2>&5
5227   ac_status=$?
5228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5229   (exit $ac_status); }; }; then
5230   ac_cv_lib_BSD_main=yes
5231 else
5232   echo "$as_me: failed program was:" >&5
5233 cat conftest.$ac_ext >&5
5234 ac_cv_lib_BSD_main=no
5235 fi
5236 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5237 LIBS=$ac_check_lib_save_LIBS
5238 fi
5239 echo "$as_me:$LINENO: result: $ac_cv_lib_BSD_main" >&5
5240 echo "${ECHO_T}$ac_cv_lib_BSD_main" >&6
5241 if test $ac_cv_lib_BSD_main = yes; then
5242   cat >>confdefs.h <<_ACEOF
5243 #define HAVE_LIBBSD 1
5244 _ACEOF
5245
5246   LIBS="-lBSD $LIBS"
5247
5248 fi
5249
5250
5251 echo "$as_me:$LINENO: checking for main in -lgen" >&5
5252 echo $ECHO_N "checking for main in -lgen... $ECHO_C" >&6
5253 if test "${ac_cv_lib_gen_main+set}" = set; then
5254   echo $ECHO_N "(cached) $ECHO_C" >&6
5255 else
5256   ac_check_lib_save_LIBS=$LIBS
5257 LIBS="-lgen  $LIBS"
5258 cat >conftest.$ac_ext <<_ACEOF
5259 #line $LINENO "configure"
5260 #include "confdefs.h"
5261
5262
5263 #ifdef F77_DUMMY_MAIN
5264 #  ifdef __cplusplus
5265      extern "C"
5266 #  endif
5267    int F77_DUMMY_MAIN() { return 1; }
5268 #endif
5269 int
5270 main ()
5271 {
5272 main ();
5273   ;
5274   return 0;
5275 }
5276 _ACEOF
5277 rm -f conftest.$ac_objext conftest$ac_exeext
5278 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5279   (eval $ac_link) 2>&5
5280   ac_status=$?
5281   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5282   (exit $ac_status); } &&
5283          { ac_try='test -s conftest$ac_exeext'
5284   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5285   (eval $ac_try) 2>&5
5286   ac_status=$?
5287   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5288   (exit $ac_status); }; }; then
5289   ac_cv_lib_gen_main=yes
5290 else
5291   echo "$as_me: failed program was:" >&5
5292 cat conftest.$ac_ext >&5
5293 ac_cv_lib_gen_main=no
5294 fi
5295 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5296 LIBS=$ac_check_lib_save_LIBS
5297 fi
5298 echo "$as_me:$LINENO: result: $ac_cv_lib_gen_main" >&5
5299 echo "${ECHO_T}$ac_cv_lib_gen_main" >&6
5300 if test $ac_cv_lib_gen_main = yes; then
5301   cat >>confdefs.h <<_ACEOF
5302 #define HAVE_LIBGEN 1
5303 _ACEOF
5304
5305   LIBS="-lgen $LIBS"
5306
5307 fi
5308
5309
5310 echo "$as_me:$LINENO: checking for main in -lPW" >&5
5311 echo $ECHO_N "checking for main in -lPW... $ECHO_C" >&6
5312 if test "${ac_cv_lib_PW_main+set}" = set; then
5313   echo $ECHO_N "(cached) $ECHO_C" >&6
5314 else
5315   ac_check_lib_save_LIBS=$LIBS
5316 LIBS="-lPW  $LIBS"
5317 cat >conftest.$ac_ext <<_ACEOF
5318 #line $LINENO "configure"
5319 #include "confdefs.h"
5320
5321
5322 #ifdef F77_DUMMY_MAIN
5323 #  ifdef __cplusplus
5324      extern "C"
5325 #  endif
5326    int F77_DUMMY_MAIN() { return 1; }
5327 #endif
5328 int
5329 main ()
5330 {
5331 main ();
5332   ;
5333   return 0;
5334 }
5335 _ACEOF
5336 rm -f conftest.$ac_objext conftest$ac_exeext
5337 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5338   (eval $ac_link) 2>&5
5339   ac_status=$?
5340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5341   (exit $ac_status); } &&
5342          { ac_try='test -s conftest$ac_exeext'
5343   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5344   (eval $ac_try) 2>&5
5345   ac_status=$?
5346   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5347   (exit $ac_status); }; }; then
5348   ac_cv_lib_PW_main=yes
5349 else
5350   echo "$as_me: failed program was:" >&5
5351 cat conftest.$ac_ext >&5
5352 ac_cv_lib_PW_main=no
5353 fi
5354 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5355 LIBS=$ac_check_lib_save_LIBS
5356 fi
5357 echo "$as_me:$LINENO: result: $ac_cv_lib_PW_main" >&5
5358 echo "${ECHO_T}$ac_cv_lib_PW_main" >&6
5359 if test $ac_cv_lib_PW_main = yes; then
5360   cat >>confdefs.h <<_ACEOF
5361 #define HAVE_LIBPW 1
5362 _ACEOF
5363
5364   LIBS="-lPW $LIBS"
5365
5366 fi
5367
5368
5369 echo "$as_me:$LINENO: checking for main in -lresolv" >&5
5370 echo $ECHO_N "checking for main in -lresolv... $ECHO_C" >&6
5371 if test "${ac_cv_lib_resolv_main+set}" = set; then
5372   echo $ECHO_N "(cached) $ECHO_C" >&6
5373 else
5374   ac_check_lib_save_LIBS=$LIBS
5375 LIBS="-lresolv  $LIBS"
5376 cat >conftest.$ac_ext <<_ACEOF
5377 #line $LINENO "configure"
5378 #include "confdefs.h"
5379
5380
5381 #ifdef F77_DUMMY_MAIN
5382 #  ifdef __cplusplus
5383      extern "C"
5384 #  endif
5385    int F77_DUMMY_MAIN() { return 1; }
5386 #endif
5387 int
5388 main ()
5389 {
5390 main ();
5391   ;
5392   return 0;
5393 }
5394 _ACEOF
5395 rm -f conftest.$ac_objext conftest$ac_exeext
5396 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5397   (eval $ac_link) 2>&5
5398   ac_status=$?
5399   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5400   (exit $ac_status); } &&
5401          { ac_try='test -s conftest$ac_exeext'
5402   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5403   (eval $ac_try) 2>&5
5404   ac_status=$?
5405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5406   (exit $ac_status); }; }; then
5407   ac_cv_lib_resolv_main=yes
5408 else
5409   echo "$as_me: failed program was:" >&5
5410 cat conftest.$ac_ext >&5
5411 ac_cv_lib_resolv_main=no
5412 fi
5413 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5414 LIBS=$ac_check_lib_save_LIBS
5415 fi
5416 echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_main" >&5
5417 echo "${ECHO_T}$ac_cv_lib_resolv_main" >&6
5418 if test $ac_cv_lib_resolv_main = yes; then
5419   cat >>confdefs.h <<_ACEOF
5420 #define HAVE_LIBRESOLV 1
5421 _ACEOF
5422
5423   LIBS="-lresolv $LIBS"
5424
5425 fi
5426
5427 echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
5428 echo $ECHO_N "checking for library containing getopt_long... $ECHO_C" >&6
5429 if test "${ac_cv_search_getopt_long+set}" = set; then
5430   echo $ECHO_N "(cached) $ECHO_C" >&6
5431 else
5432   ac_func_search_save_LIBS=$LIBS
5433 ac_cv_search_getopt_long=no
5434 cat >conftest.$ac_ext <<_ACEOF
5435 #line $LINENO "configure"
5436 #include "confdefs.h"
5437
5438 /* Override any gcc2 internal prototype to avoid an error.  */
5439 #ifdef __cplusplus
5440 extern "C"
5441 #endif
5442 /* We use char because int might match the return type of a gcc2
5443    builtin and then its argument prototype would still apply.  */
5444 char getopt_long ();
5445 #ifdef F77_DUMMY_MAIN
5446 #  ifdef __cplusplus
5447      extern "C"
5448 #  endif
5449    int F77_DUMMY_MAIN() { return 1; }
5450 #endif
5451 int
5452 main ()
5453 {
5454 getopt_long ();
5455   ;
5456   return 0;
5457 }
5458 _ACEOF
5459 rm -f conftest.$ac_objext conftest$ac_exeext
5460 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5461   (eval $ac_link) 2>&5
5462   ac_status=$?
5463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5464   (exit $ac_status); } &&
5465          { ac_try='test -s conftest$ac_exeext'
5466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5467   (eval $ac_try) 2>&5
5468   ac_status=$?
5469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5470   (exit $ac_status); }; }; then
5471   ac_cv_search_getopt_long="none required"
5472 else
5473   echo "$as_me: failed program was:" >&5
5474 cat conftest.$ac_ext >&5
5475 fi
5476 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5477 if test "$ac_cv_search_getopt_long" = no; then
5478   for ac_lib in getopt gnugetopt; do
5479     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5480     cat >conftest.$ac_ext <<_ACEOF
5481 #line $LINENO "configure"
5482 #include "confdefs.h"
5483
5484 /* Override any gcc2 internal prototype to avoid an error.  */
5485 #ifdef __cplusplus
5486 extern "C"
5487 #endif
5488 /* We use char because int might match the return type of a gcc2
5489    builtin and then its argument prototype would still apply.  */
5490 char getopt_long ();
5491 #ifdef F77_DUMMY_MAIN
5492 #  ifdef __cplusplus
5493      extern "C"
5494 #  endif
5495    int F77_DUMMY_MAIN() { return 1; }
5496 #endif
5497 int
5498 main ()
5499 {
5500 getopt_long ();
5501   ;
5502   return 0;
5503 }
5504 _ACEOF
5505 rm -f conftest.$ac_objext conftest$ac_exeext
5506 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5507   (eval $ac_link) 2>&5
5508   ac_status=$?
5509   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5510   (exit $ac_status); } &&
5511          { ac_try='test -s conftest$ac_exeext'
5512   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5513   (eval $ac_try) 2>&5
5514   ac_status=$?
5515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5516   (exit $ac_status); }; }; then
5517   ac_cv_search_getopt_long="-l$ac_lib"
5518 break
5519 else
5520   echo "$as_me: failed program was:" >&5
5521 cat conftest.$ac_ext >&5
5522 fi
5523 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5524   done
5525 fi
5526 LIBS=$ac_func_search_save_LIBS
5527 fi
5528 echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
5529 echo "${ECHO_T}$ac_cv_search_getopt_long" >&6
5530 if test "$ac_cv_search_getopt_long" != no; then
5531   test "$ac_cv_search_getopt_long" = "none required" || LIBS="$ac_cv_search_getopt_long $LIBS"
5532
5533 fi
5534
5535 # QNX:
5536
5537 echo "$as_me:$LINENO: checking for main in -lunix" >&5
5538 echo $ECHO_N "checking for main in -lunix... $ECHO_C" >&6
5539 if test "${ac_cv_lib_unix_main+set}" = set; then
5540   echo $ECHO_N "(cached) $ECHO_C" >&6
5541 else
5542   ac_check_lib_save_LIBS=$LIBS
5543 LIBS="-lunix  $LIBS"
5544 cat >conftest.$ac_ext <<_ACEOF
5545 #line $LINENO "configure"
5546 #include "confdefs.h"
5547
5548
5549 #ifdef F77_DUMMY_MAIN
5550 #  ifdef __cplusplus
5551      extern "C"
5552 #  endif
5553    int F77_DUMMY_MAIN() { return 1; }
5554 #endif
5555 int
5556 main ()
5557 {
5558 main ();
5559   ;
5560   return 0;
5561 }
5562 _ACEOF
5563 rm -f conftest.$ac_objext conftest$ac_exeext
5564 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5565   (eval $ac_link) 2>&5
5566   ac_status=$?
5567   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5568   (exit $ac_status); } &&
5569          { ac_try='test -s conftest$ac_exeext'
5570   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5571   (eval $ac_try) 2>&5
5572   ac_status=$?
5573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5574   (exit $ac_status); }; }; then
5575   ac_cv_lib_unix_main=yes
5576 else
5577   echo "$as_me: failed program was:" >&5
5578 cat conftest.$ac_ext >&5
5579 ac_cv_lib_unix_main=no
5580 fi
5581 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5582 LIBS=$ac_check_lib_save_LIBS
5583 fi
5584 echo "$as_me:$LINENO: result: $ac_cv_lib_unix_main" >&5
5585 echo "${ECHO_T}$ac_cv_lib_unix_main" >&6
5586 if test $ac_cv_lib_unix_main = yes; then
5587   cat >>confdefs.h <<_ACEOF
5588 #define HAVE_LIBUNIX 1
5589 _ACEOF
5590
5591   LIBS="-lunix $LIBS"
5592
5593 fi
5594
5595 echo "$as_me:$LINENO: checking for library containing crypt" >&5
5596 echo $ECHO_N "checking for library containing crypt... $ECHO_C" >&6
5597 if test "${ac_cv_search_crypt+set}" = set; then
5598   echo $ECHO_N "(cached) $ECHO_C" >&6
5599 else
5600   ac_func_search_save_LIBS=$LIBS
5601 ac_cv_search_crypt=no
5602 cat >conftest.$ac_ext <<_ACEOF
5603 #line $LINENO "configure"
5604 #include "confdefs.h"
5605
5606 /* Override any gcc2 internal prototype to avoid an error.  */
5607 #ifdef __cplusplus
5608 extern "C"
5609 #endif
5610 /* We use char because int might match the return type of a gcc2
5611    builtin and then its argument prototype would still apply.  */
5612 char crypt ();
5613 #ifdef F77_DUMMY_MAIN
5614 #  ifdef __cplusplus
5615      extern "C"
5616 #  endif
5617    int F77_DUMMY_MAIN() { return 1; }
5618 #endif
5619 int
5620 main ()
5621 {
5622 crypt ();
5623   ;
5624   return 0;
5625 }
5626 _ACEOF
5627 rm -f conftest.$ac_objext conftest$ac_exeext
5628 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5629   (eval $ac_link) 2>&5
5630   ac_status=$?
5631   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5632   (exit $ac_status); } &&
5633          { ac_try='test -s conftest$ac_exeext'
5634   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5635   (eval $ac_try) 2>&5
5636   ac_status=$?
5637   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5638   (exit $ac_status); }; }; then
5639   ac_cv_search_crypt="none required"
5640 else
5641   echo "$as_me: failed program was:" >&5
5642 cat conftest.$ac_ext >&5
5643 fi
5644 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5645 if test "$ac_cv_search_crypt" = no; then
5646   for ac_lib in crypt; do
5647     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5648     cat >conftest.$ac_ext <<_ACEOF
5649 #line $LINENO "configure"
5650 #include "confdefs.h"
5651
5652 /* Override any gcc2 internal prototype to avoid an error.  */
5653 #ifdef __cplusplus
5654 extern "C"
5655 #endif
5656 /* We use char because int might match the return type of a gcc2
5657    builtin and then its argument prototype would still apply.  */
5658 char crypt ();
5659 #ifdef F77_DUMMY_MAIN
5660 #  ifdef __cplusplus
5661      extern "C"
5662 #  endif
5663    int F77_DUMMY_MAIN() { return 1; }
5664 #endif
5665 int
5666 main ()
5667 {
5668 crypt ();
5669   ;
5670   return 0;
5671 }
5672 _ACEOF
5673 rm -f conftest.$ac_objext conftest$ac_exeext
5674 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5675   (eval $ac_link) 2>&5
5676   ac_status=$?
5677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5678   (exit $ac_status); } &&
5679          { ac_try='test -s conftest$ac_exeext'
5680   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5681   (eval $ac_try) 2>&5
5682   ac_status=$?
5683   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5684   (exit $ac_status); }; }; then
5685   ac_cv_search_crypt="-l$ac_lib"
5686 break
5687 else
5688   echo "$as_me: failed program was:" >&5
5689 cat conftest.$ac_ext >&5
5690 fi
5691 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5692   done
5693 fi
5694 LIBS=$ac_func_search_save_LIBS
5695 fi
5696 echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
5697 echo "${ECHO_T}$ac_cv_search_crypt" >&6
5698 if test "$ac_cv_search_crypt" != no; then
5699   test "$ac_cv_search_crypt" = "none required" || LIBS="$ac_cv_search_crypt $LIBS"
5700
5701 fi
5702
5703 # BeOS:
5704 if test "$PORTNAME" = "beos"
5705 then
5706
5707 echo "$as_me:$LINENO: checking for __inet_ntoa in -lbind" >&5
5708 echo $ECHO_N "checking for __inet_ntoa in -lbind... $ECHO_C" >&6
5709 if test "${ac_cv_lib_bind___inet_ntoa+set}" = set; then
5710   echo $ECHO_N "(cached) $ECHO_C" >&6
5711 else
5712   ac_check_lib_save_LIBS=$LIBS
5713 LIBS="-lbind  $LIBS"
5714 cat >conftest.$ac_ext <<_ACEOF
5715 #line $LINENO "configure"
5716 #include "confdefs.h"
5717
5718 /* Override any gcc2 internal prototype to avoid an error.  */
5719 #ifdef __cplusplus
5720 extern "C"
5721 #endif
5722 /* We use char because int might match the return type of a gcc2
5723    builtin and then its argument prototype would still apply.  */
5724 char __inet_ntoa ();
5725 #ifdef F77_DUMMY_MAIN
5726 #  ifdef __cplusplus
5727      extern "C"
5728 #  endif
5729    int F77_DUMMY_MAIN() { return 1; }
5730 #endif
5731 int
5732 main ()
5733 {
5734 __inet_ntoa ();
5735   ;
5736   return 0;
5737 }
5738 _ACEOF
5739 rm -f conftest.$ac_objext conftest$ac_exeext
5740 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5741   (eval $ac_link) 2>&5
5742   ac_status=$?
5743   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5744   (exit $ac_status); } &&
5745          { ac_try='test -s conftest$ac_exeext'
5746   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5747   (eval $ac_try) 2>&5
5748   ac_status=$?
5749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5750   (exit $ac_status); }; }; then
5751   ac_cv_lib_bind___inet_ntoa=yes
5752 else
5753   echo "$as_me: failed program was:" >&5
5754 cat conftest.$ac_ext >&5
5755 ac_cv_lib_bind___inet_ntoa=no
5756 fi
5757 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5758 LIBS=$ac_check_lib_save_LIBS
5759 fi
5760 echo "$as_me:$LINENO: result: $ac_cv_lib_bind___inet_ntoa" >&5
5761 echo "${ECHO_T}$ac_cv_lib_bind___inet_ntoa" >&6
5762 if test $ac_cv_lib_bind___inet_ntoa = yes; then
5763   cat >>confdefs.h <<_ACEOF
5764 #define HAVE_LIBBIND 1
5765 _ACEOF
5766
5767   LIBS="-lbind $LIBS"
5768
5769 fi
5770
5771 fi
5772 # Solaris:
5773 echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
5774 echo $ECHO_N "checking for library containing fdatasync... $ECHO_C" >&6
5775 if test "${ac_cv_search_fdatasync+set}" = set; then
5776   echo $ECHO_N "(cached) $ECHO_C" >&6
5777 else
5778   ac_func_search_save_LIBS=$LIBS
5779 ac_cv_search_fdatasync=no
5780 cat >conftest.$ac_ext <<_ACEOF
5781 #line $LINENO "configure"
5782 #include "confdefs.h"
5783
5784 /* Override any gcc2 internal prototype to avoid an error.  */
5785 #ifdef __cplusplus
5786 extern "C"
5787 #endif
5788 /* We use char because int might match the return type of a gcc2
5789    builtin and then its argument prototype would still apply.  */
5790 char fdatasync ();
5791 #ifdef F77_DUMMY_MAIN
5792 #  ifdef __cplusplus
5793      extern "C"
5794 #  endif
5795    int F77_DUMMY_MAIN() { return 1; }
5796 #endif
5797 int
5798 main ()
5799 {
5800 fdatasync ();
5801   ;
5802   return 0;
5803 }
5804 _ACEOF
5805 rm -f conftest.$ac_objext conftest$ac_exeext
5806 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5807   (eval $ac_link) 2>&5
5808   ac_status=$?
5809   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5810   (exit $ac_status); } &&
5811          { ac_try='test -s conftest$ac_exeext'
5812   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5813   (eval $ac_try) 2>&5
5814   ac_status=$?
5815   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5816   (exit $ac_status); }; }; then
5817   ac_cv_search_fdatasync="none required"
5818 else
5819   echo "$as_me: failed program was:" >&5
5820 cat conftest.$ac_ext >&5
5821 fi
5822 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5823 if test "$ac_cv_search_fdatasync" = no; then
5824   for ac_lib in rt posix4; do
5825     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
5826     cat >conftest.$ac_ext <<_ACEOF
5827 #line $LINENO "configure"
5828 #include "confdefs.h"
5829
5830 /* Override any gcc2 internal prototype to avoid an error.  */
5831 #ifdef __cplusplus
5832 extern "C"
5833 #endif
5834 /* We use char because int might match the return type of a gcc2
5835    builtin and then its argument prototype would still apply.  */
5836 char fdatasync ();
5837 #ifdef F77_DUMMY_MAIN
5838 #  ifdef __cplusplus
5839      extern "C"
5840 #  endif
5841    int F77_DUMMY_MAIN() { return 1; }
5842 #endif
5843 int
5844 main ()
5845 {
5846 fdatasync ();
5847   ;
5848   return 0;
5849 }
5850 _ACEOF
5851 rm -f conftest.$ac_objext conftest$ac_exeext
5852 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5853   (eval $ac_link) 2>&5
5854   ac_status=$?
5855   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5856   (exit $ac_status); } &&
5857          { ac_try='test -s conftest$ac_exeext'
5858   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5859   (eval $ac_try) 2>&5
5860   ac_status=$?
5861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5862   (exit $ac_status); }; }; then
5863   ac_cv_search_fdatasync="-l$ac_lib"
5864 break
5865 else
5866   echo "$as_me: failed program was:" >&5
5867 cat conftest.$ac_ext >&5
5868 fi
5869 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5870   done
5871 fi
5872 LIBS=$ac_func_search_save_LIBS
5873 fi
5874 echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
5875 echo "${ECHO_T}$ac_cv_search_fdatasync" >&6
5876 if test "$ac_cv_search_fdatasync" != no; then
5877   test "$ac_cv_search_fdatasync" = "none required" || LIBS="$ac_cv_search_fdatasync $LIBS"
5878
5879 fi
5880
5881 # Cygwin:
5882
5883 echo "$as_me:$LINENO: checking for shmget in -lcygipc" >&5
5884 echo $ECHO_N "checking for shmget in -lcygipc... $ECHO_C" >&6
5885 if test "${ac_cv_lib_cygipc_shmget+set}" = set; then
5886   echo $ECHO_N "(cached) $ECHO_C" >&6
5887 else
5888   ac_check_lib_save_LIBS=$LIBS
5889 LIBS="-lcygipc  $LIBS"
5890 cat >conftest.$ac_ext <<_ACEOF
5891 #line $LINENO "configure"
5892 #include "confdefs.h"
5893
5894 /* Override any gcc2 internal prototype to avoid an error.  */
5895 #ifdef __cplusplus
5896 extern "C"
5897 #endif
5898 /* We use char because int might match the return type of a gcc2
5899    builtin and then its argument prototype would still apply.  */
5900 char shmget ();
5901 #ifdef F77_DUMMY_MAIN
5902 #  ifdef __cplusplus
5903      extern "C"
5904 #  endif
5905    int F77_DUMMY_MAIN() { return 1; }
5906 #endif
5907 int
5908 main ()
5909 {
5910 shmget ();
5911   ;
5912   return 0;
5913 }
5914 _ACEOF
5915 rm -f conftest.$ac_objext conftest$ac_exeext
5916 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5917   (eval $ac_link) 2>&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_lib_cygipc_shmget=yes
5928 else
5929   echo "$as_me: failed program was:" >&5
5930 cat conftest.$ac_ext >&5
5931 ac_cv_lib_cygipc_shmget=no
5932 fi
5933 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5934 LIBS=$ac_check_lib_save_LIBS
5935 fi
5936 echo "$as_me:$LINENO: result: $ac_cv_lib_cygipc_shmget" >&5
5937 echo "${ECHO_T}$ac_cv_lib_cygipc_shmget" >&6
5938 if test $ac_cv_lib_cygipc_shmget = yes; then
5939   cat >>confdefs.h <<_ACEOF
5940 #define HAVE_LIBCYGIPC 1
5941 _ACEOF
5942
5943   LIBS="-lcygipc $LIBS"
5944
5945 fi
5946
5947 # WIN32:
5948 if test "$PORTNAME" = "win32"
5949 then
5950
5951 echo "$as_me:$LINENO: checking for main in -lwsock32" >&5
5952 echo $ECHO_N "checking for main in -lwsock32... $ECHO_C" >&6
5953 if test "${ac_cv_lib_wsock32_main+set}" = set; then
5954   echo $ECHO_N "(cached) $ECHO_C" >&6
5955 else
5956   ac_check_lib_save_LIBS=$LIBS
5957 LIBS="-lwsock32  $LIBS"
5958 cat >conftest.$ac_ext <<_ACEOF
5959 #line $LINENO "configure"
5960 #include "confdefs.h"
5961
5962
5963 #ifdef F77_DUMMY_MAIN
5964 #  ifdef __cplusplus
5965      extern "C"
5966 #  endif
5967    int F77_DUMMY_MAIN() { return 1; }
5968 #endif
5969 int
5970 main ()
5971 {
5972 main ();
5973   ;
5974   return 0;
5975 }
5976 _ACEOF
5977 rm -f conftest.$ac_objext conftest$ac_exeext
5978 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
5979   (eval $ac_link) 2>&5
5980   ac_status=$?
5981   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5982   (exit $ac_status); } &&
5983          { ac_try='test -s conftest$ac_exeext'
5984   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
5985   (eval $ac_try) 2>&5
5986   ac_status=$?
5987   echo "$as_me:$LINENO: \$? = $ac_status" >&5
5988   (exit $ac_status); }; }; then
5989   ac_cv_lib_wsock32_main=yes
5990 else
5991   echo "$as_me: failed program was:" >&5
5992 cat conftest.$ac_ext >&5
5993 ac_cv_lib_wsock32_main=no
5994 fi
5995 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
5996 LIBS=$ac_check_lib_save_LIBS
5997 fi
5998 echo "$as_me:$LINENO: result: $ac_cv_lib_wsock32_main" >&5
5999 echo "${ECHO_T}$ac_cv_lib_wsock32_main" >&6
6000 if test $ac_cv_lib_wsock32_main = yes; then
6001   cat >>confdefs.h <<_ACEOF
6002 #define HAVE_LIBWSOCK32 1
6003 _ACEOF
6004
6005   LIBS="-lwsock32 $LIBS"
6006
6007 fi
6008
6009 fi
6010
6011 if test "$with_readline" = yes; then
6012
6013 echo "$as_me:$LINENO: checking for readline" >&5
6014 echo $ECHO_N "checking for readline... $ECHO_C" >&6
6015
6016 if test "${pgac_cv_check_readline+set}" = set; then
6017   echo $ECHO_N "(cached) $ECHO_C" >&6
6018 else
6019   pgac_cv_check_readline=no
6020 pgac_save_LIBS=$LIBS
6021 for pgac_rllib in -lreadline -ledit ; do
6022   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
6023     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
6024     cat >conftest.$ac_ext <<_ACEOF
6025 #line $LINENO "configure"
6026 #include "confdefs.h"
6027
6028 /* Override any gcc2 internal prototype to avoid an error.  */
6029 #ifdef __cplusplus
6030 extern "C"
6031 #endif
6032 /* We use char because int might match the return type of a gcc2
6033    builtin and then its argument prototype would still apply.  */
6034 char readline ();
6035 #ifdef F77_DUMMY_MAIN
6036 #  ifdef __cplusplus
6037      extern "C"
6038 #  endif
6039    int F77_DUMMY_MAIN() { return 1; }
6040 #endif
6041 int
6042 main ()
6043 {
6044 readline ();
6045   ;
6046   return 0;
6047 }
6048 _ACEOF
6049 rm -f conftest.$ac_objext conftest$ac_exeext
6050 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6051   (eval $ac_link) 2>&5
6052   ac_status=$?
6053   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6054   (exit $ac_status); } &&
6055          { ac_try='test -s conftest$ac_exeext'
6056   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6057   (eval $ac_try) 2>&5
6058   ac_status=$?
6059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6060   (exit $ac_status); }; }; then
6061
6062       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
6063       # recognize dependent libraries; assume curses is needed if we didn't
6064       # find any dependency.
6065       case $host_os in
6066         netbsd* | openbsd* | irix*)
6067           if test x"$pgac_lib" = x"" ; then
6068             pgac_lib=" -lcurses"
6069           fi ;;
6070       esac
6071
6072       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
6073       break 2
6074
6075 else
6076   echo "$as_me: failed program was:" >&5
6077 cat conftest.$ac_ext >&5
6078 fi
6079 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6080   done
6081 done
6082 LIBS=$pgac_save_LIBS
6083
6084 fi
6085
6086 if test "$pgac_cv_check_readline" != no ; then
6087
6088 cat >>confdefs.h <<\_ACEOF
6089 #define HAVE_LIBREADLINE 1
6090 _ACEOF
6091
6092   LIBS="$pgac_cv_check_readline $LIBS"
6093   echo "$as_me:$LINENO: result: yes ($pgac_cv_check_readline)" >&5
6094 echo "${ECHO_T}yes ($pgac_cv_check_readline)" >&6
6095 else
6096   echo "$as_me:$LINENO: result: no" >&5
6097 echo "${ECHO_T}no" >&6
6098 fi
6099   if test x"$pgac_cv_check_readline" = x"no"; then
6100     { { echo "$as_me:$LINENO: error: readline library not found
6101 If you have readline already installed, see config.log for details on the
6102 failure.  It is possible the compiler isn't looking in the proper directory.
6103 Use --without-readline to disable readline support." >&5
6104 echo "$as_me: error: readline library not found
6105 If you have readline already installed, see config.log for details on the
6106 failure.  It is possible the compiler isn't looking in the proper directory.
6107 Use --without-readline to disable readline support." >&2;}
6108    { (exit 1); exit 1; }; }
6109   fi
6110 fi
6111
6112 if test "$with_zlib" = yes; then
6113
6114 echo "$as_me:$LINENO: checking for inflate in -lz" >&5
6115 echo $ECHO_N "checking for inflate in -lz... $ECHO_C" >&6
6116 if test "${ac_cv_lib_z_inflate+set}" = set; then
6117   echo $ECHO_N "(cached) $ECHO_C" >&6
6118 else
6119   ac_check_lib_save_LIBS=$LIBS
6120 LIBS="-lz  $LIBS"
6121 cat >conftest.$ac_ext <<_ACEOF
6122 #line $LINENO "configure"
6123 #include "confdefs.h"
6124
6125 /* Override any gcc2 internal prototype to avoid an error.  */
6126 #ifdef __cplusplus
6127 extern "C"
6128 #endif
6129 /* We use char because int might match the return type of a gcc2
6130    builtin and then its argument prototype would still apply.  */
6131 char inflate ();
6132 #ifdef F77_DUMMY_MAIN
6133 #  ifdef __cplusplus
6134      extern "C"
6135 #  endif
6136    int F77_DUMMY_MAIN() { return 1; }
6137 #endif
6138 int
6139 main ()
6140 {
6141 inflate ();
6142   ;
6143   return 0;
6144 }
6145 _ACEOF
6146 rm -f conftest.$ac_objext conftest$ac_exeext
6147 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6148   (eval $ac_link) 2>&5
6149   ac_status=$?
6150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6151   (exit $ac_status); } &&
6152          { ac_try='test -s conftest$ac_exeext'
6153   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6154   (eval $ac_try) 2>&5
6155   ac_status=$?
6156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6157   (exit $ac_status); }; }; then
6158   ac_cv_lib_z_inflate=yes
6159 else
6160   echo "$as_me: failed program was:" >&5
6161 cat conftest.$ac_ext >&5
6162 ac_cv_lib_z_inflate=no
6163 fi
6164 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6165 LIBS=$ac_check_lib_save_LIBS
6166 fi
6167 echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
6168 echo "${ECHO_T}$ac_cv_lib_z_inflate" >&6
6169 if test $ac_cv_lib_z_inflate = yes; then
6170   cat >>confdefs.h <<_ACEOF
6171 #define HAVE_LIBZ 1
6172 _ACEOF
6173
6174   LIBS="-lz $LIBS"
6175
6176 else
6177   { { echo "$as_me:$LINENO: error: zlib library not found
6178 If you have zlib already installed, see config.log for details on the
6179 failure.  It is possible the compiler isn't looking in the proper directory.
6180 Use --without-zlib to disable zlib support." >&5
6181 echo "$as_me: error: zlib library not found
6182 If you have zlib already installed, see config.log for details on the
6183 failure.  It is possible the compiler isn't looking in the proper directory.
6184 Use --without-zlib to disable zlib support." >&2;}
6185    { (exit 1); exit 1; }; }
6186 fi
6187
6188 fi
6189
6190 if test "$enable_spinlocks" = yes; then
6191
6192 cat >>confdefs.h <<\_ACEOF
6193 #define HAVE_SPINLOCKS 1
6194 _ACEOF
6195
6196 else
6197   { echo "$as_me:$LINENO: WARNING:
6198 *** Not using spinlocks will cause poor performance." >&5
6199 echo "$as_me: WARNING:
6200 *** Not using spinlocks will cause poor performance." >&2;}
6201 fi
6202
6203 if test "$with_krb4" = yes ; then
6204
6205 echo "$as_me:$LINENO: checking for des_encrypt in -ldes" >&5
6206 echo $ECHO_N "checking for des_encrypt in -ldes... $ECHO_C" >&6
6207 if test "${ac_cv_lib_des_des_encrypt+set}" = set; then
6208   echo $ECHO_N "(cached) $ECHO_C" >&6
6209 else
6210   ac_check_lib_save_LIBS=$LIBS
6211 LIBS="-ldes  $LIBS"
6212 cat >conftest.$ac_ext <<_ACEOF
6213 #line $LINENO "configure"
6214 #include "confdefs.h"
6215
6216 /* Override any gcc2 internal prototype to avoid an error.  */
6217 #ifdef __cplusplus
6218 extern "C"
6219 #endif
6220 /* We use char because int might match the return type of a gcc2
6221    builtin and then its argument prototype would still apply.  */
6222 char des_encrypt ();
6223 #ifdef F77_DUMMY_MAIN
6224 #  ifdef __cplusplus
6225      extern "C"
6226 #  endif
6227    int F77_DUMMY_MAIN() { return 1; }
6228 #endif
6229 int
6230 main ()
6231 {
6232 des_encrypt ();
6233   ;
6234   return 0;
6235 }
6236 _ACEOF
6237 rm -f conftest.$ac_objext conftest$ac_exeext
6238 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6239   (eval $ac_link) 2>&5
6240   ac_status=$?
6241   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6242   (exit $ac_status); } &&
6243          { ac_try='test -s conftest$ac_exeext'
6244   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6245   (eval $ac_try) 2>&5
6246   ac_status=$?
6247   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6248   (exit $ac_status); }; }; then
6249   ac_cv_lib_des_des_encrypt=yes
6250 else
6251   echo "$as_me: failed program was:" >&5
6252 cat conftest.$ac_ext >&5
6253 ac_cv_lib_des_des_encrypt=no
6254 fi
6255 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6256 LIBS=$ac_check_lib_save_LIBS
6257 fi
6258 echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_encrypt" >&5
6259 echo "${ECHO_T}$ac_cv_lib_des_des_encrypt" >&6
6260 if test $ac_cv_lib_des_des_encrypt = yes; then
6261   cat >>confdefs.h <<_ACEOF
6262 #define HAVE_LIBDES 1
6263 _ACEOF
6264
6265   LIBS="-ldes $LIBS"
6266
6267 else
6268   { { echo "$as_me:$LINENO: error: library 'des' is required for Kerberos 4" >&5
6269 echo "$as_me: error: library 'des' is required for Kerberos 4" >&2;}
6270    { (exit 1); exit 1; }; }
6271 fi
6272
6273
6274 echo "$as_me:$LINENO: checking for krb_sendauth in -lkrb" >&5
6275 echo $ECHO_N "checking for krb_sendauth in -lkrb... $ECHO_C" >&6
6276 if test "${ac_cv_lib_krb_krb_sendauth+set}" = set; then
6277   echo $ECHO_N "(cached) $ECHO_C" >&6
6278 else
6279   ac_check_lib_save_LIBS=$LIBS
6280 LIBS="-lkrb  $LIBS"
6281 cat >conftest.$ac_ext <<_ACEOF
6282 #line $LINENO "configure"
6283 #include "confdefs.h"
6284
6285 /* Override any gcc2 internal prototype to avoid an error.  */
6286 #ifdef __cplusplus
6287 extern "C"
6288 #endif
6289 /* We use char because int might match the return type of a gcc2
6290    builtin and then its argument prototype would still apply.  */
6291 char krb_sendauth ();
6292 #ifdef F77_DUMMY_MAIN
6293 #  ifdef __cplusplus
6294      extern "C"
6295 #  endif
6296    int F77_DUMMY_MAIN() { return 1; }
6297 #endif
6298 int
6299 main ()
6300 {
6301 krb_sendauth ();
6302   ;
6303   return 0;
6304 }
6305 _ACEOF
6306 rm -f conftest.$ac_objext conftest$ac_exeext
6307 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6308   (eval $ac_link) 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   ac_cv_lib_krb_krb_sendauth=yes
6319 else
6320   echo "$as_me: failed program was:" >&5
6321 cat conftest.$ac_ext >&5
6322 ac_cv_lib_krb_krb_sendauth=no
6323 fi
6324 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6325 LIBS=$ac_check_lib_save_LIBS
6326 fi
6327 echo "$as_me:$LINENO: result: $ac_cv_lib_krb_krb_sendauth" >&5
6328 echo "${ECHO_T}$ac_cv_lib_krb_krb_sendauth" >&6
6329 if test $ac_cv_lib_krb_krb_sendauth = yes; then
6330   cat >>confdefs.h <<_ACEOF
6331 #define HAVE_LIBKRB 1
6332 _ACEOF
6333
6334   LIBS="-lkrb $LIBS"
6335
6336 else
6337   { { echo "$as_me:$LINENO: error: library 'krb' is required for Kerberos 4" >&5
6338 echo "$as_me: error: library 'krb' is required for Kerberos 4" >&2;}
6339    { (exit 1); exit 1; }; }
6340 fi
6341
6342
6343 for ac_func in gethostname
6344 do
6345 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
6346 echo "$as_me:$LINENO: checking for $ac_func" >&5
6347 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
6348 if eval "test \"\${$as_ac_var+set}\" = set"; then
6349   echo $ECHO_N "(cached) $ECHO_C" >&6
6350 else
6351   cat >conftest.$ac_ext <<_ACEOF
6352 #line $LINENO "configure"
6353 #include "confdefs.h"
6354 /* System header to define __stub macros and hopefully few prototypes,
6355     which can conflict with char $ac_func (); below.  */
6356 #include <assert.h>
6357 /* Override any gcc2 internal prototype to avoid an error.  */
6358 #ifdef __cplusplus
6359 extern "C"
6360 #endif
6361 /* We use char because int might match the return type of a gcc2
6362    builtin and then its argument prototype would still apply.  */
6363 char $ac_func ();
6364 char (*f) ();
6365
6366 #ifdef F77_DUMMY_MAIN
6367 #  ifdef __cplusplus
6368      extern "C"
6369 #  endif
6370    int F77_DUMMY_MAIN() { return 1; }
6371 #endif
6372 int
6373 main ()
6374 {
6375 /* The GNU C library defines this for functions which it implements
6376     to always fail with ENOSYS.  Some functions are actually named
6377     something starting with __ and the normal name is an alias.  */
6378 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6379 choke me
6380 #else
6381 f = $ac_func;
6382 #endif
6383
6384   ;
6385   return 0;
6386 }
6387 _ACEOF
6388 rm -f conftest.$ac_objext conftest$ac_exeext
6389 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6390   (eval $ac_link) 2>&5
6391   ac_status=$?
6392   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6393   (exit $ac_status); } &&
6394          { ac_try='test -s conftest$ac_exeext'
6395   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6396   (eval $ac_try) 2>&5
6397   ac_status=$?
6398   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6399   (exit $ac_status); }; }; then
6400   eval "$as_ac_var=yes"
6401 else
6402   echo "$as_me: failed program was:" >&5
6403 cat conftest.$ac_ext >&5
6404 eval "$as_ac_var=no"
6405 fi
6406 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6407 fi
6408 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
6409 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
6410 if test `eval echo '${'$as_ac_var'}'` = yes; then
6411   cat >>confdefs.h <<_ACEOF
6412 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
6413 _ACEOF
6414
6415 else
6416   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
6417 fi
6418 done
6419
6420
6421 fi
6422
6423 if test "$with_krb5" = yes ; then
6424   if test "$PORTNAME" != "win32"; then
6425      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6426 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6427 if test "${ac_cv_search_com_err+set}" = set; then
6428   echo $ECHO_N "(cached) $ECHO_C" >&6
6429 else
6430   ac_func_search_save_LIBS=$LIBS
6431 ac_cv_search_com_err=no
6432 cat >conftest.$ac_ext <<_ACEOF
6433 #line $LINENO "configure"
6434 #include "confdefs.h"
6435
6436 /* Override any gcc2 internal prototype to avoid an error.  */
6437 #ifdef __cplusplus
6438 extern "C"
6439 #endif
6440 /* We use char because int might match the return type of a gcc2
6441    builtin and then its argument prototype would still apply.  */
6442 char com_err ();
6443 #ifdef F77_DUMMY_MAIN
6444 #  ifdef __cplusplus
6445      extern "C"
6446 #  endif
6447    int F77_DUMMY_MAIN() { return 1; }
6448 #endif
6449 int
6450 main ()
6451 {
6452 com_err ();
6453   ;
6454   return 0;
6455 }
6456 _ACEOF
6457 rm -f conftest.$ac_objext conftest$ac_exeext
6458 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6459   (eval $ac_link) 2>&5
6460   ac_status=$?
6461   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6462   (exit $ac_status); } &&
6463          { ac_try='test -s conftest$ac_exeext'
6464   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6465   (eval $ac_try) 2>&5
6466   ac_status=$?
6467   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6468   (exit $ac_status); }; }; then
6469   ac_cv_search_com_err="none required"
6470 else
6471   echo "$as_me: failed program was:" >&5
6472 cat conftest.$ac_ext >&5
6473 fi
6474 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6475 if test "$ac_cv_search_com_err" = no; then
6476   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' com_err; do
6477     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6478     cat >conftest.$ac_ext <<_ACEOF
6479 #line $LINENO "configure"
6480 #include "confdefs.h"
6481
6482 /* Override any gcc2 internal prototype to avoid an error.  */
6483 #ifdef __cplusplus
6484 extern "C"
6485 #endif
6486 /* We use char because int might match the return type of a gcc2
6487    builtin and then its argument prototype would still apply.  */
6488 char com_err ();
6489 #ifdef F77_DUMMY_MAIN
6490 #  ifdef __cplusplus
6491      extern "C"
6492 #  endif
6493    int F77_DUMMY_MAIN() { return 1; }
6494 #endif
6495 int
6496 main ()
6497 {
6498 com_err ();
6499   ;
6500   return 0;
6501 }
6502 _ACEOF
6503 rm -f conftest.$ac_objext conftest$ac_exeext
6504 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6505   (eval $ac_link) 2>&5
6506   ac_status=$?
6507   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6508   (exit $ac_status); } &&
6509          { ac_try='test -s conftest$ac_exeext'
6510   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6511   (eval $ac_try) 2>&5
6512   ac_status=$?
6513   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6514   (exit $ac_status); }; }; then
6515   ac_cv_search_com_err="-l$ac_lib"
6516 break
6517 else
6518   echo "$as_me: failed program was:" >&5
6519 cat conftest.$ac_ext >&5
6520 fi
6521 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6522   done
6523 fi
6524 LIBS=$ac_func_search_save_LIBS
6525 fi
6526 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6527 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6528 if test "$ac_cv_search_com_err" != no; then
6529   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6530
6531 else
6532   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6533 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6534    { (exit 1); exit 1; }; }
6535 fi
6536
6537      echo "$as_me:$LINENO: checking for library containing krb5_encrypt" >&5
6538 echo $ECHO_N "checking for library containing krb5_encrypt... $ECHO_C" >&6
6539 if test "${ac_cv_search_krb5_encrypt+set}" = set; then
6540   echo $ECHO_N "(cached) $ECHO_C" >&6
6541 else
6542   ac_func_search_save_LIBS=$LIBS
6543 ac_cv_search_krb5_encrypt=no
6544 cat >conftest.$ac_ext <<_ACEOF
6545 #line $LINENO "configure"
6546 #include "confdefs.h"
6547
6548 /* Override any gcc2 internal prototype to avoid an error.  */
6549 #ifdef __cplusplus
6550 extern "C"
6551 #endif
6552 /* We use char because int might match the return type of a gcc2
6553    builtin and then its argument prototype would still apply.  */
6554 char krb5_encrypt ();
6555 #ifdef F77_DUMMY_MAIN
6556 #  ifdef __cplusplus
6557      extern "C"
6558 #  endif
6559    int F77_DUMMY_MAIN() { return 1; }
6560 #endif
6561 int
6562 main ()
6563 {
6564 krb5_encrypt ();
6565   ;
6566   return 0;
6567 }
6568 _ACEOF
6569 rm -f conftest.$ac_objext conftest$ac_exeext
6570 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6571   (eval $ac_link) 2>&5
6572   ac_status=$?
6573   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6574   (exit $ac_status); } &&
6575          { ac_try='test -s conftest$ac_exeext'
6576   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6577   (eval $ac_try) 2>&5
6578   ac_status=$?
6579   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6580   (exit $ac_status); }; }; then
6581   ac_cv_search_krb5_encrypt="none required"
6582 else
6583   echo "$as_me: failed program was:" >&5
6584 cat conftest.$ac_ext >&5
6585 fi
6586 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6587 if test "$ac_cv_search_krb5_encrypt" = no; then
6588   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken' crypto k5crypto; do
6589     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6590     cat >conftest.$ac_ext <<_ACEOF
6591 #line $LINENO "configure"
6592 #include "confdefs.h"
6593
6594 /* Override any gcc2 internal prototype to avoid an error.  */
6595 #ifdef __cplusplus
6596 extern "C"
6597 #endif
6598 /* We use char because int might match the return type of a gcc2
6599    builtin and then its argument prototype would still apply.  */
6600 char krb5_encrypt ();
6601 #ifdef F77_DUMMY_MAIN
6602 #  ifdef __cplusplus
6603      extern "C"
6604 #  endif
6605    int F77_DUMMY_MAIN() { return 1; }
6606 #endif
6607 int
6608 main ()
6609 {
6610 krb5_encrypt ();
6611   ;
6612   return 0;
6613 }
6614 _ACEOF
6615 rm -f conftest.$ac_objext conftest$ac_exeext
6616 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6617   (eval $ac_link) 2>&5
6618   ac_status=$?
6619   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6620   (exit $ac_status); } &&
6621          { ac_try='test -s conftest$ac_exeext'
6622   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6623   (eval $ac_try) 2>&5
6624   ac_status=$?
6625   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6626   (exit $ac_status); }; }; then
6627   ac_cv_search_krb5_encrypt="-l$ac_lib"
6628 break
6629 else
6630   echo "$as_me: failed program was:" >&5
6631 cat conftest.$ac_ext >&5
6632 fi
6633 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6634   done
6635 fi
6636 LIBS=$ac_func_search_save_LIBS
6637 fi
6638 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_encrypt" >&5
6639 echo "${ECHO_T}$ac_cv_search_krb5_encrypt" >&6
6640 if test "$ac_cv_search_krb5_encrypt" != no; then
6641   test "$ac_cv_search_krb5_encrypt" = "none required" || LIBS="$ac_cv_search_krb5_encrypt $LIBS"
6642
6643 else
6644   { { echo "$as_me:$LINENO: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&5
6645 echo "$as_me: error: could not find function 'krb5_encrypt' required for Kerberos 5" >&2;}
6646    { (exit 1); exit 1; }; }
6647 fi
6648
6649      echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
6650 echo $ECHO_N "checking for library containing krb5_sendauth... $ECHO_C" >&6
6651 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
6652   echo $ECHO_N "(cached) $ECHO_C" >&6
6653 else
6654   ac_func_search_save_LIBS=$LIBS
6655 ac_cv_search_krb5_sendauth=no
6656 cat >conftest.$ac_ext <<_ACEOF
6657 #line $LINENO "configure"
6658 #include "confdefs.h"
6659
6660 /* Override any gcc2 internal prototype to avoid an error.  */
6661 #ifdef __cplusplus
6662 extern "C"
6663 #endif
6664 /* We use char because int might match the return type of a gcc2
6665    builtin and then its argument prototype would still apply.  */
6666 char krb5_sendauth ();
6667 #ifdef F77_DUMMY_MAIN
6668 #  ifdef __cplusplus
6669      extern "C"
6670 #  endif
6671    int F77_DUMMY_MAIN() { return 1; }
6672 #endif
6673 int
6674 main ()
6675 {
6676 krb5_sendauth ();
6677   ;
6678   return 0;
6679 }
6680 _ACEOF
6681 rm -f conftest.$ac_objext conftest$ac_exeext
6682 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6683   (eval $ac_link) 2>&5
6684   ac_status=$?
6685   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6686   (exit $ac_status); } &&
6687          { ac_try='test -s conftest$ac_exeext'
6688   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6689   (eval $ac_try) 2>&5
6690   ac_status=$?
6691   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6692   (exit $ac_status); }; }; then
6693   ac_cv_search_krb5_sendauth="none required"
6694 else
6695   echo "$as_me: failed program was:" >&5
6696 cat conftest.$ac_ext >&5
6697 fi
6698 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6699 if test "$ac_cv_search_krb5_sendauth" = no; then
6700   for ac_lib in krb5 'krb5 -ldes -lasn1 -lroken'; do
6701     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6702     cat >conftest.$ac_ext <<_ACEOF
6703 #line $LINENO "configure"
6704 #include "confdefs.h"
6705
6706 /* Override any gcc2 internal prototype to avoid an error.  */
6707 #ifdef __cplusplus
6708 extern "C"
6709 #endif
6710 /* We use char because int might match the return type of a gcc2
6711    builtin and then its argument prototype would still apply.  */
6712 char krb5_sendauth ();
6713 #ifdef F77_DUMMY_MAIN
6714 #  ifdef __cplusplus
6715      extern "C"
6716 #  endif
6717    int F77_DUMMY_MAIN() { return 1; }
6718 #endif
6719 int
6720 main ()
6721 {
6722 krb5_sendauth ();
6723   ;
6724   return 0;
6725 }
6726 _ACEOF
6727 rm -f conftest.$ac_objext conftest$ac_exeext
6728 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6729   (eval $ac_link) 2>&5
6730   ac_status=$?
6731   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6732   (exit $ac_status); } &&
6733          { ac_try='test -s conftest$ac_exeext'
6734   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6735   (eval $ac_try) 2>&5
6736   ac_status=$?
6737   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6738   (exit $ac_status); }; }; then
6739   ac_cv_search_krb5_sendauth="-l$ac_lib"
6740 break
6741 else
6742   echo "$as_me: failed program was:" >&5
6743 cat conftest.$ac_ext >&5
6744 fi
6745 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6746   done
6747 fi
6748 LIBS=$ac_func_search_save_LIBS
6749 fi
6750 echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
6751 echo "${ECHO_T}$ac_cv_search_krb5_sendauth" >&6
6752 if test "$ac_cv_search_krb5_sendauth" != no; then
6753   test "$ac_cv_search_krb5_sendauth" = "none required" || LIBS="$ac_cv_search_krb5_sendauth $LIBS"
6754
6755 else
6756   { { echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
6757 echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
6758    { (exit 1); exit 1; }; }
6759 fi
6760
6761   else
6762      echo "$as_me:$LINENO: checking for library containing com_err" >&5
6763 echo $ECHO_N "checking for library containing com_err... $ECHO_C" >&6
6764 if test "${ac_cv_search_com_err+set}" = set; then
6765   echo $ECHO_N "(cached) $ECHO_C" >&6
6766 else
6767   ac_func_search_save_LIBS=$LIBS
6768 ac_cv_search_com_err=no
6769 cat >conftest.$ac_ext <<_ACEOF
6770 #line $LINENO "configure"
6771 #include "confdefs.h"
6772
6773 /* Override any gcc2 internal prototype to avoid an error.  */
6774 #ifdef __cplusplus
6775 extern "C"
6776 #endif
6777 /* We use char because int might match the return type of a gcc2
6778    builtin and then its argument prototype would still apply.  */
6779 char com_err ();
6780 #ifdef F77_DUMMY_MAIN
6781 #  ifdef __cplusplus
6782      extern "C"
6783 #  endif
6784    int F77_DUMMY_MAIN() { return 1; }
6785 #endif
6786 int
6787 main ()
6788 {
6789 com_err ();
6790   ;
6791   return 0;
6792 }
6793 _ACEOF
6794 rm -f conftest.$ac_objext conftest$ac_exeext
6795 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6796   (eval $ac_link) 2>&5
6797   ac_status=$?
6798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6799   (exit $ac_status); } &&
6800          { ac_try='test -s conftest$ac_exeext'
6801   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6802   (eval $ac_try) 2>&5
6803   ac_status=$?
6804   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6805   (exit $ac_status); }; }; then
6806   ac_cv_search_com_err="none required"
6807 else
6808   echo "$as_me: failed program was:" >&5
6809 cat conftest.$ac_ext >&5
6810 fi
6811 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6812 if test "$ac_cv_search_com_err" = no; then
6813   for ac_lib in 'comerr32 -lkrb5_32'; do
6814     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
6815     cat >conftest.$ac_ext <<_ACEOF
6816 #line $LINENO "configure"
6817 #include "confdefs.h"
6818
6819 /* Override any gcc2 internal prototype to avoid an error.  */
6820 #ifdef __cplusplus
6821 extern "C"
6822 #endif
6823 /* We use char because int might match the return type of a gcc2
6824    builtin and then its argument prototype would still apply.  */
6825 char com_err ();
6826 #ifdef F77_DUMMY_MAIN
6827 #  ifdef __cplusplus
6828      extern "C"
6829 #  endif
6830    int F77_DUMMY_MAIN() { return 1; }
6831 #endif
6832 int
6833 main ()
6834 {
6835 com_err ();
6836   ;
6837   return 0;
6838 }
6839 _ACEOF
6840 rm -f conftest.$ac_objext conftest$ac_exeext
6841 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6842   (eval $ac_link) 2>&5
6843   ac_status=$?
6844   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6845   (exit $ac_status); } &&
6846          { ac_try='test -s conftest$ac_exeext'
6847   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6848   (eval $ac_try) 2>&5
6849   ac_status=$?
6850   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6851   (exit $ac_status); }; }; then
6852   ac_cv_search_com_err="-l$ac_lib"
6853 break
6854 else
6855   echo "$as_me: failed program was:" >&5
6856 cat conftest.$ac_ext >&5
6857 fi
6858 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6859   done
6860 fi
6861 LIBS=$ac_func_search_save_LIBS
6862 fi
6863 echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
6864 echo "${ECHO_T}$ac_cv_search_com_err" >&6
6865 if test "$ac_cv_search_com_err" != no; then
6866   test "$ac_cv_search_com_err" = "none required" || LIBS="$ac_cv_search_com_err $LIBS"
6867
6868 else
6869   { { echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
6870 echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
6871    { (exit 1); exit 1; }; }
6872 fi
6873
6874   fi
6875 fi
6876
6877 if test "$with_openssl" = yes ; then
6878     if test "$PORTNAME" != "win32"; then
6879
6880 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
6881 echo $ECHO_N "checking for CRYPTO_new_ex_data in -lcrypto... $ECHO_C" >&6
6882 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
6883   echo $ECHO_N "(cached) $ECHO_C" >&6
6884 else
6885   ac_check_lib_save_LIBS=$LIBS
6886 LIBS="-lcrypto  $LIBS"
6887 cat >conftest.$ac_ext <<_ACEOF
6888 #line $LINENO "configure"
6889 #include "confdefs.h"
6890
6891 /* Override any gcc2 internal prototype to avoid an error.  */
6892 #ifdef __cplusplus
6893 extern "C"
6894 #endif
6895 /* We use char because int might match the return type of a gcc2
6896    builtin and then its argument prototype would still apply.  */
6897 char CRYPTO_new_ex_data ();
6898 #ifdef F77_DUMMY_MAIN
6899 #  ifdef __cplusplus
6900      extern "C"
6901 #  endif
6902    int F77_DUMMY_MAIN() { return 1; }
6903 #endif
6904 int
6905 main ()
6906 {
6907 CRYPTO_new_ex_data ();
6908   ;
6909   return 0;
6910 }
6911 _ACEOF
6912 rm -f conftest.$ac_objext conftest$ac_exeext
6913 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6914   (eval $ac_link) 2>&5
6915   ac_status=$?
6916   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6917   (exit $ac_status); } &&
6918          { ac_try='test -s conftest$ac_exeext'
6919   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6920   (eval $ac_try) 2>&5
6921   ac_status=$?
6922   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6923   (exit $ac_status); }; }; then
6924   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
6925 else
6926   echo "$as_me: failed program was:" >&5
6927 cat conftest.$ac_ext >&5
6928 ac_cv_lib_crypto_CRYPTO_new_ex_data=no
6929 fi
6930 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
6931 LIBS=$ac_check_lib_save_LIBS
6932 fi
6933 echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
6934 echo "${ECHO_T}$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6
6935 if test $ac_cv_lib_crypto_CRYPTO_new_ex_data = yes; then
6936   cat >>confdefs.h <<_ACEOF
6937 #define HAVE_LIBCRYPTO 1
6938 _ACEOF
6939
6940   LIBS="-lcrypto $LIBS"
6941
6942 else
6943   { { echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
6944 echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
6945    { (exit 1); exit 1; }; }
6946 fi
6947
6948
6949 echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
6950 echo $ECHO_N "checking for SSL_library_init in -lssl... $ECHO_C" >&6
6951 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
6952   echo $ECHO_N "(cached) $ECHO_C" >&6
6953 else
6954   ac_check_lib_save_LIBS=$LIBS
6955 LIBS="-lssl  $LIBS"
6956 cat >conftest.$ac_ext <<_ACEOF
6957 #line $LINENO "configure"
6958 #include "confdefs.h"
6959
6960 /* Override any gcc2 internal prototype to avoid an error.  */
6961 #ifdef __cplusplus
6962 extern "C"
6963 #endif
6964 /* We use char because int might match the return type of a gcc2
6965    builtin and then its argument prototype would still apply.  */
6966 char SSL_library_init ();
6967 #ifdef F77_DUMMY_MAIN
6968 #  ifdef __cplusplus
6969      extern "C"
6970 #  endif
6971    int F77_DUMMY_MAIN() { return 1; }
6972 #endif
6973 int
6974 main ()
6975 {
6976 SSL_library_init ();
6977   ;
6978   return 0;
6979 }
6980 _ACEOF
6981 rm -f conftest.$ac_objext conftest$ac_exeext
6982 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
6983   (eval $ac_link) 2>&5
6984   ac_status=$?
6985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6986   (exit $ac_status); } &&
6987          { ac_try='test -s conftest$ac_exeext'
6988   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
6989   (eval $ac_try) 2>&5
6990   ac_status=$?
6991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
6992   (exit $ac_status); }; }; then
6993   ac_cv_lib_ssl_SSL_library_init=yes
6994 else
6995   echo "$as_me: failed program was:" >&5
6996 cat conftest.$ac_ext >&5
6997 ac_cv_lib_ssl_SSL_library_init=no
6998 fi
6999 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7000 LIBS=$ac_check_lib_save_LIBS
7001 fi
7002 echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
7003 echo "${ECHO_T}$ac_cv_lib_ssl_SSL_library_init" >&6
7004 if test $ac_cv_lib_ssl_SSL_library_init = yes; then
7005   cat >>confdefs.h <<_ACEOF
7006 #define HAVE_LIBSSL 1
7007 _ACEOF
7008
7009   LIBS="-lssl $LIBS"
7010
7011 else
7012   { { echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
7013 echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
7014    { (exit 1); exit 1; }; }
7015 fi
7016
7017   else
7018
7019 echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
7020 echo $ECHO_N "checking for CRYPTO_new_ex_data in -leay32... $ECHO_C" >&6
7021 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
7022   echo $ECHO_N "(cached) $ECHO_C" >&6
7023 else
7024   ac_check_lib_save_LIBS=$LIBS
7025 LIBS="-leay32  $LIBS"
7026 cat >conftest.$ac_ext <<_ACEOF
7027 #line $LINENO "configure"
7028 #include "confdefs.h"
7029
7030 /* Override any gcc2 internal prototype to avoid an error.  */
7031 #ifdef __cplusplus
7032 extern "C"
7033 #endif
7034 /* We use char because int might match the return type of a gcc2
7035    builtin and then its argument prototype would still apply.  */
7036 char CRYPTO_new_ex_data ();
7037 #ifdef F77_DUMMY_MAIN
7038 #  ifdef __cplusplus
7039      extern "C"
7040 #  endif
7041    int F77_DUMMY_MAIN() { return 1; }
7042 #endif
7043 int
7044 main ()
7045 {
7046 CRYPTO_new_ex_data ();
7047   ;
7048   return 0;
7049 }
7050 _ACEOF
7051 rm -f conftest.$ac_objext conftest$ac_exeext
7052 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7053   (eval $ac_link) 2>&5
7054   ac_status=$?
7055   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7056   (exit $ac_status); } &&
7057          { ac_try='test -s conftest$ac_exeext'
7058   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7059   (eval $ac_try) 2>&5
7060   ac_status=$?
7061   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7062   (exit $ac_status); }; }; then
7063   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
7064 else
7065   echo "$as_me: failed program was:" >&5
7066 cat conftest.$ac_ext >&5
7067 ac_cv_lib_eay32_CRYPTO_new_ex_data=no
7068 fi
7069 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7070 LIBS=$ac_check_lib_save_LIBS
7071 fi
7072 echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
7073 echo "${ECHO_T}$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6
7074 if test $ac_cv_lib_eay32_CRYPTO_new_ex_data = yes; then
7075   cat >>confdefs.h <<_ACEOF
7076 #define HAVE_LIBEAY32 1
7077 _ACEOF
7078
7079   LIBS="-leay32 $LIBS"
7080
7081 else
7082   { { echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
7083 echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
7084    { (exit 1); exit 1; }; }
7085 fi
7086
7087
7088 echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
7089 echo $ECHO_N "checking for SSL_library_init in -lssleay32... $ECHO_C" >&6
7090 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
7091   echo $ECHO_N "(cached) $ECHO_C" >&6
7092 else
7093   ac_check_lib_save_LIBS=$LIBS
7094 LIBS="-lssleay32  $LIBS"
7095 cat >conftest.$ac_ext <<_ACEOF
7096 #line $LINENO "configure"
7097 #include "confdefs.h"
7098
7099 /* Override any gcc2 internal prototype to avoid an error.  */
7100 #ifdef __cplusplus
7101 extern "C"
7102 #endif
7103 /* We use char because int might match the return type of a gcc2
7104    builtin and then its argument prototype would still apply.  */
7105 char SSL_library_init ();
7106 #ifdef F77_DUMMY_MAIN
7107 #  ifdef __cplusplus
7108      extern "C"
7109 #  endif
7110    int F77_DUMMY_MAIN() { return 1; }
7111 #endif
7112 int
7113 main ()
7114 {
7115 SSL_library_init ();
7116   ;
7117   return 0;
7118 }
7119 _ACEOF
7120 rm -f conftest.$ac_objext conftest$ac_exeext
7121 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7122   (eval $ac_link) 2>&5
7123   ac_status=$?
7124   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7125   (exit $ac_status); } &&
7126          { ac_try='test -s conftest$ac_exeext'
7127   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7128   (eval $ac_try) 2>&5
7129   ac_status=$?
7130   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7131   (exit $ac_status); }; }; then
7132   ac_cv_lib_ssleay32_SSL_library_init=yes
7133 else
7134   echo "$as_me: failed program was:" >&5
7135 cat conftest.$ac_ext >&5
7136 ac_cv_lib_ssleay32_SSL_library_init=no
7137 fi
7138 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7139 LIBS=$ac_check_lib_save_LIBS
7140 fi
7141 echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
7142 echo "${ECHO_T}$ac_cv_lib_ssleay32_SSL_library_init" >&6
7143 if test $ac_cv_lib_ssleay32_SSL_library_init = yes; then
7144   cat >>confdefs.h <<_ACEOF
7145 #define HAVE_LIBSSLEAY32 1
7146 _ACEOF
7147
7148   LIBS="-lssleay32 $LIBS"
7149
7150 else
7151   { { echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
7152 echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
7153    { (exit 1); exit 1; }; }
7154 fi
7155
7156   fi
7157 fi
7158
7159 if test "$with_pam" = yes ; then
7160
7161 echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
7162 echo $ECHO_N "checking for pam_start in -lpam... $ECHO_C" >&6
7163 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
7164   echo $ECHO_N "(cached) $ECHO_C" >&6
7165 else
7166   ac_check_lib_save_LIBS=$LIBS
7167 LIBS="-lpam  $LIBS"
7168 cat >conftest.$ac_ext <<_ACEOF
7169 #line $LINENO "configure"
7170 #include "confdefs.h"
7171
7172 /* Override any gcc2 internal prototype to avoid an error.  */
7173 #ifdef __cplusplus
7174 extern "C"
7175 #endif
7176 /* We use char because int might match the return type of a gcc2
7177    builtin and then its argument prototype would still apply.  */
7178 char pam_start ();
7179 #ifdef F77_DUMMY_MAIN
7180 #  ifdef __cplusplus
7181      extern "C"
7182 #  endif
7183    int F77_DUMMY_MAIN() { return 1; }
7184 #endif
7185 int
7186 main ()
7187 {
7188 pam_start ();
7189   ;
7190   return 0;
7191 }
7192 _ACEOF
7193 rm -f conftest.$ac_objext conftest$ac_exeext
7194 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7195   (eval $ac_link) 2>&5
7196   ac_status=$?
7197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7198   (exit $ac_status); } &&
7199          { ac_try='test -s conftest$ac_exeext'
7200   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7201   (eval $ac_try) 2>&5
7202   ac_status=$?
7203   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7204   (exit $ac_status); }; }; then
7205   ac_cv_lib_pam_pam_start=yes
7206 else
7207   echo "$as_me: failed program was:" >&5
7208 cat conftest.$ac_ext >&5
7209 ac_cv_lib_pam_pam_start=no
7210 fi
7211 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
7212 LIBS=$ac_check_lib_save_LIBS
7213 fi
7214 echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
7215 echo "${ECHO_T}$ac_cv_lib_pam_pam_start" >&6
7216 if test $ac_cv_lib_pam_pam_start = yes; then
7217   cat >>confdefs.h <<_ACEOF
7218 #define HAVE_LIBPAM 1
7219 _ACEOF
7220
7221   LIBS="-lpam $LIBS"
7222
7223 else
7224   { { echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
7225 echo "$as_me: error: library 'pam' is required for PAM" >&2;}
7226    { (exit 1); exit 1; }; }
7227 fi
7228
7229 fi
7230
7231
7232 ##
7233 ## Header files
7234 ##
7235
7236 echo "$as_me:$LINENO: checking for ANSI C header files" >&5
7237 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
7238 if test "${ac_cv_header_stdc+set}" = set; then
7239   echo $ECHO_N "(cached) $ECHO_C" >&6
7240 else
7241   cat >conftest.$ac_ext <<_ACEOF
7242 #line $LINENO "configure"
7243 #include "confdefs.h"
7244 #include <stdlib.h>
7245 #include <stdarg.h>
7246 #include <string.h>
7247 #include <float.h>
7248
7249 _ACEOF
7250 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7251   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7252   ac_status=$?
7253   egrep -v '^ *\+' conftest.er1 >conftest.err
7254   rm -f conftest.er1
7255   cat conftest.err >&5
7256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7257   (exit $ac_status); } >/dev/null; then
7258   if test -s conftest.err; then
7259     ac_cpp_err=$ac_c_preproc_warn_flag
7260   else
7261     ac_cpp_err=
7262   fi
7263 else
7264   ac_cpp_err=yes
7265 fi
7266 if test -z "$ac_cpp_err"; then
7267   ac_cv_header_stdc=yes
7268 else
7269   echo "$as_me: failed program was:" >&5
7270   cat conftest.$ac_ext >&5
7271   ac_cv_header_stdc=no
7272 fi
7273 rm -f conftest.err conftest.$ac_ext
7274
7275 if test $ac_cv_header_stdc = yes; then
7276   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
7277   cat >conftest.$ac_ext <<_ACEOF
7278 #line $LINENO "configure"
7279 #include "confdefs.h"
7280 #include <string.h>
7281
7282 _ACEOF
7283 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7284   egrep "memchr" >/dev/null 2>&1; then
7285   :
7286 else
7287   ac_cv_header_stdc=no
7288 fi
7289 rm -f conftest*
7290
7291 fi
7292
7293 if test $ac_cv_header_stdc = yes; then
7294   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
7295   cat >conftest.$ac_ext <<_ACEOF
7296 #line $LINENO "configure"
7297 #include "confdefs.h"
7298 #include <stdlib.h>
7299
7300 _ACEOF
7301 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7302   egrep "free" >/dev/null 2>&1; then
7303   :
7304 else
7305   ac_cv_header_stdc=no
7306 fi
7307 rm -f conftest*
7308
7309 fi
7310
7311 if test $ac_cv_header_stdc = yes; then
7312   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
7313   if test "$cross_compiling" = yes; then
7314   :
7315 else
7316   cat >conftest.$ac_ext <<_ACEOF
7317 #line $LINENO "configure"
7318 #include "confdefs.h"
7319 #include <ctype.h>
7320 #if ((' ' & 0x0FF) == 0x020)
7321 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
7322 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
7323 #else
7324 # define ISLOWER(c) (('a' <= (c) && (c) <= 'i') \
7325                      || ('j' <= (c) && (c) <= 'r') \
7326                      || ('s' <= (c) && (c) <= 'z'))
7327 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
7328 #endif
7329
7330 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
7331 int
7332 main ()
7333 {
7334   int i;
7335   for (i = 0; i < 256; i++)
7336     if (XOR (islower (i), ISLOWER (i))
7337         || toupper (i) != TOUPPER (i))
7338       exit(2);
7339   exit (0);
7340 }
7341 _ACEOF
7342 rm -f conftest$ac_exeext
7343 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
7344   (eval $ac_link) 2>&5
7345   ac_status=$?
7346   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7347   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7348   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7349   (eval $ac_try) 2>&5
7350   ac_status=$?
7351   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7352   (exit $ac_status); }; }; then
7353   :
7354 else
7355   echo "$as_me: program exited with status $ac_status" >&5
7356 echo "$as_me: failed program was:" >&5
7357 cat conftest.$ac_ext >&5
7358 ( exit $ac_status )
7359 ac_cv_header_stdc=no
7360 fi
7361 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7362 fi
7363 fi
7364 fi
7365 echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
7366 echo "${ECHO_T}$ac_cv_header_stdc" >&6
7367 if test $ac_cv_header_stdc = yes; then
7368
7369 cat >>confdefs.h <<\_ACEOF
7370 #define STDC_HEADERS 1
7371 _ACEOF
7372
7373 fi
7374
7375 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
7376
7377
7378
7379
7380
7381
7382
7383
7384
7385 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
7386                   inttypes.h stdint.h unistd.h
7387 do
7388 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7389 echo "$as_me:$LINENO: checking for $ac_header" >&5
7390 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7391 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7392   echo $ECHO_N "(cached) $ECHO_C" >&6
7393 else
7394   cat >conftest.$ac_ext <<_ACEOF
7395 #line $LINENO "configure"
7396 #include "confdefs.h"
7397 $ac_includes_default
7398
7399 #include <$ac_header>
7400 _ACEOF
7401 rm -f conftest.$ac_objext
7402 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7403   (eval $ac_compile) 2>&5
7404   ac_status=$?
7405   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7406   (exit $ac_status); } &&
7407          { ac_try='test -s conftest.$ac_objext'
7408   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7409   (eval $ac_try) 2>&5
7410   ac_status=$?
7411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7412   (exit $ac_status); }; }; then
7413   eval "$as_ac_Header=yes"
7414 else
7415   echo "$as_me: failed program was:" >&5
7416 cat conftest.$ac_ext >&5
7417 eval "$as_ac_Header=no"
7418 fi
7419 rm -f conftest.$ac_objext conftest.$ac_ext
7420 fi
7421 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7422 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7423 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7424   cat >>confdefs.h <<_ACEOF
7425 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7426 _ACEOF
7427
7428 fi
7429
7430 done
7431
7432
7433
7434
7435
7436
7437
7438
7439
7440
7441
7442
7443
7444
7445
7446
7447
7448
7449
7450
7451
7452
7453
7454
7455
7456
7457
7458 for ac_header in crypt.h dld.h endian.h fp_class.h getopt.h ieeefp.h langinfo.h poll.h pwd.h sys/ipc.h sys/poll.h sys/pstat.h sys/select.h sys/sem.h sys/socket.h sys/shm.h sys/time.h sys/un.h termios.h utime.h wchar.h wctype.h kernel/OS.h kernel/image.h SupportDefs.h
7459 do
7460 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7461 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7462   echo "$as_me:$LINENO: checking for $ac_header" >&5
7463 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7464 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7465   echo $ECHO_N "(cached) $ECHO_C" >&6
7466 fi
7467 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7468 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7469 else
7470   # Is the header compilable?
7471 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7472 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7473 cat >conftest.$ac_ext <<_ACEOF
7474 #line $LINENO "configure"
7475 #include "confdefs.h"
7476 $ac_includes_default
7477 #include <$ac_header>
7478 _ACEOF
7479 rm -f conftest.$ac_objext
7480 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7481   (eval $ac_compile) 2>&5
7482   ac_status=$?
7483   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7484   (exit $ac_status); } &&
7485          { ac_try='test -s conftest.$ac_objext'
7486   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7487   (eval $ac_try) 2>&5
7488   ac_status=$?
7489   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7490   (exit $ac_status); }; }; then
7491   ac_header_compiler=yes
7492 else
7493   echo "$as_me: failed program was:" >&5
7494 cat conftest.$ac_ext >&5
7495 ac_header_compiler=no
7496 fi
7497 rm -f conftest.$ac_objext conftest.$ac_ext
7498 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7499 echo "${ECHO_T}$ac_header_compiler" >&6
7500
7501 # Is the header present?
7502 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7503 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7504 cat >conftest.$ac_ext <<_ACEOF
7505 #line $LINENO "configure"
7506 #include "confdefs.h"
7507 #include <$ac_header>
7508 _ACEOF
7509 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7510   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7511   ac_status=$?
7512   egrep -v '^ *\+' conftest.er1 >conftest.err
7513   rm -f conftest.er1
7514   cat conftest.err >&5
7515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7516   (exit $ac_status); } >/dev/null; then
7517   if test -s conftest.err; then
7518     ac_cpp_err=$ac_c_preproc_warn_flag
7519   else
7520     ac_cpp_err=
7521   fi
7522 else
7523   ac_cpp_err=yes
7524 fi
7525 if test -z "$ac_cpp_err"; then
7526   ac_header_preproc=yes
7527 else
7528   echo "$as_me: failed program was:" >&5
7529   cat conftest.$ac_ext >&5
7530   ac_header_preproc=no
7531 fi
7532 rm -f conftest.err conftest.$ac_ext
7533 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7534 echo "${ECHO_T}$ac_header_preproc" >&6
7535
7536 # So?  What about this header?
7537 case $ac_header_compiler:$ac_header_preproc in
7538   yes:no )
7539     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7540 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7541     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7542 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7543   no:yes )
7544     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7545 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7546     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7547 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7548     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7549 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7550 esac
7551 echo "$as_me:$LINENO: checking for $ac_header" >&5
7552 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7553 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7554   echo $ECHO_N "(cached) $ECHO_C" >&6
7555 else
7556   eval "$as_ac_Header=$ac_header_preproc"
7557 fi
7558 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7559 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7560
7561 fi
7562 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7563   cat >>confdefs.h <<_ACEOF
7564 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7565 _ACEOF
7566
7567 fi
7568
7569 done
7570
7571
7572 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
7573 # netinet/in.h is included first.
7574
7575 for ac_header in netinet/in.h
7576 do
7577 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7578 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7579   echo "$as_me:$LINENO: checking for $ac_header" >&5
7580 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7581 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7582   echo $ECHO_N "(cached) $ECHO_C" >&6
7583 fi
7584 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7585 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7586 else
7587   # Is the header compilable?
7588 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7589 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7590 cat >conftest.$ac_ext <<_ACEOF
7591 #line $LINENO "configure"
7592 #include "confdefs.h"
7593 $ac_includes_default
7594 #include <$ac_header>
7595 _ACEOF
7596 rm -f conftest.$ac_objext
7597 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7598   (eval $ac_compile) 2>&5
7599   ac_status=$?
7600   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7601   (exit $ac_status); } &&
7602          { ac_try='test -s conftest.$ac_objext'
7603   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7604   (eval $ac_try) 2>&5
7605   ac_status=$?
7606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7607   (exit $ac_status); }; }; then
7608   ac_header_compiler=yes
7609 else
7610   echo "$as_me: failed program was:" >&5
7611 cat conftest.$ac_ext >&5
7612 ac_header_compiler=no
7613 fi
7614 rm -f conftest.$ac_objext conftest.$ac_ext
7615 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7616 echo "${ECHO_T}$ac_header_compiler" >&6
7617
7618 # Is the header present?
7619 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7620 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7621 cat >conftest.$ac_ext <<_ACEOF
7622 #line $LINENO "configure"
7623 #include "confdefs.h"
7624 #include <$ac_header>
7625 _ACEOF
7626 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7627   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7628   ac_status=$?
7629   egrep -v '^ *\+' conftest.er1 >conftest.err
7630   rm -f conftest.er1
7631   cat conftest.err >&5
7632   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7633   (exit $ac_status); } >/dev/null; then
7634   if test -s conftest.err; then
7635     ac_cpp_err=$ac_c_preproc_warn_flag
7636   else
7637     ac_cpp_err=
7638   fi
7639 else
7640   ac_cpp_err=yes
7641 fi
7642 if test -z "$ac_cpp_err"; then
7643   ac_header_preproc=yes
7644 else
7645   echo "$as_me: failed program was:" >&5
7646   cat conftest.$ac_ext >&5
7647   ac_header_preproc=no
7648 fi
7649 rm -f conftest.err conftest.$ac_ext
7650 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7651 echo "${ECHO_T}$ac_header_preproc" >&6
7652
7653 # So?  What about this header?
7654 case $ac_header_compiler:$ac_header_preproc in
7655   yes:no )
7656     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7657 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7658     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7659 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7660   no:yes )
7661     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7662 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7663     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7664 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7665     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7666 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7667 esac
7668 echo "$as_me:$LINENO: checking for $ac_header" >&5
7669 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7670 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7671   echo $ECHO_N "(cached) $ECHO_C" >&6
7672 else
7673   eval "$as_ac_Header=$ac_header_preproc"
7674 fi
7675 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7676 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7677
7678 fi
7679 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7680   cat >>confdefs.h <<_ACEOF
7681 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7682 _ACEOF
7683
7684 fi
7685
7686 done
7687
7688
7689 for ac_header in netinet/tcp.h
7690 do
7691 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7692 echo "$as_me:$LINENO: checking for $ac_header" >&5
7693 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7694 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7695   echo $ECHO_N "(cached) $ECHO_C" >&6
7696 else
7697   cat >conftest.$ac_ext <<_ACEOF
7698 #line $LINENO "configure"
7699 #include "confdefs.h"
7700 $ac_includes_default
7701 #ifdef HAVE_NETINET_IN_H
7702 #include <netinet/in.h>
7703 #endif
7704
7705
7706 #include <$ac_header>
7707 _ACEOF
7708 rm -f conftest.$ac_objext
7709 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7710   (eval $ac_compile) 2>&5
7711   ac_status=$?
7712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7713   (exit $ac_status); } &&
7714          { ac_try='test -s conftest.$ac_objext'
7715   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7716   (eval $ac_try) 2>&5
7717   ac_status=$?
7718   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7719   (exit $ac_status); }; }; then
7720   eval "$as_ac_Header=yes"
7721 else
7722   echo "$as_me: failed program was:" >&5
7723 cat conftest.$ac_ext >&5
7724 eval "$as_ac_Header=no"
7725 fi
7726 rm -f conftest.$ac_objext conftest.$ac_ext
7727 fi
7728 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7729 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7730 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7731   cat >>confdefs.h <<_ACEOF
7732 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7733 _ACEOF
7734
7735 fi
7736
7737 done
7738
7739
7740 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
7741
7742 for ac_header in readline/readline.h
7743 do
7744 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7745 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7746   echo "$as_me:$LINENO: checking for $ac_header" >&5
7747 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7748 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7749   echo $ECHO_N "(cached) $ECHO_C" >&6
7750 fi
7751 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7752 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7753 else
7754   # Is the header compilable?
7755 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7756 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7757 cat >conftest.$ac_ext <<_ACEOF
7758 #line $LINENO "configure"
7759 #include "confdefs.h"
7760 $ac_includes_default
7761 #include <$ac_header>
7762 _ACEOF
7763 rm -f conftest.$ac_objext
7764 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7765   (eval $ac_compile) 2>&5
7766   ac_status=$?
7767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7768   (exit $ac_status); } &&
7769          { ac_try='test -s conftest.$ac_objext'
7770   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7771   (eval $ac_try) 2>&5
7772   ac_status=$?
7773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7774   (exit $ac_status); }; }; then
7775   ac_header_compiler=yes
7776 else
7777   echo "$as_me: failed program was:" >&5
7778 cat conftest.$ac_ext >&5
7779 ac_header_compiler=no
7780 fi
7781 rm -f conftest.$ac_objext conftest.$ac_ext
7782 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7783 echo "${ECHO_T}$ac_header_compiler" >&6
7784
7785 # Is the header present?
7786 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7787 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7788 cat >conftest.$ac_ext <<_ACEOF
7789 #line $LINENO "configure"
7790 #include "confdefs.h"
7791 #include <$ac_header>
7792 _ACEOF
7793 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7794   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7795   ac_status=$?
7796   egrep -v '^ *\+' conftest.er1 >conftest.err
7797   rm -f conftest.er1
7798   cat conftest.err >&5
7799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7800   (exit $ac_status); } >/dev/null; then
7801   if test -s conftest.err; then
7802     ac_cpp_err=$ac_c_preproc_warn_flag
7803   else
7804     ac_cpp_err=
7805   fi
7806 else
7807   ac_cpp_err=yes
7808 fi
7809 if test -z "$ac_cpp_err"; then
7810   ac_header_preproc=yes
7811 else
7812   echo "$as_me: failed program was:" >&5
7813   cat conftest.$ac_ext >&5
7814   ac_header_preproc=no
7815 fi
7816 rm -f conftest.err conftest.$ac_ext
7817 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7818 echo "${ECHO_T}$ac_header_preproc" >&6
7819
7820 # So?  What about this header?
7821 case $ac_header_compiler:$ac_header_preproc in
7822   yes:no )
7823     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7824 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7825     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7826 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7827   no:yes )
7828     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7829 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7830     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7831 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7832     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7833 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7834 esac
7835 echo "$as_me:$LINENO: checking for $ac_header" >&5
7836 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7837 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7838   echo $ECHO_N "(cached) $ECHO_C" >&6
7839 else
7840   eval "$as_ac_Header=$ac_header_preproc"
7841 fi
7842 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7843 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7844
7845 fi
7846 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7847   cat >>confdefs.h <<_ACEOF
7848 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7849 _ACEOF
7850
7851 else
7852
7853 for ac_header in readline.h
7854 do
7855 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7856 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7857   echo "$as_me:$LINENO: checking for $ac_header" >&5
7858 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7859 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7860   echo $ECHO_N "(cached) $ECHO_C" >&6
7861 fi
7862 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7863 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7864 else
7865   # Is the header compilable?
7866 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7867 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7868 cat >conftest.$ac_ext <<_ACEOF
7869 #line $LINENO "configure"
7870 #include "confdefs.h"
7871 $ac_includes_default
7872 #include <$ac_header>
7873 _ACEOF
7874 rm -f conftest.$ac_objext
7875 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
7876   (eval $ac_compile) 2>&5
7877   ac_status=$?
7878   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7879   (exit $ac_status); } &&
7880          { ac_try='test -s conftest.$ac_objext'
7881   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
7882   (eval $ac_try) 2>&5
7883   ac_status=$?
7884   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7885   (exit $ac_status); }; }; then
7886   ac_header_compiler=yes
7887 else
7888   echo "$as_me: failed program was:" >&5
7889 cat conftest.$ac_ext >&5
7890 ac_header_compiler=no
7891 fi
7892 rm -f conftest.$ac_objext conftest.$ac_ext
7893 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7894 echo "${ECHO_T}$ac_header_compiler" >&6
7895
7896 # Is the header present?
7897 echo "$as_me:$LINENO: checking $ac_header presence" >&5
7898 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
7899 cat >conftest.$ac_ext <<_ACEOF
7900 #line $LINENO "configure"
7901 #include "confdefs.h"
7902 #include <$ac_header>
7903 _ACEOF
7904 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
7905   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
7906   ac_status=$?
7907   egrep -v '^ *\+' conftest.er1 >conftest.err
7908   rm -f conftest.er1
7909   cat conftest.err >&5
7910   echo "$as_me:$LINENO: \$? = $ac_status" >&5
7911   (exit $ac_status); } >/dev/null; then
7912   if test -s conftest.err; then
7913     ac_cpp_err=$ac_c_preproc_warn_flag
7914   else
7915     ac_cpp_err=
7916   fi
7917 else
7918   ac_cpp_err=yes
7919 fi
7920 if test -z "$ac_cpp_err"; then
7921   ac_header_preproc=yes
7922 else
7923   echo "$as_me: failed program was:" >&5
7924   cat conftest.$ac_ext >&5
7925   ac_header_preproc=no
7926 fi
7927 rm -f conftest.err conftest.$ac_ext
7928 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7929 echo "${ECHO_T}$ac_header_preproc" >&6
7930
7931 # So?  What about this header?
7932 case $ac_header_compiler:$ac_header_preproc in
7933   yes:no )
7934     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7935 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7936     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7937 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7938   no:yes )
7939     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7940 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7941     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
7942 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
7943     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7944 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
7945 esac
7946 echo "$as_me:$LINENO: checking for $ac_header" >&5
7947 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7948 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7949   echo $ECHO_N "(cached) $ECHO_C" >&6
7950 else
7951   eval "$as_ac_Header=$ac_header_preproc"
7952 fi
7953 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7954 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7955
7956 fi
7957 if test `eval echo '${'$as_ac_Header'}'` = yes; then
7958   cat >>confdefs.h <<_ACEOF
7959 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7960 _ACEOF
7961
7962 else
7963   { { echo "$as_me:$LINENO: error: readline header not found
7964 If you have readline already installed, see config.log for details on the
7965 failure.  It is possible the compiler isn't looking in the proper directory.
7966 Use --without-readline to disable readline support." >&5
7967 echo "$as_me: error: readline header not found
7968 If you have readline already installed, see config.log for details on the
7969 failure.  It is possible the compiler isn't looking in the proper directory.
7970 Use --without-readline to disable readline support." >&2;}
7971    { (exit 1); exit 1; }; }
7972 fi
7973
7974 done
7975
7976 fi
7977
7978 done
7979
7980
7981 for ac_header in readline/history.h
7982 do
7983 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7984 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7985   echo "$as_me:$LINENO: checking for $ac_header" >&5
7986 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
7987 if eval "test \"\${$as_ac_Header+set}\" = set"; then
7988   echo $ECHO_N "(cached) $ECHO_C" >&6
7989 fi
7990 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
7991 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
7992 else
7993   # Is the header compilable?
7994 echo "$as_me:$LINENO: checking $ac_header usability" >&5
7995 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
7996 cat >conftest.$ac_ext <<_ACEOF
7997 #line $LINENO "configure"
7998 #include "confdefs.h"
7999 $ac_includes_default
8000 #include <$ac_header>
8001 _ACEOF
8002 rm -f conftest.$ac_objext
8003 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8004   (eval $ac_compile) 2>&5
8005   ac_status=$?
8006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8007   (exit $ac_status); } &&
8008          { ac_try='test -s conftest.$ac_objext'
8009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8010   (eval $ac_try) 2>&5
8011   ac_status=$?
8012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8013   (exit $ac_status); }; }; then
8014   ac_header_compiler=yes
8015 else
8016   echo "$as_me: failed program was:" >&5
8017 cat conftest.$ac_ext >&5
8018 ac_header_compiler=no
8019 fi
8020 rm -f conftest.$ac_objext conftest.$ac_ext
8021 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8022 echo "${ECHO_T}$ac_header_compiler" >&6
8023
8024 # Is the header present?
8025 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8026 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8027 cat >conftest.$ac_ext <<_ACEOF
8028 #line $LINENO "configure"
8029 #include "confdefs.h"
8030 #include <$ac_header>
8031 _ACEOF
8032 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8033   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8034   ac_status=$?
8035   egrep -v '^ *\+' conftest.er1 >conftest.err
8036   rm -f conftest.er1
8037   cat conftest.err >&5
8038   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8039   (exit $ac_status); } >/dev/null; then
8040   if test -s conftest.err; then
8041     ac_cpp_err=$ac_c_preproc_warn_flag
8042   else
8043     ac_cpp_err=
8044   fi
8045 else
8046   ac_cpp_err=yes
8047 fi
8048 if test -z "$ac_cpp_err"; then
8049   ac_header_preproc=yes
8050 else
8051   echo "$as_me: failed program was:" >&5
8052   cat conftest.$ac_ext >&5
8053   ac_header_preproc=no
8054 fi
8055 rm -f conftest.err conftest.$ac_ext
8056 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8057 echo "${ECHO_T}$ac_header_preproc" >&6
8058
8059 # So?  What about this header?
8060 case $ac_header_compiler:$ac_header_preproc in
8061   yes:no )
8062     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8063 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8064     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8065 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8066   no:yes )
8067     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8068 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8069     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8070 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8071     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8072 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8073 esac
8074 echo "$as_me:$LINENO: checking for $ac_header" >&5
8075 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8076 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8077   echo $ECHO_N "(cached) $ECHO_C" >&6
8078 else
8079   eval "$as_ac_Header=$ac_header_preproc"
8080 fi
8081 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8082 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8083
8084 fi
8085 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8086   cat >>confdefs.h <<_ACEOF
8087 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8088 _ACEOF
8089
8090 else
8091
8092 for ac_header in history.h
8093 do
8094 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8095 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8096   echo "$as_me:$LINENO: checking for $ac_header" >&5
8097 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8098 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8099   echo $ECHO_N "(cached) $ECHO_C" >&6
8100 fi
8101 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8102 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8103 else
8104   # Is the header compilable?
8105 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8106 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8107 cat >conftest.$ac_ext <<_ACEOF
8108 #line $LINENO "configure"
8109 #include "confdefs.h"
8110 $ac_includes_default
8111 #include <$ac_header>
8112 _ACEOF
8113 rm -f conftest.$ac_objext
8114 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8115   (eval $ac_compile) 2>&5
8116   ac_status=$?
8117   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8118   (exit $ac_status); } &&
8119          { ac_try='test -s conftest.$ac_objext'
8120   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8121   (eval $ac_try) 2>&5
8122   ac_status=$?
8123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8124   (exit $ac_status); }; }; then
8125   ac_header_compiler=yes
8126 else
8127   echo "$as_me: failed program was:" >&5
8128 cat conftest.$ac_ext >&5
8129 ac_header_compiler=no
8130 fi
8131 rm -f conftest.$ac_objext conftest.$ac_ext
8132 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8133 echo "${ECHO_T}$ac_header_compiler" >&6
8134
8135 # Is the header present?
8136 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8137 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8138 cat >conftest.$ac_ext <<_ACEOF
8139 #line $LINENO "configure"
8140 #include "confdefs.h"
8141 #include <$ac_header>
8142 _ACEOF
8143 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8144   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8145   ac_status=$?
8146   egrep -v '^ *\+' conftest.er1 >conftest.err
8147   rm -f conftest.er1
8148   cat conftest.err >&5
8149   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8150   (exit $ac_status); } >/dev/null; then
8151   if test -s conftest.err; then
8152     ac_cpp_err=$ac_c_preproc_warn_flag
8153   else
8154     ac_cpp_err=
8155   fi
8156 else
8157   ac_cpp_err=yes
8158 fi
8159 if test -z "$ac_cpp_err"; then
8160   ac_header_preproc=yes
8161 else
8162   echo "$as_me: failed program was:" >&5
8163   cat conftest.$ac_ext >&5
8164   ac_header_preproc=no
8165 fi
8166 rm -f conftest.err conftest.$ac_ext
8167 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8168 echo "${ECHO_T}$ac_header_preproc" >&6
8169
8170 # So?  What about this header?
8171 case $ac_header_compiler:$ac_header_preproc in
8172   yes:no )
8173     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8174 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8175     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8176 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8177   no:yes )
8178     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8179 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8180     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8181 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8182     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8183 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8184 esac
8185 echo "$as_me:$LINENO: checking for $ac_header" >&5
8186 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8187 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8188   echo $ECHO_N "(cached) $ECHO_C" >&6
8189 else
8190   eval "$as_ac_Header=$ac_header_preproc"
8191 fi
8192 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8193 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8194
8195 fi
8196 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8197   cat >>confdefs.h <<_ACEOF
8198 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8199 _ACEOF
8200
8201 else
8202   { { echo "$as_me:$LINENO: error: history header not found
8203 If you have readline already installed, see config.log for details on the
8204 failure.  It is possible the compiler isn't looking in the proper directory.
8205 Use --without-readline to disable readline support." >&5
8206 echo "$as_me: error: history header not found
8207 If you have readline already installed, see config.log for details on the
8208 failure.  It is possible the compiler isn't looking in the proper directory.
8209 Use --without-readline to disable readline support." >&2;}
8210    { (exit 1); exit 1; }; }
8211 fi
8212
8213 done
8214
8215 fi
8216
8217 done
8218
8219 fi
8220
8221 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
8222 # Some installations of libedit usurp /usr/include/readline/, which seems
8223 # bad practice, since in combined installations readline will have its headers
8224 # there.  We might have to resort to AC_EGREP checks to make sure we found
8225 # the proper header...
8226
8227 for ac_header in editline/readline.h
8228 do
8229 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8230 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8231   echo "$as_me:$LINENO: checking for $ac_header" >&5
8232 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8233 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8234   echo $ECHO_N "(cached) $ECHO_C" >&6
8235 fi
8236 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8237 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8238 else
8239   # Is the header compilable?
8240 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8241 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8242 cat >conftest.$ac_ext <<_ACEOF
8243 #line $LINENO "configure"
8244 #include "confdefs.h"
8245 $ac_includes_default
8246 #include <$ac_header>
8247 _ACEOF
8248 rm -f conftest.$ac_objext
8249 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8250   (eval $ac_compile) 2>&5
8251   ac_status=$?
8252   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8253   (exit $ac_status); } &&
8254          { ac_try='test -s conftest.$ac_objext'
8255   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8256   (eval $ac_try) 2>&5
8257   ac_status=$?
8258   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8259   (exit $ac_status); }; }; then
8260   ac_header_compiler=yes
8261 else
8262   echo "$as_me: failed program was:" >&5
8263 cat conftest.$ac_ext >&5
8264 ac_header_compiler=no
8265 fi
8266 rm -f conftest.$ac_objext conftest.$ac_ext
8267 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8268 echo "${ECHO_T}$ac_header_compiler" >&6
8269
8270 # Is the header present?
8271 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8272 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8273 cat >conftest.$ac_ext <<_ACEOF
8274 #line $LINENO "configure"
8275 #include "confdefs.h"
8276 #include <$ac_header>
8277 _ACEOF
8278 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8279   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8280   ac_status=$?
8281   egrep -v '^ *\+' conftest.er1 >conftest.err
8282   rm -f conftest.er1
8283   cat conftest.err >&5
8284   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8285   (exit $ac_status); } >/dev/null; then
8286   if test -s conftest.err; then
8287     ac_cpp_err=$ac_c_preproc_warn_flag
8288   else
8289     ac_cpp_err=
8290   fi
8291 else
8292   ac_cpp_err=yes
8293 fi
8294 if test -z "$ac_cpp_err"; then
8295   ac_header_preproc=yes
8296 else
8297   echo "$as_me: failed program was:" >&5
8298   cat conftest.$ac_ext >&5
8299   ac_header_preproc=no
8300 fi
8301 rm -f conftest.err conftest.$ac_ext
8302 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8303 echo "${ECHO_T}$ac_header_preproc" >&6
8304
8305 # So?  What about this header?
8306 case $ac_header_compiler:$ac_header_preproc in
8307   yes:no )
8308     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8309 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8310     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8311 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8312   no:yes )
8313     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8314 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8315     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8316 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8317     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8318 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8319 esac
8320 echo "$as_me:$LINENO: checking for $ac_header" >&5
8321 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8322 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8323   echo $ECHO_N "(cached) $ECHO_C" >&6
8324 else
8325   eval "$as_ac_Header=$ac_header_preproc"
8326 fi
8327 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8328 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8329
8330 fi
8331 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8332   cat >>confdefs.h <<_ACEOF
8333 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8334 _ACEOF
8335
8336 else
8337
8338 for ac_header in readline.h
8339 do
8340 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8341 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8342   echo "$as_me:$LINENO: checking for $ac_header" >&5
8343 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8344 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8345   echo $ECHO_N "(cached) $ECHO_C" >&6
8346 fi
8347 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8348 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8349 else
8350   # Is the header compilable?
8351 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8352 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8353 cat >conftest.$ac_ext <<_ACEOF
8354 #line $LINENO "configure"
8355 #include "confdefs.h"
8356 $ac_includes_default
8357 #include <$ac_header>
8358 _ACEOF
8359 rm -f conftest.$ac_objext
8360 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8361   (eval $ac_compile) 2>&5
8362   ac_status=$?
8363   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8364   (exit $ac_status); } &&
8365          { ac_try='test -s conftest.$ac_objext'
8366   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8367   (eval $ac_try) 2>&5
8368   ac_status=$?
8369   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8370   (exit $ac_status); }; }; then
8371   ac_header_compiler=yes
8372 else
8373   echo "$as_me: failed program was:" >&5
8374 cat conftest.$ac_ext >&5
8375 ac_header_compiler=no
8376 fi
8377 rm -f conftest.$ac_objext conftest.$ac_ext
8378 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8379 echo "${ECHO_T}$ac_header_compiler" >&6
8380
8381 # Is the header present?
8382 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8383 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8384 cat >conftest.$ac_ext <<_ACEOF
8385 #line $LINENO "configure"
8386 #include "confdefs.h"
8387 #include <$ac_header>
8388 _ACEOF
8389 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8390   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8391   ac_status=$?
8392   egrep -v '^ *\+' conftest.er1 >conftest.err
8393   rm -f conftest.er1
8394   cat conftest.err >&5
8395   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8396   (exit $ac_status); } >/dev/null; then
8397   if test -s conftest.err; then
8398     ac_cpp_err=$ac_c_preproc_warn_flag
8399   else
8400     ac_cpp_err=
8401   fi
8402 else
8403   ac_cpp_err=yes
8404 fi
8405 if test -z "$ac_cpp_err"; then
8406   ac_header_preproc=yes
8407 else
8408   echo "$as_me: failed program was:" >&5
8409   cat conftest.$ac_ext >&5
8410   ac_header_preproc=no
8411 fi
8412 rm -f conftest.err conftest.$ac_ext
8413 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8414 echo "${ECHO_T}$ac_header_preproc" >&6
8415
8416 # So?  What about this header?
8417 case $ac_header_compiler:$ac_header_preproc in
8418   yes:no )
8419     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8420 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8421     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8422 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8423   no:yes )
8424     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8425 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8426     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8427 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8428     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8429 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8430 esac
8431 echo "$as_me:$LINENO: checking for $ac_header" >&5
8432 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8433 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8434   echo $ECHO_N "(cached) $ECHO_C" >&6
8435 else
8436   eval "$as_ac_Header=$ac_header_preproc"
8437 fi
8438 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8439 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8440
8441 fi
8442 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8443   cat >>confdefs.h <<_ACEOF
8444 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8445 _ACEOF
8446
8447 else
8448
8449 for ac_header in readline/readline.h
8450 do
8451 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8452 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8453   echo "$as_me:$LINENO: checking for $ac_header" >&5
8454 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8455 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8456   echo $ECHO_N "(cached) $ECHO_C" >&6
8457 fi
8458 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8459 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8460 else
8461   # Is the header compilable?
8462 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8463 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8464 cat >conftest.$ac_ext <<_ACEOF
8465 #line $LINENO "configure"
8466 #include "confdefs.h"
8467 $ac_includes_default
8468 #include <$ac_header>
8469 _ACEOF
8470 rm -f conftest.$ac_objext
8471 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8472   (eval $ac_compile) 2>&5
8473   ac_status=$?
8474   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8475   (exit $ac_status); } &&
8476          { ac_try='test -s conftest.$ac_objext'
8477   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8478   (eval $ac_try) 2>&5
8479   ac_status=$?
8480   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8481   (exit $ac_status); }; }; then
8482   ac_header_compiler=yes
8483 else
8484   echo "$as_me: failed program was:" >&5
8485 cat conftest.$ac_ext >&5
8486 ac_header_compiler=no
8487 fi
8488 rm -f conftest.$ac_objext conftest.$ac_ext
8489 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8490 echo "${ECHO_T}$ac_header_compiler" >&6
8491
8492 # Is the header present?
8493 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8494 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8495 cat >conftest.$ac_ext <<_ACEOF
8496 #line $LINENO "configure"
8497 #include "confdefs.h"
8498 #include <$ac_header>
8499 _ACEOF
8500 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8501   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8502   ac_status=$?
8503   egrep -v '^ *\+' conftest.er1 >conftest.err
8504   rm -f conftest.er1
8505   cat conftest.err >&5
8506   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8507   (exit $ac_status); } >/dev/null; then
8508   if test -s conftest.err; then
8509     ac_cpp_err=$ac_c_preproc_warn_flag
8510   else
8511     ac_cpp_err=
8512   fi
8513 else
8514   ac_cpp_err=yes
8515 fi
8516 if test -z "$ac_cpp_err"; then
8517   ac_header_preproc=yes
8518 else
8519   echo "$as_me: failed program was:" >&5
8520   cat conftest.$ac_ext >&5
8521   ac_header_preproc=no
8522 fi
8523 rm -f conftest.err conftest.$ac_ext
8524 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8525 echo "${ECHO_T}$ac_header_preproc" >&6
8526
8527 # So?  What about this header?
8528 case $ac_header_compiler:$ac_header_preproc in
8529   yes:no )
8530     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8531 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8532     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8533 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8534   no:yes )
8535     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8536 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8537     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8538 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8539     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8540 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8541 esac
8542 echo "$as_me:$LINENO: checking for $ac_header" >&5
8543 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8544 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8545   echo $ECHO_N "(cached) $ECHO_C" >&6
8546 else
8547   eval "$as_ac_Header=$ac_header_preproc"
8548 fi
8549 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8550 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8551
8552 fi
8553 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8554   cat >>confdefs.h <<_ACEOF
8555 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8556 _ACEOF
8557
8558 else
8559   { { echo "$as_me:$LINENO: error: readline header not found
8560 If you have libedit already installed, see config.log for details on the
8561 failure.  It is possible the compiler isn't looking in the proper directory.
8562 Use --without-readline to disable libedit support." >&5
8563 echo "$as_me: error: readline header not found
8564 If you have libedit already installed, see config.log for details on the
8565 failure.  It is possible the compiler isn't looking in the proper directory.
8566 Use --without-readline to disable libedit support." >&2;}
8567    { (exit 1); exit 1; }; }
8568 fi
8569
8570 done
8571
8572 fi
8573
8574 done
8575
8576 fi
8577
8578 done
8579
8580
8581 for ac_header in editline/history.h
8582 do
8583 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8584 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8585   echo "$as_me:$LINENO: checking for $ac_header" >&5
8586 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8587 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8588   echo $ECHO_N "(cached) $ECHO_C" >&6
8589 fi
8590 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8591 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8592 else
8593   # Is the header compilable?
8594 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8595 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8596 cat >conftest.$ac_ext <<_ACEOF
8597 #line $LINENO "configure"
8598 #include "confdefs.h"
8599 $ac_includes_default
8600 #include <$ac_header>
8601 _ACEOF
8602 rm -f conftest.$ac_objext
8603 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8604   (eval $ac_compile) 2>&5
8605   ac_status=$?
8606   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8607   (exit $ac_status); } &&
8608          { ac_try='test -s conftest.$ac_objext'
8609   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8610   (eval $ac_try) 2>&5
8611   ac_status=$?
8612   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8613   (exit $ac_status); }; }; then
8614   ac_header_compiler=yes
8615 else
8616   echo "$as_me: failed program was:" >&5
8617 cat conftest.$ac_ext >&5
8618 ac_header_compiler=no
8619 fi
8620 rm -f conftest.$ac_objext conftest.$ac_ext
8621 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8622 echo "${ECHO_T}$ac_header_compiler" >&6
8623
8624 # Is the header present?
8625 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8626 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8627 cat >conftest.$ac_ext <<_ACEOF
8628 #line $LINENO "configure"
8629 #include "confdefs.h"
8630 #include <$ac_header>
8631 _ACEOF
8632 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8633   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8634   ac_status=$?
8635   egrep -v '^ *\+' conftest.er1 >conftest.err
8636   rm -f conftest.er1
8637   cat conftest.err >&5
8638   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8639   (exit $ac_status); } >/dev/null; then
8640   if test -s conftest.err; then
8641     ac_cpp_err=$ac_c_preproc_warn_flag
8642   else
8643     ac_cpp_err=
8644   fi
8645 else
8646   ac_cpp_err=yes
8647 fi
8648 if test -z "$ac_cpp_err"; then
8649   ac_header_preproc=yes
8650 else
8651   echo "$as_me: failed program was:" >&5
8652   cat conftest.$ac_ext >&5
8653   ac_header_preproc=no
8654 fi
8655 rm -f conftest.err conftest.$ac_ext
8656 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8657 echo "${ECHO_T}$ac_header_preproc" >&6
8658
8659 # So?  What about this header?
8660 case $ac_header_compiler:$ac_header_preproc in
8661   yes:no )
8662     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8663 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8664     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8665 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8666   no:yes )
8667     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8668 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8669     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8670 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8671     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8672 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8673 esac
8674 echo "$as_me:$LINENO: checking for $ac_header" >&5
8675 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8676 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8677   echo $ECHO_N "(cached) $ECHO_C" >&6
8678 else
8679   eval "$as_ac_Header=$ac_header_preproc"
8680 fi
8681 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8682 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8683
8684 fi
8685 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8686   cat >>confdefs.h <<_ACEOF
8687 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8688 _ACEOF
8689
8690 else
8691
8692 for ac_header in history.h
8693 do
8694 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8695 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8696   echo "$as_me:$LINENO: checking for $ac_header" >&5
8697 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8698 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8699   echo $ECHO_N "(cached) $ECHO_C" >&6
8700 fi
8701 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8702 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8703 else
8704   # Is the header compilable?
8705 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8706 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8707 cat >conftest.$ac_ext <<_ACEOF
8708 #line $LINENO "configure"
8709 #include "confdefs.h"
8710 $ac_includes_default
8711 #include <$ac_header>
8712 _ACEOF
8713 rm -f conftest.$ac_objext
8714 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8715   (eval $ac_compile) 2>&5
8716   ac_status=$?
8717   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8718   (exit $ac_status); } &&
8719          { ac_try='test -s conftest.$ac_objext'
8720   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8721   (eval $ac_try) 2>&5
8722   ac_status=$?
8723   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8724   (exit $ac_status); }; }; then
8725   ac_header_compiler=yes
8726 else
8727   echo "$as_me: failed program was:" >&5
8728 cat conftest.$ac_ext >&5
8729 ac_header_compiler=no
8730 fi
8731 rm -f conftest.$ac_objext conftest.$ac_ext
8732 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8733 echo "${ECHO_T}$ac_header_compiler" >&6
8734
8735 # Is the header present?
8736 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8737 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8738 cat >conftest.$ac_ext <<_ACEOF
8739 #line $LINENO "configure"
8740 #include "confdefs.h"
8741 #include <$ac_header>
8742 _ACEOF
8743 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8744   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8745   ac_status=$?
8746   egrep -v '^ *\+' conftest.er1 >conftest.err
8747   rm -f conftest.er1
8748   cat conftest.err >&5
8749   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8750   (exit $ac_status); } >/dev/null; then
8751   if test -s conftest.err; then
8752     ac_cpp_err=$ac_c_preproc_warn_flag
8753   else
8754     ac_cpp_err=
8755   fi
8756 else
8757   ac_cpp_err=yes
8758 fi
8759 if test -z "$ac_cpp_err"; then
8760   ac_header_preproc=yes
8761 else
8762   echo "$as_me: failed program was:" >&5
8763   cat conftest.$ac_ext >&5
8764   ac_header_preproc=no
8765 fi
8766 rm -f conftest.err conftest.$ac_ext
8767 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8768 echo "${ECHO_T}$ac_header_preproc" >&6
8769
8770 # So?  What about this header?
8771 case $ac_header_compiler:$ac_header_preproc in
8772   yes:no )
8773     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8774 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8775     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8776 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8777   no:yes )
8778     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8779 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8780     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8781 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8782     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8783 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8784 esac
8785 echo "$as_me:$LINENO: checking for $ac_header" >&5
8786 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8787 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8788   echo $ECHO_N "(cached) $ECHO_C" >&6
8789 else
8790   eval "$as_ac_Header=$ac_header_preproc"
8791 fi
8792 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8793 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8794
8795 fi
8796 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8797   cat >>confdefs.h <<_ACEOF
8798 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8799 _ACEOF
8800
8801 else
8802
8803 for ac_header in readline/history.h
8804 do
8805 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
8806 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8807   echo "$as_me:$LINENO: checking for $ac_header" >&5
8808 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8809 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8810   echo $ECHO_N "(cached) $ECHO_C" >&6
8811 fi
8812 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8813 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8814 else
8815   # Is the header compilable?
8816 echo "$as_me:$LINENO: checking $ac_header usability" >&5
8817 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
8818 cat >conftest.$ac_ext <<_ACEOF
8819 #line $LINENO "configure"
8820 #include "confdefs.h"
8821 $ac_includes_default
8822 #include <$ac_header>
8823 _ACEOF
8824 rm -f conftest.$ac_objext
8825 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8826   (eval $ac_compile) 2>&5
8827   ac_status=$?
8828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8829   (exit $ac_status); } &&
8830          { ac_try='test -s conftest.$ac_objext'
8831   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8832   (eval $ac_try) 2>&5
8833   ac_status=$?
8834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8835   (exit $ac_status); }; }; then
8836   ac_header_compiler=yes
8837 else
8838   echo "$as_me: failed program was:" >&5
8839 cat conftest.$ac_ext >&5
8840 ac_header_compiler=no
8841 fi
8842 rm -f conftest.$ac_objext conftest.$ac_ext
8843 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8844 echo "${ECHO_T}$ac_header_compiler" >&6
8845
8846 # Is the header present?
8847 echo "$as_me:$LINENO: checking $ac_header presence" >&5
8848 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
8849 cat >conftest.$ac_ext <<_ACEOF
8850 #line $LINENO "configure"
8851 #include "confdefs.h"
8852 #include <$ac_header>
8853 _ACEOF
8854 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8855   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8856   ac_status=$?
8857   egrep -v '^ *\+' conftest.er1 >conftest.err
8858   rm -f conftest.er1
8859   cat conftest.err >&5
8860   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8861   (exit $ac_status); } >/dev/null; then
8862   if test -s conftest.err; then
8863     ac_cpp_err=$ac_c_preproc_warn_flag
8864   else
8865     ac_cpp_err=
8866   fi
8867 else
8868   ac_cpp_err=yes
8869 fi
8870 if test -z "$ac_cpp_err"; then
8871   ac_header_preproc=yes
8872 else
8873   echo "$as_me: failed program was:" >&5
8874   cat conftest.$ac_ext >&5
8875   ac_header_preproc=no
8876 fi
8877 rm -f conftest.err conftest.$ac_ext
8878 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
8879 echo "${ECHO_T}$ac_header_preproc" >&6
8880
8881 # So?  What about this header?
8882 case $ac_header_compiler:$ac_header_preproc in
8883   yes:no )
8884     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
8885 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
8886     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8887 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8888   no:yes )
8889     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
8890 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
8891     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
8892 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
8893     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
8894 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
8895 esac
8896 echo "$as_me:$LINENO: checking for $ac_header" >&5
8897 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
8898 if eval "test \"\${$as_ac_Header+set}\" = set"; then
8899   echo $ECHO_N "(cached) $ECHO_C" >&6
8900 else
8901   eval "$as_ac_Header=$ac_header_preproc"
8902 fi
8903 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
8904 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
8905
8906 fi
8907 if test `eval echo '${'$as_ac_Header'}'` = yes; then
8908   cat >>confdefs.h <<_ACEOF
8909 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
8910 _ACEOF
8911
8912 else
8913   { { echo "$as_me:$LINENO: error: history header not found
8914 If you have libedit already installed, see config.log for details on the
8915 failure.  It is possible the compiler isn't looking in the proper directory.
8916 Use --without-readline to disable libedit support." >&5
8917 echo "$as_me: error: history header not found
8918 If you have libedit already installed, see config.log for details on the
8919 failure.  It is possible the compiler isn't looking in the proper directory.
8920 Use --without-readline to disable libedit support." >&2;}
8921    { (exit 1); exit 1; }; }
8922 fi
8923
8924 done
8925
8926 fi
8927
8928 done
8929
8930 fi
8931
8932 done
8933
8934 fi
8935
8936 if test "$with_zlib" = yes; then
8937   if test "${ac_cv_header_zlib_h+set}" = set; then
8938   echo "$as_me:$LINENO: checking for zlib.h" >&5
8939 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
8940 if test "${ac_cv_header_zlib_h+set}" = set; then
8941   echo $ECHO_N "(cached) $ECHO_C" >&6
8942 fi
8943 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
8944 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
8945 else
8946   # Is the header compilable?
8947 echo "$as_me:$LINENO: checking zlib.h usability" >&5
8948 echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6
8949 cat >conftest.$ac_ext <<_ACEOF
8950 #line $LINENO "configure"
8951 #include "confdefs.h"
8952 $ac_includes_default
8953 #include <zlib.h>
8954 _ACEOF
8955 rm -f conftest.$ac_objext
8956 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
8957   (eval $ac_compile) 2>&5
8958   ac_status=$?
8959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8960   (exit $ac_status); } &&
8961          { ac_try='test -s conftest.$ac_objext'
8962   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
8963   (eval $ac_try) 2>&5
8964   ac_status=$?
8965   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8966   (exit $ac_status); }; }; then
8967   ac_header_compiler=yes
8968 else
8969   echo "$as_me: failed program was:" >&5
8970 cat conftest.$ac_ext >&5
8971 ac_header_compiler=no
8972 fi
8973 rm -f conftest.$ac_objext conftest.$ac_ext
8974 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
8975 echo "${ECHO_T}$ac_header_compiler" >&6
8976
8977 # Is the header present?
8978 echo "$as_me:$LINENO: checking zlib.h presence" >&5
8979 echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6
8980 cat >conftest.$ac_ext <<_ACEOF
8981 #line $LINENO "configure"
8982 #include "confdefs.h"
8983 #include <zlib.h>
8984 _ACEOF
8985 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
8986   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
8987   ac_status=$?
8988   egrep -v '^ *\+' conftest.er1 >conftest.err
8989   rm -f conftest.er1
8990   cat conftest.err >&5
8991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
8992   (exit $ac_status); } >/dev/null; then
8993   if test -s conftest.err; then
8994     ac_cpp_err=$ac_c_preproc_warn_flag
8995   else
8996     ac_cpp_err=
8997   fi
8998 else
8999   ac_cpp_err=yes
9000 fi
9001 if test -z "$ac_cpp_err"; then
9002   ac_header_preproc=yes
9003 else
9004   echo "$as_me: failed program was:" >&5
9005   cat conftest.$ac_ext >&5
9006   ac_header_preproc=no
9007 fi
9008 rm -f conftest.err conftest.$ac_ext
9009 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9010 echo "${ECHO_T}$ac_header_preproc" >&6
9011
9012 # So?  What about this header?
9013 case $ac_header_compiler:$ac_header_preproc in
9014   yes:no )
9015     { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
9016 echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9017     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
9018 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;};;
9019   no:yes )
9020     { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
9021 echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
9022     { echo "$as_me:$LINENO: WARNING: zlib.h: check for missing prerequisite headers?" >&5
9023 echo "$as_me: WARNING: zlib.h: check for missing prerequisite headers?" >&2;}
9024     { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
9025 echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;};;
9026 esac
9027 echo "$as_me:$LINENO: checking for zlib.h" >&5
9028 echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6
9029 if test "${ac_cv_header_zlib_h+set}" = set; then
9030   echo $ECHO_N "(cached) $ECHO_C" >&6
9031 else
9032   ac_cv_header_zlib_h=$ac_header_preproc
9033 fi
9034 echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
9035 echo "${ECHO_T}$ac_cv_header_zlib_h" >&6
9036
9037 fi
9038 if test $ac_cv_header_zlib_h = yes; then
9039   :
9040 else
9041   { { echo "$as_me:$LINENO: error: zlib header not found
9042 If you have zlib already installed, see config.log for details on the
9043 failure.  It is possible the compiler isn't looking in the proper directory.
9044 Use --without-zlib to disable zlib support." >&5
9045 echo "$as_me: error: zlib header not found
9046 If you have zlib already installed, see config.log for details on the
9047 failure.  It is possible the compiler isn't looking in the proper directory.
9048 Use --without-zlib to disable zlib support." >&2;}
9049    { (exit 1); exit 1; }; }
9050 fi
9051
9052
9053 fi
9054
9055 if test "$with_krb4" = yes ; then
9056   if test "${ac_cv_header_krb_h+set}" = set; then
9057   echo "$as_me:$LINENO: checking for krb.h" >&5
9058 echo $ECHO_N "checking for krb.h... $ECHO_C" >&6
9059 if test "${ac_cv_header_krb_h+set}" = set; then
9060   echo $ECHO_N "(cached) $ECHO_C" >&6
9061 fi
9062 echo "$as_me:$LINENO: result: $ac_cv_header_krb_h" >&5
9063 echo "${ECHO_T}$ac_cv_header_krb_h" >&6
9064 else
9065   # Is the header compilable?
9066 echo "$as_me:$LINENO: checking krb.h usability" >&5
9067 echo $ECHO_N "checking krb.h usability... $ECHO_C" >&6
9068 cat >conftest.$ac_ext <<_ACEOF
9069 #line $LINENO "configure"
9070 #include "confdefs.h"
9071 $ac_includes_default
9072 #include <krb.h>
9073 _ACEOF
9074 rm -f conftest.$ac_objext
9075 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9076   (eval $ac_compile) 2>&5
9077   ac_status=$?
9078   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9079   (exit $ac_status); } &&
9080          { ac_try='test -s conftest.$ac_objext'
9081   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9082   (eval $ac_try) 2>&5
9083   ac_status=$?
9084   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9085   (exit $ac_status); }; }; then
9086   ac_header_compiler=yes
9087 else
9088   echo "$as_me: failed program was:" >&5
9089 cat conftest.$ac_ext >&5
9090 ac_header_compiler=no
9091 fi
9092 rm -f conftest.$ac_objext conftest.$ac_ext
9093 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9094 echo "${ECHO_T}$ac_header_compiler" >&6
9095
9096 # Is the header present?
9097 echo "$as_me:$LINENO: checking krb.h presence" >&5
9098 echo $ECHO_N "checking krb.h presence... $ECHO_C" >&6
9099 cat >conftest.$ac_ext <<_ACEOF
9100 #line $LINENO "configure"
9101 #include "confdefs.h"
9102 #include <krb.h>
9103 _ACEOF
9104 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9105   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9106   ac_status=$?
9107   egrep -v '^ *\+' conftest.er1 >conftest.err
9108   rm -f conftest.er1
9109   cat conftest.err >&5
9110   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9111   (exit $ac_status); } >/dev/null; then
9112   if test -s conftest.err; then
9113     ac_cpp_err=$ac_c_preproc_warn_flag
9114   else
9115     ac_cpp_err=
9116   fi
9117 else
9118   ac_cpp_err=yes
9119 fi
9120 if test -z "$ac_cpp_err"; then
9121   ac_header_preproc=yes
9122 else
9123   echo "$as_me: failed program was:" >&5
9124   cat conftest.$ac_ext >&5
9125   ac_header_preproc=no
9126 fi
9127 rm -f conftest.err conftest.$ac_ext
9128 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9129 echo "${ECHO_T}$ac_header_preproc" >&6
9130
9131 # So?  What about this header?
9132 case $ac_header_compiler:$ac_header_preproc in
9133   yes:no )
9134     { echo "$as_me:$LINENO: WARNING: krb.h: accepted by the compiler, rejected by the preprocessor!" >&5
9135 echo "$as_me: WARNING: krb.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9136     { echo "$as_me:$LINENO: WARNING: krb.h: proceeding with the preprocessor's result" >&5
9137 echo "$as_me: WARNING: krb.h: proceeding with the preprocessor's result" >&2;};;
9138   no:yes )
9139     { echo "$as_me:$LINENO: WARNING: krb.h: present but cannot be compiled" >&5
9140 echo "$as_me: WARNING: krb.h: present but cannot be compiled" >&2;}
9141     { echo "$as_me:$LINENO: WARNING: krb.h: check for missing prerequisite headers?" >&5
9142 echo "$as_me: WARNING: krb.h: check for missing prerequisite headers?" >&2;}
9143     { echo "$as_me:$LINENO: WARNING: krb.h: proceeding with the preprocessor's result" >&5
9144 echo "$as_me: WARNING: krb.h: proceeding with the preprocessor's result" >&2;};;
9145 esac
9146 echo "$as_me:$LINENO: checking for krb.h" >&5
9147 echo $ECHO_N "checking for krb.h... $ECHO_C" >&6
9148 if test "${ac_cv_header_krb_h+set}" = set; then
9149   echo $ECHO_N "(cached) $ECHO_C" >&6
9150 else
9151   ac_cv_header_krb_h=$ac_header_preproc
9152 fi
9153 echo "$as_me:$LINENO: result: $ac_cv_header_krb_h" >&5
9154 echo "${ECHO_T}$ac_cv_header_krb_h" >&6
9155
9156 fi
9157 if test $ac_cv_header_krb_h = yes; then
9158   :
9159 else
9160   { { echo "$as_me:$LINENO: error: header file <krb.h> is required for Kerberos 4" >&5
9161 echo "$as_me: error: header file <krb.h> is required for Kerberos 4" >&2;}
9162    { (exit 1); exit 1; }; }
9163 fi
9164
9165
9166 fi
9167
9168 if test "$with_krb5" = yes ; then
9169   if test "${ac_cv_header_krb5_h+set}" = set; then
9170   echo "$as_me:$LINENO: checking for krb5.h" >&5
9171 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9172 if test "${ac_cv_header_krb5_h+set}" = set; then
9173   echo $ECHO_N "(cached) $ECHO_C" >&6
9174 fi
9175 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9176 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9177 else
9178   # Is the header compilable?
9179 echo "$as_me:$LINENO: checking krb5.h usability" >&5
9180 echo $ECHO_N "checking krb5.h usability... $ECHO_C" >&6
9181 cat >conftest.$ac_ext <<_ACEOF
9182 #line $LINENO "configure"
9183 #include "confdefs.h"
9184 $ac_includes_default
9185 #include <krb5.h>
9186 _ACEOF
9187 rm -f conftest.$ac_objext
9188 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9189   (eval $ac_compile) 2>&5
9190   ac_status=$?
9191   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9192   (exit $ac_status); } &&
9193          { ac_try='test -s conftest.$ac_objext'
9194   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9195   (eval $ac_try) 2>&5
9196   ac_status=$?
9197   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9198   (exit $ac_status); }; }; then
9199   ac_header_compiler=yes
9200 else
9201   echo "$as_me: failed program was:" >&5
9202 cat conftest.$ac_ext >&5
9203 ac_header_compiler=no
9204 fi
9205 rm -f conftest.$ac_objext conftest.$ac_ext
9206 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9207 echo "${ECHO_T}$ac_header_compiler" >&6
9208
9209 # Is the header present?
9210 echo "$as_me:$LINENO: checking krb5.h presence" >&5
9211 echo $ECHO_N "checking krb5.h presence... $ECHO_C" >&6
9212 cat >conftest.$ac_ext <<_ACEOF
9213 #line $LINENO "configure"
9214 #include "confdefs.h"
9215 #include <krb5.h>
9216 _ACEOF
9217 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9218   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9219   ac_status=$?
9220   egrep -v '^ *\+' conftest.er1 >conftest.err
9221   rm -f conftest.er1
9222   cat conftest.err >&5
9223   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9224   (exit $ac_status); } >/dev/null; then
9225   if test -s conftest.err; then
9226     ac_cpp_err=$ac_c_preproc_warn_flag
9227   else
9228     ac_cpp_err=
9229   fi
9230 else
9231   ac_cpp_err=yes
9232 fi
9233 if test -z "$ac_cpp_err"; then
9234   ac_header_preproc=yes
9235 else
9236   echo "$as_me: failed program was:" >&5
9237   cat conftest.$ac_ext >&5
9238   ac_header_preproc=no
9239 fi
9240 rm -f conftest.err conftest.$ac_ext
9241 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9242 echo "${ECHO_T}$ac_header_preproc" >&6
9243
9244 # So?  What about this header?
9245 case $ac_header_compiler:$ac_header_preproc in
9246   yes:no )
9247     { echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
9248 echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9249     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
9250 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;};;
9251   no:yes )
9252     { echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
9253 echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
9254     { echo "$as_me:$LINENO: WARNING: krb5.h: check for missing prerequisite headers?" >&5
9255 echo "$as_me: WARNING: krb5.h: check for missing prerequisite headers?" >&2;}
9256     { echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
9257 echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;};;
9258 esac
9259 echo "$as_me:$LINENO: checking for krb5.h" >&5
9260 echo $ECHO_N "checking for krb5.h... $ECHO_C" >&6
9261 if test "${ac_cv_header_krb5_h+set}" = set; then
9262   echo $ECHO_N "(cached) $ECHO_C" >&6
9263 else
9264   ac_cv_header_krb5_h=$ac_header_preproc
9265 fi
9266 echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
9267 echo "${ECHO_T}$ac_cv_header_krb5_h" >&6
9268
9269 fi
9270 if test $ac_cv_header_krb5_h = yes; then
9271   :
9272 else
9273   { { echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
9274 echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
9275    { (exit 1); exit 1; }; }
9276 fi
9277
9278
9279 fi
9280
9281 if test "$with_openssl" = yes ; then
9282   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9283   echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9284 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9285 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9286   echo $ECHO_N "(cached) $ECHO_C" >&6
9287 fi
9288 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9289 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9290 else
9291   # Is the header compilable?
9292 echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
9293 echo $ECHO_N "checking openssl/ssl.h usability... $ECHO_C" >&6
9294 cat >conftest.$ac_ext <<_ACEOF
9295 #line $LINENO "configure"
9296 #include "confdefs.h"
9297 $ac_includes_default
9298 #include <openssl/ssl.h>
9299 _ACEOF
9300 rm -f conftest.$ac_objext
9301 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9302   (eval $ac_compile) 2>&5
9303   ac_status=$?
9304   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9305   (exit $ac_status); } &&
9306          { ac_try='test -s conftest.$ac_objext'
9307   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9308   (eval $ac_try) 2>&5
9309   ac_status=$?
9310   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9311   (exit $ac_status); }; }; then
9312   ac_header_compiler=yes
9313 else
9314   echo "$as_me: failed program was:" >&5
9315 cat conftest.$ac_ext >&5
9316 ac_header_compiler=no
9317 fi
9318 rm -f conftest.$ac_objext conftest.$ac_ext
9319 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9320 echo "${ECHO_T}$ac_header_compiler" >&6
9321
9322 # Is the header present?
9323 echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
9324 echo $ECHO_N "checking openssl/ssl.h presence... $ECHO_C" >&6
9325 cat >conftest.$ac_ext <<_ACEOF
9326 #line $LINENO "configure"
9327 #include "confdefs.h"
9328 #include <openssl/ssl.h>
9329 _ACEOF
9330 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9331   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9332   ac_status=$?
9333   egrep -v '^ *\+' conftest.er1 >conftest.err
9334   rm -f conftest.er1
9335   cat conftest.err >&5
9336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9337   (exit $ac_status); } >/dev/null; then
9338   if test -s conftest.err; then
9339     ac_cpp_err=$ac_c_preproc_warn_flag
9340   else
9341     ac_cpp_err=
9342   fi
9343 else
9344   ac_cpp_err=yes
9345 fi
9346 if test -z "$ac_cpp_err"; then
9347   ac_header_preproc=yes
9348 else
9349   echo "$as_me: failed program was:" >&5
9350   cat conftest.$ac_ext >&5
9351   ac_header_preproc=no
9352 fi
9353 rm -f conftest.err conftest.$ac_ext
9354 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9355 echo "${ECHO_T}$ac_header_preproc" >&6
9356
9357 # So?  What about this header?
9358 case $ac_header_compiler:$ac_header_preproc in
9359   yes:no )
9360     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
9361 echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9362     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
9363 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;};;
9364   no:yes )
9365     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
9366 echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
9367     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: check for missing prerequisite headers?" >&5
9368 echo "$as_me: WARNING: openssl/ssl.h: check for missing prerequisite headers?" >&2;}
9369     { echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
9370 echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;};;
9371 esac
9372 echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
9373 echo $ECHO_N "checking for openssl/ssl.h... $ECHO_C" >&6
9374 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
9375   echo $ECHO_N "(cached) $ECHO_C" >&6
9376 else
9377   ac_cv_header_openssl_ssl_h=$ac_header_preproc
9378 fi
9379 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
9380 echo "${ECHO_T}$ac_cv_header_openssl_ssl_h" >&6
9381
9382 fi
9383 if test $ac_cv_header_openssl_ssl_h = yes; then
9384   :
9385 else
9386   { { echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
9387 echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
9388    { (exit 1); exit 1; }; }
9389 fi
9390
9391
9392   if test "${ac_cv_header_openssl_err_h+set}" = set; then
9393   echo "$as_me:$LINENO: checking for openssl/err.h" >&5
9394 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
9395 if test "${ac_cv_header_openssl_err_h+set}" = set; then
9396   echo $ECHO_N "(cached) $ECHO_C" >&6
9397 fi
9398 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
9399 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
9400 else
9401   # Is the header compilable?
9402 echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
9403 echo $ECHO_N "checking openssl/err.h usability... $ECHO_C" >&6
9404 cat >conftest.$ac_ext <<_ACEOF
9405 #line $LINENO "configure"
9406 #include "confdefs.h"
9407 $ac_includes_default
9408 #include <openssl/err.h>
9409 _ACEOF
9410 rm -f conftest.$ac_objext
9411 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9412   (eval $ac_compile) 2>&5
9413   ac_status=$?
9414   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9415   (exit $ac_status); } &&
9416          { ac_try='test -s conftest.$ac_objext'
9417   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9418   (eval $ac_try) 2>&5
9419   ac_status=$?
9420   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9421   (exit $ac_status); }; }; then
9422   ac_header_compiler=yes
9423 else
9424   echo "$as_me: failed program was:" >&5
9425 cat conftest.$ac_ext >&5
9426 ac_header_compiler=no
9427 fi
9428 rm -f conftest.$ac_objext conftest.$ac_ext
9429 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9430 echo "${ECHO_T}$ac_header_compiler" >&6
9431
9432 # Is the header present?
9433 echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
9434 echo $ECHO_N "checking openssl/err.h presence... $ECHO_C" >&6
9435 cat >conftest.$ac_ext <<_ACEOF
9436 #line $LINENO "configure"
9437 #include "confdefs.h"
9438 #include <openssl/err.h>
9439 _ACEOF
9440 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9441   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9442   ac_status=$?
9443   egrep -v '^ *\+' conftest.er1 >conftest.err
9444   rm -f conftest.er1
9445   cat conftest.err >&5
9446   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9447   (exit $ac_status); } >/dev/null; then
9448   if test -s conftest.err; then
9449     ac_cpp_err=$ac_c_preproc_warn_flag
9450   else
9451     ac_cpp_err=
9452   fi
9453 else
9454   ac_cpp_err=yes
9455 fi
9456 if test -z "$ac_cpp_err"; then
9457   ac_header_preproc=yes
9458 else
9459   echo "$as_me: failed program was:" >&5
9460   cat conftest.$ac_ext >&5
9461   ac_header_preproc=no
9462 fi
9463 rm -f conftest.err conftest.$ac_ext
9464 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9465 echo "${ECHO_T}$ac_header_preproc" >&6
9466
9467 # So?  What about this header?
9468 case $ac_header_compiler:$ac_header_preproc in
9469   yes:no )
9470     { echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
9471 echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9472     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
9473 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;};;
9474   no:yes )
9475     { echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
9476 echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
9477     { echo "$as_me:$LINENO: WARNING: openssl/err.h: check for missing prerequisite headers?" >&5
9478 echo "$as_me: WARNING: openssl/err.h: check for missing prerequisite headers?" >&2;}
9479     { echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
9480 echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;};;
9481 esac
9482 echo "$as_me:$LINENO: checking for openssl/err.h" >&5
9483 echo $ECHO_N "checking for openssl/err.h... $ECHO_C" >&6
9484 if test "${ac_cv_header_openssl_err_h+set}" = set; then
9485   echo $ECHO_N "(cached) $ECHO_C" >&6
9486 else
9487   ac_cv_header_openssl_err_h=$ac_header_preproc
9488 fi
9489 echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
9490 echo "${ECHO_T}$ac_cv_header_openssl_err_h" >&6
9491
9492 fi
9493 if test $ac_cv_header_openssl_err_h = yes; then
9494   :
9495 else
9496   { { echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
9497 echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
9498    { (exit 1); exit 1; }; }
9499 fi
9500
9501
9502 fi
9503
9504 if test "$with_pam" = yes ; then
9505
9506 for ac_header in security/pam_appl.h
9507 do
9508 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9509 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9510   echo "$as_me:$LINENO: checking for $ac_header" >&5
9511 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9512 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9513   echo $ECHO_N "(cached) $ECHO_C" >&6
9514 fi
9515 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9516 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9517 else
9518   # Is the header compilable?
9519 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9520 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9521 cat >conftest.$ac_ext <<_ACEOF
9522 #line $LINENO "configure"
9523 #include "confdefs.h"
9524 $ac_includes_default
9525 #include <$ac_header>
9526 _ACEOF
9527 rm -f conftest.$ac_objext
9528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9529   (eval $ac_compile) 2>&5
9530   ac_status=$?
9531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9532   (exit $ac_status); } &&
9533          { ac_try='test -s conftest.$ac_objext'
9534   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9535   (eval $ac_try) 2>&5
9536   ac_status=$?
9537   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9538   (exit $ac_status); }; }; then
9539   ac_header_compiler=yes
9540 else
9541   echo "$as_me: failed program was:" >&5
9542 cat conftest.$ac_ext >&5
9543 ac_header_compiler=no
9544 fi
9545 rm -f conftest.$ac_objext conftest.$ac_ext
9546 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9547 echo "${ECHO_T}$ac_header_compiler" >&6
9548
9549 # Is the header present?
9550 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9551 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9552 cat >conftest.$ac_ext <<_ACEOF
9553 #line $LINENO "configure"
9554 #include "confdefs.h"
9555 #include <$ac_header>
9556 _ACEOF
9557 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9558   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9559   ac_status=$?
9560   egrep -v '^ *\+' conftest.er1 >conftest.err
9561   rm -f conftest.er1
9562   cat conftest.err >&5
9563   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9564   (exit $ac_status); } >/dev/null; then
9565   if test -s conftest.err; then
9566     ac_cpp_err=$ac_c_preproc_warn_flag
9567   else
9568     ac_cpp_err=
9569   fi
9570 else
9571   ac_cpp_err=yes
9572 fi
9573 if test -z "$ac_cpp_err"; then
9574   ac_header_preproc=yes
9575 else
9576   echo "$as_me: failed program was:" >&5
9577   cat conftest.$ac_ext >&5
9578   ac_header_preproc=no
9579 fi
9580 rm -f conftest.err conftest.$ac_ext
9581 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9582 echo "${ECHO_T}$ac_header_preproc" >&6
9583
9584 # So?  What about this header?
9585 case $ac_header_compiler:$ac_header_preproc in
9586   yes:no )
9587     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9588 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9589     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9590 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
9591   no:yes )
9592     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9593 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9594     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
9595 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
9596     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9597 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
9598 esac
9599 echo "$as_me:$LINENO: checking for $ac_header" >&5
9600 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9601 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9602   echo $ECHO_N "(cached) $ECHO_C" >&6
9603 else
9604   eval "$as_ac_Header=$ac_header_preproc"
9605 fi
9606 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9607 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9608
9609 fi
9610 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9611   cat >>confdefs.h <<_ACEOF
9612 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9613 _ACEOF
9614
9615 else
9616
9617 for ac_header in pam/pam_appl.h
9618 do
9619 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9620 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9621   echo "$as_me:$LINENO: checking for $ac_header" >&5
9622 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9623 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9624   echo $ECHO_N "(cached) $ECHO_C" >&6
9625 fi
9626 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9627 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9628 else
9629   # Is the header compilable?
9630 echo "$as_me:$LINENO: checking $ac_header usability" >&5
9631 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
9632 cat >conftest.$ac_ext <<_ACEOF
9633 #line $LINENO "configure"
9634 #include "confdefs.h"
9635 $ac_includes_default
9636 #include <$ac_header>
9637 _ACEOF
9638 rm -f conftest.$ac_objext
9639 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9640   (eval $ac_compile) 2>&5
9641   ac_status=$?
9642   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9643   (exit $ac_status); } &&
9644          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
9650   ac_header_compiler=yes
9651 else
9652   echo "$as_me: failed program was:" >&5
9653 cat conftest.$ac_ext >&5
9654 ac_header_compiler=no
9655 fi
9656 rm -f conftest.$ac_objext conftest.$ac_ext
9657 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9658 echo "${ECHO_T}$ac_header_compiler" >&6
9659
9660 # Is the header present?
9661 echo "$as_me:$LINENO: checking $ac_header presence" >&5
9662 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
9663 cat >conftest.$ac_ext <<_ACEOF
9664 #line $LINENO "configure"
9665 #include "confdefs.h"
9666 #include <$ac_header>
9667 _ACEOF
9668 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9669   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9670   ac_status=$?
9671   egrep -v '^ *\+' conftest.er1 >conftest.err
9672   rm -f conftest.er1
9673   cat conftest.err >&5
9674   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9675   (exit $ac_status); } >/dev/null; then
9676   if test -s conftest.err; then
9677     ac_cpp_err=$ac_c_preproc_warn_flag
9678   else
9679     ac_cpp_err=
9680   fi
9681 else
9682   ac_cpp_err=yes
9683 fi
9684 if test -z "$ac_cpp_err"; then
9685   ac_header_preproc=yes
9686 else
9687   echo "$as_me: failed program was:" >&5
9688   cat conftest.$ac_ext >&5
9689   ac_header_preproc=no
9690 fi
9691 rm -f conftest.err conftest.$ac_ext
9692 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9693 echo "${ECHO_T}$ac_header_preproc" >&6
9694
9695 # So?  What about this header?
9696 case $ac_header_compiler:$ac_header_preproc in
9697   yes:no )
9698     { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9699 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9700     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9701 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
9702   no:yes )
9703     { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9704 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9705     { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
9706 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
9707     { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9708 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;};;
9709 esac
9710 echo "$as_me:$LINENO: checking for $ac_header" >&5
9711 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
9712 if eval "test \"\${$as_ac_Header+set}\" = set"; then
9713   echo $ECHO_N "(cached) $ECHO_C" >&6
9714 else
9715   eval "$as_ac_Header=$ac_header_preproc"
9716 fi
9717 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
9718 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
9719
9720 fi
9721 if test `eval echo '${'$as_ac_Header'}'` = yes; then
9722   cat >>confdefs.h <<_ACEOF
9723 #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9724 _ACEOF
9725
9726 else
9727   { { echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
9728 echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
9729    { (exit 1); exit 1; }; }
9730 fi
9731
9732 done
9733
9734 fi
9735
9736 done
9737
9738 fi
9739
9740 if test "$with_rendezvous" = yes ; then
9741   if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
9742   echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
9743 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
9744 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
9745   echo $ECHO_N "(cached) $ECHO_C" >&6
9746 fi
9747 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
9748 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
9749 else
9750   # Is the header compilable?
9751 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h usability" >&5
9752 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h usability... $ECHO_C" >&6
9753 cat >conftest.$ac_ext <<_ACEOF
9754 #line $LINENO "configure"
9755 #include "confdefs.h"
9756 $ac_includes_default
9757 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
9758 _ACEOF
9759 rm -f conftest.$ac_objext
9760 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9761   (eval $ac_compile) 2>&5
9762   ac_status=$?
9763   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9764   (exit $ac_status); } &&
9765          { ac_try='test -s conftest.$ac_objext'
9766   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9767   (eval $ac_try) 2>&5
9768   ac_status=$?
9769   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9770   (exit $ac_status); }; }; then
9771   ac_header_compiler=yes
9772 else
9773   echo "$as_me: failed program was:" >&5
9774 cat conftest.$ac_ext >&5
9775 ac_header_compiler=no
9776 fi
9777 rm -f conftest.$ac_objext conftest.$ac_ext
9778 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9779 echo "${ECHO_T}$ac_header_compiler" >&6
9780
9781 # Is the header present?
9782 echo "$as_me:$LINENO: checking DNSServiceDiscovery/DNSServiceDiscovery.h presence" >&5
9783 echo $ECHO_N "checking DNSServiceDiscovery/DNSServiceDiscovery.h presence... $ECHO_C" >&6
9784 cat >conftest.$ac_ext <<_ACEOF
9785 #line $LINENO "configure"
9786 #include "confdefs.h"
9787 #include <DNSServiceDiscovery/DNSServiceDiscovery.h>
9788 _ACEOF
9789 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
9790   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
9791   ac_status=$?
9792   egrep -v '^ *\+' conftest.er1 >conftest.err
9793   rm -f conftest.er1
9794   cat conftest.err >&5
9795   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9796   (exit $ac_status); } >/dev/null; then
9797   if test -s conftest.err; then
9798     ac_cpp_err=$ac_c_preproc_warn_flag
9799   else
9800     ac_cpp_err=
9801   fi
9802 else
9803   ac_cpp_err=yes
9804 fi
9805 if test -z "$ac_cpp_err"; then
9806   ac_header_preproc=yes
9807 else
9808   echo "$as_me: failed program was:" >&5
9809   cat conftest.$ac_ext >&5
9810   ac_header_preproc=no
9811 fi
9812 rm -f conftest.err conftest.$ac_ext
9813 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9814 echo "${ECHO_T}$ac_header_preproc" >&6
9815
9816 # So?  What about this header?
9817 case $ac_header_compiler:$ac_header_preproc in
9818   yes:no )
9819     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&5
9820 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
9821     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
9822 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;};;
9823   no:yes )
9824     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&5
9825 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: present but cannot be compiled" >&2;}
9826     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: check for missing prerequisite headers?" >&5
9827 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: check for missing prerequisite headers?" >&2;}
9828     { echo "$as_me:$LINENO: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&5
9829 echo "$as_me: WARNING: DNSServiceDiscovery/DNSServiceDiscovery.h: proceeding with the preprocessor's result" >&2;};;
9830 esac
9831 echo "$as_me:$LINENO: checking for DNSServiceDiscovery/DNSServiceDiscovery.h" >&5
9832 echo $ECHO_N "checking for DNSServiceDiscovery/DNSServiceDiscovery.h... $ECHO_C" >&6
9833 if test "${ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h+set}" = set; then
9834   echo $ECHO_N "(cached) $ECHO_C" >&6
9835 else
9836   ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h=$ac_header_preproc
9837 fi
9838 echo "$as_me:$LINENO: result: $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&5
9839 echo "${ECHO_T}$ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h" >&6
9840
9841 fi
9842 if test $ac_cv_header_DNSServiceDiscovery_DNSServiceDiscovery_h = yes; then
9843   :
9844 else
9845   { { echo "$as_me:$LINENO: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Rendezvous" >&5
9846 echo "$as_me: error: header file <DNSServiceDiscovery/DNSServiceDiscovery.h> is required for Rendezvous" >&2;}
9847    { (exit 1); exit 1; }; }
9848 fi
9849
9850
9851 fi
9852
9853
9854 ##
9855 ## Types, structures, compiler characteristics
9856 ##
9857
9858
9859 echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
9860 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
9861 if test "${ac_cv_c_const+set}" = set; then
9862   echo $ECHO_N "(cached) $ECHO_C" >&6
9863 else
9864   cat >conftest.$ac_ext <<_ACEOF
9865 #line $LINENO "configure"
9866 #include "confdefs.h"
9867
9868 #ifdef F77_DUMMY_MAIN
9869 #  ifdef __cplusplus
9870      extern "C"
9871 #  endif
9872    int F77_DUMMY_MAIN() { return 1; }
9873 #endif
9874 int
9875 main ()
9876 {
9877 /* FIXME: Include the comments suggested by Paul. */
9878 #ifndef __cplusplus
9879   /* Ultrix mips cc rejects this.  */
9880   typedef int charset[2];
9881   const charset x;
9882   /* SunOS 4.1.1 cc rejects this.  */
9883   char const *const *ccp;
9884   char **p;
9885   /* NEC SVR4.0.2 mips cc rejects this.  */
9886   struct point {int x, y;};
9887   static struct point const zero = {0,0};
9888   /* AIX XL C 1.02.0.0 rejects this.
9889      It does not let you subtract one const X* pointer from another in
9890      an arm of an if-expression whose if-part is not a constant
9891      expression */
9892   const char *g = "string";
9893   ccp = &g + (g ? g-g : 0);
9894   /* HPUX 7.0 cc rejects these. */
9895   ++ccp;
9896   p = (char**) ccp;
9897   ccp = (char const *const *) p;
9898   { /* SCO 3.2v4 cc rejects this.  */
9899     char *t;
9900     char const *s = 0 ? (char *) 0 : (char const *) 0;
9901
9902     *t++ = 0;
9903   }
9904   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
9905     int x[] = {25, 17};
9906     const int *foo = &x[0];
9907     ++foo;
9908   }
9909   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
9910     typedef const int *iptr;
9911     iptr p = 0;
9912     ++p;
9913   }
9914   { /* AIX XL C 1.02.0.0 rejects this saying
9915        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
9916     struct s { int j; const int *ap[3]; };
9917     struct s *b; b->j = 5;
9918   }
9919   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
9920     const int foo = 10;
9921   }
9922 #endif
9923
9924   ;
9925   return 0;
9926 }
9927 _ACEOF
9928 rm -f conftest.$ac_objext
9929 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9930   (eval $ac_compile) 2>&5
9931   ac_status=$?
9932   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9933   (exit $ac_status); } &&
9934          { ac_try='test -s conftest.$ac_objext'
9935   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9936   (eval $ac_try) 2>&5
9937   ac_status=$?
9938   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9939   (exit $ac_status); }; }; then
9940   ac_cv_c_const=yes
9941 else
9942   echo "$as_me: failed program was:" >&5
9943 cat conftest.$ac_ext >&5
9944 ac_cv_c_const=no
9945 fi
9946 rm -f conftest.$ac_objext conftest.$ac_ext
9947 fi
9948 echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
9949 echo "${ECHO_T}$ac_cv_c_const" >&6
9950 if test $ac_cv_c_const = no; then
9951
9952 cat >>confdefs.h <<\_ACEOF
9953 #define const
9954 _ACEOF
9955
9956 fi
9957
9958 echo "$as_me:$LINENO: checking for inline" >&5
9959 echo $ECHO_N "checking for inline... $ECHO_C" >&6
9960 if test "${ac_cv_c_inline+set}" = set; then
9961   echo $ECHO_N "(cached) $ECHO_C" >&6
9962 else
9963   ac_cv_c_inline=no
9964 for ac_kw in inline __inline__ __inline; do
9965   cat >conftest.$ac_ext <<_ACEOF
9966 #line $LINENO "configure"
9967 #include "confdefs.h"
9968 #ifndef __cplusplus
9969 typedef int foo_t;
9970 static $ac_kw foo_t static_foo () {return 0; }
9971 $ac_kw int foo () {return 0; }
9972 #endif
9973
9974 _ACEOF
9975 rm -f conftest.$ac_objext
9976 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
9977   (eval $ac_compile) 2>&5
9978   ac_status=$?
9979   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9980   (exit $ac_status); } &&
9981          { ac_try='test -s conftest.$ac_objext'
9982   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
9983   (eval $ac_try) 2>&5
9984   ac_status=$?
9985   echo "$as_me:$LINENO: \$? = $ac_status" >&5
9986   (exit $ac_status); }; }; then
9987   ac_cv_c_inline=$ac_kw; break
9988 else
9989   echo "$as_me: failed program was:" >&5
9990 cat conftest.$ac_ext >&5
9991 fi
9992 rm -f conftest.$ac_objext conftest.$ac_ext
9993 done
9994
9995 fi
9996 echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
9997 echo "${ECHO_T}$ac_cv_c_inline" >&6
9998 case $ac_cv_c_inline in
9999   inline | yes) ;;
10000   no)
10001 cat >>confdefs.h <<\_ACEOF
10002 #define inline
10003 _ACEOF
10004  ;;
10005   *)  cat >>confdefs.h <<_ACEOF
10006 #define inline $ac_cv_c_inline
10007 _ACEOF
10008  ;;
10009 esac
10010
10011 echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
10012 echo $ECHO_N "checking for preprocessor stringizing operator... $ECHO_C" >&6
10013 if test "${ac_cv_c_stringize+set}" = set; then
10014   echo $ECHO_N "(cached) $ECHO_C" >&6
10015 else
10016   cat >conftest.$ac_ext <<_ACEOF
10017 #line $LINENO "configure"
10018 #include "confdefs.h"
10019 #define x(y) #y
10020
10021 char *s = x(teststring);
10022 _ACEOF
10023 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
10024   egrep "#teststring" >/dev/null 2>&1; then
10025   ac_cv_c_stringize=no
10026 else
10027   ac_cv_c_stringize=yes
10028 fi
10029 rm -f conftest*
10030
10031 fi
10032 echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
10033 echo "${ECHO_T}$ac_cv_c_stringize" >&6
10034 if test $ac_cv_c_stringize = yes; then
10035
10036 cat >>confdefs.h <<\_ACEOF
10037 #define HAVE_STRINGIZE 1
10038 _ACEOF
10039
10040 fi
10041
10042 echo "$as_me:$LINENO: checking for signed types" >&5
10043 echo $ECHO_N "checking for signed types... $ECHO_C" >&6
10044 if test "${pgac_cv_c_signed+set}" = set; then
10045   echo $ECHO_N "(cached) $ECHO_C" >&6
10046 else
10047   cat >conftest.$ac_ext <<_ACEOF
10048 #line $LINENO "configure"
10049 #include "confdefs.h"
10050
10051 #ifdef F77_DUMMY_MAIN
10052 #  ifdef __cplusplus
10053      extern "C"
10054 #  endif
10055    int F77_DUMMY_MAIN() { return 1; }
10056 #endif
10057 int
10058 main ()
10059 {
10060 signed char c; signed short s; signed int i;
10061   ;
10062   return 0;
10063 }
10064 _ACEOF
10065 rm -f conftest.$ac_objext
10066 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10067   (eval $ac_compile) 2>&5
10068   ac_status=$?
10069   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10070   (exit $ac_status); } &&
10071          { ac_try='test -s conftest.$ac_objext'
10072   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10073   (eval $ac_try) 2>&5
10074   ac_status=$?
10075   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10076   (exit $ac_status); }; }; then
10077   pgac_cv_c_signed=yes
10078 else
10079   echo "$as_me: failed program was:" >&5
10080 cat conftest.$ac_ext >&5
10081 pgac_cv_c_signed=no
10082 fi
10083 rm -f conftest.$ac_objext conftest.$ac_ext
10084 fi
10085 echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
10086 echo "${ECHO_T}$pgac_cv_c_signed" >&6
10087 if test x"$pgac_cv_c_signed" = xno ; then
10088
10089 cat >>confdefs.h <<\_ACEOF
10090 #define signed
10091 _ACEOF
10092
10093 fi
10094 echo "$as_me:$LINENO: checking for working volatile" >&5
10095 echo $ECHO_N "checking for working volatile... $ECHO_C" >&6
10096 if test "${ac_cv_c_volatile+set}" = set; then
10097   echo $ECHO_N "(cached) $ECHO_C" >&6
10098 else
10099   cat >conftest.$ac_ext <<_ACEOF
10100 #line $LINENO "configure"
10101 #include "confdefs.h"
10102
10103 #ifdef F77_DUMMY_MAIN
10104 #  ifdef __cplusplus
10105      extern "C"
10106 #  endif
10107    int F77_DUMMY_MAIN() { return 1; }
10108 #endif
10109 int
10110 main ()
10111 {
10112
10113 volatile int x;
10114 int * volatile y;
10115   ;
10116   return 0;
10117 }
10118 _ACEOF
10119 rm -f conftest.$ac_objext
10120 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10121   (eval $ac_compile) 2>&5
10122   ac_status=$?
10123   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10124   (exit $ac_status); } &&
10125          { ac_try='test -s conftest.$ac_objext'
10126   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10127   (eval $ac_try) 2>&5
10128   ac_status=$?
10129   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10130   (exit $ac_status); }; }; then
10131   ac_cv_c_volatile=yes
10132 else
10133   echo "$as_me: failed program was:" >&5
10134 cat conftest.$ac_ext >&5
10135 ac_cv_c_volatile=no
10136 fi
10137 rm -f conftest.$ac_objext conftest.$ac_ext
10138 fi
10139 echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
10140 echo "${ECHO_T}$ac_cv_c_volatile" >&6
10141 if test $ac_cv_c_volatile = no; then
10142
10143 cat >>confdefs.h <<\_ACEOF
10144 #define volatile
10145 _ACEOF
10146
10147 fi
10148
10149 echo "$as_me:$LINENO: checking for __func__" >&5
10150 echo $ECHO_N "checking for __func__... $ECHO_C" >&6
10151 if test "${pgac_cv_funcname_func_support+set}" = set; then
10152   echo $ECHO_N "(cached) $ECHO_C" >&6
10153 else
10154   cat >conftest.$ac_ext <<_ACEOF
10155 #line $LINENO "configure"
10156 #include "confdefs.h"
10157 #include <stdio.h>
10158 #ifdef F77_DUMMY_MAIN
10159 #  ifdef __cplusplus
10160      extern "C"
10161 #  endif
10162    int F77_DUMMY_MAIN() { return 1; }
10163 #endif
10164 int
10165 main ()
10166 {
10167 printf("%s\n", __func__);
10168   ;
10169   return 0;
10170 }
10171 _ACEOF
10172 rm -f conftest.$ac_objext
10173 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10174   (eval $ac_compile) 2>&5
10175   ac_status=$?
10176   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10177   (exit $ac_status); } &&
10178          { ac_try='test -s conftest.$ac_objext'
10179   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10180   (eval $ac_try) 2>&5
10181   ac_status=$?
10182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10183   (exit $ac_status); }; }; then
10184   pgac_cv_funcname_func_support=yes
10185 else
10186   echo "$as_me: failed program was:" >&5
10187 cat conftest.$ac_ext >&5
10188 pgac_cv_funcname_func_support=no
10189 fi
10190 rm -f conftest.$ac_objext conftest.$ac_ext
10191 fi
10192 echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
10193 echo "${ECHO_T}$pgac_cv_funcname_func_support" >&6
10194 if test x"$pgac_cv_funcname_func_support" = xyes ; then
10195
10196 cat >>confdefs.h <<\_ACEOF
10197 #define HAVE_FUNCNAME__FUNC 1
10198 _ACEOF
10199
10200 else
10201 echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
10202 echo $ECHO_N "checking for __FUNCTION__... $ECHO_C" >&6
10203 if test "${pgac_cv_funcname_function_support+set}" = set; then
10204   echo $ECHO_N "(cached) $ECHO_C" >&6
10205 else
10206   cat >conftest.$ac_ext <<_ACEOF
10207 #line $LINENO "configure"
10208 #include "confdefs.h"
10209 #include <stdio.h>
10210 #ifdef F77_DUMMY_MAIN
10211 #  ifdef __cplusplus
10212      extern "C"
10213 #  endif
10214    int F77_DUMMY_MAIN() { return 1; }
10215 #endif
10216 int
10217 main ()
10218 {
10219 printf("%s\n", __FUNCTION__);
10220   ;
10221   return 0;
10222 }
10223 _ACEOF
10224 rm -f conftest.$ac_objext
10225 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10226   (eval $ac_compile) 2>&5
10227   ac_status=$?
10228   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10229   (exit $ac_status); } &&
10230          { ac_try='test -s conftest.$ac_objext'
10231   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10232   (eval $ac_try) 2>&5
10233   ac_status=$?
10234   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10235   (exit $ac_status); }; }; then
10236   pgac_cv_funcname_function_support=yes
10237 else
10238   echo "$as_me: failed program was:" >&5
10239 cat conftest.$ac_ext >&5
10240 pgac_cv_funcname_function_support=no
10241 fi
10242 rm -f conftest.$ac_objext conftest.$ac_ext
10243 fi
10244 echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
10245 echo "${ECHO_T}$pgac_cv_funcname_function_support" >&6
10246 if test x"$pgac_cv_funcname_function_support" = xyes ; then
10247
10248 cat >>confdefs.h <<\_ACEOF
10249 #define HAVE_FUNCNAME__FUNCTION 1
10250 _ACEOF
10251
10252 fi
10253 fi
10254 echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
10255 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6
10256 if test "${ac_cv_struct_tm+set}" = set; then
10257   echo $ECHO_N "(cached) $ECHO_C" >&6
10258 else
10259   cat >conftest.$ac_ext <<_ACEOF
10260 #line $LINENO "configure"
10261 #include "confdefs.h"
10262 #include <sys/types.h>
10263 #include <time.h>
10264
10265 #ifdef F77_DUMMY_MAIN
10266 #  ifdef __cplusplus
10267      extern "C"
10268 #  endif
10269    int F77_DUMMY_MAIN() { return 1; }
10270 #endif
10271 int
10272 main ()
10273 {
10274 struct tm *tp; tp->tm_sec;
10275   ;
10276   return 0;
10277 }
10278 _ACEOF
10279 rm -f conftest.$ac_objext
10280 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10281   (eval $ac_compile) 2>&5
10282   ac_status=$?
10283   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10284   (exit $ac_status); } &&
10285          { ac_try='test -s conftest.$ac_objext'
10286   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10287   (eval $ac_try) 2>&5
10288   ac_status=$?
10289   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10290   (exit $ac_status); }; }; then
10291   ac_cv_struct_tm=time.h
10292 else
10293   echo "$as_me: failed program was:" >&5
10294 cat conftest.$ac_ext >&5
10295 ac_cv_struct_tm=sys/time.h
10296 fi
10297 rm -f conftest.$ac_objext conftest.$ac_ext
10298 fi
10299 echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
10300 echo "${ECHO_T}$ac_cv_struct_tm" >&6
10301 if test $ac_cv_struct_tm = sys/time.h; then
10302
10303 cat >>confdefs.h <<\_ACEOF
10304 #define TM_IN_SYS_TIME 1
10305 _ACEOF
10306
10307 fi
10308
10309 echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
10310 echo $ECHO_N "checking for struct tm.tm_zone... $ECHO_C" >&6
10311 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
10312   echo $ECHO_N "(cached) $ECHO_C" >&6
10313 else
10314   cat >conftest.$ac_ext <<_ACEOF
10315 #line $LINENO "configure"
10316 #include "confdefs.h"
10317 #include <sys/types.h>
10318 #include <$ac_cv_struct_tm>
10319
10320
10321 #ifdef F77_DUMMY_MAIN
10322 #  ifdef __cplusplus
10323      extern "C"
10324 #  endif
10325    int F77_DUMMY_MAIN() { return 1; }
10326 #endif
10327 int
10328 main ()
10329 {
10330 static struct tm ac_aggr;
10331 if (ac_aggr.tm_zone)
10332 return 0;
10333   ;
10334   return 0;
10335 }
10336 _ACEOF
10337 rm -f conftest.$ac_objext
10338 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10339   (eval $ac_compile) 2>&5
10340   ac_status=$?
10341   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10342   (exit $ac_status); } &&
10343          { ac_try='test -s conftest.$ac_objext'
10344   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10345   (eval $ac_try) 2>&5
10346   ac_status=$?
10347   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10348   (exit $ac_status); }; }; then
10349   ac_cv_member_struct_tm_tm_zone=yes
10350 else
10351   echo "$as_me: failed program was:" >&5
10352 cat conftest.$ac_ext >&5
10353 ac_cv_member_struct_tm_tm_zone=no
10354 fi
10355 rm -f conftest.$ac_objext conftest.$ac_ext
10356 fi
10357 echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
10358 echo "${ECHO_T}$ac_cv_member_struct_tm_tm_zone" >&6
10359 if test $ac_cv_member_struct_tm_tm_zone = yes; then
10360
10361 cat >>confdefs.h <<_ACEOF
10362 #define HAVE_STRUCT_TM_TM_ZONE 1
10363 _ACEOF
10364
10365
10366 fi
10367
10368 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
10369
10370 cat >>confdefs.h <<\_ACEOF
10371 #define HAVE_TM_ZONE 1
10372 _ACEOF
10373
10374 fi
10375 echo "$as_me:$LINENO: checking for tzname" >&5
10376 echo $ECHO_N "checking for tzname... $ECHO_C" >&6
10377 if test "${ac_cv_var_tzname+set}" = set; then
10378   echo $ECHO_N "(cached) $ECHO_C" >&6
10379 else
10380   cat >conftest.$ac_ext <<_ACEOF
10381 #line $LINENO "configure"
10382 #include "confdefs.h"
10383 #include <time.h>
10384 #ifndef tzname /* For SGI.  */
10385 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
10386 #endif
10387
10388 #ifdef F77_DUMMY_MAIN
10389 #  ifdef __cplusplus
10390      extern "C"
10391 #  endif
10392    int F77_DUMMY_MAIN() { return 1; }
10393 #endif
10394 int
10395 main ()
10396 {
10397 atoi(*tzname);
10398   ;
10399   return 0;
10400 }
10401 _ACEOF
10402 rm -f conftest.$ac_objext conftest$ac_exeext
10403 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10404   (eval $ac_link) 2>&5
10405   ac_status=$?
10406   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10407   (exit $ac_status); } &&
10408          { ac_try='test -s conftest$ac_exeext'
10409   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10410   (eval $ac_try) 2>&5
10411   ac_status=$?
10412   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10413   (exit $ac_status); }; }; then
10414   ac_cv_var_tzname=yes
10415 else
10416   echo "$as_me: failed program was:" >&5
10417 cat conftest.$ac_ext >&5
10418 ac_cv_var_tzname=no
10419 fi
10420 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
10421 fi
10422 echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
10423 echo "${ECHO_T}$ac_cv_var_tzname" >&6
10424 if test $ac_cv_var_tzname = yes; then
10425
10426 cat >>confdefs.h <<\_ACEOF
10427 #define HAVE_TZNAME 1
10428 _ACEOF
10429
10430 fi
10431
10432 echo "$as_me:$LINENO: checking for union semun" >&5
10433 echo $ECHO_N "checking for union semun... $ECHO_C" >&6
10434 if test "${ac_cv_type_union_semun+set}" = set; then
10435   echo $ECHO_N "(cached) $ECHO_C" >&6
10436 else
10437   cat >conftest.$ac_ext <<_ACEOF
10438 #line $LINENO "configure"
10439 #include "confdefs.h"
10440 #include <sys/types.h>
10441 #include <sys/ipc.h>
10442 #include <sys/sem.h>
10443
10444 #ifdef F77_DUMMY_MAIN
10445 #  ifdef __cplusplus
10446      extern "C"
10447 #  endif
10448    int F77_DUMMY_MAIN() { return 1; }
10449 #endif
10450 int
10451 main ()
10452 {
10453 if ((union semun *) 0)
10454   return 0;
10455 if (sizeof (union semun))
10456   return 0;
10457   ;
10458   return 0;
10459 }
10460 _ACEOF
10461 rm -f conftest.$ac_objext
10462 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10463   (eval $ac_compile) 2>&5
10464   ac_status=$?
10465   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10466   (exit $ac_status); } &&
10467          { ac_try='test -s conftest.$ac_objext'
10468   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10469   (eval $ac_try) 2>&5
10470   ac_status=$?
10471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10472   (exit $ac_status); }; }; then
10473   ac_cv_type_union_semun=yes
10474 else
10475   echo "$as_me: failed program was:" >&5
10476 cat conftest.$ac_ext >&5
10477 ac_cv_type_union_semun=no
10478 fi
10479 rm -f conftest.$ac_objext conftest.$ac_ext
10480 fi
10481 echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
10482 echo "${ECHO_T}$ac_cv_type_union_semun" >&6
10483 if test $ac_cv_type_union_semun = yes; then
10484
10485 cat >>confdefs.h <<_ACEOF
10486 #define HAVE_UNION_SEMUN 1
10487 _ACEOF
10488
10489
10490 fi
10491
10492 echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
10493 echo $ECHO_N "checking for struct sockaddr_un... $ECHO_C" >&6
10494 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
10495   echo $ECHO_N "(cached) $ECHO_C" >&6
10496 else
10497   cat >conftest.$ac_ext <<_ACEOF
10498 #line $LINENO "configure"
10499 #include "confdefs.h"
10500 #include <sys/types.h>
10501 #ifdef HAVE_SYS_UN_H
10502 #include <sys/un.h>
10503 #endif
10504
10505
10506 #ifdef F77_DUMMY_MAIN
10507 #  ifdef __cplusplus
10508      extern "C"
10509 #  endif
10510    int F77_DUMMY_MAIN() { return 1; }
10511 #endif
10512 int
10513 main ()
10514 {
10515 if ((struct sockaddr_un *) 0)
10516   return 0;
10517 if (sizeof (struct sockaddr_un))
10518   return 0;
10519   ;
10520   return 0;
10521 }
10522 _ACEOF
10523 rm -f conftest.$ac_objext
10524 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10525   (eval $ac_compile) 2>&5
10526   ac_status=$?
10527   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10528   (exit $ac_status); } &&
10529          { ac_try='test -s conftest.$ac_objext'
10530   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10531   (eval $ac_try) 2>&5
10532   ac_status=$?
10533   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10534   (exit $ac_status); }; }; then
10535   ac_cv_type_struct_sockaddr_un=yes
10536 else
10537   echo "$as_me: failed program was:" >&5
10538 cat conftest.$ac_ext >&5
10539 ac_cv_type_struct_sockaddr_un=no
10540 fi
10541 rm -f conftest.$ac_objext conftest.$ac_ext
10542 fi
10543 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
10544 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_un" >&6
10545 if test $ac_cv_type_struct_sockaddr_un = yes; then
10546
10547 cat >>confdefs.h <<_ACEOF
10548 #define HAVE_STRUCT_SOCKADDR_UN 1
10549 _ACEOF
10550
10551
10552 cat >>confdefs.h <<\_ACEOF
10553 #define HAVE_UNIX_SOCKETS 1
10554 _ACEOF
10555
10556 fi
10557
10558 echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
10559 echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6
10560 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
10561   echo $ECHO_N "(cached) $ECHO_C" >&6
10562 else
10563   cat >conftest.$ac_ext <<_ACEOF
10564 #line $LINENO "configure"
10565 #include "confdefs.h"
10566 #include <sys/types.h>
10567 #ifdef HAVE_SYS_SOCKET_H
10568 #include <sys/socket.h>
10569 #endif
10570
10571
10572 #ifdef F77_DUMMY_MAIN
10573 #  ifdef __cplusplus
10574      extern "C"
10575 #  endif
10576    int F77_DUMMY_MAIN() { return 1; }
10577 #endif
10578 int
10579 main ()
10580 {
10581 if ((struct sockaddr_storage *) 0)
10582   return 0;
10583 if (sizeof (struct sockaddr_storage))
10584   return 0;
10585   ;
10586   return 0;
10587 }
10588 _ACEOF
10589 rm -f conftest.$ac_objext
10590 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10591   (eval $ac_compile) 2>&5
10592   ac_status=$?
10593   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10594   (exit $ac_status); } &&
10595          { ac_try='test -s conftest.$ac_objext'
10596   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10597   (eval $ac_try) 2>&5
10598   ac_status=$?
10599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10600   (exit $ac_status); }; }; then
10601   ac_cv_type_struct_sockaddr_storage=yes
10602 else
10603   echo "$as_me: failed program was:" >&5
10604 cat conftest.$ac_ext >&5
10605 ac_cv_type_struct_sockaddr_storage=no
10606 fi
10607 rm -f conftest.$ac_objext conftest.$ac_ext
10608 fi
10609 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
10610 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_storage" >&6
10611 if test $ac_cv_type_struct_sockaddr_storage = yes; then
10612
10613 cat >>confdefs.h <<_ACEOF
10614 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
10615 _ACEOF
10616
10617
10618 fi
10619
10620 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
10621 echo $ECHO_N "checking for struct sockaddr_storage.ss_family... $ECHO_C" >&6
10622 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
10623   echo $ECHO_N "(cached) $ECHO_C" >&6
10624 else
10625   cat >conftest.$ac_ext <<_ACEOF
10626 #line $LINENO "configure"
10627 #include "confdefs.h"
10628 #include <sys/types.h>
10629 #ifdef HAVE_SYS_SOCKET_H
10630 #include <sys/socket.h>
10631 #endif
10632
10633
10634 #ifdef F77_DUMMY_MAIN
10635 #  ifdef __cplusplus
10636      extern "C"
10637 #  endif
10638    int F77_DUMMY_MAIN() { return 1; }
10639 #endif
10640 int
10641 main ()
10642 {
10643 static struct sockaddr_storage ac_aggr;
10644 if (ac_aggr.ss_family)
10645 return 0;
10646   ;
10647   return 0;
10648 }
10649 _ACEOF
10650 rm -f conftest.$ac_objext
10651 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10652   (eval $ac_compile) 2>&5
10653   ac_status=$?
10654   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10655   (exit $ac_status); } &&
10656          { ac_try='test -s conftest.$ac_objext'
10657   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10658   (eval $ac_try) 2>&5
10659   ac_status=$?
10660   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10661   (exit $ac_status); }; }; then
10662   ac_cv_member_struct_sockaddr_storage_ss_family=yes
10663 else
10664   echo "$as_me: failed program was:" >&5
10665 cat conftest.$ac_ext >&5
10666 ac_cv_member_struct_sockaddr_storage_ss_family=no
10667 fi
10668 rm -f conftest.$ac_objext conftest.$ac_ext
10669 fi
10670 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
10671 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_family" >&6
10672 if test $ac_cv_member_struct_sockaddr_storage_ss_family = yes; then
10673
10674 cat >>confdefs.h <<_ACEOF
10675 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
10676 _ACEOF
10677
10678
10679 fi
10680 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
10681 echo $ECHO_N "checking for struct sockaddr_storage.__ss_family... $ECHO_C" >&6
10682 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
10683   echo $ECHO_N "(cached) $ECHO_C" >&6
10684 else
10685   cat >conftest.$ac_ext <<_ACEOF
10686 #line $LINENO "configure"
10687 #include "confdefs.h"
10688 #include <sys/types.h>
10689 #ifdef HAVE_SYS_SOCKET_H
10690 #include <sys/socket.h>
10691 #endif
10692
10693
10694 #ifdef F77_DUMMY_MAIN
10695 #  ifdef __cplusplus
10696      extern "C"
10697 #  endif
10698    int F77_DUMMY_MAIN() { return 1; }
10699 #endif
10700 int
10701 main ()
10702 {
10703 static struct sockaddr_storage ac_aggr;
10704 if (ac_aggr.__ss_family)
10705 return 0;
10706   ;
10707   return 0;
10708 }
10709 _ACEOF
10710 rm -f conftest.$ac_objext
10711 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10712   (eval $ac_compile) 2>&5
10713   ac_status=$?
10714   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10715   (exit $ac_status); } &&
10716          { ac_try='test -s conftest.$ac_objext'
10717   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10718   (eval $ac_try) 2>&5
10719   ac_status=$?
10720   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10721   (exit $ac_status); }; }; then
10722   ac_cv_member_struct_sockaddr_storage___ss_family=yes
10723 else
10724   echo "$as_me: failed program was:" >&5
10725 cat conftest.$ac_ext >&5
10726 ac_cv_member_struct_sockaddr_storage___ss_family=no
10727 fi
10728 rm -f conftest.$ac_objext conftest.$ac_ext
10729 fi
10730 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
10731 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_family" >&6
10732 if test $ac_cv_member_struct_sockaddr_storage___ss_family = yes; then
10733
10734 cat >>confdefs.h <<_ACEOF
10735 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
10736 _ACEOF
10737
10738
10739 fi
10740 echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
10741 echo $ECHO_N "checking for struct sockaddr_storage.ss_len... $ECHO_C" >&6
10742 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
10743   echo $ECHO_N "(cached) $ECHO_C" >&6
10744 else
10745   cat >conftest.$ac_ext <<_ACEOF
10746 #line $LINENO "configure"
10747 #include "confdefs.h"
10748 #include <sys/types.h>
10749 #ifdef HAVE_SYS_SOCKET_H
10750 #include <sys/socket.h>
10751 #endif
10752
10753
10754 #ifdef F77_DUMMY_MAIN
10755 #  ifdef __cplusplus
10756      extern "C"
10757 #  endif
10758    int F77_DUMMY_MAIN() { return 1; }
10759 #endif
10760 int
10761 main ()
10762 {
10763 static struct sockaddr_storage ac_aggr;
10764 if (ac_aggr.ss_len)
10765 return 0;
10766   ;
10767   return 0;
10768 }
10769 _ACEOF
10770 rm -f conftest.$ac_objext
10771 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10772   (eval $ac_compile) 2>&5
10773   ac_status=$?
10774   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10775   (exit $ac_status); } &&
10776          { ac_try='test -s conftest.$ac_objext'
10777   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10778   (eval $ac_try) 2>&5
10779   ac_status=$?
10780   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10781   (exit $ac_status); }; }; then
10782   ac_cv_member_struct_sockaddr_storage_ss_len=yes
10783 else
10784   echo "$as_me: failed program was:" >&5
10785 cat conftest.$ac_ext >&5
10786 ac_cv_member_struct_sockaddr_storage_ss_len=no
10787 fi
10788 rm -f conftest.$ac_objext conftest.$ac_ext
10789 fi
10790 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
10791 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage_ss_len" >&6
10792 if test $ac_cv_member_struct_sockaddr_storage_ss_len = yes; then
10793
10794 cat >>confdefs.h <<_ACEOF
10795 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
10796 _ACEOF
10797
10798
10799 fi
10800 echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
10801 echo $ECHO_N "checking for struct sockaddr_storage.__ss_len... $ECHO_C" >&6
10802 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
10803   echo $ECHO_N "(cached) $ECHO_C" >&6
10804 else
10805   cat >conftest.$ac_ext <<_ACEOF
10806 #line $LINENO "configure"
10807 #include "confdefs.h"
10808 #include <sys/types.h>
10809 #ifdef HAVE_SYS_SOCKET_H
10810 #include <sys/socket.h>
10811 #endif
10812
10813
10814 #ifdef F77_DUMMY_MAIN
10815 #  ifdef __cplusplus
10816      extern "C"
10817 #  endif
10818    int F77_DUMMY_MAIN() { return 1; }
10819 #endif
10820 int
10821 main ()
10822 {
10823 static struct sockaddr_storage ac_aggr;
10824 if (ac_aggr.__ss_len)
10825 return 0;
10826   ;
10827   return 0;
10828 }
10829 _ACEOF
10830 rm -f conftest.$ac_objext
10831 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10832   (eval $ac_compile) 2>&5
10833   ac_status=$?
10834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10835   (exit $ac_status); } &&
10836          { ac_try='test -s conftest.$ac_objext'
10837   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10838   (eval $ac_try) 2>&5
10839   ac_status=$?
10840   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10841   (exit $ac_status); }; }; then
10842   ac_cv_member_struct_sockaddr_storage___ss_len=yes
10843 else
10844   echo "$as_me: failed program was:" >&5
10845 cat conftest.$ac_ext >&5
10846 ac_cv_member_struct_sockaddr_storage___ss_len=no
10847 fi
10848 rm -f conftest.$ac_objext conftest.$ac_ext
10849 fi
10850 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
10851 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_storage___ss_len" >&6
10852 if test $ac_cv_member_struct_sockaddr_storage___ss_len = yes; then
10853
10854 cat >>confdefs.h <<_ACEOF
10855 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
10856 _ACEOF
10857
10858
10859 fi
10860 echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
10861 echo $ECHO_N "checking for struct sockaddr.sa_len... $ECHO_C" >&6
10862 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
10863   echo $ECHO_N "(cached) $ECHO_C" >&6
10864 else
10865   cat >conftest.$ac_ext <<_ACEOF
10866 #line $LINENO "configure"
10867 #include "confdefs.h"
10868 #include <sys/types.h>
10869 #ifdef HAVE_SYS_SOCKET_H
10870 #include <sys/socket.h>
10871 #endif
10872
10873
10874 #ifdef F77_DUMMY_MAIN
10875 #  ifdef __cplusplus
10876      extern "C"
10877 #  endif
10878    int F77_DUMMY_MAIN() { return 1; }
10879 #endif
10880 int
10881 main ()
10882 {
10883 static struct sockaddr ac_aggr;
10884 if (ac_aggr.sa_len)
10885 return 0;
10886   ;
10887   return 0;
10888 }
10889 _ACEOF
10890 rm -f conftest.$ac_objext
10891 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10892   (eval $ac_compile) 2>&5
10893   ac_status=$?
10894   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10895   (exit $ac_status); } &&
10896          { ac_try='test -s conftest.$ac_objext'
10897   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10898   (eval $ac_try) 2>&5
10899   ac_status=$?
10900   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10901   (exit $ac_status); }; }; then
10902   ac_cv_member_struct_sockaddr_sa_len=yes
10903 else
10904   echo "$as_me: failed program was:" >&5
10905 cat conftest.$ac_ext >&5
10906 ac_cv_member_struct_sockaddr_sa_len=no
10907 fi
10908 rm -f conftest.$ac_objext conftest.$ac_ext
10909 fi
10910 echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
10911 echo "${ECHO_T}$ac_cv_member_struct_sockaddr_sa_len" >&6
10912 if test $ac_cv_member_struct_sockaddr_sa_len = yes; then
10913
10914 cat >>confdefs.h <<_ACEOF
10915 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
10916 _ACEOF
10917
10918
10919 fi
10920
10921 echo "$as_me:$LINENO: checking for struct addrinfo" >&5
10922 echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6
10923 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
10924   echo $ECHO_N "(cached) $ECHO_C" >&6
10925 else
10926   cat >conftest.$ac_ext <<_ACEOF
10927 #line $LINENO "configure"
10928 #include "confdefs.h"
10929 #include <sys/types.h>
10930 #include <sys/socket.h>
10931 #include <netdb.h>
10932
10933
10934 #ifdef F77_DUMMY_MAIN
10935 #  ifdef __cplusplus
10936      extern "C"
10937 #  endif
10938    int F77_DUMMY_MAIN() { return 1; }
10939 #endif
10940 int
10941 main ()
10942 {
10943 if ((struct addrinfo *) 0)
10944   return 0;
10945 if (sizeof (struct addrinfo))
10946   return 0;
10947   ;
10948   return 0;
10949 }
10950 _ACEOF
10951 rm -f conftest.$ac_objext
10952 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10953   (eval $ac_compile) 2>&5
10954   ac_status=$?
10955   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10956   (exit $ac_status); } &&
10957          { ac_try='test -s conftest.$ac_objext'
10958   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10959   (eval $ac_try) 2>&5
10960   ac_status=$?
10961   echo "$as_me:$LINENO: \$? = $ac_status" >&5
10962   (exit $ac_status); }; }; then
10963   ac_cv_type_struct_addrinfo=yes
10964 else
10965   echo "$as_me: failed program was:" >&5
10966 cat conftest.$ac_ext >&5
10967 ac_cv_type_struct_addrinfo=no
10968 fi
10969 rm -f conftest.$ac_objext conftest.$ac_ext
10970 fi
10971 echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
10972 echo "${ECHO_T}$ac_cv_type_struct_addrinfo" >&6
10973 if test $ac_cv_type_struct_addrinfo = yes; then
10974
10975 cat >>confdefs.h <<_ACEOF
10976 #define HAVE_STRUCT_ADDRINFO 1
10977 _ACEOF
10978
10979
10980 fi
10981
10982
10983 echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
10984 echo $ECHO_N "checking for struct cmsgcred... $ECHO_C" >&6
10985 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
10986   echo $ECHO_N "(cached) $ECHO_C" >&6
10987 else
10988   cat >conftest.$ac_ext <<_ACEOF
10989 #line $LINENO "configure"
10990 #include "confdefs.h"
10991 #include <sys/param.h>
10992 #include <sys/types.h>
10993 #include <sys/socket.h>
10994 #include <sys/ucred.h>
10995
10996 #ifdef F77_DUMMY_MAIN
10997 #  ifdef __cplusplus
10998      extern "C"
10999 #  endif
11000    int F77_DUMMY_MAIN() { return 1; }
11001 #endif
11002 int
11003 main ()
11004 {
11005 if ((struct cmsgcred *) 0)
11006   return 0;
11007 if (sizeof (struct cmsgcred))
11008   return 0;
11009   ;
11010   return 0;
11011 }
11012 _ACEOF
11013 rm -f conftest.$ac_objext
11014 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11015   (eval $ac_compile) 2>&5
11016   ac_status=$?
11017   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11018   (exit $ac_status); } &&
11019          { ac_try='test -s conftest.$ac_objext'
11020   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11021   (eval $ac_try) 2>&5
11022   ac_status=$?
11023   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11024   (exit $ac_status); }; }; then
11025   ac_cv_type_struct_cmsgcred=yes
11026 else
11027   echo "$as_me: failed program was:" >&5
11028 cat conftest.$ac_ext >&5
11029 ac_cv_type_struct_cmsgcred=no
11030 fi
11031 rm -f conftest.$ac_objext conftest.$ac_ext
11032 fi
11033 echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
11034 echo "${ECHO_T}$ac_cv_type_struct_cmsgcred" >&6
11035 if test $ac_cv_type_struct_cmsgcred = yes; then
11036
11037 cat >>confdefs.h <<_ACEOF
11038 #define HAVE_STRUCT_CMSGCRED 1
11039 _ACEOF
11040
11041
11042 fi
11043 echo "$as_me:$LINENO: checking for struct fcred" >&5
11044 echo $ECHO_N "checking for struct fcred... $ECHO_C" >&6
11045 if test "${ac_cv_type_struct_fcred+set}" = set; then
11046   echo $ECHO_N "(cached) $ECHO_C" >&6
11047 else
11048   cat >conftest.$ac_ext <<_ACEOF
11049 #line $LINENO "configure"
11050 #include "confdefs.h"
11051 #include <sys/param.h>
11052 #include <sys/types.h>
11053 #include <sys/socket.h>
11054 #include <sys/ucred.h>
11055
11056 #ifdef F77_DUMMY_MAIN
11057 #  ifdef __cplusplus
11058      extern "C"
11059 #  endif
11060    int F77_DUMMY_MAIN() { return 1; }
11061 #endif
11062 int
11063 main ()
11064 {
11065 if ((struct fcred *) 0)
11066   return 0;
11067 if (sizeof (struct fcred))
11068   return 0;
11069   ;
11070   return 0;
11071 }
11072 _ACEOF
11073 rm -f conftest.$ac_objext
11074 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11075   (eval $ac_compile) 2>&5
11076   ac_status=$?
11077   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11078   (exit $ac_status); } &&
11079          { ac_try='test -s conftest.$ac_objext'
11080   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11081   (eval $ac_try) 2>&5
11082   ac_status=$?
11083   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11084   (exit $ac_status); }; }; then
11085   ac_cv_type_struct_fcred=yes
11086 else
11087   echo "$as_me: failed program was:" >&5
11088 cat conftest.$ac_ext >&5
11089 ac_cv_type_struct_fcred=no
11090 fi
11091 rm -f conftest.$ac_objext conftest.$ac_ext
11092 fi
11093 echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
11094 echo "${ECHO_T}$ac_cv_type_struct_fcred" >&6
11095 if test $ac_cv_type_struct_fcred = yes; then
11096
11097 cat >>confdefs.h <<_ACEOF
11098 #define HAVE_STRUCT_FCRED 1
11099 _ACEOF
11100
11101
11102 fi
11103 echo "$as_me:$LINENO: checking for struct sockcred" >&5
11104 echo $ECHO_N "checking for struct sockcred... $ECHO_C" >&6
11105 if test "${ac_cv_type_struct_sockcred+set}" = set; then
11106   echo $ECHO_N "(cached) $ECHO_C" >&6
11107 else
11108   cat >conftest.$ac_ext <<_ACEOF
11109 #line $LINENO "configure"
11110 #include "confdefs.h"
11111 #include <sys/param.h>
11112 #include <sys/types.h>
11113 #include <sys/socket.h>
11114 #include <sys/ucred.h>
11115
11116 #ifdef F77_DUMMY_MAIN
11117 #  ifdef __cplusplus
11118      extern "C"
11119 #  endif
11120    int F77_DUMMY_MAIN() { return 1; }
11121 #endif
11122 int
11123 main ()
11124 {
11125 if ((struct sockcred *) 0)
11126   return 0;
11127 if (sizeof (struct sockcred))
11128   return 0;
11129   ;
11130   return 0;
11131 }
11132 _ACEOF
11133 rm -f conftest.$ac_objext
11134 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11135   (eval $ac_compile) 2>&5
11136   ac_status=$?
11137   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11138   (exit $ac_status); } &&
11139          { ac_try='test -s conftest.$ac_objext'
11140   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11141   (eval $ac_try) 2>&5
11142   ac_status=$?
11143   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11144   (exit $ac_status); }; }; then
11145   ac_cv_type_struct_sockcred=yes
11146 else
11147   echo "$as_me: failed program was:" >&5
11148 cat conftest.$ac_ext >&5
11149 ac_cv_type_struct_sockcred=no
11150 fi
11151 rm -f conftest.$ac_objext conftest.$ac_ext
11152 fi
11153 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
11154 echo "${ECHO_T}$ac_cv_type_struct_sockcred" >&6
11155 if test $ac_cv_type_struct_sockcred = yes; then
11156
11157 cat >>confdefs.h <<_ACEOF
11158 #define HAVE_STRUCT_SOCKCRED 1
11159 _ACEOF
11160
11161
11162 fi
11163
11164
11165 echo "$as_me:$LINENO: checking for struct option" >&5
11166 echo $ECHO_N "checking for struct option... $ECHO_C" >&6
11167 if test "${ac_cv_type_struct_option+set}" = set; then
11168   echo $ECHO_N "(cached) $ECHO_C" >&6
11169 else
11170   cat >conftest.$ac_ext <<_ACEOF
11171 #line $LINENO "configure"
11172 #include "confdefs.h"
11173 #ifdef HAVE_GETOPT_H
11174 #include <getopt.h>
11175 #endif
11176
11177 #ifdef F77_DUMMY_MAIN
11178 #  ifdef __cplusplus
11179      extern "C"
11180 #  endif
11181    int F77_DUMMY_MAIN() { return 1; }
11182 #endif
11183 int
11184 main ()
11185 {
11186 if ((struct option *) 0)
11187   return 0;
11188 if (sizeof (struct option))
11189   return 0;
11190   ;
11191   return 0;
11192 }
11193 _ACEOF
11194 rm -f conftest.$ac_objext
11195 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11196   (eval $ac_compile) 2>&5
11197   ac_status=$?
11198   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11199   (exit $ac_status); } &&
11200          { ac_try='test -s conftest.$ac_objext'
11201   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11202   (eval $ac_try) 2>&5
11203   ac_status=$?
11204   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11205   (exit $ac_status); }; }; then
11206   ac_cv_type_struct_option=yes
11207 else
11208   echo "$as_me: failed program was:" >&5
11209 cat conftest.$ac_ext >&5
11210 ac_cv_type_struct_option=no
11211 fi
11212 rm -f conftest.$ac_objext conftest.$ac_ext
11213 fi
11214 echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
11215 echo "${ECHO_T}$ac_cv_type_struct_option" >&6
11216 if test $ac_cv_type_struct_option = yes; then
11217
11218 cat >>confdefs.h <<_ACEOF
11219 #define HAVE_STRUCT_OPTION 1
11220 _ACEOF
11221
11222
11223 fi
11224
11225
11226 if test "$with_zlib" = yes; then
11227   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
11228   # did not).  While we could work around the lack of z_streamp, it
11229   # seems unwise to encourage people to use such old zlib versions...
11230   echo "$as_me:$LINENO: checking for z_streamp" >&5
11231 echo $ECHO_N "checking for z_streamp... $ECHO_C" >&6
11232 if test "${ac_cv_type_z_streamp+set}" = set; then
11233   echo $ECHO_N "(cached) $ECHO_C" >&6
11234 else
11235   cat >conftest.$ac_ext <<_ACEOF
11236 #line $LINENO "configure"
11237 #include "confdefs.h"
11238 #include <zlib.h>
11239
11240 #ifdef F77_DUMMY_MAIN
11241 #  ifdef __cplusplus
11242      extern "C"
11243 #  endif
11244    int F77_DUMMY_MAIN() { return 1; }
11245 #endif
11246 int
11247 main ()
11248 {
11249 if ((z_streamp *) 0)
11250   return 0;
11251 if (sizeof (z_streamp))
11252   return 0;
11253   ;
11254   return 0;
11255 }
11256 _ACEOF
11257 rm -f conftest.$ac_objext
11258 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11259   (eval $ac_compile) 2>&5
11260   ac_status=$?
11261   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11262   (exit $ac_status); } &&
11263          { ac_try='test -s conftest.$ac_objext'
11264   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11265   (eval $ac_try) 2>&5
11266   ac_status=$?
11267   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11268   (exit $ac_status); }; }; then
11269   ac_cv_type_z_streamp=yes
11270 else
11271   echo "$as_me: failed program was:" >&5
11272 cat conftest.$ac_ext >&5
11273 ac_cv_type_z_streamp=no
11274 fi
11275 rm -f conftest.$ac_objext conftest.$ac_ext
11276 fi
11277 echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
11278 echo "${ECHO_T}$ac_cv_type_z_streamp" >&6
11279 if test $ac_cv_type_z_streamp = yes; then
11280   :
11281 else
11282   { { echo "$as_me:$LINENO: error: zlib version is too old
11283 Use --without-zlib to disable zlib support." >&5
11284 echo "$as_me: error: zlib version is too old
11285 Use --without-zlib to disable zlib support." >&2;}
11286    { (exit 1); exit 1; }; }
11287 fi
11288
11289 fi
11290
11291 if test "$with_krb5" = yes; then
11292 # Check for differences between MIT and Heimdal (KTH) releases
11293   echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
11294 echo $ECHO_N "checking for krb5_ticket.enc_part2... $ECHO_C" >&6
11295 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
11296   echo $ECHO_N "(cached) $ECHO_C" >&6
11297 else
11298   cat >conftest.$ac_ext <<_ACEOF
11299 #line $LINENO "configure"
11300 #include "confdefs.h"
11301 #include <krb5.h>
11302
11303 #ifdef F77_DUMMY_MAIN
11304 #  ifdef __cplusplus
11305      extern "C"
11306 #  endif
11307    int F77_DUMMY_MAIN() { return 1; }
11308 #endif
11309 int
11310 main ()
11311 {
11312 static krb5_ticket ac_aggr;
11313 if (ac_aggr.enc_part2)
11314 return 0;
11315   ;
11316   return 0;
11317 }
11318 _ACEOF
11319 rm -f conftest.$ac_objext
11320 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11321   (eval $ac_compile) 2>&5
11322   ac_status=$?
11323   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11324   (exit $ac_status); } &&
11325          { ac_try='test -s conftest.$ac_objext'
11326   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11327   (eval $ac_try) 2>&5
11328   ac_status=$?
11329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11330   (exit $ac_status); }; }; then
11331   ac_cv_member_krb5_ticket_enc_part2=yes
11332 else
11333   echo "$as_me: failed program was:" >&5
11334 cat conftest.$ac_ext >&5
11335 ac_cv_member_krb5_ticket_enc_part2=no
11336 fi
11337 rm -f conftest.$ac_objext conftest.$ac_ext
11338 fi
11339 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
11340 echo "${ECHO_T}$ac_cv_member_krb5_ticket_enc_part2" >&6
11341 if test $ac_cv_member_krb5_ticket_enc_part2 = yes; then
11342
11343 cat >>confdefs.h <<_ACEOF
11344 #define HAVE_KRB5_TICKET_ENC_PART2 1
11345 _ACEOF
11346
11347
11348 else
11349   echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
11350 echo $ECHO_N "checking for krb5_ticket.client... $ECHO_C" >&6
11351 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
11352   echo $ECHO_N "(cached) $ECHO_C" >&6
11353 else
11354   cat >conftest.$ac_ext <<_ACEOF
11355 #line $LINENO "configure"
11356 #include "confdefs.h"
11357 #include <krb5.h>
11358
11359 #ifdef F77_DUMMY_MAIN
11360 #  ifdef __cplusplus
11361      extern "C"
11362 #  endif
11363    int F77_DUMMY_MAIN() { return 1; }
11364 #endif
11365 int
11366 main ()
11367 {
11368 static krb5_ticket ac_aggr;
11369 if (ac_aggr.client)
11370 return 0;
11371   ;
11372   return 0;
11373 }
11374 _ACEOF
11375 rm -f conftest.$ac_objext
11376 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11377   (eval $ac_compile) 2>&5
11378   ac_status=$?
11379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11380   (exit $ac_status); } &&
11381          { ac_try='test -s conftest.$ac_objext'
11382   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11383   (eval $ac_try) 2>&5
11384   ac_status=$?
11385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11386   (exit $ac_status); }; }; then
11387   ac_cv_member_krb5_ticket_client=yes
11388 else
11389   echo "$as_me: failed program was:" >&5
11390 cat conftest.$ac_ext >&5
11391 ac_cv_member_krb5_ticket_client=no
11392 fi
11393 rm -f conftest.$ac_objext conftest.$ac_ext
11394 fi
11395 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
11396 echo "${ECHO_T}$ac_cv_member_krb5_ticket_client" >&6
11397 if test $ac_cv_member_krb5_ticket_client = yes; then
11398
11399 cat >>confdefs.h <<_ACEOF
11400 #define HAVE_KRB5_TICKET_CLIENT 1
11401 _ACEOF
11402
11403
11404 else
11405   { { echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
11406 echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
11407    { (exit 1); exit 1; }; }
11408 fi
11409
11410 fi
11411
11412   echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
11413 echo $ECHO_N "checking for krb5_error.text.data... $ECHO_C" >&6
11414 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
11415   echo $ECHO_N "(cached) $ECHO_C" >&6
11416 else
11417   cat >conftest.$ac_ext <<_ACEOF
11418 #line $LINENO "configure"
11419 #include "confdefs.h"
11420 #include <krb5.h>
11421
11422 #ifdef F77_DUMMY_MAIN
11423 #  ifdef __cplusplus
11424      extern "C"
11425 #  endif
11426    int F77_DUMMY_MAIN() { return 1; }
11427 #endif
11428 int
11429 main ()
11430 {
11431 static krb5_error ac_aggr;
11432 if (ac_aggr.text.data)
11433 return 0;
11434   ;
11435   return 0;
11436 }
11437 _ACEOF
11438 rm -f conftest.$ac_objext
11439 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11440   (eval $ac_compile) 2>&5
11441   ac_status=$?
11442   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11443   (exit $ac_status); } &&
11444          { ac_try='test -s conftest.$ac_objext'
11445   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11446   (eval $ac_try) 2>&5
11447   ac_status=$?
11448   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11449   (exit $ac_status); }; }; then
11450   ac_cv_member_krb5_error_text_data=yes
11451 else
11452   echo "$as_me: failed program was:" >&5
11453 cat conftest.$ac_ext >&5
11454 ac_cv_member_krb5_error_text_data=no
11455 fi
11456 rm -f conftest.$ac_objext conftest.$ac_ext
11457 fi
11458 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
11459 echo "${ECHO_T}$ac_cv_member_krb5_error_text_data" >&6
11460 if test $ac_cv_member_krb5_error_text_data = yes; then
11461
11462 cat >>confdefs.h <<_ACEOF
11463 #define HAVE_KRB5_ERROR_TEXT_DATA 1
11464 _ACEOF
11465
11466
11467 else
11468   echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
11469 echo $ECHO_N "checking for krb5_error.e_data... $ECHO_C" >&6
11470 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
11471   echo $ECHO_N "(cached) $ECHO_C" >&6
11472 else
11473   cat >conftest.$ac_ext <<_ACEOF
11474 #line $LINENO "configure"
11475 #include "confdefs.h"
11476 #include <krb5.h>
11477
11478 #ifdef F77_DUMMY_MAIN
11479 #  ifdef __cplusplus
11480      extern "C"
11481 #  endif
11482    int F77_DUMMY_MAIN() { return 1; }
11483 #endif
11484 int
11485 main ()
11486 {
11487 static krb5_error ac_aggr;
11488 if (ac_aggr.e_data)
11489 return 0;
11490   ;
11491   return 0;
11492 }
11493 _ACEOF
11494 rm -f conftest.$ac_objext
11495 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11496   (eval $ac_compile) 2>&5
11497   ac_status=$?
11498   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11499   (exit $ac_status); } &&
11500          { ac_try='test -s conftest.$ac_objext'
11501   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11502   (eval $ac_try) 2>&5
11503   ac_status=$?
11504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11505   (exit $ac_status); }; }; then
11506   ac_cv_member_krb5_error_e_data=yes
11507 else
11508   echo "$as_me: failed program was:" >&5
11509 cat conftest.$ac_ext >&5
11510 ac_cv_member_krb5_error_e_data=no
11511 fi
11512 rm -f conftest.$ac_objext conftest.$ac_ext
11513 fi
11514 echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
11515 echo "${ECHO_T}$ac_cv_member_krb5_error_e_data" >&6
11516 if test $ac_cv_member_krb5_error_e_data = yes; then
11517
11518 cat >>confdefs.h <<_ACEOF
11519 #define HAVE_KRB5_ERROR_E_DATA 1
11520 _ACEOF
11521
11522
11523 else
11524   { { echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
11525 echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
11526    { (exit 1); exit 1; }; }
11527 fi
11528
11529 fi
11530
11531 fi
11532
11533 ##
11534 ## Functions, global variables
11535 ##
11536
11537 echo "$as_me:$LINENO: checking for int timezone" >&5
11538 echo $ECHO_N "checking for int timezone... $ECHO_C" >&6
11539 if test "${pgac_cv_var_int_timezone+set}" = set; then
11540   echo $ECHO_N "(cached) $ECHO_C" >&6
11541 else
11542   cat >conftest.$ac_ext <<_ACEOF
11543 #line $LINENO "configure"
11544 #include "confdefs.h"
11545 #include <time.h>
11546 int res;
11547 #ifdef F77_DUMMY_MAIN
11548 #  ifdef __cplusplus
11549      extern "C"
11550 #  endif
11551    int F77_DUMMY_MAIN() { return 1; }
11552 #endif
11553 int
11554 main ()
11555 {
11556 #ifndef __CYGWIN__
11557 res = timezone / 60;
11558 #else
11559 res = _timezone / 60;
11560 #endif
11561   ;
11562   return 0;
11563 }
11564 _ACEOF
11565 rm -f conftest.$ac_objext conftest$ac_exeext
11566 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11567   (eval $ac_link) 2>&5
11568   ac_status=$?
11569   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11570   (exit $ac_status); } &&
11571          { ac_try='test -s conftest$ac_exeext'
11572   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11573   (eval $ac_try) 2>&5
11574   ac_status=$?
11575   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11576   (exit $ac_status); }; }; then
11577   pgac_cv_var_int_timezone=yes
11578 else
11579   echo "$as_me: failed program was:" >&5
11580 cat conftest.$ac_ext >&5
11581 pgac_cv_var_int_timezone=no
11582 fi
11583 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11584 fi
11585 echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
11586 echo "${ECHO_T}$pgac_cv_var_int_timezone" >&6
11587 if test x"$pgac_cv_var_int_timezone" = xyes ; then
11588
11589 cat >>confdefs.h <<\_ACEOF
11590 #define HAVE_INT_TIMEZONE
11591 _ACEOF
11592
11593 fi
11594 echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
11595 echo $ECHO_N "checking types of arguments for accept()... $ECHO_C" >&6
11596  if test "${ac_cv_func_accept_return+set}" = set; then
11597   echo $ECHO_N "(cached) $ECHO_C" >&6
11598 else
11599    if test "${ac_cv_func_accept_arg1+set}" = set; then
11600   echo $ECHO_N "(cached) $ECHO_C" >&6
11601 else
11602     if test "${ac_cv_func_accept_arg2+set}" = set; then
11603   echo $ECHO_N "(cached) $ECHO_C" >&6
11604 else
11605      if test "${ac_cv_func_accept_arg3+set}" = set; then
11606   echo $ECHO_N "(cached) $ECHO_C" >&6
11607 else
11608       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
11609       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
11610        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
11611         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
11612          cat >conftest.$ac_ext <<_ACEOF
11613 #line $LINENO "configure"
11614 #include "confdefs.h"
11615 #ifdef HAVE_SYS_TYPES_H
11616 #include <sys/types.h>
11617 #endif
11618 #ifdef HAVE_SYS_SOCKET_H
11619 #include <sys/socket.h>
11620 #endif
11621 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
11622 #ifdef F77_DUMMY_MAIN
11623 #  ifdef __cplusplus
11624      extern "C"
11625 #  endif
11626    int F77_DUMMY_MAIN() { return 1; }
11627 #endif
11628 int
11629 main ()
11630 {
11631
11632   ;
11633   return 0;
11634 }
11635 _ACEOF
11636 rm -f conftest.$ac_objext
11637 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11638   (eval $ac_compile) 2>&5
11639   ac_status=$?
11640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11641   (exit $ac_status); } &&
11642          { ac_try='test -s conftest.$ac_objext'
11643   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11644   (eval $ac_try) 2>&5
11645   ac_status=$?
11646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11647   (exit $ac_status); }; }; then
11648   ac_not_found=no; break 4
11649 else
11650   echo "$as_me: failed program was:" >&5
11651 cat conftest.$ac_ext >&5
11652 ac_not_found=yes
11653 fi
11654 rm -f conftest.$ac_objext conftest.$ac_ext
11655        done
11656       done
11657      done
11658     done
11659     if test "$ac_not_found" = yes; then
11660       { { echo "$as_me:$LINENO: error: could not determine argument types" >&5
11661 echo "$as_me: error: could not determine argument types" >&2;}
11662    { (exit 1); exit 1; }; }
11663     fi
11664     if test "$ac_cv_func_accept_arg3" = "void"; then
11665       ac_cv_func_accept_arg3=int
11666     fi
11667
11668 fi
11669
11670 fi
11671
11672 fi
11673
11674 fi
11675  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
11676 echo "${ECHO_T}$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6
11677
11678 cat >>confdefs.h <<_ACEOF
11679 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
11680 _ACEOF
11681
11682
11683 cat >>confdefs.h <<_ACEOF
11684 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
11685 _ACEOF
11686
11687
11688 cat >>confdefs.h <<_ACEOF
11689 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
11690 _ACEOF
11691
11692
11693 cat >>confdefs.h <<_ACEOF
11694 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
11695 _ACEOF
11696
11697
11698 echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
11699 echo $ECHO_N "checking whether gettimeofday takes only one argument... $ECHO_C" >&6
11700 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
11701   echo $ECHO_N "(cached) $ECHO_C" >&6
11702 else
11703   cat >conftest.$ac_ext <<_ACEOF
11704 #line $LINENO "configure"
11705 #include "confdefs.h"
11706 #include <sys/time.h>
11707 #ifdef F77_DUMMY_MAIN
11708 #  ifdef __cplusplus
11709      extern "C"
11710 #  endif
11711    int F77_DUMMY_MAIN() { return 1; }
11712 #endif
11713 int
11714 main ()
11715 {
11716 struct timeval *tp;
11717 struct timezone *tzp;
11718 gettimeofday(tp,tzp);
11719   ;
11720   return 0;
11721 }
11722 _ACEOF
11723 rm -f conftest.$ac_objext
11724 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11725   (eval $ac_compile) 2>&5
11726   ac_status=$?
11727   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11728   (exit $ac_status); } &&
11729          { ac_try='test -s conftest.$ac_objext'
11730   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11731   (eval $ac_try) 2>&5
11732   ac_status=$?
11733   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11734   (exit $ac_status); }; }; then
11735   pgac_cv_func_gettimeofday_1arg=no
11736 else
11737   echo "$as_me: failed program was:" >&5
11738 cat conftest.$ac_ext >&5
11739 pgac_cv_func_gettimeofday_1arg=yes
11740 fi
11741 rm -f conftest.$ac_objext conftest.$ac_ext
11742 fi
11743 echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
11744 echo "${ECHO_T}$pgac_cv_func_gettimeofday_1arg" >&6
11745 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
11746
11747 cat >>confdefs.h <<\_ACEOF
11748 #define GETTIMEOFDAY_1ARG
11749 _ACEOF
11750
11751 fi
11752
11753
11754
11755
11756
11757
11758
11759
11760
11761
11762
11763
11764
11765
11766
11767
11768
11769
11770
11771
11772
11773
11774 for ac_func in cbrt dlopen fcvt fdatasync getpeereid memmove poll pstat readlink setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
11775 do
11776 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11777 echo "$as_me:$LINENO: checking for $ac_func" >&5
11778 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
11779 if eval "test \"\${$as_ac_var+set}\" = set"; then
11780   echo $ECHO_N "(cached) $ECHO_C" >&6
11781 else
11782   cat >conftest.$ac_ext <<_ACEOF
11783 #line $LINENO "configure"
11784 #include "confdefs.h"
11785 /* System header to define __stub macros and hopefully few prototypes,
11786     which can conflict with char $ac_func (); below.  */
11787 #include <assert.h>
11788 /* Override any gcc2 internal prototype to avoid an error.  */
11789 #ifdef __cplusplus
11790 extern "C"
11791 #endif
11792 /* We use char because int might match the return type of a gcc2
11793    builtin and then its argument prototype would still apply.  */
11794 char $ac_func ();
11795 char (*f) ();
11796
11797 #ifdef F77_DUMMY_MAIN
11798 #  ifdef __cplusplus
11799      extern "C"
11800 #  endif
11801    int F77_DUMMY_MAIN() { return 1; }
11802 #endif
11803 int
11804 main ()
11805 {
11806 /* The GNU C library defines this for functions which it implements
11807     to always fail with ENOSYS.  Some functions are actually named
11808     something starting with __ and the normal name is an alias.  */
11809 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
11810 choke me
11811 #else
11812 f = $ac_func;
11813 #endif
11814
11815   ;
11816   return 0;
11817 }
11818 _ACEOF
11819 rm -f conftest.$ac_objext conftest$ac_exeext
11820 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11821   (eval $ac_link) 2>&5
11822   ac_status=$?
11823   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11824   (exit $ac_status); } &&
11825          { ac_try='test -s conftest$ac_exeext'
11826   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11827   (eval $ac_try) 2>&5
11828   ac_status=$?
11829   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11830   (exit $ac_status); }; }; then
11831   eval "$as_ac_var=yes"
11832 else
11833   echo "$as_me: failed program was:" >&5
11834 cat conftest.$ac_ext >&5
11835 eval "$as_ac_var=no"
11836 fi
11837 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
11838 fi
11839 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
11840 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
11841 if test `eval echo '${'$as_ac_var'}'` = yes; then
11842   cat >>confdefs.h <<_ACEOF
11843 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11844 _ACEOF
11845
11846 fi
11847 done
11848
11849
11850 echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
11851 echo $ECHO_N "checking whether fdatasync is declared... $ECHO_C" >&6
11852 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
11853   echo $ECHO_N "(cached) $ECHO_C" >&6
11854 else
11855   cat >conftest.$ac_ext <<_ACEOF
11856 #line $LINENO "configure"
11857 #include "confdefs.h"
11858 #include <unistd.h>
11859
11860 #ifdef F77_DUMMY_MAIN
11861 #  ifdef __cplusplus
11862      extern "C"
11863 #  endif
11864    int F77_DUMMY_MAIN() { return 1; }
11865 #endif
11866 int
11867 main ()
11868 {
11869 #ifndef fdatasync
11870   char *p = (char *) fdatasync;
11871 #endif
11872
11873   ;
11874   return 0;
11875 }
11876 _ACEOF
11877 rm -f conftest.$ac_objext
11878 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11879   (eval $ac_compile) 2>&5
11880   ac_status=$?
11881   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11882   (exit $ac_status); } &&
11883          { ac_try='test -s conftest.$ac_objext'
11884   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11885   (eval $ac_try) 2>&5
11886   ac_status=$?
11887   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11888   (exit $ac_status); }; }; then
11889   ac_cv_have_decl_fdatasync=yes
11890 else
11891   echo "$as_me: failed program was:" >&5
11892 cat conftest.$ac_ext >&5
11893 ac_cv_have_decl_fdatasync=no
11894 fi
11895 rm -f conftest.$ac_objext conftest.$ac_ext
11896 fi
11897 echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
11898 echo "${ECHO_T}$ac_cv_have_decl_fdatasync" >&6
11899 if test $ac_cv_have_decl_fdatasync = yes; then
11900
11901 cat >>confdefs.h <<_ACEOF
11902 #define HAVE_DECL_FDATASYNC 1
11903 _ACEOF
11904
11905
11906 else
11907   cat >>confdefs.h <<_ACEOF
11908 #define HAVE_DECL_FDATASYNC 0
11909 _ACEOF
11910
11911
11912 fi
11913
11914
11915
11916 HAVE_IPV6=no
11917 echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
11918 echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6
11919 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
11920   echo $ECHO_N "(cached) $ECHO_C" >&6
11921 else
11922   cat >conftest.$ac_ext <<_ACEOF
11923 #line $LINENO "configure"
11924 #include "confdefs.h"
11925 $ac_includes_default
11926 #include <netinet/in.h>
11927
11928 #ifdef F77_DUMMY_MAIN
11929 #  ifdef __cplusplus
11930      extern "C"
11931 #  endif
11932    int F77_DUMMY_MAIN() { return 1; }
11933 #endif
11934 int
11935 main ()
11936 {
11937 if ((struct sockaddr_in6 *) 0)
11938   return 0;
11939 if (sizeof (struct sockaddr_in6))
11940   return 0;
11941   ;
11942   return 0;
11943 }
11944 _ACEOF
11945 rm -f conftest.$ac_objext
11946 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11947   (eval $ac_compile) 2>&5
11948   ac_status=$?
11949   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11950   (exit $ac_status); } &&
11951          { ac_try='test -s conftest.$ac_objext'
11952   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11953   (eval $ac_try) 2>&5
11954   ac_status=$?
11955   echo "$as_me:$LINENO: \$? = $ac_status" >&5
11956   (exit $ac_status); }; }; then
11957   ac_cv_type_struct_sockaddr_in6=yes
11958 else
11959   echo "$as_me: failed program was:" >&5
11960 cat conftest.$ac_ext >&5
11961 ac_cv_type_struct_sockaddr_in6=no
11962 fi
11963 rm -f conftest.$ac_objext conftest.$ac_ext
11964 fi
11965 echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
11966 echo "${ECHO_T}$ac_cv_type_struct_sockaddr_in6" >&6
11967 if test $ac_cv_type_struct_sockaddr_in6 = yes; then
11968   echo "$as_me:$LINENO: checking for inet_ntop" >&5
11969 echo $ECHO_N "checking for inet_ntop... $ECHO_C" >&6
11970 if test "${ac_cv_func_inet_ntop+set}" = set; then
11971   echo $ECHO_N "(cached) $ECHO_C" >&6
11972 else
11973   cat >conftest.$ac_ext <<_ACEOF
11974 #line $LINENO "configure"
11975 #include "confdefs.h"
11976 /* System header to define __stub macros and hopefully few prototypes,
11977     which can conflict with char inet_ntop (); below.  */
11978 #include <assert.h>
11979 /* Override any gcc2 internal prototype to avoid an error.  */
11980 #ifdef __cplusplus
11981 extern "C"
11982 #endif
11983 /* We use char because int might match the return type of a gcc2
11984    builtin and then its argument prototype would still apply.  */
11985 char inet_ntop ();
11986 char (*f) ();
11987
11988 #ifdef F77_DUMMY_MAIN
11989 #  ifdef __cplusplus
11990      extern "C"
11991 #  endif
11992    int F77_DUMMY_MAIN() { return 1; }
11993 #endif
11994 int
11995 main ()
11996 {
11997 /* The GNU C library defines this for functions which it implements
11998     to always fail with ENOSYS.  Some functions are actually named
11999     something starting with __ and the normal name is an alias.  */
12000 #if defined (__stub_inet_ntop) || defined (__stub___inet_ntop)
12001 choke me
12002 #else
12003 f = inet_ntop;
12004 #endif
12005
12006   ;
12007   return 0;
12008 }
12009 _ACEOF
12010 rm -f conftest.$ac_objext conftest$ac_exeext
12011 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12012   (eval $ac_link) 2>&5
12013   ac_status=$?
12014   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12015   (exit $ac_status); } &&
12016          { ac_try='test -s conftest$ac_exeext'
12017   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12018   (eval $ac_try) 2>&5
12019   ac_status=$?
12020   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12021   (exit $ac_status); }; }; then
12022   ac_cv_func_inet_ntop=yes
12023 else
12024   echo "$as_me: failed program was:" >&5
12025 cat conftest.$ac_ext >&5
12026 ac_cv_func_inet_ntop=no
12027 fi
12028 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12029 fi
12030 echo "$as_me:$LINENO: result: $ac_cv_func_inet_ntop" >&5
12031 echo "${ECHO_T}$ac_cv_func_inet_ntop" >&6
12032 if test $ac_cv_func_inet_ntop = yes; then
12033
12034 cat >>confdefs.h <<\_ACEOF
12035 #define HAVE_IPV6 1
12036 _ACEOF
12037
12038                                                           HAVE_IPV6=yes
12039 fi
12040
12041 fi
12042
12043
12044
12045 echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
12046 echo $ECHO_N "checking for PS_STRINGS... $ECHO_C" >&6
12047 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
12048   echo $ECHO_N "(cached) $ECHO_C" >&6
12049 else
12050   cat >conftest.$ac_ext <<_ACEOF
12051 #line $LINENO "configure"
12052 #include "confdefs.h"
12053 #include <machine/vmparam.h>
12054 #include <sys/exec.h>
12055
12056 #ifdef F77_DUMMY_MAIN
12057 #  ifdef __cplusplus
12058      extern "C"
12059 #  endif
12060    int F77_DUMMY_MAIN() { return 1; }
12061 #endif
12062 int
12063 main ()
12064 {
12065 PS_STRINGS->ps_nargvstr = 1;
12066 PS_STRINGS->ps_argvstr = "foo";
12067   ;
12068   return 0;
12069 }
12070 _ACEOF
12071 rm -f conftest.$ac_objext conftest$ac_exeext
12072 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12073   (eval $ac_link) 2>&5
12074   ac_status=$?
12075   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12076   (exit $ac_status); } &&
12077          { ac_try='test -s conftest$ac_exeext'
12078   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12079   (eval $ac_try) 2>&5
12080   ac_status=$?
12081   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12082   (exit $ac_status); }; }; then
12083   pgac_cv_var_PS_STRINGS=yes
12084 else
12085   echo "$as_me: failed program was:" >&5
12086 cat conftest.$ac_ext >&5
12087 pgac_cv_var_PS_STRINGS=no
12088 fi
12089 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12090 fi
12091 echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
12092 echo "${ECHO_T}$pgac_cv_var_PS_STRINGS" >&6
12093 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
12094
12095 cat >>confdefs.h <<\_ACEOF
12096 #define HAVE_PS_STRINGS
12097 _ACEOF
12098
12099 fi
12100
12101
12102 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
12103 # is missing.  Yes, there are machines that have only one.  We may
12104 # also decide to use snprintf.c if snprintf() is present but does not
12105 # have all the features we need --- see below.
12106
12107 pgac_need_repl_snprintf=no
12108
12109 for ac_func in snprintf
12110 do
12111 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12112 echo "$as_me:$LINENO: checking for $ac_func" >&5
12113 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12114 if eval "test \"\${$as_ac_var+set}\" = set"; then
12115   echo $ECHO_N "(cached) $ECHO_C" >&6
12116 else
12117   cat >conftest.$ac_ext <<_ACEOF
12118 #line $LINENO "configure"
12119 #include "confdefs.h"
12120 /* System header to define __stub macros and hopefully few prototypes,
12121     which can conflict with char $ac_func (); below.  */
12122 #include <assert.h>
12123 /* Override any gcc2 internal prototype to avoid an error.  */
12124 #ifdef __cplusplus
12125 extern "C"
12126 #endif
12127 /* We use char because int might match the return type of a gcc2
12128    builtin and then its argument prototype would still apply.  */
12129 char $ac_func ();
12130 char (*f) ();
12131
12132 #ifdef F77_DUMMY_MAIN
12133 #  ifdef __cplusplus
12134      extern "C"
12135 #  endif
12136    int F77_DUMMY_MAIN() { return 1; }
12137 #endif
12138 int
12139 main ()
12140 {
12141 /* The GNU C library defines this for functions which it implements
12142     to always fail with ENOSYS.  Some functions are actually named
12143     something starting with __ and the normal name is an alias.  */
12144 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12145 choke me
12146 #else
12147 f = $ac_func;
12148 #endif
12149
12150   ;
12151   return 0;
12152 }
12153 _ACEOF
12154 rm -f conftest.$ac_objext conftest$ac_exeext
12155 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12156   (eval $ac_link) 2>&5
12157   ac_status=$?
12158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12159   (exit $ac_status); } &&
12160          { ac_try='test -s conftest$ac_exeext'
12161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12162   (eval $ac_try) 2>&5
12163   ac_status=$?
12164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12165   (exit $ac_status); }; }; then
12166   eval "$as_ac_var=yes"
12167 else
12168   echo "$as_me: failed program was:" >&5
12169 cat conftest.$ac_ext >&5
12170 eval "$as_ac_var=no"
12171 fi
12172 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12173 fi
12174 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12175 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12176 if test `eval echo '${'$as_ac_var'}'` = yes; then
12177   cat >>confdefs.h <<_ACEOF
12178 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12179 _ACEOF
12180
12181 else
12182   pgac_need_repl_snprintf=yes
12183 fi
12184 done
12185
12186
12187 for ac_func in vsnprintf
12188 do
12189 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12190 echo "$as_me:$LINENO: checking for $ac_func" >&5
12191 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12192 if eval "test \"\${$as_ac_var+set}\" = set"; then
12193   echo $ECHO_N "(cached) $ECHO_C" >&6
12194 else
12195   cat >conftest.$ac_ext <<_ACEOF
12196 #line $LINENO "configure"
12197 #include "confdefs.h"
12198 /* System header to define __stub macros and hopefully few prototypes,
12199     which can conflict with char $ac_func (); below.  */
12200 #include <assert.h>
12201 /* Override any gcc2 internal prototype to avoid an error.  */
12202 #ifdef __cplusplus
12203 extern "C"
12204 #endif
12205 /* We use char because int might match the return type of a gcc2
12206    builtin and then its argument prototype would still apply.  */
12207 char $ac_func ();
12208 char (*f) ();
12209
12210 #ifdef F77_DUMMY_MAIN
12211 #  ifdef __cplusplus
12212      extern "C"
12213 #  endif
12214    int F77_DUMMY_MAIN() { return 1; }
12215 #endif
12216 int
12217 main ()
12218 {
12219 /* The GNU C library defines this for functions which it implements
12220     to always fail with ENOSYS.  Some functions are actually named
12221     something starting with __ and the normal name is an alias.  */
12222 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12223 choke me
12224 #else
12225 f = $ac_func;
12226 #endif
12227
12228   ;
12229   return 0;
12230 }
12231 _ACEOF
12232 rm -f conftest.$ac_objext conftest$ac_exeext
12233 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12234   (eval $ac_link) 2>&5
12235   ac_status=$?
12236   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12237   (exit $ac_status); } &&
12238          { ac_try='test -s conftest$ac_exeext'
12239   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12240   (eval $ac_try) 2>&5
12241   ac_status=$?
12242   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12243   (exit $ac_status); }; }; then
12244   eval "$as_ac_var=yes"
12245 else
12246   echo "$as_me: failed program was:" >&5
12247 cat conftest.$ac_ext >&5
12248 eval "$as_ac_var=no"
12249 fi
12250 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12251 fi
12252 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12253 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12254 if test `eval echo '${'$as_ac_var'}'` = yes; then
12255   cat >>confdefs.h <<_ACEOF
12256 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12257 _ACEOF
12258
12259 else
12260   pgac_need_repl_snprintf=yes
12261 fi
12262 done
12263
12264
12265
12266 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
12267 # include/c.h will provide declarations.  Note this is a separate test
12268 # from whether the functions exist in the C library --- there are
12269 # systems that have the functions but don't bother to declare them :-(
12270
12271 echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
12272 echo $ECHO_N "checking whether snprintf is declared... $ECHO_C" >&6
12273 if test "${ac_cv_have_decl_snprintf+set}" = set; then
12274   echo $ECHO_N "(cached) $ECHO_C" >&6
12275 else
12276   cat >conftest.$ac_ext <<_ACEOF
12277 #line $LINENO "configure"
12278 #include "confdefs.h"
12279 $ac_includes_default
12280 #ifdef F77_DUMMY_MAIN
12281 #  ifdef __cplusplus
12282      extern "C"
12283 #  endif
12284    int F77_DUMMY_MAIN() { return 1; }
12285 #endif
12286 int
12287 main ()
12288 {
12289 #ifndef snprintf
12290   char *p = (char *) snprintf;
12291 #endif
12292
12293   ;
12294   return 0;
12295 }
12296 _ACEOF
12297 rm -f conftest.$ac_objext
12298 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12299   (eval $ac_compile) 2>&5
12300   ac_status=$?
12301   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12302   (exit $ac_status); } &&
12303          { ac_try='test -s conftest.$ac_objext'
12304   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12305   (eval $ac_try) 2>&5
12306   ac_status=$?
12307   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12308   (exit $ac_status); }; }; then
12309   ac_cv_have_decl_snprintf=yes
12310 else
12311   echo "$as_me: failed program was:" >&5
12312 cat conftest.$ac_ext >&5
12313 ac_cv_have_decl_snprintf=no
12314 fi
12315 rm -f conftest.$ac_objext conftest.$ac_ext
12316 fi
12317 echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
12318 echo "${ECHO_T}$ac_cv_have_decl_snprintf" >&6
12319 if test $ac_cv_have_decl_snprintf = yes; then
12320
12321 cat >>confdefs.h <<_ACEOF
12322 #define HAVE_DECL_SNPRINTF 1
12323 _ACEOF
12324
12325
12326 else
12327   cat >>confdefs.h <<_ACEOF
12328 #define HAVE_DECL_SNPRINTF 0
12329 _ACEOF
12330
12331
12332 fi
12333 echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
12334 echo $ECHO_N "checking whether vsnprintf is declared... $ECHO_C" >&6
12335 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
12336   echo $ECHO_N "(cached) $ECHO_C" >&6
12337 else
12338   cat >conftest.$ac_ext <<_ACEOF
12339 #line $LINENO "configure"
12340 #include "confdefs.h"
12341 $ac_includes_default
12342 #ifdef F77_DUMMY_MAIN
12343 #  ifdef __cplusplus
12344      extern "C"
12345 #  endif
12346    int F77_DUMMY_MAIN() { return 1; }
12347 #endif
12348 int
12349 main ()
12350 {
12351 #ifndef vsnprintf
12352   char *p = (char *) vsnprintf;
12353 #endif
12354
12355   ;
12356   return 0;
12357 }
12358 _ACEOF
12359 rm -f conftest.$ac_objext
12360 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12361   (eval $ac_compile) 2>&5
12362   ac_status=$?
12363   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12364   (exit $ac_status); } &&
12365          { ac_try='test -s conftest.$ac_objext'
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); }; }; then
12371   ac_cv_have_decl_vsnprintf=yes
12372 else
12373   echo "$as_me: failed program was:" >&5
12374 cat conftest.$ac_ext >&5
12375 ac_cv_have_decl_vsnprintf=no
12376 fi
12377 rm -f conftest.$ac_objext conftest.$ac_ext
12378 fi
12379 echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
12380 echo "${ECHO_T}$ac_cv_have_decl_vsnprintf" >&6
12381 if test $ac_cv_have_decl_vsnprintf = yes; then
12382
12383 cat >>confdefs.h <<_ACEOF
12384 #define HAVE_DECL_VSNPRINTF 1
12385 _ACEOF
12386
12387
12388 else
12389   cat >>confdefs.h <<_ACEOF
12390 #define HAVE_DECL_VSNPRINTF 0
12391 _ACEOF
12392
12393
12394 fi
12395
12396
12397
12398
12399 # do this one the hard way in case isinf() is a macro
12400 echo "$as_me:$LINENO: checking for isinf" >&5
12401 echo $ECHO_N "checking for isinf... $ECHO_C" >&6
12402 if test "${ac_cv_func_isinf+set}" = set; then
12403   echo $ECHO_N "(cached) $ECHO_C" >&6
12404 else
12405   cat >conftest.$ac_ext <<_ACEOF
12406 #line $LINENO "configure"
12407 #include "confdefs.h"
12408 #include <math.h>
12409
12410 #ifdef F77_DUMMY_MAIN
12411 #  ifdef __cplusplus
12412      extern "C"
12413 #  endif
12414    int F77_DUMMY_MAIN() { return 1; }
12415 #endif
12416 int
12417 main ()
12418 {
12419 double x = 0.0; int res = isinf(x);
12420   ;
12421   return 0;
12422 }
12423 _ACEOF
12424 rm -f conftest.$ac_objext conftest$ac_exeext
12425 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12426   (eval $ac_link) 2>&5
12427   ac_status=$?
12428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12429   (exit $ac_status); } &&
12430          { ac_try='test -s conftest$ac_exeext'
12431   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12432   (eval $ac_try) 2>&5
12433   ac_status=$?
12434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12435   (exit $ac_status); }; }; then
12436   ac_cv_func_isinf=yes
12437 else
12438   echo "$as_me: failed program was:" >&5
12439 cat conftest.$ac_ext >&5
12440 ac_cv_func_isinf=no
12441 fi
12442 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12443 fi
12444 echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
12445 echo "${ECHO_T}$ac_cv_func_isinf" >&6
12446
12447 if test $ac_cv_func_isinf = yes ; then
12448
12449 cat >>confdefs.h <<\_ACEOF
12450 #define HAVE_ISINF 1
12451 _ACEOF
12452
12453 else
12454   LIBOBJS="$LIBOBJS isinf.$ac_objext"
12455   # Look for a way to implement a substitute for isinf()
12456
12457
12458
12459
12460 for ac_func in fpclass fp_class fp_class_d class
12461 do
12462 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12463 echo "$as_me:$LINENO: checking for $ac_func" >&5
12464 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12465 if eval "test \"\${$as_ac_var+set}\" = set"; then
12466   echo $ECHO_N "(cached) $ECHO_C" >&6
12467 else
12468   cat >conftest.$ac_ext <<_ACEOF
12469 #line $LINENO "configure"
12470 #include "confdefs.h"
12471 /* System header to define __stub macros and hopefully few prototypes,
12472     which can conflict with char $ac_func (); below.  */
12473 #include <assert.h>
12474 /* Override any gcc2 internal prototype to avoid an error.  */
12475 #ifdef __cplusplus
12476 extern "C"
12477 #endif
12478 /* We use char because int might match the return type of a gcc2
12479    builtin and then its argument prototype would still apply.  */
12480 char $ac_func ();
12481 char (*f) ();
12482
12483 #ifdef F77_DUMMY_MAIN
12484 #  ifdef __cplusplus
12485      extern "C"
12486 #  endif
12487    int F77_DUMMY_MAIN() { return 1; }
12488 #endif
12489 int
12490 main ()
12491 {
12492 /* The GNU C library defines this for functions which it implements
12493     to always fail with ENOSYS.  Some functions are actually named
12494     something starting with __ and the normal name is an alias.  */
12495 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12496 choke me
12497 #else
12498 f = $ac_func;
12499 #endif
12500
12501   ;
12502   return 0;
12503 }
12504 _ACEOF
12505 rm -f conftest.$ac_objext conftest$ac_exeext
12506 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12507   (eval $ac_link) 2>&5
12508   ac_status=$?
12509   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12510   (exit $ac_status); } &&
12511          { ac_try='test -s conftest$ac_exeext'
12512   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12513   (eval $ac_try) 2>&5
12514   ac_status=$?
12515   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12516   (exit $ac_status); }; }; then
12517   eval "$as_ac_var=yes"
12518 else
12519   echo "$as_me: failed program was:" >&5
12520 cat conftest.$ac_ext >&5
12521 eval "$as_ac_var=no"
12522 fi
12523 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12524 fi
12525 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12526 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12527 if test `eval echo '${'$as_ac_var'}'` = yes; then
12528   cat >>confdefs.h <<_ACEOF
12529 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12530 _ACEOF
12531  break
12532 fi
12533 done
12534
12535 fi
12536
12537
12538
12539
12540
12541
12542
12543
12544
12545
12546
12547
12548
12549
12550 for ac_func in crypt fseeko getopt getrusage inet_aton random rint srandom strdup strerror strtol strtoul unsetenv
12551 do
12552 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12553 echo "$as_me:$LINENO: checking for $ac_func" >&5
12554 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12555 if eval "test \"\${$as_ac_var+set}\" = set"; then
12556   echo $ECHO_N "(cached) $ECHO_C" >&6
12557 else
12558   cat >conftest.$ac_ext <<_ACEOF
12559 #line $LINENO "configure"
12560 #include "confdefs.h"
12561 /* System header to define __stub macros and hopefully few prototypes,
12562     which can conflict with char $ac_func (); below.  */
12563 #include <assert.h>
12564 /* Override any gcc2 internal prototype to avoid an error.  */
12565 #ifdef __cplusplus
12566 extern "C"
12567 #endif
12568 /* We use char because int might match the return type of a gcc2
12569    builtin and then its argument prototype would still apply.  */
12570 char $ac_func ();
12571 char (*f) ();
12572
12573 #ifdef F77_DUMMY_MAIN
12574 #  ifdef __cplusplus
12575      extern "C"
12576 #  endif
12577    int F77_DUMMY_MAIN() { return 1; }
12578 #endif
12579 int
12580 main ()
12581 {
12582 /* The GNU C library defines this for functions which it implements
12583     to always fail with ENOSYS.  Some functions are actually named
12584     something starting with __ and the normal name is an alias.  */
12585 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12586 choke me
12587 #else
12588 f = $ac_func;
12589 #endif
12590
12591   ;
12592   return 0;
12593 }
12594 _ACEOF
12595 rm -f conftest.$ac_objext conftest$ac_exeext
12596 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12597   (eval $ac_link) 2>&5
12598   ac_status=$?
12599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12600   (exit $ac_status); } &&
12601          { ac_try='test -s conftest$ac_exeext'
12602   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12603   (eval $ac_try) 2>&5
12604   ac_status=$?
12605   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12606   (exit $ac_status); }; }; then
12607   eval "$as_ac_var=yes"
12608 else
12609   echo "$as_me: failed program was:" >&5
12610 cat conftest.$ac_ext >&5
12611 eval "$as_ac_var=no"
12612 fi
12613 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12614 fi
12615 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12616 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12617 if test `eval echo '${'$as_ac_var'}'` = yes; then
12618   cat >>confdefs.h <<_ACEOF
12619 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12620 _ACEOF
12621
12622 else
12623   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
12624 fi
12625 done
12626
12627
12628
12629 # system's version of getaddrinfo(), if any, may be used only if we found
12630 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h
12631 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
12632
12633 for ac_func in getaddrinfo
12634 do
12635 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12636 echo "$as_me:$LINENO: checking for $ac_func" >&5
12637 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12638 if eval "test \"\${$as_ac_var+set}\" = set"; then
12639   echo $ECHO_N "(cached) $ECHO_C" >&6
12640 else
12641   cat >conftest.$ac_ext <<_ACEOF
12642 #line $LINENO "configure"
12643 #include "confdefs.h"
12644 /* System header to define __stub macros and hopefully few prototypes,
12645     which can conflict with char $ac_func (); below.  */
12646 #include <assert.h>
12647 /* Override any gcc2 internal prototype to avoid an error.  */
12648 #ifdef __cplusplus
12649 extern "C"
12650 #endif
12651 /* We use char because int might match the return type of a gcc2
12652    builtin and then its argument prototype would still apply.  */
12653 char $ac_func ();
12654 char (*f) ();
12655
12656 #ifdef F77_DUMMY_MAIN
12657 #  ifdef __cplusplus
12658      extern "C"
12659 #  endif
12660    int F77_DUMMY_MAIN() { return 1; }
12661 #endif
12662 int
12663 main ()
12664 {
12665 /* The GNU C library defines this for functions which it implements
12666     to always fail with ENOSYS.  Some functions are actually named
12667     something starting with __ and the normal name is an alias.  */
12668 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12669 choke me
12670 #else
12671 f = $ac_func;
12672 #endif
12673
12674   ;
12675   return 0;
12676 }
12677 _ACEOF
12678 rm -f conftest.$ac_objext conftest$ac_exeext
12679 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12680   (eval $ac_link) 2>&5
12681   ac_status=$?
12682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12683   (exit $ac_status); } &&
12684          { ac_try='test -s conftest$ac_exeext'
12685   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12686   (eval $ac_try) 2>&5
12687   ac_status=$?
12688   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12689   (exit $ac_status); }; }; then
12690   eval "$as_ac_var=yes"
12691 else
12692   echo "$as_me: failed program was:" >&5
12693 cat conftest.$ac_ext >&5
12694 eval "$as_ac_var=no"
12695 fi
12696 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12697 fi
12698 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12699 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12700 if test `eval echo '${'$as_ac_var'}'` = yes; then
12701   cat >>confdefs.h <<_ACEOF
12702 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12703 _ACEOF
12704
12705 else
12706   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
12707 fi
12708 done
12709
12710
12711 else
12712   LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
12713 fi
12714
12715 # similarly, use system's getopt_long() only if system provides struct option.
12716 if test x"$ac_cv_type_struct_option" = xyes ; then
12717
12718 for ac_func in getopt_long
12719 do
12720 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12721 echo "$as_me:$LINENO: checking for $ac_func" >&5
12722 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12723 if eval "test \"\${$as_ac_var+set}\" = set"; then
12724   echo $ECHO_N "(cached) $ECHO_C" >&6
12725 else
12726   cat >conftest.$ac_ext <<_ACEOF
12727 #line $LINENO "configure"
12728 #include "confdefs.h"
12729 /* System header to define __stub macros and hopefully few prototypes,
12730     which can conflict with char $ac_func (); below.  */
12731 #include <assert.h>
12732 /* Override any gcc2 internal prototype to avoid an error.  */
12733 #ifdef __cplusplus
12734 extern "C"
12735 #endif
12736 /* We use char because int might match the return type of a gcc2
12737    builtin and then its argument prototype would still apply.  */
12738 char $ac_func ();
12739 char (*f) ();
12740
12741 #ifdef F77_DUMMY_MAIN
12742 #  ifdef __cplusplus
12743      extern "C"
12744 #  endif
12745    int F77_DUMMY_MAIN() { return 1; }
12746 #endif
12747 int
12748 main ()
12749 {
12750 /* The GNU C library defines this for functions which it implements
12751     to always fail with ENOSYS.  Some functions are actually named
12752     something starting with __ and the normal name is an alias.  */
12753 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12754 choke me
12755 #else
12756 f = $ac_func;
12757 #endif
12758
12759   ;
12760   return 0;
12761 }
12762 _ACEOF
12763 rm -f conftest.$ac_objext conftest$ac_exeext
12764 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12765   (eval $ac_link) 2>&5
12766   ac_status=$?
12767   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12768   (exit $ac_status); } &&
12769          { ac_try='test -s conftest$ac_exeext'
12770   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12771   (eval $ac_try) 2>&5
12772   ac_status=$?
12773   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12774   (exit $ac_status); }; }; then
12775   eval "$as_ac_var=yes"
12776 else
12777   echo "$as_me: failed program was:" >&5
12778 cat conftest.$ac_ext >&5
12779 eval "$as_ac_var=no"
12780 fi
12781 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12782 fi
12783 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12784 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12785 if test `eval echo '${'$as_ac_var'}'` = yes; then
12786   cat >>confdefs.h <<_ACEOF
12787 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12788 _ACEOF
12789
12790 else
12791   LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
12792 fi
12793 done
12794
12795
12796 else
12797   LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
12798 fi
12799
12800 # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
12801 # We override the previous test that said fseeko/ftello didn't exist
12802 # OS tests are also done in include/c.h and port/fseeko.c
12803 case $host_os in bsdi*|netbsd*)
12804 ac_cv_func_fseeko=yes
12805 esac
12806
12807 # Solaris has a very slow qsort in certain cases, so we replace it.
12808 if test "$PORTNAME" = "solaris"; then
12809 LIBOBJS="$LIBOBJS qsort.$ac_objext"
12810 fi
12811
12812 # Win32 support
12813 if test "$PORTNAME" = "win32"; then
12814 LIBOBJS="$LIBOBJS copydir.$ac_objext"
12815 LIBOBJS="$LIBOBJS gettimeofday.$ac_objext"
12816 LIBOBJS="$LIBOBJS kill.$ac_objext"
12817 LIBOBJS="$LIBOBJS open.$ac_objext"
12818 LIBOBJS="$LIBOBJS rand.$ac_objext"
12819
12820 cat >>confdefs.h <<\_ACEOF
12821 #define HAVE_SYMLINK 1
12822 _ACEOF
12823
12824 fi
12825
12826 if test "$with_readline" = yes; then
12827   echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
12828 echo $ECHO_N "checking for rl_completion_append_character... $ECHO_C" >&6
12829 cat >conftest.$ac_ext <<_ACEOF
12830 #line $LINENO "configure"
12831 #include "confdefs.h"
12832 #include <stdio.h>
12833 #ifdef HAVE_READLINE_READLINE_H
12834 # include <readline/readline.h>
12835 #elif defined(HAVE_READLINE_H)
12836 # include <readline.h>
12837 #endif
12838
12839 #ifdef F77_DUMMY_MAIN
12840 #  ifdef __cplusplus
12841      extern "C"
12842 #  endif
12843    int F77_DUMMY_MAIN() { return 1; }
12844 #endif
12845 int
12846 main ()
12847 {
12848 rl_completion_append_character = 'x';
12849   ;
12850   return 0;
12851 }
12852 _ACEOF
12853 rm -f conftest.$ac_objext conftest$ac_exeext
12854 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12855   (eval $ac_link) 2>&5
12856   ac_status=$?
12857   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12858   (exit $ac_status); } &&
12859          { ac_try='test -s conftest$ac_exeext'
12860   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12861   (eval $ac_try) 2>&5
12862   ac_status=$?
12863   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12864   (exit $ac_status); }; }; then
12865   echo "$as_me:$LINENO: result: yes" >&5
12866 echo "${ECHO_T}yes" >&6
12867
12868 cat >>confdefs.h <<\_ACEOF
12869 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
12870 _ACEOF
12871
12872 else
12873   echo "$as_me: failed program was:" >&5
12874 cat conftest.$ac_ext >&5
12875 echo "$as_me:$LINENO: result: no" >&5
12876 echo "${ECHO_T}no" >&6
12877 fi
12878 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12879
12880
12881 for ac_func in rl_completion_matches rl_filename_completion_function
12882 do
12883 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12884 echo "$as_me:$LINENO: checking for $ac_func" >&5
12885 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12886 if eval "test \"\${$as_ac_var+set}\" = set"; then
12887   echo $ECHO_N "(cached) $ECHO_C" >&6
12888 else
12889   cat >conftest.$ac_ext <<_ACEOF
12890 #line $LINENO "configure"
12891 #include "confdefs.h"
12892 /* System header to define __stub macros and hopefully few prototypes,
12893     which can conflict with char $ac_func (); below.  */
12894 #include <assert.h>
12895 /* Override any gcc2 internal prototype to avoid an error.  */
12896 #ifdef __cplusplus
12897 extern "C"
12898 #endif
12899 /* We use char because int might match the return type of a gcc2
12900    builtin and then its argument prototype would still apply.  */
12901 char $ac_func ();
12902 char (*f) ();
12903
12904 #ifdef F77_DUMMY_MAIN
12905 #  ifdef __cplusplus
12906      extern "C"
12907 #  endif
12908    int F77_DUMMY_MAIN() { return 1; }
12909 #endif
12910 int
12911 main ()
12912 {
12913 /* The GNU C library defines this for functions which it implements
12914     to always fail with ENOSYS.  Some functions are actually named
12915     something starting with __ and the normal name is an alias.  */
12916 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12917 choke me
12918 #else
12919 f = $ac_func;
12920 #endif
12921
12922   ;
12923   return 0;
12924 }
12925 _ACEOF
12926 rm -f conftest.$ac_objext conftest$ac_exeext
12927 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12928   (eval $ac_link) 2>&5
12929   ac_status=$?
12930   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12931   (exit $ac_status); } &&
12932          { ac_try='test -s conftest$ac_exeext'
12933   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12934   (eval $ac_try) 2>&5
12935   ac_status=$?
12936   echo "$as_me:$LINENO: \$? = $ac_status" >&5
12937   (exit $ac_status); }; }; then
12938   eval "$as_ac_var=yes"
12939 else
12940   echo "$as_me: failed program was:" >&5
12941 cat conftest.$ac_ext >&5
12942 eval "$as_ac_var=no"
12943 fi
12944 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
12945 fi
12946 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12947 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12948 if test `eval echo '${'$as_ac_var'}'` = yes; then
12949   cat >>confdefs.h <<_ACEOF
12950 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12951 _ACEOF
12952
12953 fi
12954 done
12955
12956
12957 for ac_func in replace_history_entry
12958 do
12959 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12960 echo "$as_me:$LINENO: checking for $ac_func" >&5
12961 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12962 if eval "test \"\${$as_ac_var+set}\" = set"; then
12963   echo $ECHO_N "(cached) $ECHO_C" >&6
12964 else
12965   cat >conftest.$ac_ext <<_ACEOF
12966 #line $LINENO "configure"
12967 #include "confdefs.h"
12968 /* System header to define __stub macros and hopefully few prototypes,
12969     which can conflict with char $ac_func (); below.  */
12970 #include <assert.h>
12971 /* Override any gcc2 internal prototype to avoid an error.  */
12972 #ifdef __cplusplus
12973 extern "C"
12974 #endif
12975 /* We use char because int might match the return type of a gcc2
12976    builtin and then its argument prototype would still apply.  */
12977 char $ac_func ();
12978 char (*f) ();
12979
12980 #ifdef F77_DUMMY_MAIN
12981 #  ifdef __cplusplus
12982      extern "C"
12983 #  endif
12984    int F77_DUMMY_MAIN() { return 1; }
12985 #endif
12986 int
12987 main ()
12988 {
12989 /* The GNU C library defines this for functions which it implements
12990     to always fail with ENOSYS.  Some functions are actually named
12991     something starting with __ and the normal name is an alias.  */
12992 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12993 choke me
12994 #else
12995 f = $ac_func;
12996 #endif
12997
12998   ;
12999   return 0;
13000 }
13001 _ACEOF
13002 rm -f conftest.$ac_objext conftest$ac_exeext
13003 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13004   (eval $ac_link) 2>&5
13005   ac_status=$?
13006   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13007   (exit $ac_status); } &&
13008          { ac_try='test -s conftest$ac_exeext'
13009   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13010   (eval $ac_try) 2>&5
13011   ac_status=$?
13012   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13013   (exit $ac_status); }; }; then
13014   eval "$as_ac_var=yes"
13015 else
13016   echo "$as_me: failed program was:" >&5
13017 cat conftest.$ac_ext >&5
13018 eval "$as_ac_var=no"
13019 fi
13020 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13021 fi
13022 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13023 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13024 if test `eval echo '${'$as_ac_var'}'` = yes; then
13025   cat >>confdefs.h <<_ACEOF
13026 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13027 _ACEOF
13028
13029 fi
13030 done
13031
13032 fi
13033
13034
13035 echo "$as_me:$LINENO: checking for finite" >&5
13036 echo $ECHO_N "checking for finite... $ECHO_C" >&6
13037 cat >conftest.$ac_ext <<_ACEOF
13038 #line $LINENO "configure"
13039 #include "confdefs.h"
13040 #include <math.h>
13041 #ifdef F77_DUMMY_MAIN
13042 #  ifdef __cplusplus
13043      extern "C"
13044 #  endif
13045    int F77_DUMMY_MAIN() { return 1; }
13046 #endif
13047 int
13048 main ()
13049 {
13050 int dummy=finite(1.0);
13051   ;
13052   return 0;
13053 }
13054 _ACEOF
13055 rm -f conftest.$ac_objext conftest$ac_exeext
13056 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13057   (eval $ac_link) 2>&5
13058   ac_status=$?
13059   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13060   (exit $ac_status); } &&
13061          { ac_try='test -s conftest$ac_exeext'
13062   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13063   (eval $ac_try) 2>&5
13064   ac_status=$?
13065   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13066   (exit $ac_status); }; }; then
13067
13068 cat >>confdefs.h <<\_ACEOF
13069 #define HAVE_FINITE 1
13070 _ACEOF
13071
13072 echo "$as_me:$LINENO: result: yes" >&5
13073 echo "${ECHO_T}yes" >&6
13074 else
13075   echo "$as_me: failed program was:" >&5
13076 cat conftest.$ac_ext >&5
13077 echo "$as_me:$LINENO: result: no" >&5
13078 echo "${ECHO_T}no" >&6
13079 fi
13080 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13081
13082 echo "$as_me:$LINENO: checking for sigsetjmp" >&5
13083 echo $ECHO_N "checking for sigsetjmp... $ECHO_C" >&6
13084 cat >conftest.$ac_ext <<_ACEOF
13085 #line $LINENO "configure"
13086 #include "confdefs.h"
13087 #include <setjmp.h>
13088 #ifdef F77_DUMMY_MAIN
13089 #  ifdef __cplusplus
13090      extern "C"
13091 #  endif
13092    int F77_DUMMY_MAIN() { return 1; }
13093 #endif
13094 int
13095 main ()
13096 {
13097 sigjmp_buf x; sigsetjmp(x, 1);
13098   ;
13099   return 0;
13100 }
13101 _ACEOF
13102 rm -f conftest.$ac_objext conftest$ac_exeext
13103 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13104   (eval $ac_link) 2>&5
13105   ac_status=$?
13106   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13107   (exit $ac_status); } &&
13108          { ac_try='test -s conftest$ac_exeext'
13109   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13110   (eval $ac_try) 2>&5
13111   ac_status=$?
13112   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13113   (exit $ac_status); }; }; then
13114
13115 cat >>confdefs.h <<\_ACEOF
13116 #define HAVE_SIGSETJMP 1
13117 _ACEOF
13118
13119 echo "$as_me:$LINENO: result: yes" >&5
13120 echo "${ECHO_T}yes" >&6
13121 else
13122   echo "$as_me: failed program was:" >&5
13123 cat conftest.$ac_ext >&5
13124 echo "$as_me:$LINENO: result: no" >&5
13125 echo "${ECHO_T}no" >&6
13126 fi
13127 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13128
13129 echo "$as_me:$LINENO: checking for syslog" >&5
13130 echo $ECHO_N "checking for syslog... $ECHO_C" >&6
13131 if test "${ac_cv_func_syslog+set}" = set; then
13132   echo $ECHO_N "(cached) $ECHO_C" >&6
13133 else
13134   cat >conftest.$ac_ext <<_ACEOF
13135 #line $LINENO "configure"
13136 #include "confdefs.h"
13137 /* System header to define __stub macros and hopefully few prototypes,
13138     which can conflict with char syslog (); below.  */
13139 #include <assert.h>
13140 /* Override any gcc2 internal prototype to avoid an error.  */
13141 #ifdef __cplusplus
13142 extern "C"
13143 #endif
13144 /* We use char because int might match the return type of a gcc2
13145    builtin and then its argument prototype would still apply.  */
13146 char syslog ();
13147 char (*f) ();
13148
13149 #ifdef F77_DUMMY_MAIN
13150 #  ifdef __cplusplus
13151      extern "C"
13152 #  endif
13153    int F77_DUMMY_MAIN() { return 1; }
13154 #endif
13155 int
13156 main ()
13157 {
13158 /* The GNU C library defines this for functions which it implements
13159     to always fail with ENOSYS.  Some functions are actually named
13160     something starting with __ and the normal name is an alias.  */
13161 #if defined (__stub_syslog) || defined (__stub___syslog)
13162 choke me
13163 #else
13164 f = syslog;
13165 #endif
13166
13167   ;
13168   return 0;
13169 }
13170 _ACEOF
13171 rm -f conftest.$ac_objext conftest$ac_exeext
13172 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13173   (eval $ac_link) 2>&5
13174   ac_status=$?
13175   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13176   (exit $ac_status); } &&
13177          { ac_try='test -s conftest$ac_exeext'
13178   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13179   (eval $ac_try) 2>&5
13180   ac_status=$?
13181   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13182   (exit $ac_status); }; }; then
13183   ac_cv_func_syslog=yes
13184 else
13185   echo "$as_me: failed program was:" >&5
13186 cat conftest.$ac_ext >&5
13187 ac_cv_func_syslog=no
13188 fi
13189 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13190 fi
13191 echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
13192 echo "${ECHO_T}$ac_cv_func_syslog" >&6
13193 if test $ac_cv_func_syslog = yes; then
13194   if test "${ac_cv_header_syslog_h+set}" = set; then
13195   echo "$as_me:$LINENO: checking for syslog.h" >&5
13196 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
13197 if test "${ac_cv_header_syslog_h+set}" = set; then
13198   echo $ECHO_N "(cached) $ECHO_C" >&6
13199 fi
13200 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
13201 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
13202 else
13203   # Is the header compilable?
13204 echo "$as_me:$LINENO: checking syslog.h usability" >&5
13205 echo $ECHO_N "checking syslog.h usability... $ECHO_C" >&6
13206 cat >conftest.$ac_ext <<_ACEOF
13207 #line $LINENO "configure"
13208 #include "confdefs.h"
13209 $ac_includes_default
13210 #include <syslog.h>
13211 _ACEOF
13212 rm -f conftest.$ac_objext
13213 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13214   (eval $ac_compile) 2>&5
13215   ac_status=$?
13216   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13217   (exit $ac_status); } &&
13218          { ac_try='test -s conftest.$ac_objext'
13219   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13220   (eval $ac_try) 2>&5
13221   ac_status=$?
13222   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13223   (exit $ac_status); }; }; then
13224   ac_header_compiler=yes
13225 else
13226   echo "$as_me: failed program was:" >&5
13227 cat conftest.$ac_ext >&5
13228 ac_header_compiler=no
13229 fi
13230 rm -f conftest.$ac_objext conftest.$ac_ext
13231 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13232 echo "${ECHO_T}$ac_header_compiler" >&6
13233
13234 # Is the header present?
13235 echo "$as_me:$LINENO: checking syslog.h presence" >&5
13236 echo $ECHO_N "checking syslog.h presence... $ECHO_C" >&6
13237 cat >conftest.$ac_ext <<_ACEOF
13238 #line $LINENO "configure"
13239 #include "confdefs.h"
13240 #include <syslog.h>
13241 _ACEOF
13242 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
13243   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
13244   ac_status=$?
13245   egrep -v '^ *\+' conftest.er1 >conftest.err
13246   rm -f conftest.er1
13247   cat conftest.err >&5
13248   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13249   (exit $ac_status); } >/dev/null; then
13250   if test -s conftest.err; then
13251     ac_cpp_err=$ac_c_preproc_warn_flag
13252   else
13253     ac_cpp_err=
13254   fi
13255 else
13256   ac_cpp_err=yes
13257 fi
13258 if test -z "$ac_cpp_err"; then
13259   ac_header_preproc=yes
13260 else
13261   echo "$as_me: failed program was:" >&5
13262   cat conftest.$ac_ext >&5
13263   ac_header_preproc=no
13264 fi
13265 rm -f conftest.err conftest.$ac_ext
13266 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13267 echo "${ECHO_T}$ac_header_preproc" >&6
13268
13269 # So?  What about this header?
13270 case $ac_header_compiler:$ac_header_preproc in
13271   yes:no )
13272     { echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
13273 echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13274     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
13275 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;};;
13276   no:yes )
13277     { echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
13278 echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
13279     { echo "$as_me:$LINENO: WARNING: syslog.h: check for missing prerequisite headers?" >&5
13280 echo "$as_me: WARNING: syslog.h: check for missing prerequisite headers?" >&2;}
13281     { echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
13282 echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;};;
13283 esac
13284 echo "$as_me:$LINENO: checking for syslog.h" >&5
13285 echo $ECHO_N "checking for syslog.h... $ECHO_C" >&6
13286 if test "${ac_cv_header_syslog_h+set}" = set; then
13287   echo $ECHO_N "(cached) $ECHO_C" >&6
13288 else
13289   ac_cv_header_syslog_h=$ac_header_preproc
13290 fi
13291 echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
13292 echo "${ECHO_T}$ac_cv_header_syslog_h" >&6
13293
13294 fi
13295 if test $ac_cv_header_syslog_h = yes; then
13296
13297 cat >>confdefs.h <<\_ACEOF
13298 #define HAVE_SYSLOG 1
13299 _ACEOF
13300
13301 fi
13302
13303
13304 fi
13305
13306
13307 echo "$as_me:$LINENO: checking for optreset" >&5
13308 echo $ECHO_N "checking for optreset... $ECHO_C" >&6
13309 if test "${pgac_cv_var_int_optreset+set}" = set; then
13310   echo $ECHO_N "(cached) $ECHO_C" >&6
13311 else
13312   cat >conftest.$ac_ext <<_ACEOF
13313 #line $LINENO "configure"
13314 #include "confdefs.h"
13315 #include <unistd.h>
13316 #ifdef F77_DUMMY_MAIN
13317 #  ifdef __cplusplus
13318      extern "C"
13319 #  endif
13320    int F77_DUMMY_MAIN() { return 1; }
13321 #endif
13322 int
13323 main ()
13324 {
13325 extern int optreset; optreset = 1;
13326   ;
13327   return 0;
13328 }
13329 _ACEOF
13330 rm -f conftest.$ac_objext conftest$ac_exeext
13331 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13332   (eval $ac_link) 2>&5
13333   ac_status=$?
13334   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13335   (exit $ac_status); } &&
13336          { ac_try='test -s conftest$ac_exeext'
13337   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13338   (eval $ac_try) 2>&5
13339   ac_status=$?
13340   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13341   (exit $ac_status); }; }; then
13342   pgac_cv_var_int_optreset=yes
13343 else
13344   echo "$as_me: failed program was:" >&5
13345 cat conftest.$ac_ext >&5
13346 pgac_cv_var_int_optreset=no
13347 fi
13348 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13349 fi
13350 echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
13351 echo "${ECHO_T}$pgac_cv_var_int_optreset" >&6
13352 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
13353
13354 cat >>confdefs.h <<\_ACEOF
13355 #define HAVE_INT_OPTRESET 1
13356 _ACEOF
13357
13358 fi
13359
13360
13361
13362 for ac_func in strtoll strtoq
13363 do
13364 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13365 echo "$as_me:$LINENO: checking for $ac_func" >&5
13366 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13367 if eval "test \"\${$as_ac_var+set}\" = set"; then
13368   echo $ECHO_N "(cached) $ECHO_C" >&6
13369 else
13370   cat >conftest.$ac_ext <<_ACEOF
13371 #line $LINENO "configure"
13372 #include "confdefs.h"
13373 /* System header to define __stub macros and hopefully few prototypes,
13374     which can conflict with char $ac_func (); below.  */
13375 #include <assert.h>
13376 /* Override any gcc2 internal prototype to avoid an error.  */
13377 #ifdef __cplusplus
13378 extern "C"
13379 #endif
13380 /* We use char because int might match the return type of a gcc2
13381    builtin and then its argument prototype would still apply.  */
13382 char $ac_func ();
13383 char (*f) ();
13384
13385 #ifdef F77_DUMMY_MAIN
13386 #  ifdef __cplusplus
13387      extern "C"
13388 #  endif
13389    int F77_DUMMY_MAIN() { return 1; }
13390 #endif
13391 int
13392 main ()
13393 {
13394 /* The GNU C library defines this for functions which it implements
13395     to always fail with ENOSYS.  Some functions are actually named
13396     something starting with __ and the normal name is an alias.  */
13397 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13398 choke me
13399 #else
13400 f = $ac_func;
13401 #endif
13402
13403   ;
13404   return 0;
13405 }
13406 _ACEOF
13407 rm -f conftest.$ac_objext conftest$ac_exeext
13408 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13409   (eval $ac_link) 2>&5
13410   ac_status=$?
13411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13412   (exit $ac_status); } &&
13413          { ac_try='test -s conftest$ac_exeext'
13414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13415   (eval $ac_try) 2>&5
13416   ac_status=$?
13417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13418   (exit $ac_status); }; }; then
13419   eval "$as_ac_var=yes"
13420 else
13421   echo "$as_me: failed program was:" >&5
13422 cat conftest.$ac_ext >&5
13423 eval "$as_ac_var=no"
13424 fi
13425 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13426 fi
13427 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13428 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13429 if test `eval echo '${'$as_ac_var'}'` = yes; then
13430   cat >>confdefs.h <<_ACEOF
13431 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13432 _ACEOF
13433  break
13434 fi
13435 done
13436
13437
13438
13439 for ac_func in strtoull strtouq
13440 do
13441 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13442 echo "$as_me:$LINENO: checking for $ac_func" >&5
13443 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13444 if eval "test \"\${$as_ac_var+set}\" = set"; then
13445   echo $ECHO_N "(cached) $ECHO_C" >&6
13446 else
13447   cat >conftest.$ac_ext <<_ACEOF
13448 #line $LINENO "configure"
13449 #include "confdefs.h"
13450 /* System header to define __stub macros and hopefully few prototypes,
13451     which can conflict with char $ac_func (); below.  */
13452 #include <assert.h>
13453 /* Override any gcc2 internal prototype to avoid an error.  */
13454 #ifdef __cplusplus
13455 extern "C"
13456 #endif
13457 /* We use char because int might match the return type of a gcc2
13458    builtin and then its argument prototype would still apply.  */
13459 char $ac_func ();
13460 char (*f) ();
13461
13462 #ifdef F77_DUMMY_MAIN
13463 #  ifdef __cplusplus
13464      extern "C"
13465 #  endif
13466    int F77_DUMMY_MAIN() { return 1; }
13467 #endif
13468 int
13469 main ()
13470 {
13471 /* The GNU C library defines this for functions which it implements
13472     to always fail with ENOSYS.  Some functions are actually named
13473     something starting with __ and the normal name is an alias.  */
13474 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13475 choke me
13476 #else
13477 f = $ac_func;
13478 #endif
13479
13480   ;
13481   return 0;
13482 }
13483 _ACEOF
13484 rm -f conftest.$ac_objext conftest$ac_exeext
13485 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13486   (eval $ac_link) 2>&5
13487   ac_status=$?
13488   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13489   (exit $ac_status); } &&
13490          { ac_try='test -s conftest$ac_exeext'
13491   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13492   (eval $ac_try) 2>&5
13493   ac_status=$?
13494   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13495   (exit $ac_status); }; }; then
13496   eval "$as_ac_var=yes"
13497 else
13498   echo "$as_me: failed program was:" >&5
13499 cat conftest.$ac_ext >&5
13500 eval "$as_ac_var=no"
13501 fi
13502 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13503 fi
13504 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13505 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13506 if test `eval echo '${'$as_ac_var'}'` = yes; then
13507   cat >>confdefs.h <<_ACEOF
13508 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13509 _ACEOF
13510  break
13511 fi
13512 done
13513
13514
13515 # Check for one of atexit() or on_exit()
13516
13517 for ac_func in atexit
13518 do
13519 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13520 echo "$as_me:$LINENO: checking for $ac_func" >&5
13521 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13522 if eval "test \"\${$as_ac_var+set}\" = set"; then
13523   echo $ECHO_N "(cached) $ECHO_C" >&6
13524 else
13525   cat >conftest.$ac_ext <<_ACEOF
13526 #line $LINENO "configure"
13527 #include "confdefs.h"
13528 /* System header to define __stub macros and hopefully few prototypes,
13529     which can conflict with char $ac_func (); below.  */
13530 #include <assert.h>
13531 /* Override any gcc2 internal prototype to avoid an error.  */
13532 #ifdef __cplusplus
13533 extern "C"
13534 #endif
13535 /* We use char because int might match the return type of a gcc2
13536    builtin and then its argument prototype would still apply.  */
13537 char $ac_func ();
13538 char (*f) ();
13539
13540 #ifdef F77_DUMMY_MAIN
13541 #  ifdef __cplusplus
13542      extern "C"
13543 #  endif
13544    int F77_DUMMY_MAIN() { return 1; }
13545 #endif
13546 int
13547 main ()
13548 {
13549 /* The GNU C library defines this for functions which it implements
13550     to always fail with ENOSYS.  Some functions are actually named
13551     something starting with __ and the normal name is an alias.  */
13552 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13553 choke me
13554 #else
13555 f = $ac_func;
13556 #endif
13557
13558   ;
13559   return 0;
13560 }
13561 _ACEOF
13562 rm -f conftest.$ac_objext conftest$ac_exeext
13563 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13564   (eval $ac_link) 2>&5
13565   ac_status=$?
13566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13567   (exit $ac_status); } &&
13568          { ac_try='test -s conftest$ac_exeext'
13569   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13570   (eval $ac_try) 2>&5
13571   ac_status=$?
13572   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13573   (exit $ac_status); }; }; then
13574   eval "$as_ac_var=yes"
13575 else
13576   echo "$as_me: failed program was:" >&5
13577 cat conftest.$ac_ext >&5
13578 eval "$as_ac_var=no"
13579 fi
13580 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13581 fi
13582 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13583 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13584 if test `eval echo '${'$as_ac_var'}'` = yes; then
13585   cat >>confdefs.h <<_ACEOF
13586 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13587 _ACEOF
13588
13589 else
13590
13591 for ac_func in on_exit
13592 do
13593 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13594 echo "$as_me:$LINENO: checking for $ac_func" >&5
13595 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
13596 if eval "test \"\${$as_ac_var+set}\" = set"; then
13597   echo $ECHO_N "(cached) $ECHO_C" >&6
13598 else
13599   cat >conftest.$ac_ext <<_ACEOF
13600 #line $LINENO "configure"
13601 #include "confdefs.h"
13602 /* System header to define __stub macros and hopefully few prototypes,
13603     which can conflict with char $ac_func (); below.  */
13604 #include <assert.h>
13605 /* Override any gcc2 internal prototype to avoid an error.  */
13606 #ifdef __cplusplus
13607 extern "C"
13608 #endif
13609 /* We use char because int might match the return type of a gcc2
13610    builtin and then its argument prototype would still apply.  */
13611 char $ac_func ();
13612 char (*f) ();
13613
13614 #ifdef F77_DUMMY_MAIN
13615 #  ifdef __cplusplus
13616      extern "C"
13617 #  endif
13618    int F77_DUMMY_MAIN() { return 1; }
13619 #endif
13620 int
13621 main ()
13622 {
13623 /* The GNU C library defines this for functions which it implements
13624     to always fail with ENOSYS.  Some functions are actually named
13625     something starting with __ and the normal name is an alias.  */
13626 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
13627 choke me
13628 #else
13629 f = $ac_func;
13630 #endif
13631
13632   ;
13633   return 0;
13634 }
13635 _ACEOF
13636 rm -f conftest.$ac_objext conftest$ac_exeext
13637 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13638   (eval $ac_link) 2>&5
13639   ac_status=$?
13640   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13641   (exit $ac_status); } &&
13642          { ac_try='test -s conftest$ac_exeext'
13643   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13644   (eval $ac_try) 2>&5
13645   ac_status=$?
13646   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13647   (exit $ac_status); }; }; then
13648   eval "$as_ac_var=yes"
13649 else
13650   echo "$as_me: failed program was:" >&5
13651 cat conftest.$ac_ext >&5
13652 eval "$as_ac_var=no"
13653 fi
13654 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13655 fi
13656 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
13657 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
13658 if test `eval echo '${'$as_ac_var'}'` = yes; then
13659   cat >>confdefs.h <<_ACEOF
13660 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13661 _ACEOF
13662
13663 else
13664   { { echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
13665 echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
13666    { (exit 1); exit 1; }; }
13667 fi
13668 done
13669
13670 fi
13671 done
13672
13673
13674 echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13675 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
13676 if test "${ac_cv_sys_largefile_source+set}" = set; then
13677   echo $ECHO_N "(cached) $ECHO_C" >&6
13678 else
13679   while :; do
13680   ac_cv_sys_largefile_source=no
13681   cat >conftest.$ac_ext <<_ACEOF
13682 #line $LINENO "configure"
13683 #include "confdefs.h"
13684 #include <stdio.h>
13685 #ifdef F77_DUMMY_MAIN
13686 #  ifdef __cplusplus
13687      extern "C"
13688 #  endif
13689    int F77_DUMMY_MAIN() { return 1; }
13690 #endif
13691 int
13692 main ()
13693 {
13694 return !fseeko;
13695   ;
13696   return 0;
13697 }
13698 _ACEOF
13699 rm -f conftest.$ac_objext
13700 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13701   (eval $ac_compile) 2>&5
13702   ac_status=$?
13703   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13704   (exit $ac_status); } &&
13705          { ac_try='test -s conftest.$ac_objext'
13706   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13707   (eval $ac_try) 2>&5
13708   ac_status=$?
13709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13710   (exit $ac_status); }; }; then
13711   break
13712 else
13713   echo "$as_me: failed program was:" >&5
13714 cat conftest.$ac_ext >&5
13715 fi
13716 rm -f conftest.$ac_objext conftest.$ac_ext
13717   cat >conftest.$ac_ext <<_ACEOF
13718 #line $LINENO "configure"
13719 #include "confdefs.h"
13720 #define _LARGEFILE_SOURCE 1
13721 #include <stdio.h>
13722 #ifdef F77_DUMMY_MAIN
13723 #  ifdef __cplusplus
13724      extern "C"
13725 #  endif
13726    int F77_DUMMY_MAIN() { return 1; }
13727 #endif
13728 int
13729 main ()
13730 {
13731 return !fseeko;
13732   ;
13733   return 0;
13734 }
13735 _ACEOF
13736 rm -f conftest.$ac_objext
13737 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
13738   (eval $ac_compile) 2>&5
13739   ac_status=$?
13740   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13741   (exit $ac_status); } &&
13742          { ac_try='test -s conftest.$ac_objext'
13743   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13744   (eval $ac_try) 2>&5
13745   ac_status=$?
13746   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13747   (exit $ac_status); }; }; then
13748   ac_cv_sys_largefile_source=1; break
13749 else
13750   echo "$as_me: failed program was:" >&5
13751 cat conftest.$ac_ext >&5
13752 fi
13753 rm -f conftest.$ac_objext conftest.$ac_ext
13754   break
13755 done
13756 fi
13757 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
13758 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
13759 if test "$ac_cv_sys_largefile_source" != no; then
13760
13761 cat >>confdefs.h <<_ACEOF
13762 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13763 _ACEOF
13764
13765 fi
13766 rm -f conftest*
13767
13768 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13769 # in glibc 2.1.3, but that breaks too many other things.
13770 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13771 echo "$as_me:$LINENO: checking for fseeko" >&5
13772 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
13773 if test "${ac_cv_func_fseeko+set}" = set; then
13774   echo $ECHO_N "(cached) $ECHO_C" >&6
13775 else
13776   cat >conftest.$ac_ext <<_ACEOF
13777 #line $LINENO "configure"
13778 #include "confdefs.h"
13779 #include <stdio.h>
13780 #ifdef F77_DUMMY_MAIN
13781 #  ifdef __cplusplus
13782      extern "C"
13783 #  endif
13784    int F77_DUMMY_MAIN() { return 1; }
13785 #endif
13786 int
13787 main ()
13788 {
13789 return fseeko && fseeko (stdin, 0, 0);
13790   ;
13791   return 0;
13792 }
13793 _ACEOF
13794 rm -f conftest.$ac_objext conftest$ac_exeext
13795 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13796   (eval $ac_link) 2>&5
13797   ac_status=$?
13798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13799   (exit $ac_status); } &&
13800          { ac_try='test -s conftest$ac_exeext'
13801   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13802   (eval $ac_try) 2>&5
13803   ac_status=$?
13804   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13805   (exit $ac_status); }; }; then
13806   ac_cv_func_fseeko=yes
13807 else
13808   echo "$as_me: failed program was:" >&5
13809 cat conftest.$ac_ext >&5
13810 ac_cv_func_fseeko=no
13811 fi
13812 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13813 fi
13814 echo "$as_me:$LINENO: result: $ac_cv_func_fseeko" >&5
13815 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
13816 if test $ac_cv_func_fseeko = yes; then
13817
13818 cat >>confdefs.h <<\_ACEOF
13819 #define HAVE_FSEEKO 1
13820 _ACEOF
13821
13822 fi
13823
13824
13825 #
13826 # Pthreads
13827 #
13828 # For each platform, we need to know about any special compile and link
13829 # libraries, and whether the normal C function names are thread-safe.
13830 # See the comment at the top of src/port/thread.c for more information.
13831 #
13832 if test "$enable_thread_safety" = yes; then
13833
13834
13835
13836
13837 ac_ext=c
13838 ac_cpp='$CPP $CPPFLAGS'
13839 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
13840 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
13841 ac_compiler_gnu=$ac_cv_c_compiler_gnu
13842
13843 acx_pthread_ok=no
13844
13845 # We used to check for pthread.h first, but this fails if pthread.h
13846 # requires special compiler flags (e.g. on True64 or Sequent).
13847 # It gets checked for in the link test anyway.
13848
13849 # First of all, check if the user has set any of the PTHREAD_LIBS,
13850 # etcetera environment variables, and if threads linking works using
13851 # them:
13852 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
13853         save_CFLAGS="$CFLAGS"
13854         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
13855         save_LIBS="$LIBS"
13856         LIBS="$PTHREAD_LIBS $LIBS"
13857         echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
13858 echo $ECHO_N "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... $ECHO_C" >&6
13859         cat >conftest.$ac_ext <<_ACEOF
13860 #line $LINENO "configure"
13861 #include "confdefs.h"
13862
13863 /* Override any gcc2 internal prototype to avoid an error.  */
13864 #ifdef __cplusplus
13865 extern "C"
13866 #endif
13867 /* We use char because int might match the return type of a gcc2
13868    builtin and then its argument prototype would still apply.  */
13869 char pthread_join ();
13870 #ifdef F77_DUMMY_MAIN
13871 #  ifdef __cplusplus
13872      extern "C"
13873 #  endif
13874    int F77_DUMMY_MAIN() { return 1; }
13875 #endif
13876 int
13877 main ()
13878 {
13879 pthread_join ();
13880   ;
13881   return 0;
13882 }
13883 _ACEOF
13884 rm -f conftest.$ac_objext conftest$ac_exeext
13885 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
13886   (eval $ac_link) 2>&5
13887   ac_status=$?
13888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13889   (exit $ac_status); } &&
13890          { ac_try='test -s conftest$ac_exeext'
13891   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
13892   (eval $ac_try) 2>&5
13893   ac_status=$?
13894   echo "$as_me:$LINENO: \$? = $ac_status" >&5
13895   (exit $ac_status); }; }; then
13896   acx_pthread_ok=yes
13897 else
13898   echo "$as_me: failed program was:" >&5
13899 cat conftest.$ac_ext >&5
13900 fi
13901 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
13902         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
13903 echo "${ECHO_T}$acx_pthread_ok" >&6
13904         if test x"$acx_pthread_ok" = xno; then
13905                 PTHREAD_LIBS=""
13906                 PTHREAD_CFLAGS=""
13907         fi
13908         LIBS="$save_LIBS"
13909         CFLAGS="$save_CFLAGS"
13910 fi
13911
13912 # We must check for the threads library under a number of different
13913 # names; the ordering is very important because some systems
13914 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
13915 # libraries is broken (non-POSIX).
13916
13917 # Create a list of thread flags to try.  Items starting with a "-" are
13918 # C compiler flags, and other items are library names, except for "none"
13919 # which indicates that we try without any flags at all, and "pthread-config"
13920 # which is a program returning the flags for the Pth emulation library.
13921
13922 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
13923
13924 # The ordering *is* (sometimes) important.  Some notes on the
13925 # individual items follow:
13926
13927 # pthreads: AIX (must check this before -lpthread)
13928 # none: in case threads are in libc; should be tried before -Kthread and
13929 #       other compiler flags to prevent continual compiler warnings
13930 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
13931 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
13932 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
13933 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
13934 # -pthreads: Solaris/gcc
13935 # -mthreads: Mingw32/gcc, Lynx/gcc
13936 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
13937 #      doesn't hurt to check since this sometimes defines pthreads too;
13938 #      also defines -D_REENTRANT)
13939 # pthread: Linux, etcetera
13940 # --thread-safe: KAI C++
13941 # pthread-config: use pthread-config program (for GNU Pth library)
13942
13943 case "${host_cpu}-${host_os}" in
13944         *solaris*)
13945
13946         # On Solaris (at least, for some versions), libc contains stubbed
13947         # (non-functional) versions of the pthreads routines, so link-based
13948         # tests will erroneously succeed.  (We need to link with -pthread or
13949         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
13950         # a function called by this macro, so we could check for that, but
13951         # who knows whether they'll stub that too in a future libc.)  So,
13952         # we'll just look for -pthreads and -lpthread first:
13953
13954         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
13955         ;;
13956 esac
13957
13958 if test x"$acx_pthread_ok" = xno; then
13959 for flag in $acx_pthread_flags; do
13960
13961         tryPTHREAD_CFLAGS=""
13962         tryPTHREAD_LIBS=""
13963         case $flag in
13964                 none)
13965                 echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
13966 echo $ECHO_N "checking whether pthreads work without any flags... $ECHO_C" >&6
13967                 ;;
13968
13969                 -*)
13970                 echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
13971 echo $ECHO_N "checking whether pthreads work with $flag... $ECHO_C" >&6
13972                 tryPTHREAD_CFLAGS="$flag"
13973                 ;;
13974
13975                 pthread-config)
13976                 # skip this if we already have flags defined, for PostgreSQL
13977                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
13978                 # Extract the first word of "pthread-config", so it can be a program name with args.
13979 set dummy pthread-config; ac_word=$2
13980 echo "$as_me:$LINENO: checking for $ac_word" >&5
13981 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
13982 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
13983   echo $ECHO_N "(cached) $ECHO_C" >&6
13984 else
13985   if test -n "$acx_pthread_config"; then
13986   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
13987 else
13988 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13989 for as_dir in $PATH
13990 do
13991   IFS=$as_save_IFS
13992   test -z "$as_dir" && as_dir=.
13993   for ac_exec_ext in '' $ac_executable_extensions; do
13994   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
13995     ac_cv_prog_acx_pthread_config="yes"
13996     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
13997     break 2
13998   fi
13999 done
14000 done
14001
14002   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
14003 fi
14004 fi
14005 acx_pthread_config=$ac_cv_prog_acx_pthread_config
14006 if test -n "$acx_pthread_config"; then
14007   echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
14008 echo "${ECHO_T}$acx_pthread_config" >&6
14009 else
14010   echo "$as_me:$LINENO: result: no" >&5
14011 echo "${ECHO_T}no" >&6
14012 fi
14013
14014                 if test x"$acx_pthread_config" = xno; then continue; fi
14015                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
14016                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
14017                 ;;
14018
14019                 *)
14020                 echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
14021 echo $ECHO_N "checking for the pthreads library -l$flag... $ECHO_C" >&6
14022                 tryPTHREAD_LIBS="-l$flag"
14023                 ;;
14024         esac
14025
14026         save_LIBS="$LIBS"
14027         save_CFLAGS="$CFLAGS"
14028         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
14029         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
14030
14031         # Check for various functions.  We must include pthread.h,
14032         # since some functions may be macros.  (On the Sequent, we
14033         # need a special flag -Kthread to make this header compile.)
14034         # We check for pthread_join because it is in -lpthread on IRIX
14035         # while pthread_create is in libc.  We check for pthread_attr_init
14036         # due to DEC craziness with -lpthreads.  We check for
14037         # pthread_cleanup_push because it is one of the few pthread
14038         # functions on Solaris that doesn't have a non-functional libc stub.
14039         # We try pthread_create on general principles.
14040         cat >conftest.$ac_ext <<_ACEOF
14041 #line $LINENO "configure"
14042 #include "confdefs.h"
14043 #include <pthread.h>
14044 #ifdef F77_DUMMY_MAIN
14045 #  ifdef __cplusplus
14046      extern "C"
14047 #  endif
14048    int F77_DUMMY_MAIN() { return 1; }
14049 #endif
14050 int
14051 main ()
14052 {
14053 pthread_t th; pthread_join(th, 0);
14054                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
14055                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
14056   ;
14057   return 0;
14058 }
14059 _ACEOF
14060 rm -f conftest.$ac_objext conftest$ac_exeext
14061 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14062   (eval $ac_link) 2>&5
14063   ac_status=$?
14064   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14065   (exit $ac_status); } &&
14066          { ac_try='test -s conftest$ac_exeext'
14067   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14068   (eval $ac_try) 2>&5
14069   ac_status=$?
14070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14071   (exit $ac_status); }; }; then
14072   acx_pthread_ok=yes
14073 else
14074   echo "$as_me: failed program was:" >&5
14075 cat conftest.$ac_ext >&5
14076 acx_pthread_ok=no
14077 fi
14078 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14079
14080         if test "x$acx_pthread_ok" = xyes; then
14081             # Don't use options that are ignored by the compiler.
14082             # We find them by checking stderror.
14083             cat >conftest.$ac_ext <<_ACEOF
14084 int
14085 main (int argc, char **argv)
14086 {
14087   (void) argc;
14088   (void) argv;
14089   return 0;
14090 }
14091 _ACEOF
14092             rm -f conftest.$ac_objext conftest$ac_exeext
14093             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
14094                 # we continue with more flags because Linux needs -lpthread
14095                 # for libpq builds on PostgreSQL.  The test above only
14096                 # tests for building binaries, not shared libraries.
14097                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
14098                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
14099             else   acx_pthread_ok=no
14100             fi
14101         fi
14102
14103         LIBS="$save_LIBS"
14104         CFLAGS="$save_CFLAGS"
14105
14106         echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
14107 echo "${ECHO_T}$acx_pthread_ok" >&6
14108 done
14109 fi
14110
14111 # Various other checks:
14112 if test "x$acx_pthread_ok" = xyes; then
14113         save_LIBS="$LIBS"
14114         LIBS="$PTHREAD_LIBS $LIBS"
14115         save_CFLAGS="$CFLAGS"
14116         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
14117
14118         # Detect AIX lossage: threads are created detached by default
14119         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
14120         echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
14121 echo $ECHO_N "checking for joinable pthread attribute... $ECHO_C" >&6
14122         cat >conftest.$ac_ext <<_ACEOF
14123 #line $LINENO "configure"
14124 #include "confdefs.h"
14125 #include <pthread.h>
14126 #ifdef F77_DUMMY_MAIN
14127 #  ifdef __cplusplus
14128      extern "C"
14129 #  endif
14130    int F77_DUMMY_MAIN() { return 1; }
14131 #endif
14132 int
14133 main ()
14134 {
14135 int attr=PTHREAD_CREATE_JOINABLE;
14136   ;
14137   return 0;
14138 }
14139 _ACEOF
14140 rm -f conftest.$ac_objext conftest$ac_exeext
14141 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14142   (eval $ac_link) 2>&5
14143   ac_status=$?
14144   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14145   (exit $ac_status); } &&
14146          { ac_try='test -s conftest$ac_exeext'
14147   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14148   (eval $ac_try) 2>&5
14149   ac_status=$?
14150   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14151   (exit $ac_status); }; }; then
14152   ok=PTHREAD_CREATE_JOINABLE
14153 else
14154   echo "$as_me: failed program was:" >&5
14155 cat conftest.$ac_ext >&5
14156 ok=unknown
14157 fi
14158 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14159         if test x"$ok" = xunknown; then
14160                 cat >conftest.$ac_ext <<_ACEOF
14161 #line $LINENO "configure"
14162 #include "confdefs.h"
14163 #include <pthread.h>
14164 #ifdef F77_DUMMY_MAIN
14165 #  ifdef __cplusplus
14166      extern "C"
14167 #  endif
14168    int F77_DUMMY_MAIN() { return 1; }
14169 #endif
14170 int
14171 main ()
14172 {
14173 int attr=PTHREAD_CREATE_UNDETACHED;
14174   ;
14175   return 0;
14176 }
14177 _ACEOF
14178 rm -f conftest.$ac_objext conftest$ac_exeext
14179 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14180   (eval $ac_link) 2>&5
14181   ac_status=$?
14182   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14183   (exit $ac_status); } &&
14184          { ac_try='test -s conftest$ac_exeext'
14185   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14186   (eval $ac_try) 2>&5
14187   ac_status=$?
14188   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14189   (exit $ac_status); }; }; then
14190   ok=PTHREAD_CREATE_UNDETACHED
14191 else
14192   echo "$as_me: failed program was:" >&5
14193 cat conftest.$ac_ext >&5
14194 ok=unknown
14195 fi
14196 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14197         fi
14198         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
14199
14200 cat >>confdefs.h <<\_ACEOF
14201 #define PTHREAD_CREATE_JOINABLE $ok
14202 _ACEOF
14203
14204         fi
14205         echo "$as_me:$LINENO: result: ${ok}" >&5
14206 echo "${ECHO_T}${ok}" >&6
14207         if test x"$ok" = xunknown; then
14208                 { echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
14209 echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
14210         fi
14211
14212         echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
14213 echo $ECHO_N "checking if more special flags are required for pthreads... $ECHO_C" >&6
14214         flag=no
14215 # We always add these in PostgreSQL
14216 #       case "${host_cpu}-${host_os}" in
14217 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
14218 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
14219 #       esac
14220         echo "$as_me:$LINENO: result: ${flag}" >&5
14221 echo "${ECHO_T}${flag}" >&6
14222         if test "x$flag" != xno; then
14223                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
14224         fi
14225
14226         LIBS="$save_LIBS"
14227         CFLAGS="$save_CFLAGS"
14228
14229 # Supporting cc_r would require a special CC in all places that
14230 # use libpq, and that is ugly, so we don't do it.  Users can still
14231 # define their compiler as cc_r to do thread builds of everything.
14232         # More AIX lossage: must compile with cc_r
14233         # Extract the first word of "cc_r", so it can be a program name with args.
14234 set dummy cc_r; ac_word=$2
14235 echo "$as_me:$LINENO: checking for $ac_word" >&5
14236 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
14237 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
14238   echo $ECHO_N "(cached) $ECHO_C" >&6
14239 else
14240   if test -n "$PTHREAD_CC"; then
14241   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
14242 else
14243 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14244 for as_dir in $PATH
14245 do
14246   IFS=$as_save_IFS
14247   test -z "$as_dir" && as_dir=.
14248   for ac_exec_ext in '' $ac_executable_extensions; do
14249   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
14250     ac_cv_prog_PTHREAD_CC="cc_r"
14251     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
14252     break 2
14253   fi
14254 done
14255 done
14256
14257   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
14258 fi
14259 fi
14260 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
14261 if test -n "$PTHREAD_CC"; then
14262   echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
14263 echo "${ECHO_T}$PTHREAD_CC" >&6
14264 else
14265   echo "$as_me:$LINENO: result: no" >&5
14266 echo "${ECHO_T}no" >&6
14267 fi
14268
14269 else
14270         PTHREAD_CC="$CC"
14271 fi
14272
14273
14274
14275
14276
14277 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
14278 if test x"$acx_pthread_ok" = xyes; then
14279
14280 cat >>confdefs.h <<\_ACEOF
14281 #define HAVE_PTHREAD 1
14282 _ACEOF
14283
14284         :
14285 else
14286         acx_pthread_ok=no
14287
14288 fi
14289 ac_ext=c
14290 ac_cpp='$CPP $CPPFLAGS'
14291 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
14292 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
14293 ac_compiler_gnu=$ac_cv_c_compiler_gnu
14294
14295         # set thread flags
14296
14297 # Some platforms use these, so just defineed them.  They can't hurt if they
14298 # are not supported.
14299 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
14300
14301
14302 # At this point, we don't want to muck with the compiler name for threading.
14303 # Let's see who fails, perhaps AIX.  2004-04-23
14304 if test "$PTHREAD_CC" != "$CC"; then
14305 { { echo "$as_me:$LINENO: error:
14306 PostgreSQL does not support platforms that require a special
14307 compiler binary for thread-safety.
14308 " >&5
14309 echo "$as_me: error:
14310 PostgreSQL does not support platforms that require a special
14311 compiler binary for thread-safety.
14312 " >&2;}
14313    { (exit 1); exit 1; }; }
14314 fi
14315
14316 if test "$THREAD_SUPPORT" = no; then
14317 { { echo "$as_me:$LINENO: error:
14318 Cannot enable threads on your platform.
14319 Your platform is known to not support thread-safe programs.
14320 For details, compile and run src/bin/pg_thread_test.
14321 " >&5
14322 echo "$as_me: error:
14323 Cannot enable threads on your platform.
14324 Your platform is known to not support thread-safe programs.
14325 For details, compile and run src/bin/pg_thread_test.
14326 " >&2;}
14327    { (exit 1); exit 1; }; }
14328 fi
14329
14330 # Check for *_r functions
14331 _CFLAGS="$CFLAGS"
14332 _LIBS="$LIBS"
14333 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
14334 LIBS="$LIBS $PTHREAD_LIBS"
14335
14336 if test "${ac_cv_header_pthread_h+set}" = set; then
14337   echo "$as_me:$LINENO: checking for pthread.h" >&5
14338 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
14339 if test "${ac_cv_header_pthread_h+set}" = set; then
14340   echo $ECHO_N "(cached) $ECHO_C" >&6
14341 fi
14342 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
14343 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
14344 else
14345   # Is the header compilable?
14346 echo "$as_me:$LINENO: checking pthread.h usability" >&5
14347 echo $ECHO_N "checking pthread.h usability... $ECHO_C" >&6
14348 cat >conftest.$ac_ext <<_ACEOF
14349 #line $LINENO "configure"
14350 #include "confdefs.h"
14351 $ac_includes_default
14352 #include <pthread.h>
14353 _ACEOF
14354 rm -f conftest.$ac_objext
14355 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14356   (eval $ac_compile) 2>&5
14357   ac_status=$?
14358   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14359   (exit $ac_status); } &&
14360          { ac_try='test -s conftest.$ac_objext'
14361   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14362   (eval $ac_try) 2>&5
14363   ac_status=$?
14364   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14365   (exit $ac_status); }; }; then
14366   ac_header_compiler=yes
14367 else
14368   echo "$as_me: failed program was:" >&5
14369 cat conftest.$ac_ext >&5
14370 ac_header_compiler=no
14371 fi
14372 rm -f conftest.$ac_objext conftest.$ac_ext
14373 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14374 echo "${ECHO_T}$ac_header_compiler" >&6
14375
14376 # Is the header present?
14377 echo "$as_me:$LINENO: checking pthread.h presence" >&5
14378 echo $ECHO_N "checking pthread.h presence... $ECHO_C" >&6
14379 cat >conftest.$ac_ext <<_ACEOF
14380 #line $LINENO "configure"
14381 #include "confdefs.h"
14382 #include <pthread.h>
14383 _ACEOF
14384 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
14385   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
14386   ac_status=$?
14387   egrep -v '^ *\+' conftest.er1 >conftest.err
14388   rm -f conftest.er1
14389   cat conftest.err >&5
14390   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14391   (exit $ac_status); } >/dev/null; then
14392   if test -s conftest.err; then
14393     ac_cpp_err=$ac_c_preproc_warn_flag
14394   else
14395     ac_cpp_err=
14396   fi
14397 else
14398   ac_cpp_err=yes
14399 fi
14400 if test -z "$ac_cpp_err"; then
14401   ac_header_preproc=yes
14402 else
14403   echo "$as_me: failed program was:" >&5
14404   cat conftest.$ac_ext >&5
14405   ac_header_preproc=no
14406 fi
14407 rm -f conftest.err conftest.$ac_ext
14408 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14409 echo "${ECHO_T}$ac_header_preproc" >&6
14410
14411 # So?  What about this header?
14412 case $ac_header_compiler:$ac_header_preproc in
14413   yes:no )
14414     { echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
14415 echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
14416     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
14417 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;};;
14418   no:yes )
14419     { echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
14420 echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
14421     { echo "$as_me:$LINENO: WARNING: pthread.h: check for missing prerequisite headers?" >&5
14422 echo "$as_me: WARNING: pthread.h: check for missing prerequisite headers?" >&2;}
14423     { echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
14424 echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;};;
14425 esac
14426 echo "$as_me:$LINENO: checking for pthread.h" >&5
14427 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
14428 if test "${ac_cv_header_pthread_h+set}" = set; then
14429   echo $ECHO_N "(cached) $ECHO_C" >&6
14430 else
14431   ac_cv_header_pthread_h=$ac_header_preproc
14432 fi
14433 echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
14434 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
14435
14436 fi
14437 if test $ac_cv_header_pthread_h = yes; then
14438   :
14439 else
14440   { { echo "$as_me:$LINENO: error: pthread.h not found, required for --enable-thread-safety" >&5
14441 echo "$as_me: error: pthread.h not found, required for --enable-thread-safety" >&2;}
14442    { (exit 1); exit 1; }; }
14443 fi
14444
14445
14446
14447
14448
14449
14450 for ac_func in strerror_r getpwuid_r gethostbyname_r
14451 do
14452 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14453 echo "$as_me:$LINENO: checking for $ac_func" >&5
14454 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
14455 if eval "test \"\${$as_ac_var+set}\" = set"; then
14456   echo $ECHO_N "(cached) $ECHO_C" >&6
14457 else
14458   cat >conftest.$ac_ext <<_ACEOF
14459 #line $LINENO "configure"
14460 #include "confdefs.h"
14461 /* System header to define __stub macros and hopefully few prototypes,
14462     which can conflict with char $ac_func (); below.  */
14463 #include <assert.h>
14464 /* Override any gcc2 internal prototype to avoid an error.  */
14465 #ifdef __cplusplus
14466 extern "C"
14467 #endif
14468 /* We use char because int might match the return type of a gcc2
14469    builtin and then its argument prototype would still apply.  */
14470 char $ac_func ();
14471 char (*f) ();
14472
14473 #ifdef F77_DUMMY_MAIN
14474 #  ifdef __cplusplus
14475      extern "C"
14476 #  endif
14477    int F77_DUMMY_MAIN() { return 1; }
14478 #endif
14479 int
14480 main ()
14481 {
14482 /* The GNU C library defines this for functions which it implements
14483     to always fail with ENOSYS.  Some functions are actually named
14484     something starting with __ and the normal name is an alias.  */
14485 #if defined (__stub_$ac_func) || defined (__stub___$ac_func)
14486 choke me
14487 #else
14488 f = $ac_func;
14489 #endif
14490
14491   ;
14492   return 0;
14493 }
14494 _ACEOF
14495 rm -f conftest.$ac_objext conftest$ac_exeext
14496 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14497   (eval $ac_link) 2>&5
14498   ac_status=$?
14499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14500   (exit $ac_status); } &&
14501          { ac_try='test -s conftest$ac_exeext'
14502   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14503   (eval $ac_try) 2>&5
14504   ac_status=$?
14505   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14506   (exit $ac_status); }; }; then
14507   eval "$as_ac_var=yes"
14508 else
14509   echo "$as_me: failed program was:" >&5
14510 cat conftest.$ac_ext >&5
14511 eval "$as_ac_var=no"
14512 fi
14513 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
14514 fi
14515 echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
14516 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
14517 if test `eval echo '${'$as_ac_var'}'` = yes; then
14518   cat >>confdefs.h <<_ACEOF
14519 #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14520 _ACEOF
14521
14522 fi
14523 done
14524
14525
14526 # Do test here with the proper thread flags
14527 echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
14528 echo $ECHO_N "checking whether getpwuid_r takes a fifth argument... $ECHO_C" >&6
14529 if test "${pgac_func_getpwuid_r_5arg+set}" = set; then
14530   echo $ECHO_N "(cached) $ECHO_C" >&6
14531 else
14532   cat >conftest.$ac_ext <<_ACEOF
14533 #line $LINENO "configure"
14534 #include "confdefs.h"
14535 #include <sys/types.h>
14536 #include <pwd.h>
14537 #ifdef F77_DUMMY_MAIN
14538 #  ifdef __cplusplus
14539      extern "C"
14540 #  endif
14541    int F77_DUMMY_MAIN() { return 1; }
14542 #endif
14543 int
14544 main ()
14545 {
14546 uid_t uid;
14547 struct passwd *space;
14548 char *buf;
14549 size_t bufsize;
14550 struct passwd **result;
14551 getpwuid_r(uid, space, buf, bufsize, result);
14552   ;
14553   return 0;
14554 }
14555 _ACEOF
14556 rm -f conftest.$ac_objext
14557 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14558   (eval $ac_compile) 2>&5
14559   ac_status=$?
14560   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14561   (exit $ac_status); } &&
14562          { ac_try='test -s conftest.$ac_objext'
14563   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14564   (eval $ac_try) 2>&5
14565   ac_status=$?
14566   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14567   (exit $ac_status); }; }; then
14568   pgac_func_getpwuid_r_5arg=yes
14569 else
14570   echo "$as_me: failed program was:" >&5
14571 cat conftest.$ac_ext >&5
14572 pgac_func_getpwuid_r_5arg=no
14573 fi
14574 rm -f conftest.$ac_objext conftest.$ac_ext
14575 fi
14576 echo "$as_me:$LINENO: result: $pgac_func_getpwuid_r_5arg" >&5
14577 echo "${ECHO_T}$pgac_func_getpwuid_r_5arg" >&6
14578 if test x"$pgac_func_getpwuid_r_5arg" = xyes ; then
14579
14580 cat >>confdefs.h <<\_ACEOF
14581 #define GETPWUID_R_5ARG
14582 _ACEOF
14583
14584 fi
14585
14586 echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
14587 echo $ECHO_N "checking whether strerror_r returns int... $ECHO_C" >&6
14588 if test "${pgac_func_strerror_r_int+set}" = set; then
14589   echo $ECHO_N "(cached) $ECHO_C" >&6
14590 else
14591   cat >conftest.$ac_ext <<_ACEOF
14592 #line $LINENO "configure"
14593 #include "confdefs.h"
14594 #include <string.h>
14595 #ifdef F77_DUMMY_MAIN
14596 #  ifdef __cplusplus
14597      extern "C"
14598 #  endif
14599    int F77_DUMMY_MAIN() { return 1; }
14600 #endif
14601 int
14602 main ()
14603 {
14604 #ifndef _AIX
14605 int strerror_r(int, char *, size_t);
14606 #else
14607 /* Older AIX has 'int' for the third argument so we don't test the args. */
14608 int strerror_r();
14609 #endif
14610   ;
14611   return 0;
14612 }
14613 _ACEOF
14614 rm -f conftest.$ac_objext
14615 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14616   (eval $ac_compile) 2>&5
14617   ac_status=$?
14618   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14619   (exit $ac_status); } &&
14620          { ac_try='test -s conftest.$ac_objext'
14621   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14622   (eval $ac_try) 2>&5
14623   ac_status=$?
14624   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14625   (exit $ac_status); }; }; then
14626   pgac_func_strerror_r_int=yes
14627 else
14628   echo "$as_me: failed program was:" >&5
14629 cat conftest.$ac_ext >&5
14630 pgac_func_strerror_r_int=no
14631 fi
14632 rm -f conftest.$ac_objext conftest.$ac_ext
14633 fi
14634 echo "$as_me:$LINENO: result: $pgac_func_strerror_r_int" >&5
14635 echo "${ECHO_T}$pgac_func_strerror_r_int" >&6
14636 if test x"$pgac_func_strerror_r_int" = xyes ; then
14637
14638 cat >>confdefs.h <<\_ACEOF
14639 #define STRERROR_R_INT
14640 _ACEOF
14641
14642 fi
14643
14644
14645 CFLAGS="$_CFLAGS"
14646 LIBS="$_LIBS"
14647
14648 else
14649 # do not use values from template file
14650 PTHREAD_CFLAGS=
14651 PTHREAD_LIBS=
14652 fi
14653
14654
14655
14656
14657
14658 # This test makes sure that run tests work at all.  Sometimes a shared
14659 # library is found by the linker, but the runtime linker can't find it.
14660 # This check should come after all modifications of compiler or linker
14661 # variables, and before any other run tests.
14662 echo "$as_me:$LINENO: checking test program" >&5
14663 echo $ECHO_N "checking test program... $ECHO_C" >&6
14664 if test "$cross_compiling" = yes; then
14665   echo "$as_me:$LINENO: result: cross-compiling" >&5
14666 echo "${ECHO_T}cross-compiling" >&6
14667 else
14668   cat >conftest.$ac_ext <<_ACEOF
14669 #line $LINENO "configure"
14670 #include "confdefs.h"
14671 int main() { return 0; }
14672 _ACEOF
14673 rm -f conftest$ac_exeext
14674 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14675   (eval $ac_link) 2>&5
14676   ac_status=$?
14677   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14678   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14679   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14680   (eval $ac_try) 2>&5
14681   ac_status=$?
14682   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14683   (exit $ac_status); }; }; then
14684   echo "$as_me:$LINENO: result: ok" >&5
14685 echo "${ECHO_T}ok" >&6
14686 else
14687   echo "$as_me: program exited with status $ac_status" >&5
14688 echo "$as_me: failed program was:" >&5
14689 cat conftest.$ac_ext >&5
14690 ( exit $ac_status )
14691 echo "$as_me:$LINENO: result: failed" >&5
14692 echo "${ECHO_T}failed" >&6
14693 { { echo "$as_me:$LINENO: error:
14694 *** Could not execute a simple test program.  This may be a problem
14695 *** related to locating shared libraries.  Check the file 'config.log'
14696 *** for the exact reason." >&5
14697 echo "$as_me: error:
14698 *** Could not execute a simple test program.  This may be a problem
14699 *** related to locating shared libraries.  Check the file 'config.log'
14700 *** for the exact reason." >&2;}
14701    { (exit 1); exit 1; }; }
14702 fi
14703 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14704 fi
14705
14706
14707 # Force use of our snprintf if system's doesn't do arg control
14708 # This feature is used by NLS
14709 if test "$enable_nls" = yes &&
14710    test $pgac_need_repl_snprintf = no &&
14711 # On Win32, libintl replaces snprintf() with its own version that
14712 # understands arg control, so we don't need our own.  In fact, it
14713 # also uses macros that conflict with ours, so we _can't_ use
14714 # our own.
14715    test "$PORTNAME" != "win32"; then
14716   echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
14717 echo $ECHO_N "checking whether printf supports argument control... $ECHO_C" >&6
14718 if test "${pgac_cv_printf_arg_control+set}" = set; then
14719   echo $ECHO_N "(cached) $ECHO_C" >&6
14720 else
14721   if test "$cross_compiling" = yes; then
14722   pgac_cv_printf_arg_control=cross
14723 else
14724   cat >conftest.$ac_ext <<_ACEOF
14725 #line $LINENO "configure"
14726 #include "confdefs.h"
14727 #include <stdio.h>
14728 #include <string.h>
14729
14730 int main()
14731 {
14732   char buf[100];
14733
14734   /* can it swap arguments? */
14735   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
14736   if (strcmp(buf, "4 3") != 0)
14737     return 1;
14738   return 0;
14739 }
14740 _ACEOF
14741 rm -f conftest$ac_exeext
14742 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14743   (eval $ac_link) 2>&5
14744   ac_status=$?
14745   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14746   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14747   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14748   (eval $ac_try) 2>&5
14749   ac_status=$?
14750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14751   (exit $ac_status); }; }; then
14752   pgac_cv_printf_arg_control=yes
14753 else
14754   echo "$as_me: program exited with status $ac_status" >&5
14755 echo "$as_me: failed program was:" >&5
14756 cat conftest.$ac_ext >&5
14757 ( exit $ac_status )
14758 pgac_cv_printf_arg_control=no
14759 fi
14760 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14761 fi
14762
14763 fi
14764 echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
14765 echo "${ECHO_T}$pgac_cv_printf_arg_control" >&6
14766
14767   if test $pgac_cv_printf_arg_control != yes ; then
14768     pgac_need_repl_snprintf=yes
14769   fi
14770 fi
14771
14772
14773
14774 echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
14775 echo $ECHO_N "checking whether long int is 64 bits... $ECHO_C" >&6
14776 if test "${pgac_cv_type_long_int_64+set}" = set; then
14777   echo $ECHO_N "(cached) $ECHO_C" >&6
14778 else
14779   if test "$cross_compiling" = yes; then
14780   # If cross-compiling, check the size reported by the compiler and
14781 # trust that the arithmetic works.
14782 cat >conftest.$ac_ext <<_ACEOF
14783 #line $LINENO "configure"
14784 #include "confdefs.h"
14785
14786 #ifdef F77_DUMMY_MAIN
14787 #  ifdef __cplusplus
14788      extern "C"
14789 #  endif
14790    int F77_DUMMY_MAIN() { return 1; }
14791 #endif
14792 int
14793 main ()
14794 {
14795 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
14796 test_array [0] = 0
14797
14798   ;
14799   return 0;
14800 }
14801 _ACEOF
14802 rm -f conftest.$ac_objext
14803 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14804   (eval $ac_compile) 2>&5
14805   ac_status=$?
14806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14807   (exit $ac_status); } &&
14808          { ac_try='test -s conftest.$ac_objext'
14809   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14810   (eval $ac_try) 2>&5
14811   ac_status=$?
14812   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14813   (exit $ac_status); }; }; then
14814   pgac_cv_type_long_int_64=yes
14815 else
14816   echo "$as_me: failed program was:" >&5
14817 cat conftest.$ac_ext >&5
14818 pgac_cv_type_long_int_64=no
14819 fi
14820 rm -f conftest.$ac_objext conftest.$ac_ext
14821 else
14822   cat >conftest.$ac_ext <<_ACEOF
14823 #line $LINENO "configure"
14824 #include "confdefs.h"
14825 typedef long int ac_int64;
14826
14827 /*
14828  * These are globals to discourage the compiler from folding all the
14829  * arithmetic tests down to compile-time constants.
14830  */
14831 ac_int64 a = 20000001;
14832 ac_int64 b = 40000005;
14833
14834 int does_int64_work()
14835 {
14836   ac_int64 c,d;
14837
14838   if (sizeof(ac_int64) != 8)
14839     return 0;                   /* definitely not the right size */
14840
14841   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
14842   c = a * b;
14843   d = (c + b) / b;
14844   if (d != a+1)
14845     return 0;
14846   return 1;
14847 }
14848 main() {
14849   exit(! does_int64_work());
14850 }
14851 _ACEOF
14852 rm -f conftest$ac_exeext
14853 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14854   (eval $ac_link) 2>&5
14855   ac_status=$?
14856   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14857   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14858   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14859   (eval $ac_try) 2>&5
14860   ac_status=$?
14861   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14862   (exit $ac_status); }; }; then
14863   pgac_cv_type_long_int_64=yes
14864 else
14865   echo "$as_me: program exited with status $ac_status" >&5
14866 echo "$as_me: failed program was:" >&5
14867 cat conftest.$ac_ext >&5
14868 ( exit $ac_status )
14869 pgac_cv_type_long_int_64=no
14870 fi
14871 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14872 fi
14873 fi
14874 echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
14875 echo "${ECHO_T}$pgac_cv_type_long_int_64" >&6
14876
14877 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
14878 if test x"$pgac_cv_type_long_int_64" = xyes ; then
14879
14880 cat >>confdefs.h <<\_ACEOF
14881 #define HAVE_LONG_INT_64
14882 _ACEOF
14883
14884 fi
14885
14886
14887 if test x"$HAVE_LONG_INT_64" = x"no" ; then
14888   echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
14889 echo $ECHO_N "checking whether long long int is 64 bits... $ECHO_C" >&6
14890 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
14891   echo $ECHO_N "(cached) $ECHO_C" >&6
14892 else
14893   if test "$cross_compiling" = yes; then
14894   # If cross-compiling, check the size reported by the compiler and
14895 # trust that the arithmetic works.
14896 cat >conftest.$ac_ext <<_ACEOF
14897 #line $LINENO "configure"
14898 #include "confdefs.h"
14899
14900 #ifdef F77_DUMMY_MAIN
14901 #  ifdef __cplusplus
14902      extern "C"
14903 #  endif
14904    int F77_DUMMY_MAIN() { return 1; }
14905 #endif
14906 int
14907 main ()
14908 {
14909 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
14910 test_array [0] = 0
14911
14912   ;
14913   return 0;
14914 }
14915 _ACEOF
14916 rm -f conftest.$ac_objext
14917 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
14918   (eval $ac_compile) 2>&5
14919   ac_status=$?
14920   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14921   (exit $ac_status); } &&
14922          { ac_try='test -s conftest.$ac_objext'
14923   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14924   (eval $ac_try) 2>&5
14925   ac_status=$?
14926   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14927   (exit $ac_status); }; }; then
14928   pgac_cv_type_long_long_int_64=yes
14929 else
14930   echo "$as_me: failed program was:" >&5
14931 cat conftest.$ac_ext >&5
14932 pgac_cv_type_long_long_int_64=no
14933 fi
14934 rm -f conftest.$ac_objext conftest.$ac_ext
14935 else
14936   cat >conftest.$ac_ext <<_ACEOF
14937 #line $LINENO "configure"
14938 #include "confdefs.h"
14939 typedef long long int ac_int64;
14940
14941 /*
14942  * These are globals to discourage the compiler from folding all the
14943  * arithmetic tests down to compile-time constants.
14944  */
14945 ac_int64 a = 20000001;
14946 ac_int64 b = 40000005;
14947
14948 int does_int64_work()
14949 {
14950   ac_int64 c,d;
14951
14952   if (sizeof(ac_int64) != 8)
14953     return 0;                   /* definitely not the right size */
14954
14955   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
14956   c = a * b;
14957   d = (c + b) / b;
14958   if (d != a+1)
14959     return 0;
14960   return 1;
14961 }
14962 main() {
14963   exit(! does_int64_work());
14964 }
14965 _ACEOF
14966 rm -f conftest$ac_exeext
14967 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
14968   (eval $ac_link) 2>&5
14969   ac_status=$?
14970   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14971   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14972   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
14973   (eval $ac_try) 2>&5
14974   ac_status=$?
14975   echo "$as_me:$LINENO: \$? = $ac_status" >&5
14976   (exit $ac_status); }; }; then
14977   pgac_cv_type_long_long_int_64=yes
14978 else
14979   echo "$as_me: program exited with status $ac_status" >&5
14980 echo "$as_me: failed program was:" >&5
14981 cat conftest.$ac_ext >&5
14982 ( exit $ac_status )
14983 pgac_cv_type_long_long_int_64=no
14984 fi
14985 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14986 fi
14987 fi
14988 echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
14989 echo "${ECHO_T}$pgac_cv_type_long_long_int_64" >&6
14990
14991 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
14992 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
14993
14994 cat >>confdefs.h <<\_ACEOF
14995 #define HAVE_LONG_LONG_INT_64
14996 _ACEOF
14997
14998 fi
14999
15000 fi
15001
15002
15003
15004 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
15005   cat >conftest.$ac_ext <<_ACEOF
15006 #line $LINENO "configure"
15007 #include "confdefs.h"
15008
15009 #define INT64CONST(x)  x##LL
15010 long long int foo = INT64CONST(0x1234567890123456);
15011
15012 #ifdef F77_DUMMY_MAIN
15013 #  ifdef __cplusplus
15014      extern "C"
15015 #  endif
15016    int F77_DUMMY_MAIN() { return 1; }
15017 #endif
15018 int
15019 main ()
15020 {
15021
15022   ;
15023   return 0;
15024 }
15025 _ACEOF
15026 rm -f conftest.$ac_objext
15027 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15028   (eval $ac_compile) 2>&5
15029   ac_status=$?
15030   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15031   (exit $ac_status); } &&
15032          { ac_try='test -s conftest.$ac_objext'
15033   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15034   (eval $ac_try) 2>&5
15035   ac_status=$?
15036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15037   (exit $ac_status); }; }; then
15038
15039 cat >>confdefs.h <<\_ACEOF
15040 #define HAVE_LL_CONSTANTS 1
15041 _ACEOF
15042
15043 else
15044   echo "$as_me: failed program was:" >&5
15045 cat conftest.$ac_ext >&5
15046 fi
15047 rm -f conftest.$ac_objext conftest.$ac_ext
15048 fi
15049
15050
15051 # If we found "long int" is 64 bits, assume snprintf handles it.  If
15052 # we found we need to use "long long int", better check.  We cope with
15053 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
15054 # work, fall back to our own snprintf emulation (which we know uses %lld).
15055
15056 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
15057   if test $pgac_need_repl_snprintf = no; then
15058     echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
15059 echo $ECHO_N "checking snprintf format for long long int... $ECHO_C" >&6
15060 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
15061   echo $ECHO_N "(cached) $ECHO_C" >&6
15062 else
15063   for pgac_format in '%lld' '%qd' '%I64d'; do
15064 if test "$cross_compiling" = yes; then
15065   pgac_cv_snprintf_long_long_int_format=cross; break
15066 else
15067   cat >conftest.$ac_ext <<_ACEOF
15068 #line $LINENO "configure"
15069 #include "confdefs.h"
15070 #include <stdio.h>
15071 typedef long long int ac_int64;
15072 #define INT64_FORMAT "$pgac_format"
15073
15074 ac_int64 a = 20000001;
15075 ac_int64 b = 40000005;
15076
15077 int does_int64_snprintf_work()
15078 {
15079   ac_int64 c;
15080   char buf[100];
15081
15082   if (sizeof(ac_int64) != 8)
15083     return 0;                   /* doesn't look like the right size */
15084
15085   c = a * b;
15086   snprintf(buf, 100, INT64_FORMAT, c);
15087   if (strcmp(buf, "800000140000005") != 0)
15088     return 0;                   /* either multiply or snprintf is busted */
15089   return 1;
15090 }
15091 main() {
15092   exit(! does_int64_snprintf_work());
15093 }
15094 _ACEOF
15095 rm -f conftest$ac_exeext
15096 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15097   (eval $ac_link) 2>&5
15098   ac_status=$?
15099   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15100   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15101   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15102   (eval $ac_try) 2>&5
15103   ac_status=$?
15104   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15105   (exit $ac_status); }; }; then
15106   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
15107 else
15108   echo "$as_me: program exited with status $ac_status" >&5
15109 echo "$as_me: failed program was:" >&5
15110 cat conftest.$ac_ext >&5
15111 fi
15112 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15113 fi
15114 done
15115 fi
15116
15117 LONG_LONG_INT_FORMAT=''
15118
15119 case $pgac_cv_snprintf_long_long_int_format in
15120   cross) echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
15121 echo "${ECHO_T}cannot test (not on host machine)" >&6;;
15122   ?*)    echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
15123 echo "${ECHO_T}$pgac_cv_snprintf_long_long_int_format" >&6
15124          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
15125   *)     echo "$as_me:$LINENO: result: none" >&5
15126 echo "${ECHO_T}none" >&6;;
15127 esac
15128     if test "$LONG_LONG_INT_FORMAT" = ""; then
15129       # Force usage of our own snprintf, since system snprintf is broken
15130       pgac_need_repl_snprintf=yes
15131       LONG_LONG_INT_FORMAT='%lld'
15132     fi
15133   else
15134     # Here if we previously decided we needed to use our own snprintf
15135     LONG_LONG_INT_FORMAT='%lld'
15136   fi
15137   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
15138   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
15139   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
15140 else
15141   # Here if we are not using 'long long int' at all
15142   INT64_FORMAT='"%ld"'
15143   UINT64_FORMAT='"%lu"'
15144 fi
15145
15146
15147 cat >>confdefs.h <<_ACEOF
15148 #define INT64_FORMAT $INT64_FORMAT
15149 _ACEOF
15150
15151
15152
15153 cat >>confdefs.h <<_ACEOF
15154 #define UINT64_FORMAT $UINT64_FORMAT
15155 _ACEOF
15156
15157
15158 # Now we have checked all the reasons to replace snprintf
15159 if test $pgac_need_repl_snprintf = yes; then
15160
15161 cat >>confdefs.h <<\_ACEOF
15162 #define USE_SNPRINTF 1
15163 _ACEOF
15164
15165   LIBOBJS="$LIBOBJS snprintf.$ac_objext"
15166 fi
15167
15168 # Need a #define for the size of Datum (unsigned long)
15169 echo "$as_me:$LINENO: checking for unsigned long" >&5
15170 echo $ECHO_N "checking for unsigned long... $ECHO_C" >&6
15171 if test "${ac_cv_type_unsigned_long+set}" = set; then
15172   echo $ECHO_N "(cached) $ECHO_C" >&6
15173 else
15174   cat >conftest.$ac_ext <<_ACEOF
15175 #line $LINENO "configure"
15176 #include "confdefs.h"
15177 $ac_includes_default
15178 #ifdef F77_DUMMY_MAIN
15179 #  ifdef __cplusplus
15180      extern "C"
15181 #  endif
15182    int F77_DUMMY_MAIN() { return 1; }
15183 #endif
15184 int
15185 main ()
15186 {
15187 if ((unsigned long *) 0)
15188   return 0;
15189 if (sizeof (unsigned long))
15190   return 0;
15191   ;
15192   return 0;
15193 }
15194 _ACEOF
15195 rm -f conftest.$ac_objext
15196 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15197   (eval $ac_compile) 2>&5
15198   ac_status=$?
15199   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15200   (exit $ac_status); } &&
15201          { ac_try='test -s conftest.$ac_objext'
15202   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15203   (eval $ac_try) 2>&5
15204   ac_status=$?
15205   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15206   (exit $ac_status); }; }; then
15207   ac_cv_type_unsigned_long=yes
15208 else
15209   echo "$as_me: failed program was:" >&5
15210 cat conftest.$ac_ext >&5
15211 ac_cv_type_unsigned_long=no
15212 fi
15213 rm -f conftest.$ac_objext conftest.$ac_ext
15214 fi
15215 echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long" >&5
15216 echo "${ECHO_T}$ac_cv_type_unsigned_long" >&6
15217
15218 echo "$as_me:$LINENO: checking size of unsigned long" >&5
15219 echo $ECHO_N "checking size of unsigned long... $ECHO_C" >&6
15220 if test "${ac_cv_sizeof_unsigned_long+set}" = set; then
15221   echo $ECHO_N "(cached) $ECHO_C" >&6
15222 else
15223   if test "$ac_cv_type_unsigned_long" = yes; then
15224   # The cast to unsigned long works around a bug in the HP C Compiler
15225   # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
15226   # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
15227   # This bug is HP SR number 8606223364.
15228   if test "$cross_compiling" = yes; then
15229   # Depending upon the size, compute the lo and hi bounds.
15230 cat >conftest.$ac_ext <<_ACEOF
15231 #line $LINENO "configure"
15232 #include "confdefs.h"
15233 $ac_includes_default
15234 #ifdef F77_DUMMY_MAIN
15235 #  ifdef __cplusplus
15236      extern "C"
15237 #  endif
15238    int F77_DUMMY_MAIN() { return 1; }
15239 #endif
15240 int
15241 main ()
15242 {
15243 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= 0)];
15244 test_array [0] = 0
15245
15246   ;
15247   return 0;
15248 }
15249 _ACEOF
15250 rm -f conftest.$ac_objext
15251 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15252   (eval $ac_compile) 2>&5
15253   ac_status=$?
15254   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15255   (exit $ac_status); } &&
15256          { ac_try='test -s conftest.$ac_objext'
15257   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15258   (eval $ac_try) 2>&5
15259   ac_status=$?
15260   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15261   (exit $ac_status); }; }; then
15262   ac_lo=0 ac_mid=0
15263   while :; do
15264     cat >conftest.$ac_ext <<_ACEOF
15265 #line $LINENO "configure"
15266 #include "confdefs.h"
15267 $ac_includes_default
15268 #ifdef F77_DUMMY_MAIN
15269 #  ifdef __cplusplus
15270      extern "C"
15271 #  endif
15272    int F77_DUMMY_MAIN() { return 1; }
15273 #endif
15274 int
15275 main ()
15276 {
15277 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
15278 test_array [0] = 0
15279
15280   ;
15281   return 0;
15282 }
15283 _ACEOF
15284 rm -f conftest.$ac_objext
15285 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15286   (eval $ac_compile) 2>&5
15287   ac_status=$?
15288   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15289   (exit $ac_status); } &&
15290          { ac_try='test -s conftest.$ac_objext'
15291   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15292   (eval $ac_try) 2>&5
15293   ac_status=$?
15294   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15295   (exit $ac_status); }; }; then
15296   ac_hi=$ac_mid; break
15297 else
15298   echo "$as_me: failed program was:" >&5
15299 cat conftest.$ac_ext >&5
15300 ac_lo=`expr $ac_mid + 1`
15301                     if test $ac_lo -le $ac_mid; then
15302                       ac_lo= ac_hi=
15303                       break
15304                     fi
15305                     ac_mid=`expr 2 '*' $ac_mid + 1`
15306 fi
15307 rm -f conftest.$ac_objext conftest.$ac_ext
15308   done
15309 else
15310   echo "$as_me: failed program was:" >&5
15311 cat conftest.$ac_ext >&5
15312 cat >conftest.$ac_ext <<_ACEOF
15313 #line $LINENO "configure"
15314 #include "confdefs.h"
15315 $ac_includes_default
15316 #ifdef F77_DUMMY_MAIN
15317 #  ifdef __cplusplus
15318      extern "C"
15319 #  endif
15320    int F77_DUMMY_MAIN() { return 1; }
15321 #endif
15322 int
15323 main ()
15324 {
15325 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) < 0)];
15326 test_array [0] = 0
15327
15328   ;
15329   return 0;
15330 }
15331 _ACEOF
15332 rm -f conftest.$ac_objext
15333 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15334   (eval $ac_compile) 2>&5
15335   ac_status=$?
15336   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15337   (exit $ac_status); } &&
15338          { ac_try='test -s conftest.$ac_objext'
15339   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15340   (eval $ac_try) 2>&5
15341   ac_status=$?
15342   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15343   (exit $ac_status); }; }; then
15344   ac_hi=-1 ac_mid=-1
15345   while :; do
15346     cat >conftest.$ac_ext <<_ACEOF
15347 #line $LINENO "configure"
15348 #include "confdefs.h"
15349 $ac_includes_default
15350 #ifdef F77_DUMMY_MAIN
15351 #  ifdef __cplusplus
15352      extern "C"
15353 #  endif
15354    int F77_DUMMY_MAIN() { return 1; }
15355 #endif
15356 int
15357 main ()
15358 {
15359 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) >= $ac_mid)];
15360 test_array [0] = 0
15361
15362   ;
15363   return 0;
15364 }
15365 _ACEOF
15366 rm -f conftest.$ac_objext
15367 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15368   (eval $ac_compile) 2>&5
15369   ac_status=$?
15370   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15371   (exit $ac_status); } &&
15372          { ac_try='test -s conftest.$ac_objext'
15373   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15374   (eval $ac_try) 2>&5
15375   ac_status=$?
15376   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15377   (exit $ac_status); }; }; then
15378   ac_lo=$ac_mid; break
15379 else
15380   echo "$as_me: failed program was:" >&5
15381 cat conftest.$ac_ext >&5
15382 ac_hi=`expr '(' $ac_mid ')' - 1`
15383                        if test $ac_mid -le $ac_hi; then
15384                          ac_lo= ac_hi=
15385                          break
15386                        fi
15387                        ac_mid=`expr 2 '*' $ac_mid`
15388 fi
15389 rm -f conftest.$ac_objext conftest.$ac_ext
15390   done
15391 else
15392   echo "$as_me: failed program was:" >&5
15393 cat conftest.$ac_ext >&5
15394 ac_lo= ac_hi=
15395 fi
15396 rm -f conftest.$ac_objext conftest.$ac_ext
15397 fi
15398 rm -f conftest.$ac_objext conftest.$ac_ext
15399 # Binary search between lo and hi bounds.
15400 while test "x$ac_lo" != "x$ac_hi"; do
15401   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15402   cat >conftest.$ac_ext <<_ACEOF
15403 #line $LINENO "configure"
15404 #include "confdefs.h"
15405 $ac_includes_default
15406 #ifdef F77_DUMMY_MAIN
15407 #  ifdef __cplusplus
15408      extern "C"
15409 #  endif
15410    int F77_DUMMY_MAIN() { return 1; }
15411 #endif
15412 int
15413 main ()
15414 {
15415 static int test_array [1 - 2 * !(((long) (sizeof (unsigned long))) <= $ac_mid)];
15416 test_array [0] = 0
15417
15418   ;
15419   return 0;
15420 }
15421 _ACEOF
15422 rm -f conftest.$ac_objext
15423 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15424   (eval $ac_compile) 2>&5
15425   ac_status=$?
15426   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15427   (exit $ac_status); } &&
15428          { ac_try='test -s conftest.$ac_objext'
15429   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15430   (eval $ac_try) 2>&5
15431   ac_status=$?
15432   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15433   (exit $ac_status); }; }; then
15434   ac_hi=$ac_mid
15435 else
15436   echo "$as_me: failed program was:" >&5
15437 cat conftest.$ac_ext >&5
15438 ac_lo=`expr '(' $ac_mid ')' + 1`
15439 fi
15440 rm -f conftest.$ac_objext conftest.$ac_ext
15441 done
15442 case $ac_lo in
15443 ?*) ac_cv_sizeof_unsigned_long=$ac_lo;;
15444 '') { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77" >&5
15445 echo "$as_me: error: cannot compute sizeof (unsigned long), 77" >&2;}
15446    { (exit 1); exit 1; }; } ;;
15447 esac
15448 else
15449   if test "$cross_compiling" = yes; then
15450   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15451 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15452    { (exit 1); exit 1; }; }
15453 else
15454   cat >conftest.$ac_ext <<_ACEOF
15455 #line $LINENO "configure"
15456 #include "confdefs.h"
15457 $ac_includes_default
15458 long longval () { return (long) (sizeof (unsigned long)); }
15459 unsigned long ulongval () { return (long) (sizeof (unsigned long)); }
15460 #include <stdio.h>
15461 #include <stdlib.h>
15462 #ifdef F77_DUMMY_MAIN
15463 #  ifdef __cplusplus
15464      extern "C"
15465 #  endif
15466    int F77_DUMMY_MAIN() { return 1; }
15467 #endif
15468 int
15469 main ()
15470 {
15471
15472   FILE *f = fopen ("conftest.val", "w");
15473   if (! f)
15474     exit (1);
15475   if (((long) (sizeof (unsigned long))) < 0)
15476     {
15477       long i = longval ();
15478       if (i != ((long) (sizeof (unsigned long))))
15479         exit (1);
15480       fprintf (f, "%ld\n", i);
15481     }
15482   else
15483     {
15484       unsigned long i = ulongval ();
15485       if (i != ((long) (sizeof (unsigned long))))
15486         exit (1);
15487       fprintf (f, "%lu\n", i);
15488     }
15489   exit (ferror (f) || fclose (f) != 0);
15490
15491   ;
15492   return 0;
15493 }
15494 _ACEOF
15495 rm -f conftest$ac_exeext
15496 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15497   (eval $ac_link) 2>&5
15498   ac_status=$?
15499   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15500   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15501   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15502   (eval $ac_try) 2>&5
15503   ac_status=$?
15504   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15505   (exit $ac_status); }; }; then
15506   ac_cv_sizeof_unsigned_long=`cat conftest.val`
15507 else
15508   echo "$as_me: program exited with status $ac_status" >&5
15509 echo "$as_me: failed program was:" >&5
15510 cat conftest.$ac_ext >&5
15511 ( exit $ac_status )
15512 { { echo "$as_me:$LINENO: error: cannot compute sizeof (unsigned long), 77" >&5
15513 echo "$as_me: error: cannot compute sizeof (unsigned long), 77" >&2;}
15514    { (exit 1); exit 1; }; }
15515 fi
15516 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15517 fi
15518 fi
15519 rm -f conftest.val
15520 else
15521   ac_cv_sizeof_unsigned_long=0
15522 fi
15523 fi
15524 echo "$as_me:$LINENO: result: $ac_cv_sizeof_unsigned_long" >&5
15525 echo "${ECHO_T}$ac_cv_sizeof_unsigned_long" >&6
15526 cat >>confdefs.h <<_ACEOF
15527 #define SIZEOF_UNSIGNED_LONG $ac_cv_sizeof_unsigned_long
15528 _ACEOF
15529
15530
15531
15532 # Determine memory alignment requirements for the basic C data types.
15533
15534 echo "$as_me:$LINENO: checking for short" >&5
15535 echo $ECHO_N "checking for short... $ECHO_C" >&6
15536 if test "${ac_cv_type_short+set}" = set; then
15537   echo $ECHO_N "(cached) $ECHO_C" >&6
15538 else
15539   cat >conftest.$ac_ext <<_ACEOF
15540 #line $LINENO "configure"
15541 #include "confdefs.h"
15542 $ac_includes_default
15543 #ifdef F77_DUMMY_MAIN
15544 #  ifdef __cplusplus
15545      extern "C"
15546 #  endif
15547    int F77_DUMMY_MAIN() { return 1; }
15548 #endif
15549 int
15550 main ()
15551 {
15552 if ((short *) 0)
15553   return 0;
15554 if (sizeof (short))
15555   return 0;
15556   ;
15557   return 0;
15558 }
15559 _ACEOF
15560 rm -f conftest.$ac_objext
15561 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15562   (eval $ac_compile) 2>&5
15563   ac_status=$?
15564   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15565   (exit $ac_status); } &&
15566          { ac_try='test -s conftest.$ac_objext'
15567   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15568   (eval $ac_try) 2>&5
15569   ac_status=$?
15570   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15571   (exit $ac_status); }; }; then
15572   ac_cv_type_short=yes
15573 else
15574   echo "$as_me: failed program was:" >&5
15575 cat conftest.$ac_ext >&5
15576 ac_cv_type_short=no
15577 fi
15578 rm -f conftest.$ac_objext conftest.$ac_ext
15579 fi
15580 echo "$as_me:$LINENO: result: $ac_cv_type_short" >&5
15581 echo "${ECHO_T}$ac_cv_type_short" >&6
15582
15583 echo "$as_me:$LINENO: checking alignment of short" >&5
15584 echo $ECHO_N "checking alignment of short... $ECHO_C" >&6
15585 if test "${pgac_cv_alignof_short+set}" = set; then
15586   echo $ECHO_N "(cached) $ECHO_C" >&6
15587 else
15588   if test "$ac_cv_type_short" = yes; then
15589   if test "$cross_compiling" = yes; then
15590   # Depending upon the size, compute the lo and hi bounds.
15591 cat >conftest.$ac_ext <<_ACEOF
15592 #line $LINENO "configure"
15593 #include "confdefs.h"
15594 $ac_includes_default
15595 struct { char filler; short field; } pgac_struct;
15596 #ifdef F77_DUMMY_MAIN
15597 #  ifdef __cplusplus
15598      extern "C"
15599 #  endif
15600    int F77_DUMMY_MAIN() { return 1; }
15601 #endif
15602 int
15603 main ()
15604 {
15605 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
15606 test_array [0] = 0
15607
15608   ;
15609   return 0;
15610 }
15611 _ACEOF
15612 rm -f conftest.$ac_objext
15613 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15614   (eval $ac_compile) 2>&5
15615   ac_status=$?
15616   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15617   (exit $ac_status); } &&
15618          { ac_try='test -s conftest.$ac_objext'
15619   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15620   (eval $ac_try) 2>&5
15621   ac_status=$?
15622   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15623   (exit $ac_status); }; }; then
15624   ac_lo=0 ac_mid=0
15625   while :; do
15626     cat >conftest.$ac_ext <<_ACEOF
15627 #line $LINENO "configure"
15628 #include "confdefs.h"
15629 $ac_includes_default
15630 struct { char filler; short field; } pgac_struct;
15631 #ifdef F77_DUMMY_MAIN
15632 #  ifdef __cplusplus
15633      extern "C"
15634 #  endif
15635    int F77_DUMMY_MAIN() { return 1; }
15636 #endif
15637 int
15638 main ()
15639 {
15640 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15641 test_array [0] = 0
15642
15643   ;
15644   return 0;
15645 }
15646 _ACEOF
15647 rm -f conftest.$ac_objext
15648 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15649   (eval $ac_compile) 2>&5
15650   ac_status=$?
15651   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15652   (exit $ac_status); } &&
15653          { ac_try='test -s conftest.$ac_objext'
15654   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15655   (eval $ac_try) 2>&5
15656   ac_status=$?
15657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15658   (exit $ac_status); }; }; then
15659   ac_hi=$ac_mid; break
15660 else
15661   echo "$as_me: failed program was:" >&5
15662 cat conftest.$ac_ext >&5
15663 ac_lo=`expr $ac_mid + 1`
15664                     if test $ac_lo -le $ac_mid; then
15665                       ac_lo= ac_hi=
15666                       break
15667                     fi
15668                     ac_mid=`expr 2 '*' $ac_mid + 1`
15669 fi
15670 rm -f conftest.$ac_objext conftest.$ac_ext
15671   done
15672 else
15673   echo "$as_me: failed program was:" >&5
15674 cat conftest.$ac_ext >&5
15675 cat >conftest.$ac_ext <<_ACEOF
15676 #line $LINENO "configure"
15677 #include "confdefs.h"
15678 $ac_includes_default
15679 struct { char filler; short field; } pgac_struct;
15680 #ifdef F77_DUMMY_MAIN
15681 #  ifdef __cplusplus
15682      extern "C"
15683 #  endif
15684    int F77_DUMMY_MAIN() { return 1; }
15685 #endif
15686 int
15687 main ()
15688 {
15689 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
15690 test_array [0] = 0
15691
15692   ;
15693   return 0;
15694 }
15695 _ACEOF
15696 rm -f conftest.$ac_objext
15697 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15698   (eval $ac_compile) 2>&5
15699   ac_status=$?
15700   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15701   (exit $ac_status); } &&
15702          { ac_try='test -s conftest.$ac_objext'
15703   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15704   (eval $ac_try) 2>&5
15705   ac_status=$?
15706   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15707   (exit $ac_status); }; }; then
15708   ac_hi=-1 ac_mid=-1
15709   while :; do
15710     cat >conftest.$ac_ext <<_ACEOF
15711 #line $LINENO "configure"
15712 #include "confdefs.h"
15713 $ac_includes_default
15714 struct { char filler; short field; } pgac_struct;
15715 #ifdef F77_DUMMY_MAIN
15716 #  ifdef __cplusplus
15717      extern "C"
15718 #  endif
15719    int F77_DUMMY_MAIN() { return 1; }
15720 #endif
15721 int
15722 main ()
15723 {
15724 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
15725 test_array [0] = 0
15726
15727   ;
15728   return 0;
15729 }
15730 _ACEOF
15731 rm -f conftest.$ac_objext
15732 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15733   (eval $ac_compile) 2>&5
15734   ac_status=$?
15735   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15736   (exit $ac_status); } &&
15737          { ac_try='test -s conftest.$ac_objext'
15738   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15739   (eval $ac_try) 2>&5
15740   ac_status=$?
15741   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15742   (exit $ac_status); }; }; then
15743   ac_lo=$ac_mid; break
15744 else
15745   echo "$as_me: failed program was:" >&5
15746 cat conftest.$ac_ext >&5
15747 ac_hi=`expr '(' $ac_mid ')' - 1`
15748                        if test $ac_mid -le $ac_hi; then
15749                          ac_lo= ac_hi=
15750                          break
15751                        fi
15752                        ac_mid=`expr 2 '*' $ac_mid`
15753 fi
15754 rm -f conftest.$ac_objext conftest.$ac_ext
15755   done
15756 else
15757   echo "$as_me: failed program was:" >&5
15758 cat conftest.$ac_ext >&5
15759 ac_lo= ac_hi=
15760 fi
15761 rm -f conftest.$ac_objext conftest.$ac_ext
15762 fi
15763 rm -f conftest.$ac_objext conftest.$ac_ext
15764 # Binary search between lo and hi bounds.
15765 while test "x$ac_lo" != "x$ac_hi"; do
15766   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
15767   cat >conftest.$ac_ext <<_ACEOF
15768 #line $LINENO "configure"
15769 #include "confdefs.h"
15770 $ac_includes_default
15771 struct { char filler; short field; } pgac_struct;
15772 #ifdef F77_DUMMY_MAIN
15773 #  ifdef __cplusplus
15774      extern "C"
15775 #  endif
15776    int F77_DUMMY_MAIN() { return 1; }
15777 #endif
15778 int
15779 main ()
15780 {
15781 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
15782 test_array [0] = 0
15783
15784   ;
15785   return 0;
15786 }
15787 _ACEOF
15788 rm -f conftest.$ac_objext
15789 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15790   (eval $ac_compile) 2>&5
15791   ac_status=$?
15792   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15793   (exit $ac_status); } &&
15794          { ac_try='test -s conftest.$ac_objext'
15795   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15796   (eval $ac_try) 2>&5
15797   ac_status=$?
15798   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15799   (exit $ac_status); }; }; then
15800   ac_hi=$ac_mid
15801 else
15802   echo "$as_me: failed program was:" >&5
15803 cat conftest.$ac_ext >&5
15804 ac_lo=`expr '(' $ac_mid ')' + 1`
15805 fi
15806 rm -f conftest.$ac_objext conftest.$ac_ext
15807 done
15808 case $ac_lo in
15809 ?*) pgac_cv_alignof_short=$ac_lo;;
15810 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
15811 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
15812    { (exit 1); exit 1; }; } ;;
15813 esac
15814 else
15815   if test "$cross_compiling" = yes; then
15816   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
15817 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
15818    { (exit 1); exit 1; }; }
15819 else
15820   cat >conftest.$ac_ext <<_ACEOF
15821 #line $LINENO "configure"
15822 #include "confdefs.h"
15823 $ac_includes_default
15824 struct { char filler; short field; } pgac_struct;
15825 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15826 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
15827 #include <stdio.h>
15828 #include <stdlib.h>
15829 #ifdef F77_DUMMY_MAIN
15830 #  ifdef __cplusplus
15831      extern "C"
15832 #  endif
15833    int F77_DUMMY_MAIN() { return 1; }
15834 #endif
15835 int
15836 main ()
15837 {
15838
15839   FILE *f = fopen ("conftest.val", "w");
15840   if (! f)
15841     exit (1);
15842   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
15843     {
15844       long i = longval ();
15845       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15846         exit (1);
15847       fprintf (f, "%ld\n", i);
15848     }
15849   else
15850     {
15851       unsigned long i = ulongval ();
15852       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
15853         exit (1);
15854       fprintf (f, "%lu\n", i);
15855     }
15856   exit (ferror (f) || fclose (f) != 0);
15857
15858   ;
15859   return 0;
15860 }
15861 _ACEOF
15862 rm -f conftest$ac_exeext
15863 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
15864   (eval $ac_link) 2>&5
15865   ac_status=$?
15866   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15867   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15868   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15869   (eval $ac_try) 2>&5
15870   ac_status=$?
15871   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15872   (exit $ac_status); }; }; then
15873   pgac_cv_alignof_short=`cat conftest.val`
15874 else
15875   echo "$as_me: program exited with status $ac_status" >&5
15876 echo "$as_me: failed program was:" >&5
15877 cat conftest.$ac_ext >&5
15878 ( exit $ac_status )
15879 { { echo "$as_me:$LINENO: error: cannot compute alignment of short, 77" >&5
15880 echo "$as_me: error: cannot compute alignment of short, 77" >&2;}
15881    { (exit 1); exit 1; }; }
15882 fi
15883 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15884 fi
15885 fi
15886 rm -f conftest.val
15887 else
15888   pgac_cv_alignof_short=0
15889 fi
15890 fi
15891 echo "$as_me:$LINENO: result: $pgac_cv_alignof_short" >&5
15892 echo "${ECHO_T}$pgac_cv_alignof_short" >&6
15893 cat >>confdefs.h <<_ACEOF
15894 #define ALIGNOF_SHORT $pgac_cv_alignof_short
15895 _ACEOF
15896
15897
15898 echo "$as_me:$LINENO: checking for int" >&5
15899 echo $ECHO_N "checking for int... $ECHO_C" >&6
15900 if test "${ac_cv_type_int+set}" = set; then
15901   echo $ECHO_N "(cached) $ECHO_C" >&6
15902 else
15903   cat >conftest.$ac_ext <<_ACEOF
15904 #line $LINENO "configure"
15905 #include "confdefs.h"
15906 $ac_includes_default
15907 #ifdef F77_DUMMY_MAIN
15908 #  ifdef __cplusplus
15909      extern "C"
15910 #  endif
15911    int F77_DUMMY_MAIN() { return 1; }
15912 #endif
15913 int
15914 main ()
15915 {
15916 if ((int *) 0)
15917   return 0;
15918 if (sizeof (int))
15919   return 0;
15920   ;
15921   return 0;
15922 }
15923 _ACEOF
15924 rm -f conftest.$ac_objext
15925 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15926   (eval $ac_compile) 2>&5
15927   ac_status=$?
15928   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15929   (exit $ac_status); } &&
15930          { ac_try='test -s conftest.$ac_objext'
15931   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15932   (eval $ac_try) 2>&5
15933   ac_status=$?
15934   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15935   (exit $ac_status); }; }; then
15936   ac_cv_type_int=yes
15937 else
15938   echo "$as_me: failed program was:" >&5
15939 cat conftest.$ac_ext >&5
15940 ac_cv_type_int=no
15941 fi
15942 rm -f conftest.$ac_objext conftest.$ac_ext
15943 fi
15944 echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
15945 echo "${ECHO_T}$ac_cv_type_int" >&6
15946
15947 echo "$as_me:$LINENO: checking alignment of int" >&5
15948 echo $ECHO_N "checking alignment of int... $ECHO_C" >&6
15949 if test "${pgac_cv_alignof_int+set}" = set; then
15950   echo $ECHO_N "(cached) $ECHO_C" >&6
15951 else
15952   if test "$ac_cv_type_int" = yes; then
15953   if test "$cross_compiling" = yes; then
15954   # Depending upon the size, compute the lo and hi bounds.
15955 cat >conftest.$ac_ext <<_ACEOF
15956 #line $LINENO "configure"
15957 #include "confdefs.h"
15958 $ac_includes_default
15959 struct { char filler; int field; } pgac_struct;
15960 #ifdef F77_DUMMY_MAIN
15961 #  ifdef __cplusplus
15962      extern "C"
15963 #  endif
15964    int F77_DUMMY_MAIN() { return 1; }
15965 #endif
15966 int
15967 main ()
15968 {
15969 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
15970 test_array [0] = 0
15971
15972   ;
15973   return 0;
15974 }
15975 _ACEOF
15976 rm -f conftest.$ac_objext
15977 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
15978   (eval $ac_compile) 2>&5
15979   ac_status=$?
15980   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15981   (exit $ac_status); } &&
15982          { ac_try='test -s conftest.$ac_objext'
15983   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
15984   (eval $ac_try) 2>&5
15985   ac_status=$?
15986   echo "$as_me:$LINENO: \$? = $ac_status" >&5
15987   (exit $ac_status); }; }; then
15988   ac_lo=0 ac_mid=0
15989   while :; do
15990     cat >conftest.$ac_ext <<_ACEOF
15991 #line $LINENO "configure"
15992 #include "confdefs.h"
15993 $ac_includes_default
15994 struct { char filler; int field; } pgac_struct;
15995 #ifdef F77_DUMMY_MAIN
15996 #  ifdef __cplusplus
15997      extern "C"
15998 #  endif
15999    int F77_DUMMY_MAIN() { return 1; }
16000 #endif
16001 int
16002 main ()
16003 {
16004 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16005 test_array [0] = 0
16006
16007   ;
16008   return 0;
16009 }
16010 _ACEOF
16011 rm -f conftest.$ac_objext
16012 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16013   (eval $ac_compile) 2>&5
16014   ac_status=$?
16015   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16016   (exit $ac_status); } &&
16017          { ac_try='test -s conftest.$ac_objext'
16018   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16019   (eval $ac_try) 2>&5
16020   ac_status=$?
16021   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16022   (exit $ac_status); }; }; then
16023   ac_hi=$ac_mid; break
16024 else
16025   echo "$as_me: failed program was:" >&5
16026 cat conftest.$ac_ext >&5
16027 ac_lo=`expr $ac_mid + 1`
16028                     if test $ac_lo -le $ac_mid; then
16029                       ac_lo= ac_hi=
16030                       break
16031                     fi
16032                     ac_mid=`expr 2 '*' $ac_mid + 1`
16033 fi
16034 rm -f conftest.$ac_objext conftest.$ac_ext
16035   done
16036 else
16037   echo "$as_me: failed program was:" >&5
16038 cat conftest.$ac_ext >&5
16039 cat >conftest.$ac_ext <<_ACEOF
16040 #line $LINENO "configure"
16041 #include "confdefs.h"
16042 $ac_includes_default
16043 struct { char filler; int field; } pgac_struct;
16044 #ifdef F77_DUMMY_MAIN
16045 #  ifdef __cplusplus
16046      extern "C"
16047 #  endif
16048    int F77_DUMMY_MAIN() { return 1; }
16049 #endif
16050 int
16051 main ()
16052 {
16053 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
16054 test_array [0] = 0
16055
16056   ;
16057   return 0;
16058 }
16059 _ACEOF
16060 rm -f conftest.$ac_objext
16061 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16062   (eval $ac_compile) 2>&5
16063   ac_status=$?
16064   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16065   (exit $ac_status); } &&
16066          { ac_try='test -s conftest.$ac_objext'
16067   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16068   (eval $ac_try) 2>&5
16069   ac_status=$?
16070   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16071   (exit $ac_status); }; }; then
16072   ac_hi=-1 ac_mid=-1
16073   while :; do
16074     cat >conftest.$ac_ext <<_ACEOF
16075 #line $LINENO "configure"
16076 #include "confdefs.h"
16077 $ac_includes_default
16078 struct { char filler; int field; } pgac_struct;
16079 #ifdef F77_DUMMY_MAIN
16080 #  ifdef __cplusplus
16081      extern "C"
16082 #  endif
16083    int F77_DUMMY_MAIN() { return 1; }
16084 #endif
16085 int
16086 main ()
16087 {
16088 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
16089 test_array [0] = 0
16090
16091   ;
16092   return 0;
16093 }
16094 _ACEOF
16095 rm -f conftest.$ac_objext
16096 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16097   (eval $ac_compile) 2>&5
16098   ac_status=$?
16099   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16100   (exit $ac_status); } &&
16101          { ac_try='test -s conftest.$ac_objext'
16102   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16103   (eval $ac_try) 2>&5
16104   ac_status=$?
16105   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16106   (exit $ac_status); }; }; then
16107   ac_lo=$ac_mid; break
16108 else
16109   echo "$as_me: failed program was:" >&5
16110 cat conftest.$ac_ext >&5
16111 ac_hi=`expr '(' $ac_mid ')' - 1`
16112                        if test $ac_mid -le $ac_hi; then
16113                          ac_lo= ac_hi=
16114                          break
16115                        fi
16116                        ac_mid=`expr 2 '*' $ac_mid`
16117 fi
16118 rm -f conftest.$ac_objext conftest.$ac_ext
16119   done
16120 else
16121   echo "$as_me: failed program was:" >&5
16122 cat conftest.$ac_ext >&5
16123 ac_lo= ac_hi=
16124 fi
16125 rm -f conftest.$ac_objext conftest.$ac_ext
16126 fi
16127 rm -f conftest.$ac_objext conftest.$ac_ext
16128 # Binary search between lo and hi bounds.
16129 while test "x$ac_lo" != "x$ac_hi"; do
16130   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
16131   cat >conftest.$ac_ext <<_ACEOF
16132 #line $LINENO "configure"
16133 #include "confdefs.h"
16134 $ac_includes_default
16135 struct { char filler; int field; } pgac_struct;
16136 #ifdef F77_DUMMY_MAIN
16137 #  ifdef __cplusplus
16138      extern "C"
16139 #  endif
16140    int F77_DUMMY_MAIN() { return 1; }
16141 #endif
16142 int
16143 main ()
16144 {
16145 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16146 test_array [0] = 0
16147
16148   ;
16149   return 0;
16150 }
16151 _ACEOF
16152 rm -f conftest.$ac_objext
16153 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16154   (eval $ac_compile) 2>&5
16155   ac_status=$?
16156   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16157   (exit $ac_status); } &&
16158          { ac_try='test -s conftest.$ac_objext'
16159   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16160   (eval $ac_try) 2>&5
16161   ac_status=$?
16162   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16163   (exit $ac_status); }; }; then
16164   ac_hi=$ac_mid
16165 else
16166   echo "$as_me: failed program was:" >&5
16167 cat conftest.$ac_ext >&5
16168 ac_lo=`expr '(' $ac_mid ')' + 1`
16169 fi
16170 rm -f conftest.$ac_objext conftest.$ac_ext
16171 done
16172 case $ac_lo in
16173 ?*) pgac_cv_alignof_int=$ac_lo;;
16174 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
16175 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
16176    { (exit 1); exit 1; }; } ;;
16177 esac
16178 else
16179   if test "$cross_compiling" = yes; then
16180   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
16181 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
16182    { (exit 1); exit 1; }; }
16183 else
16184   cat >conftest.$ac_ext <<_ACEOF
16185 #line $LINENO "configure"
16186 #include "confdefs.h"
16187 $ac_includes_default
16188 struct { char filler; int field; } pgac_struct;
16189 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16190 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16191 #include <stdio.h>
16192 #include <stdlib.h>
16193 #ifdef F77_DUMMY_MAIN
16194 #  ifdef __cplusplus
16195      extern "C"
16196 #  endif
16197    int F77_DUMMY_MAIN() { return 1; }
16198 #endif
16199 int
16200 main ()
16201 {
16202
16203   FILE *f = fopen ("conftest.val", "w");
16204   if (! f)
16205     exit (1);
16206   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
16207     {
16208       long i = longval ();
16209       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16210         exit (1);
16211       fprintf (f, "%ld\n", i);
16212     }
16213   else
16214     {
16215       unsigned long i = ulongval ();
16216       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16217         exit (1);
16218       fprintf (f, "%lu\n", i);
16219     }
16220   exit (ferror (f) || fclose (f) != 0);
16221
16222   ;
16223   return 0;
16224 }
16225 _ACEOF
16226 rm -f conftest$ac_exeext
16227 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16228   (eval $ac_link) 2>&5
16229   ac_status=$?
16230   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16231   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16232   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16233   (eval $ac_try) 2>&5
16234   ac_status=$?
16235   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16236   (exit $ac_status); }; }; then
16237   pgac_cv_alignof_int=`cat conftest.val`
16238 else
16239   echo "$as_me: program exited with status $ac_status" >&5
16240 echo "$as_me: failed program was:" >&5
16241 cat conftest.$ac_ext >&5
16242 ( exit $ac_status )
16243 { { echo "$as_me:$LINENO: error: cannot compute alignment of int, 77" >&5
16244 echo "$as_me: error: cannot compute alignment of int, 77" >&2;}
16245    { (exit 1); exit 1; }; }
16246 fi
16247 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16248 fi
16249 fi
16250 rm -f conftest.val
16251 else
16252   pgac_cv_alignof_int=0
16253 fi
16254 fi
16255 echo "$as_me:$LINENO: result: $pgac_cv_alignof_int" >&5
16256 echo "${ECHO_T}$pgac_cv_alignof_int" >&6
16257 cat >>confdefs.h <<_ACEOF
16258 #define ALIGNOF_INT $pgac_cv_alignof_int
16259 _ACEOF
16260
16261
16262 echo "$as_me:$LINENO: checking for long" >&5
16263 echo $ECHO_N "checking for long... $ECHO_C" >&6
16264 if test "${ac_cv_type_long+set}" = set; then
16265   echo $ECHO_N "(cached) $ECHO_C" >&6
16266 else
16267   cat >conftest.$ac_ext <<_ACEOF
16268 #line $LINENO "configure"
16269 #include "confdefs.h"
16270 $ac_includes_default
16271 #ifdef F77_DUMMY_MAIN
16272 #  ifdef __cplusplus
16273      extern "C"
16274 #  endif
16275    int F77_DUMMY_MAIN() { return 1; }
16276 #endif
16277 int
16278 main ()
16279 {
16280 if ((long *) 0)
16281   return 0;
16282 if (sizeof (long))
16283   return 0;
16284   ;
16285   return 0;
16286 }
16287 _ACEOF
16288 rm -f conftest.$ac_objext
16289 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16290   (eval $ac_compile) 2>&5
16291   ac_status=$?
16292   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16293   (exit $ac_status); } &&
16294          { ac_try='test -s conftest.$ac_objext'
16295   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16296   (eval $ac_try) 2>&5
16297   ac_status=$?
16298   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16299   (exit $ac_status); }; }; then
16300   ac_cv_type_long=yes
16301 else
16302   echo "$as_me: failed program was:" >&5
16303 cat conftest.$ac_ext >&5
16304 ac_cv_type_long=no
16305 fi
16306 rm -f conftest.$ac_objext conftest.$ac_ext
16307 fi
16308 echo "$as_me:$LINENO: result: $ac_cv_type_long" >&5
16309 echo "${ECHO_T}$ac_cv_type_long" >&6
16310
16311 echo "$as_me:$LINENO: checking alignment of long" >&5
16312 echo $ECHO_N "checking alignment of long... $ECHO_C" >&6
16313 if test "${pgac_cv_alignof_long+set}" = set; then
16314   echo $ECHO_N "(cached) $ECHO_C" >&6
16315 else
16316   if test "$ac_cv_type_long" = yes; then
16317   if test "$cross_compiling" = yes; then
16318   # Depending upon the size, compute the lo and hi bounds.
16319 cat >conftest.$ac_ext <<_ACEOF
16320 #line $LINENO "configure"
16321 #include "confdefs.h"
16322 $ac_includes_default
16323 struct { char filler; long field; } pgac_struct;
16324 #ifdef F77_DUMMY_MAIN
16325 #  ifdef __cplusplus
16326      extern "C"
16327 #  endif
16328    int F77_DUMMY_MAIN() { return 1; }
16329 #endif
16330 int
16331 main ()
16332 {
16333 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
16334 test_array [0] = 0
16335
16336   ;
16337   return 0;
16338 }
16339 _ACEOF
16340 rm -f conftest.$ac_objext
16341 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16342   (eval $ac_compile) 2>&5
16343   ac_status=$?
16344   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16345   (exit $ac_status); } &&
16346          { ac_try='test -s conftest.$ac_objext'
16347   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16348   (eval $ac_try) 2>&5
16349   ac_status=$?
16350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16351   (exit $ac_status); }; }; then
16352   ac_lo=0 ac_mid=0
16353   while :; do
16354     cat >conftest.$ac_ext <<_ACEOF
16355 #line $LINENO "configure"
16356 #include "confdefs.h"
16357 $ac_includes_default
16358 struct { char filler; long field; } pgac_struct;
16359 #ifdef F77_DUMMY_MAIN
16360 #  ifdef __cplusplus
16361      extern "C"
16362 #  endif
16363    int F77_DUMMY_MAIN() { return 1; }
16364 #endif
16365 int
16366 main ()
16367 {
16368 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16369 test_array [0] = 0
16370
16371   ;
16372   return 0;
16373 }
16374 _ACEOF
16375 rm -f conftest.$ac_objext
16376 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16377   (eval $ac_compile) 2>&5
16378   ac_status=$?
16379   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16380   (exit $ac_status); } &&
16381          { ac_try='test -s conftest.$ac_objext'
16382   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16383   (eval $ac_try) 2>&5
16384   ac_status=$?
16385   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16386   (exit $ac_status); }; }; then
16387   ac_hi=$ac_mid; break
16388 else
16389   echo "$as_me: failed program was:" >&5
16390 cat conftest.$ac_ext >&5
16391 ac_lo=`expr $ac_mid + 1`
16392                     if test $ac_lo -le $ac_mid; then
16393                       ac_lo= ac_hi=
16394                       break
16395                     fi
16396                     ac_mid=`expr 2 '*' $ac_mid + 1`
16397 fi
16398 rm -f conftest.$ac_objext conftest.$ac_ext
16399   done
16400 else
16401   echo "$as_me: failed program was:" >&5
16402 cat conftest.$ac_ext >&5
16403 cat >conftest.$ac_ext <<_ACEOF
16404 #line $LINENO "configure"
16405 #include "confdefs.h"
16406 $ac_includes_default
16407 struct { char filler; long field; } pgac_struct;
16408 #ifdef F77_DUMMY_MAIN
16409 #  ifdef __cplusplus
16410      extern "C"
16411 #  endif
16412    int F77_DUMMY_MAIN() { return 1; }
16413 #endif
16414 int
16415 main ()
16416 {
16417 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
16418 test_array [0] = 0
16419
16420   ;
16421   return 0;
16422 }
16423 _ACEOF
16424 rm -f conftest.$ac_objext
16425 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16426   (eval $ac_compile) 2>&5
16427   ac_status=$?
16428   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16429   (exit $ac_status); } &&
16430          { ac_try='test -s conftest.$ac_objext'
16431   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16432   (eval $ac_try) 2>&5
16433   ac_status=$?
16434   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16435   (exit $ac_status); }; }; then
16436   ac_hi=-1 ac_mid=-1
16437   while :; do
16438     cat >conftest.$ac_ext <<_ACEOF
16439 #line $LINENO "configure"
16440 #include "confdefs.h"
16441 $ac_includes_default
16442 struct { char filler; long field; } pgac_struct;
16443 #ifdef F77_DUMMY_MAIN
16444 #  ifdef __cplusplus
16445      extern "C"
16446 #  endif
16447    int F77_DUMMY_MAIN() { return 1; }
16448 #endif
16449 int
16450 main ()
16451 {
16452 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
16453 test_array [0] = 0
16454
16455   ;
16456   return 0;
16457 }
16458 _ACEOF
16459 rm -f conftest.$ac_objext
16460 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16461   (eval $ac_compile) 2>&5
16462   ac_status=$?
16463   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16464   (exit $ac_status); } &&
16465          { ac_try='test -s conftest.$ac_objext'
16466   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16467   (eval $ac_try) 2>&5
16468   ac_status=$?
16469   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16470   (exit $ac_status); }; }; then
16471   ac_lo=$ac_mid; break
16472 else
16473   echo "$as_me: failed program was:" >&5
16474 cat conftest.$ac_ext >&5
16475 ac_hi=`expr '(' $ac_mid ')' - 1`
16476                        if test $ac_mid -le $ac_hi; then
16477                          ac_lo= ac_hi=
16478                          break
16479                        fi
16480                        ac_mid=`expr 2 '*' $ac_mid`
16481 fi
16482 rm -f conftest.$ac_objext conftest.$ac_ext
16483   done
16484 else
16485   echo "$as_me: failed program was:" >&5
16486 cat conftest.$ac_ext >&5
16487 ac_lo= ac_hi=
16488 fi
16489 rm -f conftest.$ac_objext conftest.$ac_ext
16490 fi
16491 rm -f conftest.$ac_objext conftest.$ac_ext
16492 # Binary search between lo and hi bounds.
16493 while test "x$ac_lo" != "x$ac_hi"; do
16494   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
16495   cat >conftest.$ac_ext <<_ACEOF
16496 #line $LINENO "configure"
16497 #include "confdefs.h"
16498 $ac_includes_default
16499 struct { char filler; long field; } pgac_struct;
16500 #ifdef F77_DUMMY_MAIN
16501 #  ifdef __cplusplus
16502      extern "C"
16503 #  endif
16504    int F77_DUMMY_MAIN() { return 1; }
16505 #endif
16506 int
16507 main ()
16508 {
16509 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16510 test_array [0] = 0
16511
16512   ;
16513   return 0;
16514 }
16515 _ACEOF
16516 rm -f conftest.$ac_objext
16517 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16518   (eval $ac_compile) 2>&5
16519   ac_status=$?
16520   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16521   (exit $ac_status); } &&
16522          { ac_try='test -s conftest.$ac_objext'
16523   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16524   (eval $ac_try) 2>&5
16525   ac_status=$?
16526   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16527   (exit $ac_status); }; }; then
16528   ac_hi=$ac_mid
16529 else
16530   echo "$as_me: failed program was:" >&5
16531 cat conftest.$ac_ext >&5
16532 ac_lo=`expr '(' $ac_mid ')' + 1`
16533 fi
16534 rm -f conftest.$ac_objext conftest.$ac_ext
16535 done
16536 case $ac_lo in
16537 ?*) pgac_cv_alignof_long=$ac_lo;;
16538 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
16539 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
16540    { (exit 1); exit 1; }; } ;;
16541 esac
16542 else
16543   if test "$cross_compiling" = yes; then
16544   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
16545 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
16546    { (exit 1); exit 1; }; }
16547 else
16548   cat >conftest.$ac_ext <<_ACEOF
16549 #line $LINENO "configure"
16550 #include "confdefs.h"
16551 $ac_includes_default
16552 struct { char filler; long field; } pgac_struct;
16553 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16554 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16555 #include <stdio.h>
16556 #include <stdlib.h>
16557 #ifdef F77_DUMMY_MAIN
16558 #  ifdef __cplusplus
16559      extern "C"
16560 #  endif
16561    int F77_DUMMY_MAIN() { return 1; }
16562 #endif
16563 int
16564 main ()
16565 {
16566
16567   FILE *f = fopen ("conftest.val", "w");
16568   if (! f)
16569     exit (1);
16570   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
16571     {
16572       long i = longval ();
16573       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16574         exit (1);
16575       fprintf (f, "%ld\n", i);
16576     }
16577   else
16578     {
16579       unsigned long i = ulongval ();
16580       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16581         exit (1);
16582       fprintf (f, "%lu\n", i);
16583     }
16584   exit (ferror (f) || fclose (f) != 0);
16585
16586   ;
16587   return 0;
16588 }
16589 _ACEOF
16590 rm -f conftest$ac_exeext
16591 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16592   (eval $ac_link) 2>&5
16593   ac_status=$?
16594   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16595   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16596   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16597   (eval $ac_try) 2>&5
16598   ac_status=$?
16599   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16600   (exit $ac_status); }; }; then
16601   pgac_cv_alignof_long=`cat conftest.val`
16602 else
16603   echo "$as_me: program exited with status $ac_status" >&5
16604 echo "$as_me: failed program was:" >&5
16605 cat conftest.$ac_ext >&5
16606 ( exit $ac_status )
16607 { { echo "$as_me:$LINENO: error: cannot compute alignment of long, 77" >&5
16608 echo "$as_me: error: cannot compute alignment of long, 77" >&2;}
16609    { (exit 1); exit 1; }; }
16610 fi
16611 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16612 fi
16613 fi
16614 rm -f conftest.val
16615 else
16616   pgac_cv_alignof_long=0
16617 fi
16618 fi
16619 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long" >&5
16620 echo "${ECHO_T}$pgac_cv_alignof_long" >&6
16621 cat >>confdefs.h <<_ACEOF
16622 #define ALIGNOF_LONG $pgac_cv_alignof_long
16623 _ACEOF
16624
16625
16626 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
16627   echo "$as_me:$LINENO: checking for long long int" >&5
16628 echo $ECHO_N "checking for long long int... $ECHO_C" >&6
16629 if test "${ac_cv_type_long_long_int+set}" = set; then
16630   echo $ECHO_N "(cached) $ECHO_C" >&6
16631 else
16632   cat >conftest.$ac_ext <<_ACEOF
16633 #line $LINENO "configure"
16634 #include "confdefs.h"
16635 $ac_includes_default
16636 #ifdef F77_DUMMY_MAIN
16637 #  ifdef __cplusplus
16638      extern "C"
16639 #  endif
16640    int F77_DUMMY_MAIN() { return 1; }
16641 #endif
16642 int
16643 main ()
16644 {
16645 if ((long long int *) 0)
16646   return 0;
16647 if (sizeof (long long int))
16648   return 0;
16649   ;
16650   return 0;
16651 }
16652 _ACEOF
16653 rm -f conftest.$ac_objext
16654 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16655   (eval $ac_compile) 2>&5
16656   ac_status=$?
16657   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16658   (exit $ac_status); } &&
16659          { ac_try='test -s conftest.$ac_objext'
16660   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16661   (eval $ac_try) 2>&5
16662   ac_status=$?
16663   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16664   (exit $ac_status); }; }; then
16665   ac_cv_type_long_long_int=yes
16666 else
16667   echo "$as_me: failed program was:" >&5
16668 cat conftest.$ac_ext >&5
16669 ac_cv_type_long_long_int=no
16670 fi
16671 rm -f conftest.$ac_objext conftest.$ac_ext
16672 fi
16673 echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
16674 echo "${ECHO_T}$ac_cv_type_long_long_int" >&6
16675
16676 echo "$as_me:$LINENO: checking alignment of long long int" >&5
16677 echo $ECHO_N "checking alignment of long long int... $ECHO_C" >&6
16678 if test "${pgac_cv_alignof_long_long_int+set}" = set; then
16679   echo $ECHO_N "(cached) $ECHO_C" >&6
16680 else
16681   if test "$ac_cv_type_long_long_int" = yes; then
16682   if test "$cross_compiling" = yes; then
16683   # Depending upon the size, compute the lo and hi bounds.
16684 cat >conftest.$ac_ext <<_ACEOF
16685 #line $LINENO "configure"
16686 #include "confdefs.h"
16687 $ac_includes_default
16688 struct { char filler; long long int field; } pgac_struct;
16689 #ifdef F77_DUMMY_MAIN
16690 #  ifdef __cplusplus
16691      extern "C"
16692 #  endif
16693    int F77_DUMMY_MAIN() { return 1; }
16694 #endif
16695 int
16696 main ()
16697 {
16698 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
16699 test_array [0] = 0
16700
16701   ;
16702   return 0;
16703 }
16704 _ACEOF
16705 rm -f conftest.$ac_objext
16706 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16707   (eval $ac_compile) 2>&5
16708   ac_status=$?
16709   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16710   (exit $ac_status); } &&
16711          { ac_try='test -s conftest.$ac_objext'
16712   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16713   (eval $ac_try) 2>&5
16714   ac_status=$?
16715   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16716   (exit $ac_status); }; }; then
16717   ac_lo=0 ac_mid=0
16718   while :; do
16719     cat >conftest.$ac_ext <<_ACEOF
16720 #line $LINENO "configure"
16721 #include "confdefs.h"
16722 $ac_includes_default
16723 struct { char filler; long long int field; } pgac_struct;
16724 #ifdef F77_DUMMY_MAIN
16725 #  ifdef __cplusplus
16726      extern "C"
16727 #  endif
16728    int F77_DUMMY_MAIN() { return 1; }
16729 #endif
16730 int
16731 main ()
16732 {
16733 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16734 test_array [0] = 0
16735
16736   ;
16737   return 0;
16738 }
16739 _ACEOF
16740 rm -f conftest.$ac_objext
16741 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16742   (eval $ac_compile) 2>&5
16743   ac_status=$?
16744   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16745   (exit $ac_status); } &&
16746          { ac_try='test -s conftest.$ac_objext'
16747   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16748   (eval $ac_try) 2>&5
16749   ac_status=$?
16750   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16751   (exit $ac_status); }; }; then
16752   ac_hi=$ac_mid; break
16753 else
16754   echo "$as_me: failed program was:" >&5
16755 cat conftest.$ac_ext >&5
16756 ac_lo=`expr $ac_mid + 1`
16757                     if test $ac_lo -le $ac_mid; then
16758                       ac_lo= ac_hi=
16759                       break
16760                     fi
16761                     ac_mid=`expr 2 '*' $ac_mid + 1`
16762 fi
16763 rm -f conftest.$ac_objext conftest.$ac_ext
16764   done
16765 else
16766   echo "$as_me: failed program was:" >&5
16767 cat conftest.$ac_ext >&5
16768 cat >conftest.$ac_ext <<_ACEOF
16769 #line $LINENO "configure"
16770 #include "confdefs.h"
16771 $ac_includes_default
16772 struct { char filler; long long int field; } pgac_struct;
16773 #ifdef F77_DUMMY_MAIN
16774 #  ifdef __cplusplus
16775      extern "C"
16776 #  endif
16777    int F77_DUMMY_MAIN() { return 1; }
16778 #endif
16779 int
16780 main ()
16781 {
16782 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
16783 test_array [0] = 0
16784
16785   ;
16786   return 0;
16787 }
16788 _ACEOF
16789 rm -f conftest.$ac_objext
16790 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16791   (eval $ac_compile) 2>&5
16792   ac_status=$?
16793   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16794   (exit $ac_status); } &&
16795          { ac_try='test -s conftest.$ac_objext'
16796   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16797   (eval $ac_try) 2>&5
16798   ac_status=$?
16799   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16800   (exit $ac_status); }; }; then
16801   ac_hi=-1 ac_mid=-1
16802   while :; do
16803     cat >conftest.$ac_ext <<_ACEOF
16804 #line $LINENO "configure"
16805 #include "confdefs.h"
16806 $ac_includes_default
16807 struct { char filler; long long int field; } pgac_struct;
16808 #ifdef F77_DUMMY_MAIN
16809 #  ifdef __cplusplus
16810      extern "C"
16811 #  endif
16812    int F77_DUMMY_MAIN() { return 1; }
16813 #endif
16814 int
16815 main ()
16816 {
16817 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
16818 test_array [0] = 0
16819
16820   ;
16821   return 0;
16822 }
16823 _ACEOF
16824 rm -f conftest.$ac_objext
16825 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16826   (eval $ac_compile) 2>&5
16827   ac_status=$?
16828   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16829   (exit $ac_status); } &&
16830          { ac_try='test -s conftest.$ac_objext'
16831   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16832   (eval $ac_try) 2>&5
16833   ac_status=$?
16834   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16835   (exit $ac_status); }; }; then
16836   ac_lo=$ac_mid; break
16837 else
16838   echo "$as_me: failed program was:" >&5
16839 cat conftest.$ac_ext >&5
16840 ac_hi=`expr '(' $ac_mid ')' - 1`
16841                        if test $ac_mid -le $ac_hi; then
16842                          ac_lo= ac_hi=
16843                          break
16844                        fi
16845                        ac_mid=`expr 2 '*' $ac_mid`
16846 fi
16847 rm -f conftest.$ac_objext conftest.$ac_ext
16848   done
16849 else
16850   echo "$as_me: failed program was:" >&5
16851 cat conftest.$ac_ext >&5
16852 ac_lo= ac_hi=
16853 fi
16854 rm -f conftest.$ac_objext conftest.$ac_ext
16855 fi
16856 rm -f conftest.$ac_objext conftest.$ac_ext
16857 # Binary search between lo and hi bounds.
16858 while test "x$ac_lo" != "x$ac_hi"; do
16859   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
16860   cat >conftest.$ac_ext <<_ACEOF
16861 #line $LINENO "configure"
16862 #include "confdefs.h"
16863 $ac_includes_default
16864 struct { char filler; long long int field; } pgac_struct;
16865 #ifdef F77_DUMMY_MAIN
16866 #  ifdef __cplusplus
16867      extern "C"
16868 #  endif
16869    int F77_DUMMY_MAIN() { return 1; }
16870 #endif
16871 int
16872 main ()
16873 {
16874 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
16875 test_array [0] = 0
16876
16877   ;
16878   return 0;
16879 }
16880 _ACEOF
16881 rm -f conftest.$ac_objext
16882 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
16883   (eval $ac_compile) 2>&5
16884   ac_status=$?
16885   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16886   (exit $ac_status); } &&
16887          { ac_try='test -s conftest.$ac_objext'
16888   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16889   (eval $ac_try) 2>&5
16890   ac_status=$?
16891   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16892   (exit $ac_status); }; }; then
16893   ac_hi=$ac_mid
16894 else
16895   echo "$as_me: failed program was:" >&5
16896 cat conftest.$ac_ext >&5
16897 ac_lo=`expr '(' $ac_mid ')' + 1`
16898 fi
16899 rm -f conftest.$ac_objext conftest.$ac_ext
16900 done
16901 case $ac_lo in
16902 ?*) pgac_cv_alignof_long_long_int=$ac_lo;;
16903 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
16904 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
16905    { (exit 1); exit 1; }; } ;;
16906 esac
16907 else
16908   if test "$cross_compiling" = yes; then
16909   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
16910 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
16911    { (exit 1); exit 1; }; }
16912 else
16913   cat >conftest.$ac_ext <<_ACEOF
16914 #line $LINENO "configure"
16915 #include "confdefs.h"
16916 $ac_includes_default
16917 struct { char filler; long long int field; } pgac_struct;
16918 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16919 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
16920 #include <stdio.h>
16921 #include <stdlib.h>
16922 #ifdef F77_DUMMY_MAIN
16923 #  ifdef __cplusplus
16924      extern "C"
16925 #  endif
16926    int F77_DUMMY_MAIN() { return 1; }
16927 #endif
16928 int
16929 main ()
16930 {
16931
16932   FILE *f = fopen ("conftest.val", "w");
16933   if (! f)
16934     exit (1);
16935   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
16936     {
16937       long i = longval ();
16938       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16939         exit (1);
16940       fprintf (f, "%ld\n", i);
16941     }
16942   else
16943     {
16944       unsigned long i = ulongval ();
16945       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
16946         exit (1);
16947       fprintf (f, "%lu\n", i);
16948     }
16949   exit (ferror (f) || fclose (f) != 0);
16950
16951   ;
16952   return 0;
16953 }
16954 _ACEOF
16955 rm -f conftest$ac_exeext
16956 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
16957   (eval $ac_link) 2>&5
16958   ac_status=$?
16959   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16960   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16961   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
16962   (eval $ac_try) 2>&5
16963   ac_status=$?
16964   echo "$as_me:$LINENO: \$? = $ac_status" >&5
16965   (exit $ac_status); }; }; then
16966   pgac_cv_alignof_long_long_int=`cat conftest.val`
16967 else
16968   echo "$as_me: program exited with status $ac_status" >&5
16969 echo "$as_me: failed program was:" >&5
16970 cat conftest.$ac_ext >&5
16971 ( exit $ac_status )
16972 { { echo "$as_me:$LINENO: error: cannot compute alignment of long long int, 77" >&5
16973 echo "$as_me: error: cannot compute alignment of long long int, 77" >&2;}
16974    { (exit 1); exit 1; }; }
16975 fi
16976 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16977 fi
16978 fi
16979 rm -f conftest.val
16980 else
16981   pgac_cv_alignof_long_long_int=0
16982 fi
16983 fi
16984 echo "$as_me:$LINENO: result: $pgac_cv_alignof_long_long_int" >&5
16985 echo "${ECHO_T}$pgac_cv_alignof_long_long_int" >&6
16986 cat >>confdefs.h <<_ACEOF
16987 #define ALIGNOF_LONG_LONG_INT $pgac_cv_alignof_long_long_int
16988 _ACEOF
16989
16990
16991 fi
16992 echo "$as_me:$LINENO: checking for double" >&5
16993 echo $ECHO_N "checking for double... $ECHO_C" >&6
16994 if test "${ac_cv_type_double+set}" = set; then
16995   echo $ECHO_N "(cached) $ECHO_C" >&6
16996 else
16997   cat >conftest.$ac_ext <<_ACEOF
16998 #line $LINENO "configure"
16999 #include "confdefs.h"
17000 $ac_includes_default
17001 #ifdef F77_DUMMY_MAIN
17002 #  ifdef __cplusplus
17003      extern "C"
17004 #  endif
17005    int F77_DUMMY_MAIN() { return 1; }
17006 #endif
17007 int
17008 main ()
17009 {
17010 if ((double *) 0)
17011   return 0;
17012 if (sizeof (double))
17013   return 0;
17014   ;
17015   return 0;
17016 }
17017 _ACEOF
17018 rm -f conftest.$ac_objext
17019 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17020   (eval $ac_compile) 2>&5
17021   ac_status=$?
17022   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17023   (exit $ac_status); } &&
17024          { ac_try='test -s conftest.$ac_objext'
17025   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17026   (eval $ac_try) 2>&5
17027   ac_status=$?
17028   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17029   (exit $ac_status); }; }; then
17030   ac_cv_type_double=yes
17031 else
17032   echo "$as_me: failed program was:" >&5
17033 cat conftest.$ac_ext >&5
17034 ac_cv_type_double=no
17035 fi
17036 rm -f conftest.$ac_objext conftest.$ac_ext
17037 fi
17038 echo "$as_me:$LINENO: result: $ac_cv_type_double" >&5
17039 echo "${ECHO_T}$ac_cv_type_double" >&6
17040
17041 echo "$as_me:$LINENO: checking alignment of double" >&5
17042 echo $ECHO_N "checking alignment of double... $ECHO_C" >&6
17043 if test "${pgac_cv_alignof_double+set}" = set; then
17044   echo $ECHO_N "(cached) $ECHO_C" >&6
17045 else
17046   if test "$ac_cv_type_double" = yes; then
17047   if test "$cross_compiling" = yes; then
17048   # Depending upon the size, compute the lo and hi bounds.
17049 cat >conftest.$ac_ext <<_ACEOF
17050 #line $LINENO "configure"
17051 #include "confdefs.h"
17052 $ac_includes_default
17053 struct { char filler; double field; } pgac_struct;
17054 #ifdef F77_DUMMY_MAIN
17055 #  ifdef __cplusplus
17056      extern "C"
17057 #  endif
17058    int F77_DUMMY_MAIN() { return 1; }
17059 #endif
17060 int
17061 main ()
17062 {
17063 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= 0)];
17064 test_array [0] = 0
17065
17066   ;
17067   return 0;
17068 }
17069 _ACEOF
17070 rm -f conftest.$ac_objext
17071 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17072   (eval $ac_compile) 2>&5
17073   ac_status=$?
17074   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17075   (exit $ac_status); } &&
17076          { ac_try='test -s conftest.$ac_objext'
17077   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17078   (eval $ac_try) 2>&5
17079   ac_status=$?
17080   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17081   (exit $ac_status); }; }; then
17082   ac_lo=0 ac_mid=0
17083   while :; do
17084     cat >conftest.$ac_ext <<_ACEOF
17085 #line $LINENO "configure"
17086 #include "confdefs.h"
17087 $ac_includes_default
17088 struct { char filler; double field; } pgac_struct;
17089 #ifdef F77_DUMMY_MAIN
17090 #  ifdef __cplusplus
17091      extern "C"
17092 #  endif
17093    int F77_DUMMY_MAIN() { return 1; }
17094 #endif
17095 int
17096 main ()
17097 {
17098 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
17099 test_array [0] = 0
17100
17101   ;
17102   return 0;
17103 }
17104 _ACEOF
17105 rm -f conftest.$ac_objext
17106 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17107   (eval $ac_compile) 2>&5
17108   ac_status=$?
17109   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17110   (exit $ac_status); } &&
17111          { ac_try='test -s conftest.$ac_objext'
17112   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17113   (eval $ac_try) 2>&5
17114   ac_status=$?
17115   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17116   (exit $ac_status); }; }; then
17117   ac_hi=$ac_mid; break
17118 else
17119   echo "$as_me: failed program was:" >&5
17120 cat conftest.$ac_ext >&5
17121 ac_lo=`expr $ac_mid + 1`
17122                     if test $ac_lo -le $ac_mid; then
17123                       ac_lo= ac_hi=
17124                       break
17125                     fi
17126                     ac_mid=`expr 2 '*' $ac_mid + 1`
17127 fi
17128 rm -f conftest.$ac_objext conftest.$ac_ext
17129   done
17130 else
17131   echo "$as_me: failed program was:" >&5
17132 cat conftest.$ac_ext >&5
17133 cat >conftest.$ac_ext <<_ACEOF
17134 #line $LINENO "configure"
17135 #include "confdefs.h"
17136 $ac_includes_default
17137 struct { char filler; double field; } pgac_struct;
17138 #ifdef F77_DUMMY_MAIN
17139 #  ifdef __cplusplus
17140      extern "C"
17141 #  endif
17142    int F77_DUMMY_MAIN() { return 1; }
17143 #endif
17144 int
17145 main ()
17146 {
17147 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)];
17148 test_array [0] = 0
17149
17150   ;
17151   return 0;
17152 }
17153 _ACEOF
17154 rm -f conftest.$ac_objext
17155 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17156   (eval $ac_compile) 2>&5
17157   ac_status=$?
17158   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17159   (exit $ac_status); } &&
17160          { ac_try='test -s conftest.$ac_objext'
17161   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17162   (eval $ac_try) 2>&5
17163   ac_status=$?
17164   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17165   (exit $ac_status); }; }; then
17166   ac_hi=-1 ac_mid=-1
17167   while :; do
17168     cat >conftest.$ac_ext <<_ACEOF
17169 #line $LINENO "configure"
17170 #include "confdefs.h"
17171 $ac_includes_default
17172 struct { char filler; double field; } pgac_struct;
17173 #ifdef F77_DUMMY_MAIN
17174 #  ifdef __cplusplus
17175      extern "C"
17176 #  endif
17177    int F77_DUMMY_MAIN() { return 1; }
17178 #endif
17179 int
17180 main ()
17181 {
17182 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) >= $ac_mid)];
17183 test_array [0] = 0
17184
17185   ;
17186   return 0;
17187 }
17188 _ACEOF
17189 rm -f conftest.$ac_objext
17190 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17191   (eval $ac_compile) 2>&5
17192   ac_status=$?
17193   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17194   (exit $ac_status); } &&
17195          { ac_try='test -s conftest.$ac_objext'
17196   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17197   (eval $ac_try) 2>&5
17198   ac_status=$?
17199   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17200   (exit $ac_status); }; }; then
17201   ac_lo=$ac_mid; break
17202 else
17203   echo "$as_me: failed program was:" >&5
17204 cat conftest.$ac_ext >&5
17205 ac_hi=`expr '(' $ac_mid ')' - 1`
17206                        if test $ac_mid -le $ac_hi; then
17207                          ac_lo= ac_hi=
17208                          break
17209                        fi
17210                        ac_mid=`expr 2 '*' $ac_mid`
17211 fi
17212 rm -f conftest.$ac_objext conftest.$ac_ext
17213   done
17214 else
17215   echo "$as_me: failed program was:" >&5
17216 cat conftest.$ac_ext >&5
17217 ac_lo= ac_hi=
17218 fi
17219 rm -f conftest.$ac_objext conftest.$ac_ext
17220 fi
17221 rm -f conftest.$ac_objext conftest.$ac_ext
17222 # Binary search between lo and hi bounds.
17223 while test "x$ac_lo" != "x$ac_hi"; do
17224   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
17225   cat >conftest.$ac_ext <<_ACEOF
17226 #line $LINENO "configure"
17227 #include "confdefs.h"
17228 $ac_includes_default
17229 struct { char filler; double field; } pgac_struct;
17230 #ifdef F77_DUMMY_MAIN
17231 #  ifdef __cplusplus
17232      extern "C"
17233 #  endif
17234    int F77_DUMMY_MAIN() { return 1; }
17235 #endif
17236 int
17237 main ()
17238 {
17239 static int test_array [1 - 2 * !((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) <= $ac_mid)];
17240 test_array [0] = 0
17241
17242   ;
17243   return 0;
17244 }
17245 _ACEOF
17246 rm -f conftest.$ac_objext
17247 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17248   (eval $ac_compile) 2>&5
17249   ac_status=$?
17250   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17251   (exit $ac_status); } &&
17252          { ac_try='test -s conftest.$ac_objext'
17253   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17254   (eval $ac_try) 2>&5
17255   ac_status=$?
17256   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17257   (exit $ac_status); }; }; then
17258   ac_hi=$ac_mid
17259 else
17260   echo "$as_me: failed program was:" >&5
17261 cat conftest.$ac_ext >&5
17262 ac_lo=`expr '(' $ac_mid ')' + 1`
17263 fi
17264 rm -f conftest.$ac_objext conftest.$ac_ext
17265 done
17266 case $ac_lo in
17267 ?*) pgac_cv_alignof_double=$ac_lo;;
17268 '') { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
17269 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
17270    { (exit 1); exit 1; }; } ;;
17271 esac
17272 else
17273   if test "$cross_compiling" = yes; then
17274   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling" >&5
17275 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
17276    { (exit 1); exit 1; }; }
17277 else
17278   cat >conftest.$ac_ext <<_ACEOF
17279 #line $LINENO "configure"
17280 #include "confdefs.h"
17281 $ac_includes_default
17282 struct { char filler; double field; } pgac_struct;
17283 long longval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
17284 unsigned long ulongval () { return ((char*) & pgac_struct.field) - ((char*) & pgac_struct); }
17285 #include <stdio.h>
17286 #include <stdlib.h>
17287 #ifdef F77_DUMMY_MAIN
17288 #  ifdef __cplusplus
17289      extern "C"
17290 #  endif
17291    int F77_DUMMY_MAIN() { return 1; }
17292 #endif
17293 int
17294 main ()
17295 {
17296
17297   FILE *f = fopen ("conftest.val", "w");
17298   if (! f)
17299     exit (1);
17300   if ((((char*) & pgac_struct.field) - ((char*) & pgac_struct)) < 0)
17301     {
17302       long i = longval ();
17303       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
17304         exit (1);
17305       fprintf (f, "%ld\n", i);
17306     }
17307   else
17308     {
17309       unsigned long i = ulongval ();
17310       if (i != (((char*) & pgac_struct.field) - ((char*) & pgac_struct)))
17311         exit (1);
17312       fprintf (f, "%lu\n", i);
17313     }
17314   exit (ferror (f) || fclose (f) != 0);
17315
17316   ;
17317   return 0;
17318 }
17319 _ACEOF
17320 rm -f conftest$ac_exeext
17321 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17322   (eval $ac_link) 2>&5
17323   ac_status=$?
17324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17325   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
17326   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17327   (eval $ac_try) 2>&5
17328   ac_status=$?
17329   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17330   (exit $ac_status); }; }; then
17331   pgac_cv_alignof_double=`cat conftest.val`
17332 else
17333   echo "$as_me: program exited with status $ac_status" >&5
17334 echo "$as_me: failed program was:" >&5
17335 cat conftest.$ac_ext >&5
17336 ( exit $ac_status )
17337 { { echo "$as_me:$LINENO: error: cannot compute alignment of double, 77" >&5
17338 echo "$as_me: error: cannot compute alignment of double, 77" >&2;}
17339    { (exit 1); exit 1; }; }
17340 fi
17341 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
17342 fi
17343 fi
17344 rm -f conftest.val
17345 else
17346   pgac_cv_alignof_double=0
17347 fi
17348 fi
17349 echo "$as_me:$LINENO: result: $pgac_cv_alignof_double" >&5
17350 echo "${ECHO_T}$pgac_cv_alignof_double" >&6
17351 cat >>confdefs.h <<_ACEOF
17352 #define ALIGNOF_DOUBLE $pgac_cv_alignof_double
17353 _ACEOF
17354
17355
17356
17357 # Compute maximum alignment of any basic type.
17358 # We assume long's alignment is at least as strong as char, short, or int;
17359 # but we must check long long (if it exists) and double.
17360
17361 MAX_ALIGNOF=$pgac_cv_alignof_long
17362 if test $MAX_ALIGNOF -lt $pgac_cv_alignof_double ; then
17363   MAX_ALIGNOF=$pgac_cv_alignof_double
17364 fi
17365 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $pgac_cv_alignof_long_long_int ; then
17366   MAX_ALIGNOF="$pgac_cv_alignof_long_long_int"
17367 fi
17368
17369 cat >>confdefs.h <<_ACEOF
17370 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
17371 _ACEOF
17372
17373
17374
17375 # Some platforms predefine the types int8, int16, etc.  Only check
17376 # a (hopefully) representative subset.
17377 echo "$as_me:$LINENO: checking for int8" >&5
17378 echo $ECHO_N "checking for int8... $ECHO_C" >&6
17379 if test "${ac_cv_type_int8+set}" = set; then
17380   echo $ECHO_N "(cached) $ECHO_C" >&6
17381 else
17382   cat >conftest.$ac_ext <<_ACEOF
17383 #line $LINENO "configure"
17384 #include "confdefs.h"
17385 #include <stdio.h>
17386 #ifdef HAVE_SUPPORTDEFS_H
17387 #include <SupportDefs.h>
17388 #endif
17389
17390 #ifdef F77_DUMMY_MAIN
17391 #  ifdef __cplusplus
17392      extern "C"
17393 #  endif
17394    int F77_DUMMY_MAIN() { return 1; }
17395 #endif
17396 int
17397 main ()
17398 {
17399 if ((int8 *) 0)
17400   return 0;
17401 if (sizeof (int8))
17402   return 0;
17403   ;
17404   return 0;
17405 }
17406 _ACEOF
17407 rm -f conftest.$ac_objext
17408 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17409   (eval $ac_compile) 2>&5
17410   ac_status=$?
17411   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17412   (exit $ac_status); } &&
17413          { ac_try='test -s conftest.$ac_objext'
17414   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17415   (eval $ac_try) 2>&5
17416   ac_status=$?
17417   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17418   (exit $ac_status); }; }; then
17419   ac_cv_type_int8=yes
17420 else
17421   echo "$as_me: failed program was:" >&5
17422 cat conftest.$ac_ext >&5
17423 ac_cv_type_int8=no
17424 fi
17425 rm -f conftest.$ac_objext conftest.$ac_ext
17426 fi
17427 echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
17428 echo "${ECHO_T}$ac_cv_type_int8" >&6
17429 if test $ac_cv_type_int8 = yes; then
17430
17431 cat >>confdefs.h <<_ACEOF
17432 #define HAVE_INT8 1
17433 _ACEOF
17434
17435
17436 fi
17437 echo "$as_me:$LINENO: checking for uint8" >&5
17438 echo $ECHO_N "checking for uint8... $ECHO_C" >&6
17439 if test "${ac_cv_type_uint8+set}" = set; then
17440   echo $ECHO_N "(cached) $ECHO_C" >&6
17441 else
17442   cat >conftest.$ac_ext <<_ACEOF
17443 #line $LINENO "configure"
17444 #include "confdefs.h"
17445 #include <stdio.h>
17446 #ifdef HAVE_SUPPORTDEFS_H
17447 #include <SupportDefs.h>
17448 #endif
17449
17450 #ifdef F77_DUMMY_MAIN
17451 #  ifdef __cplusplus
17452      extern "C"
17453 #  endif
17454    int F77_DUMMY_MAIN() { return 1; }
17455 #endif
17456 int
17457 main ()
17458 {
17459 if ((uint8 *) 0)
17460   return 0;
17461 if (sizeof (uint8))
17462   return 0;
17463   ;
17464   return 0;
17465 }
17466 _ACEOF
17467 rm -f conftest.$ac_objext
17468 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17469   (eval $ac_compile) 2>&5
17470   ac_status=$?
17471   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17472   (exit $ac_status); } &&
17473          { ac_try='test -s conftest.$ac_objext'
17474   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17475   (eval $ac_try) 2>&5
17476   ac_status=$?
17477   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17478   (exit $ac_status); }; }; then
17479   ac_cv_type_uint8=yes
17480 else
17481   echo "$as_me: failed program was:" >&5
17482 cat conftest.$ac_ext >&5
17483 ac_cv_type_uint8=no
17484 fi
17485 rm -f conftest.$ac_objext conftest.$ac_ext
17486 fi
17487 echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
17488 echo "${ECHO_T}$ac_cv_type_uint8" >&6
17489 if test $ac_cv_type_uint8 = yes; then
17490
17491 cat >>confdefs.h <<_ACEOF
17492 #define HAVE_UINT8 1
17493 _ACEOF
17494
17495
17496 fi
17497 echo "$as_me:$LINENO: checking for int64" >&5
17498 echo $ECHO_N "checking for int64... $ECHO_C" >&6
17499 if test "${ac_cv_type_int64+set}" = set; then
17500   echo $ECHO_N "(cached) $ECHO_C" >&6
17501 else
17502   cat >conftest.$ac_ext <<_ACEOF
17503 #line $LINENO "configure"
17504 #include "confdefs.h"
17505 #include <stdio.h>
17506 #ifdef HAVE_SUPPORTDEFS_H
17507 #include <SupportDefs.h>
17508 #endif
17509
17510 #ifdef F77_DUMMY_MAIN
17511 #  ifdef __cplusplus
17512      extern "C"
17513 #  endif
17514    int F77_DUMMY_MAIN() { return 1; }
17515 #endif
17516 int
17517 main ()
17518 {
17519 if ((int64 *) 0)
17520   return 0;
17521 if (sizeof (int64))
17522   return 0;
17523   ;
17524   return 0;
17525 }
17526 _ACEOF
17527 rm -f conftest.$ac_objext
17528 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17529   (eval $ac_compile) 2>&5
17530   ac_status=$?
17531   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17532   (exit $ac_status); } &&
17533          { ac_try='test -s conftest.$ac_objext'
17534   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17535   (eval $ac_try) 2>&5
17536   ac_status=$?
17537   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17538   (exit $ac_status); }; }; then
17539   ac_cv_type_int64=yes
17540 else
17541   echo "$as_me: failed program was:" >&5
17542 cat conftest.$ac_ext >&5
17543 ac_cv_type_int64=no
17544 fi
17545 rm -f conftest.$ac_objext conftest.$ac_ext
17546 fi
17547 echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
17548 echo "${ECHO_T}$ac_cv_type_int64" >&6
17549 if test $ac_cv_type_int64 = yes; then
17550
17551 cat >>confdefs.h <<_ACEOF
17552 #define HAVE_INT64 1
17553 _ACEOF
17554
17555
17556 fi
17557 echo "$as_me:$LINENO: checking for uint64" >&5
17558 echo $ECHO_N "checking for uint64... $ECHO_C" >&6
17559 if test "${ac_cv_type_uint64+set}" = set; then
17560   echo $ECHO_N "(cached) $ECHO_C" >&6
17561 else
17562   cat >conftest.$ac_ext <<_ACEOF
17563 #line $LINENO "configure"
17564 #include "confdefs.h"
17565 #include <stdio.h>
17566 #ifdef HAVE_SUPPORTDEFS_H
17567 #include <SupportDefs.h>
17568 #endif
17569
17570 #ifdef F77_DUMMY_MAIN
17571 #  ifdef __cplusplus
17572      extern "C"
17573 #  endif
17574    int F77_DUMMY_MAIN() { return 1; }
17575 #endif
17576 int
17577 main ()
17578 {
17579 if ((uint64 *) 0)
17580   return 0;
17581 if (sizeof (uint64))
17582   return 0;
17583   ;
17584   return 0;
17585 }
17586 _ACEOF
17587 rm -f conftest.$ac_objext
17588 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17589   (eval $ac_compile) 2>&5
17590   ac_status=$?
17591   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17592   (exit $ac_status); } &&
17593          { ac_try='test -s conftest.$ac_objext'
17594   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17595   (eval $ac_try) 2>&5
17596   ac_status=$?
17597   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17598   (exit $ac_status); }; }; then
17599   ac_cv_type_uint64=yes
17600 else
17601   echo "$as_me: failed program was:" >&5
17602 cat conftest.$ac_ext >&5
17603 ac_cv_type_uint64=no
17604 fi
17605 rm -f conftest.$ac_objext conftest.$ac_ext
17606 fi
17607 echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
17608 echo "${ECHO_T}$ac_cv_type_uint64" >&6
17609 if test $ac_cv_type_uint64 = yes; then
17610
17611 cat >>confdefs.h <<_ACEOF
17612 #define HAVE_UINT64 1
17613 _ACEOF
17614
17615
17616 fi
17617
17618
17619 # We also check for sig_atomic_t, which *should* be defined per ANSI
17620 # C, but is missing on some old platforms.
17621 echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
17622 echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6
17623 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
17624   echo $ECHO_N "(cached) $ECHO_C" >&6
17625 else
17626   cat >conftest.$ac_ext <<_ACEOF
17627 #line $LINENO "configure"
17628 #include "confdefs.h"
17629 #include <signal.h>
17630
17631 #ifdef F77_DUMMY_MAIN
17632 #  ifdef __cplusplus
17633      extern "C"
17634 #  endif
17635    int F77_DUMMY_MAIN() { return 1; }
17636 #endif
17637 int
17638 main ()
17639 {
17640 if ((sig_atomic_t *) 0)
17641   return 0;
17642 if (sizeof (sig_atomic_t))
17643   return 0;
17644   ;
17645   return 0;
17646 }
17647 _ACEOF
17648 rm -f conftest.$ac_objext
17649 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17650   (eval $ac_compile) 2>&5
17651   ac_status=$?
17652   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17653   (exit $ac_status); } &&
17654          { ac_try='test -s conftest.$ac_objext'
17655   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17656   (eval $ac_try) 2>&5
17657   ac_status=$?
17658   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17659   (exit $ac_status); }; }; then
17660   ac_cv_type_sig_atomic_t=yes
17661 else
17662   echo "$as_me: failed program was:" >&5
17663 cat conftest.$ac_ext >&5
17664 ac_cv_type_sig_atomic_t=no
17665 fi
17666 rm -f conftest.$ac_objext conftest.$ac_ext
17667 fi
17668 echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
17669 echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6
17670 if test $ac_cv_type_sig_atomic_t = yes; then
17671
17672 cat >>confdefs.h <<_ACEOF
17673 #define HAVE_SIG_ATOMIC_T 1
17674 _ACEOF
17675
17676
17677 fi
17678
17679
17680
17681 echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
17682 echo $ECHO_N "checking for POSIX signal interface... $ECHO_C" >&6
17683 if test "${pgac_cv_func_posix_signals+set}" = set; then
17684   echo $ECHO_N "(cached) $ECHO_C" >&6
17685 else
17686   cat >conftest.$ac_ext <<_ACEOF
17687 #line $LINENO "configure"
17688 #include "confdefs.h"
17689 #include <signal.h>
17690
17691 #ifdef F77_DUMMY_MAIN
17692 #  ifdef __cplusplus
17693      extern "C"
17694 #  endif
17695    int F77_DUMMY_MAIN() { return 1; }
17696 #endif
17697 int
17698 main ()
17699 {
17700 struct sigaction act, oact;
17701 sigemptyset(&act.sa_mask);
17702 act.sa_flags = SA_RESTART;
17703 sigaction(0, &act, &oact);
17704   ;
17705   return 0;
17706 }
17707 _ACEOF
17708 rm -f conftest.$ac_objext conftest$ac_exeext
17709 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
17710   (eval $ac_link) 2>&5
17711   ac_status=$?
17712   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17713   (exit $ac_status); } &&
17714          { ac_try='test -s conftest$ac_exeext'
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); }; }; then
17720   pgac_cv_func_posix_signals=yes
17721 else
17722   echo "$as_me: failed program was:" >&5
17723 cat conftest.$ac_ext >&5
17724 pgac_cv_func_posix_signals=no
17725 fi
17726 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
17727 fi
17728 echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
17729 echo "${ECHO_T}$pgac_cv_func_posix_signals" >&6
17730 if test x"$pgac_cv_func_posix_signals" = xyes ; then
17731
17732 cat >>confdefs.h <<\_ACEOF
17733 #define HAVE_POSIX_SIGNALS
17734 _ACEOF
17735
17736 fi
17737 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
17738
17739 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
17740   { { echo "$as_me:$LINENO: error:
17741 *** Thread-safety requires POSIX signals, which are not supported by your
17742 *** operating system.
17743 " >&5
17744 echo "$as_me: error:
17745 *** Thread-safety requires POSIX signals, which are not supported by your
17746 *** operating system.
17747 " >&2;}
17748    { (exit 1); exit 1; }; }
17749 fi
17750
17751 if test $ac_cv_func_fseeko = yes; then
17752 # Check whether --enable-largefile or --disable-largefile was given.
17753 if test "${enable_largefile+set}" = set; then
17754   enableval="$enable_largefile"
17755
17756 fi;
17757 if test "$enable_largefile" != no; then
17758
17759   echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
17760 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
17761 if test "${ac_cv_sys_largefile_CC+set}" = set; then
17762   echo $ECHO_N "(cached) $ECHO_C" >&6
17763 else
17764   ac_cv_sys_largefile_CC=no
17765      if test "$GCC" != yes; then
17766        ac_save_CC=$CC
17767        while :; do
17768          # IRIX 6.2 and later do not support large files by default,
17769          # so use the C compiler's -n32 option if that helps.
17770          cat >conftest.$ac_ext <<_ACEOF
17771 #line $LINENO "configure"
17772 #include "confdefs.h"
17773 #include <sys/types.h>
17774  /* Check that off_t can represent 2**63 - 1 correctly.
17775     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17776     since some C++ compilers masquerading as C compilers
17777     incorrectly reject 9223372036854775807.  */
17778 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17779   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17780                        && LARGE_OFF_T % 2147483647 == 1)
17781                       ? 1 : -1];
17782 #ifdef F77_DUMMY_MAIN
17783 #  ifdef __cplusplus
17784      extern "C"
17785 #  endif
17786    int F77_DUMMY_MAIN() { return 1; }
17787 #endif
17788 int
17789 main ()
17790 {
17791
17792   ;
17793   return 0;
17794 }
17795 _ACEOF
17796          rm -f conftest.$ac_objext
17797 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17798   (eval $ac_compile) 2>&5
17799   ac_status=$?
17800   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17801   (exit $ac_status); } &&
17802          { ac_try='test -s conftest.$ac_objext'
17803   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17804   (eval $ac_try) 2>&5
17805   ac_status=$?
17806   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17807   (exit $ac_status); }; }; then
17808   break
17809 else
17810   echo "$as_me: failed program was:" >&5
17811 cat conftest.$ac_ext >&5
17812 fi
17813 rm -f conftest.$ac_objext
17814          CC="$CC -n32"
17815          rm -f conftest.$ac_objext
17816 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17817   (eval $ac_compile) 2>&5
17818   ac_status=$?
17819   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17820   (exit $ac_status); } &&
17821          { ac_try='test -s conftest.$ac_objext'
17822   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17823   (eval $ac_try) 2>&5
17824   ac_status=$?
17825   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17826   (exit $ac_status); }; }; then
17827   ac_cv_sys_largefile_CC=' -n32'; break
17828 else
17829   echo "$as_me: failed program was:" >&5
17830 cat conftest.$ac_ext >&5
17831 fi
17832 rm -f conftest.$ac_objext
17833          break
17834        done
17835        CC=$ac_save_CC
17836        rm -f conftest.$ac_ext
17837     fi
17838 fi
17839 echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
17840 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
17841   if test "$ac_cv_sys_largefile_CC" != no; then
17842     CC=$CC$ac_cv_sys_largefile_CC
17843   fi
17844
17845   echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
17846 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
17847 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
17848   echo $ECHO_N "(cached) $ECHO_C" >&6
17849 else
17850   while :; do
17851   ac_cv_sys_file_offset_bits=no
17852   cat >conftest.$ac_ext <<_ACEOF
17853 #line $LINENO "configure"
17854 #include "confdefs.h"
17855 #include <sys/types.h>
17856  /* Check that off_t can represent 2**63 - 1 correctly.
17857     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17858     since some C++ compilers masquerading as C compilers
17859     incorrectly reject 9223372036854775807.  */
17860 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17861   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17862                        && LARGE_OFF_T % 2147483647 == 1)
17863                       ? 1 : -1];
17864 #ifdef F77_DUMMY_MAIN
17865 #  ifdef __cplusplus
17866      extern "C"
17867 #  endif
17868    int F77_DUMMY_MAIN() { return 1; }
17869 #endif
17870 int
17871 main ()
17872 {
17873
17874   ;
17875   return 0;
17876 }
17877 _ACEOF
17878 rm -f conftest.$ac_objext
17879 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17880   (eval $ac_compile) 2>&5
17881   ac_status=$?
17882   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17883   (exit $ac_status); } &&
17884          { ac_try='test -s conftest.$ac_objext'
17885   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17886   (eval $ac_try) 2>&5
17887   ac_status=$?
17888   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17889   (exit $ac_status); }; }; then
17890   break
17891 else
17892   echo "$as_me: failed program was:" >&5
17893 cat conftest.$ac_ext >&5
17894 fi
17895 rm -f conftest.$ac_objext conftest.$ac_ext
17896   cat >conftest.$ac_ext <<_ACEOF
17897 #line $LINENO "configure"
17898 #include "confdefs.h"
17899 #define _FILE_OFFSET_BITS 64
17900 #include <sys/types.h>
17901  /* Check that off_t can represent 2**63 - 1 correctly.
17902     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17903     since some C++ compilers masquerading as C compilers
17904     incorrectly reject 9223372036854775807.  */
17905 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17906   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17907                        && LARGE_OFF_T % 2147483647 == 1)
17908                       ? 1 : -1];
17909 #ifdef F77_DUMMY_MAIN
17910 #  ifdef __cplusplus
17911      extern "C"
17912 #  endif
17913    int F77_DUMMY_MAIN() { return 1; }
17914 #endif
17915 int
17916 main ()
17917 {
17918
17919   ;
17920   return 0;
17921 }
17922 _ACEOF
17923 rm -f conftest.$ac_objext
17924 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17925   (eval $ac_compile) 2>&5
17926   ac_status=$?
17927   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17928   (exit $ac_status); } &&
17929          { ac_try='test -s conftest.$ac_objext'
17930   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17931   (eval $ac_try) 2>&5
17932   ac_status=$?
17933   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17934   (exit $ac_status); }; }; then
17935   ac_cv_sys_file_offset_bits=64; break
17936 else
17937   echo "$as_me: failed program was:" >&5
17938 cat conftest.$ac_ext >&5
17939 fi
17940 rm -f conftest.$ac_objext conftest.$ac_ext
17941   break
17942 done
17943 fi
17944 echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
17945 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
17946 if test "$ac_cv_sys_file_offset_bits" != no; then
17947
17948 cat >>confdefs.h <<_ACEOF
17949 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
17950 _ACEOF
17951
17952 fi
17953 rm -f conftest*
17954   echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
17955 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
17956 if test "${ac_cv_sys_large_files+set}" = set; then
17957   echo $ECHO_N "(cached) $ECHO_C" >&6
17958 else
17959   while :; do
17960   ac_cv_sys_large_files=no
17961   cat >conftest.$ac_ext <<_ACEOF
17962 #line $LINENO "configure"
17963 #include "confdefs.h"
17964 #include <sys/types.h>
17965  /* Check that off_t can represent 2**63 - 1 correctly.
17966     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17967     since some C++ compilers masquerading as C compilers
17968     incorrectly reject 9223372036854775807.  */
17969 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17970   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17971                        && LARGE_OFF_T % 2147483647 == 1)
17972                       ? 1 : -1];
17973 #ifdef F77_DUMMY_MAIN
17974 #  ifdef __cplusplus
17975      extern "C"
17976 #  endif
17977    int F77_DUMMY_MAIN() { return 1; }
17978 #endif
17979 int
17980 main ()
17981 {
17982
17983   ;
17984   return 0;
17985 }
17986 _ACEOF
17987 rm -f conftest.$ac_objext
17988 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
17989   (eval $ac_compile) 2>&5
17990   ac_status=$?
17991   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17992   (exit $ac_status); } &&
17993          { ac_try='test -s conftest.$ac_objext'
17994   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
17995   (eval $ac_try) 2>&5
17996   ac_status=$?
17997   echo "$as_me:$LINENO: \$? = $ac_status" >&5
17998   (exit $ac_status); }; }; then
17999   break
18000 else
18001   echo "$as_me: failed program was:" >&5
18002 cat conftest.$ac_ext >&5
18003 fi
18004 rm -f conftest.$ac_objext conftest.$ac_ext
18005   cat >conftest.$ac_ext <<_ACEOF
18006 #line $LINENO "configure"
18007 #include "confdefs.h"
18008 #define _LARGE_FILES 1
18009 #include <sys/types.h>
18010  /* Check that off_t can represent 2**63 - 1 correctly.
18011     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18012     since some C++ compilers masquerading as C compilers
18013     incorrectly reject 9223372036854775807.  */
18014 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18015   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18016                        && LARGE_OFF_T % 2147483647 == 1)
18017                       ? 1 : -1];
18018 #ifdef F77_DUMMY_MAIN
18019 #  ifdef __cplusplus
18020      extern "C"
18021 #  endif
18022    int F77_DUMMY_MAIN() { return 1; }
18023 #endif
18024 int
18025 main ()
18026 {
18027
18028   ;
18029   return 0;
18030 }
18031 _ACEOF
18032 rm -f conftest.$ac_objext
18033 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18034   (eval $ac_compile) 2>&5
18035   ac_status=$?
18036   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18037   (exit $ac_status); } &&
18038          { ac_try='test -s conftest.$ac_objext'
18039   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18040   (eval $ac_try) 2>&5
18041   ac_status=$?
18042   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18043   (exit $ac_status); }; }; then
18044   ac_cv_sys_large_files=1; break
18045 else
18046   echo "$as_me: failed program was:" >&5
18047 cat conftest.$ac_ext >&5
18048 fi
18049 rm -f conftest.$ac_objext conftest.$ac_ext
18050   break
18051 done
18052 fi
18053 echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
18054 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
18055 if test "$ac_cv_sys_large_files" != no; then
18056
18057 cat >>confdefs.h <<_ACEOF
18058 #define _LARGE_FILES $ac_cv_sys_large_files
18059 _ACEOF
18060
18061 fi
18062 rm -f conftest*
18063 fi
18064
18065 fi
18066
18067 # SunOS doesn't handle negative byte comparisons properly with +/- return
18068 echo "$as_me:$LINENO: checking for working memcmp" >&5
18069 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6
18070 if test "${ac_cv_func_memcmp_working+set}" = set; then
18071   echo $ECHO_N "(cached) $ECHO_C" >&6
18072 else
18073   if test "$cross_compiling" = yes; then
18074   ac_cv_func_memcmp_working=no
18075 else
18076   cat >conftest.$ac_ext <<_ACEOF
18077 #line $LINENO "configure"
18078 #include "confdefs.h"
18079
18080 #ifdef F77_DUMMY_MAIN
18081 #  ifdef __cplusplus
18082      extern "C"
18083 #  endif
18084    int F77_DUMMY_MAIN() { return 1; }
18085 #endif
18086 int
18087 main ()
18088 {
18089
18090   /* Some versions of memcmp are not 8-bit clean.  */
18091   char c0 = 0x40, c1 = 0x80, c2 = 0x81;
18092   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
18093     exit (1);
18094
18095   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
18096      or more and with at least one buffer not starting on a 4-byte boundary.
18097      William Lewis provided this test program.   */
18098   {
18099     char foo[21];
18100     char bar[21];
18101     int i;
18102     for (i = 0; i < 4; i++)
18103       {
18104         char *a = foo + i;
18105         char *b = bar + i;
18106         strcpy (a, "--------01111111");
18107         strcpy (b, "--------10000000");
18108         if (memcmp (a, b, 16) >= 0)
18109           exit (1);
18110       }
18111     exit (0);
18112   }
18113
18114   ;
18115   return 0;
18116 }
18117 _ACEOF
18118 rm -f conftest$ac_exeext
18119 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18120   (eval $ac_link) 2>&5
18121   ac_status=$?
18122   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18123   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18124   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18125   (eval $ac_try) 2>&5
18126   ac_status=$?
18127   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18128   (exit $ac_status); }; }; then
18129   ac_cv_func_memcmp_working=yes
18130 else
18131   echo "$as_me: program exited with status $ac_status" >&5
18132 echo "$as_me: failed program was:" >&5
18133 cat conftest.$ac_ext >&5
18134 ( exit $ac_status )
18135 ac_cv_func_memcmp_working=no
18136 fi
18137 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18138 fi
18139 fi
18140 echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
18141 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6
18142 test $ac_cv_func_memcmp_working = no && LIBOBJS="$LIBOBJS memcmp.$ac_objext"
18143
18144
18145
18146 # Select semaphore implementation type.
18147 if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
18148
18149 cat >>confdefs.h <<\_ACEOF
18150 #define USE_NAMED_POSIX_SEMAPHORES 1
18151 _ACEOF
18152
18153   SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
18154 else
18155   if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
18156
18157 cat >>confdefs.h <<\_ACEOF
18158 #define USE_UNNAMED_POSIX_SEMAPHORES 1
18159 _ACEOF
18160
18161     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
18162   else
18163
18164 cat >>confdefs.h <<\_ACEOF
18165 #define USE_SYSV_SEMAPHORES 1
18166 _ACEOF
18167
18168     SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
18169   fi
18170 fi
18171
18172
18173 # Select shared-memory implementation type.
18174
18175 cat >>confdefs.h <<\_ACEOF
18176 #define USE_SYSV_SHARED_MEMORY 1
18177 _ACEOF
18178
18179 SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
18180
18181
18182 if test "$enable_nls" = yes ; then
18183
18184   echo "$as_me:$LINENO: checking for library containing gettext" >&5
18185 echo $ECHO_N "checking for library containing gettext... $ECHO_C" >&6
18186 if test "${ac_cv_search_gettext+set}" = set; then
18187   echo $ECHO_N "(cached) $ECHO_C" >&6
18188 else
18189   ac_func_search_save_LIBS=$LIBS
18190 ac_cv_search_gettext=no
18191 cat >conftest.$ac_ext <<_ACEOF
18192 #line $LINENO "configure"
18193 #include "confdefs.h"
18194
18195 /* Override any gcc2 internal prototype to avoid an error.  */
18196 #ifdef __cplusplus
18197 extern "C"
18198 #endif
18199 /* We use char because int might match the return type of a gcc2
18200    builtin and then its argument prototype would still apply.  */
18201 char gettext ();
18202 #ifdef F77_DUMMY_MAIN
18203 #  ifdef __cplusplus
18204      extern "C"
18205 #  endif
18206    int F77_DUMMY_MAIN() { return 1; }
18207 #endif
18208 int
18209 main ()
18210 {
18211 gettext ();
18212   ;
18213   return 0;
18214 }
18215 _ACEOF
18216 rm -f conftest.$ac_objext conftest$ac_exeext
18217 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18218   (eval $ac_link) 2>&5
18219   ac_status=$?
18220   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18221   (exit $ac_status); } &&
18222          { ac_try='test -s conftest$ac_exeext'
18223   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18224   (eval $ac_try) 2>&5
18225   ac_status=$?
18226   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18227   (exit $ac_status); }; }; then
18228   ac_cv_search_gettext="none required"
18229 else
18230   echo "$as_me: failed program was:" >&5
18231 cat conftest.$ac_ext >&5
18232 fi
18233 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18234 if test "$ac_cv_search_gettext" = no; then
18235   for ac_lib in intl; do
18236     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
18237     cat >conftest.$ac_ext <<_ACEOF
18238 #line $LINENO "configure"
18239 #include "confdefs.h"
18240
18241 /* Override any gcc2 internal prototype to avoid an error.  */
18242 #ifdef __cplusplus
18243 extern "C"
18244 #endif
18245 /* We use char because int might match the return type of a gcc2
18246    builtin and then its argument prototype would still apply.  */
18247 char gettext ();
18248 #ifdef F77_DUMMY_MAIN
18249 #  ifdef __cplusplus
18250      extern "C"
18251 #  endif
18252    int F77_DUMMY_MAIN() { return 1; }
18253 #endif
18254 int
18255 main ()
18256 {
18257 gettext ();
18258   ;
18259   return 0;
18260 }
18261 _ACEOF
18262 rm -f conftest.$ac_objext conftest$ac_exeext
18263 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
18264   (eval $ac_link) 2>&5
18265   ac_status=$?
18266   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18267   (exit $ac_status); } &&
18268          { ac_try='test -s conftest$ac_exeext'
18269   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18270   (eval $ac_try) 2>&5
18271   ac_status=$?
18272   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18273   (exit $ac_status); }; }; then
18274   ac_cv_search_gettext="-l$ac_lib"
18275 break
18276 else
18277   echo "$as_me: failed program was:" >&5
18278 cat conftest.$ac_ext >&5
18279 fi
18280 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
18281   done
18282 fi
18283 LIBS=$ac_func_search_save_LIBS
18284 fi
18285 echo "$as_me:$LINENO: result: $ac_cv_search_gettext" >&5
18286 echo "${ECHO_T}$ac_cv_search_gettext" >&6
18287 if test "$ac_cv_search_gettext" != no; then
18288   test "$ac_cv_search_gettext" = "none required" || LIBS="$ac_cv_search_gettext $LIBS"
18289
18290 else
18291   { { echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
18292 echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
18293    { (exit 1); exit 1; }; }
18294 fi
18295
18296   if test "${ac_cv_header_libintl_h+set}" = set; then
18297   echo "$as_me:$LINENO: checking for libintl.h" >&5
18298 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
18299 if test "${ac_cv_header_libintl_h+set}" = set; then
18300   echo $ECHO_N "(cached) $ECHO_C" >&6
18301 fi
18302 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
18303 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
18304 else
18305   # Is the header compilable?
18306 echo "$as_me:$LINENO: checking libintl.h usability" >&5
18307 echo $ECHO_N "checking libintl.h usability... $ECHO_C" >&6
18308 cat >conftest.$ac_ext <<_ACEOF
18309 #line $LINENO "configure"
18310 #include "confdefs.h"
18311 $ac_includes_default
18312 #include <libintl.h>
18313 _ACEOF
18314 rm -f conftest.$ac_objext
18315 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18316   (eval $ac_compile) 2>&5
18317   ac_status=$?
18318   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18319   (exit $ac_status); } &&
18320          { ac_try='test -s conftest.$ac_objext'
18321   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18322   (eval $ac_try) 2>&5
18323   ac_status=$?
18324   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18325   (exit $ac_status); }; }; then
18326   ac_header_compiler=yes
18327 else
18328   echo "$as_me: failed program was:" >&5
18329 cat conftest.$ac_ext >&5
18330 ac_header_compiler=no
18331 fi
18332 rm -f conftest.$ac_objext conftest.$ac_ext
18333 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18334 echo "${ECHO_T}$ac_header_compiler" >&6
18335
18336 # Is the header present?
18337 echo "$as_me:$LINENO: checking libintl.h presence" >&5
18338 echo $ECHO_N "checking libintl.h presence... $ECHO_C" >&6
18339 cat >conftest.$ac_ext <<_ACEOF
18340 #line $LINENO "configure"
18341 #include "confdefs.h"
18342 #include <libintl.h>
18343 _ACEOF
18344 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18345   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18346   ac_status=$?
18347   egrep -v '^ *\+' conftest.er1 >conftest.err
18348   rm -f conftest.er1
18349   cat conftest.err >&5
18350   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18351   (exit $ac_status); } >/dev/null; then
18352   if test -s conftest.err; then
18353     ac_cpp_err=$ac_c_preproc_warn_flag
18354   else
18355     ac_cpp_err=
18356   fi
18357 else
18358   ac_cpp_err=yes
18359 fi
18360 if test -z "$ac_cpp_err"; then
18361   ac_header_preproc=yes
18362 else
18363   echo "$as_me: failed program was:" >&5
18364   cat conftest.$ac_ext >&5
18365   ac_header_preproc=no
18366 fi
18367 rm -f conftest.err conftest.$ac_ext
18368 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18369 echo "${ECHO_T}$ac_header_preproc" >&6
18370
18371 # So?  What about this header?
18372 case $ac_header_compiler:$ac_header_preproc in
18373   yes:no )
18374     { echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
18375 echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
18376     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
18377 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;};;
18378   no:yes )
18379     { echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
18380 echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
18381     { echo "$as_me:$LINENO: WARNING: libintl.h: check for missing prerequisite headers?" >&5
18382 echo "$as_me: WARNING: libintl.h: check for missing prerequisite headers?" >&2;}
18383     { echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
18384 echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;};;
18385 esac
18386 echo "$as_me:$LINENO: checking for libintl.h" >&5
18387 echo $ECHO_N "checking for libintl.h... $ECHO_C" >&6
18388 if test "${ac_cv_header_libintl_h+set}" = set; then
18389   echo $ECHO_N "(cached) $ECHO_C" >&6
18390 else
18391   ac_cv_header_libintl_h=$ac_header_preproc
18392 fi
18393 echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
18394 echo "${ECHO_T}$ac_cv_header_libintl_h" >&6
18395
18396 fi
18397 if test $ac_cv_header_libintl_h = yes; then
18398   :
18399 else
18400   { { echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
18401 echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
18402    { (exit 1); exit 1; }; }
18403 fi
18404
18405
18406   for ac_prog in msgfmt
18407 do
18408   # Extract the first word of "$ac_prog", so it can be a program name with args.
18409 set dummy $ac_prog; ac_word=$2
18410 echo "$as_me:$LINENO: checking for $ac_word" >&5
18411 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18412 if test "${ac_cv_prog_MSGFMT+set}" = set; then
18413   echo $ECHO_N "(cached) $ECHO_C" >&6
18414 else
18415   if test -n "$MSGFMT"; then
18416   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
18417 else
18418 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18419 for as_dir in $PATH
18420 do
18421   IFS=$as_save_IFS
18422   test -z "$as_dir" && as_dir=.
18423   for ac_exec_ext in '' $ac_executable_extensions; do
18424   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18425     ac_cv_prog_MSGFMT="$ac_prog"
18426     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18427     break 2
18428   fi
18429 done
18430 done
18431
18432 fi
18433 fi
18434 MSGFMT=$ac_cv_prog_MSGFMT
18435 if test -n "$MSGFMT"; then
18436   echo "$as_me:$LINENO: result: $MSGFMT" >&5
18437 echo "${ECHO_T}$MSGFMT" >&6
18438 else
18439   echo "$as_me:$LINENO: result: no" >&5
18440 echo "${ECHO_T}no" >&6
18441 fi
18442
18443   test -n "$MSGFMT" && break
18444 done
18445
18446   if test -z "$MSGFMT"; then
18447     { { echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
18448 echo "$as_me: error: msgfmt is required for NLS" >&2;}
18449    { (exit 1); exit 1; }; }
18450   fi
18451   for ac_prog in msgmerge
18452 do
18453   # Extract the first word of "$ac_prog", so it can be a program name with args.
18454 set dummy $ac_prog; ac_word=$2
18455 echo "$as_me:$LINENO: checking for $ac_word" >&5
18456 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18457 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
18458   echo $ECHO_N "(cached) $ECHO_C" >&6
18459 else
18460   if test -n "$MSGMERGE"; then
18461   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
18462 else
18463 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18464 for as_dir in $PATH
18465 do
18466   IFS=$as_save_IFS
18467   test -z "$as_dir" && as_dir=.
18468   for ac_exec_ext in '' $ac_executable_extensions; do
18469   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18470     ac_cv_prog_MSGMERGE="$ac_prog"
18471     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18472     break 2
18473   fi
18474 done
18475 done
18476
18477 fi
18478 fi
18479 MSGMERGE=$ac_cv_prog_MSGMERGE
18480 if test -n "$MSGMERGE"; then
18481   echo "$as_me:$LINENO: result: $MSGMERGE" >&5
18482 echo "${ECHO_T}$MSGMERGE" >&6
18483 else
18484   echo "$as_me:$LINENO: result: no" >&5
18485 echo "${ECHO_T}no" >&6
18486 fi
18487
18488   test -n "$MSGMERGE" && break
18489 done
18490
18491   for ac_prog in xgettext
18492 do
18493   # Extract the first word of "$ac_prog", so it can be a program name with args.
18494 set dummy $ac_prog; ac_word=$2
18495 echo "$as_me:$LINENO: checking for $ac_word" >&5
18496 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18497 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
18498   echo $ECHO_N "(cached) $ECHO_C" >&6
18499 else
18500   if test -n "$XGETTEXT"; then
18501   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
18502 else
18503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18504 for as_dir in $PATH
18505 do
18506   IFS=$as_save_IFS
18507   test -z "$as_dir" && as_dir=.
18508   for ac_exec_ext in '' $ac_executable_extensions; do
18509   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18510     ac_cv_prog_XGETTEXT="$ac_prog"
18511     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18512     break 2
18513   fi
18514 done
18515 done
18516
18517 fi
18518 fi
18519 XGETTEXT=$ac_cv_prog_XGETTEXT
18520 if test -n "$XGETTEXT"; then
18521   echo "$as_me:$LINENO: result: $XGETTEXT" >&5
18522 echo "${ECHO_T}$XGETTEXT" >&6
18523 else
18524   echo "$as_me:$LINENO: result: no" >&5
18525 echo "${ECHO_T}no" >&6
18526 fi
18527
18528   test -n "$XGETTEXT" && break
18529 done
18530
18531
18532   # Note: share/locale is always the default, independent of $datadir
18533   localedir='${prefix}/share/locale'
18534   if test x"$prefix" = x"NONE"; then
18535     exp_localedir="$ac_default_prefix/share/locale"
18536   else
18537     exp_localedir="$prefix/share/locale"
18538   fi
18539
18540
18541
18542 cat >>confdefs.h <<_ACEOF
18543 #define LOCALEDIR "$exp_localedir"
18544 _ACEOF
18545
18546
18547 fi
18548
18549 # Check for Tcl configuration script tclConfig.sh
18550 if test "$with_tcl" = yes; then
18551     for ac_prog in tclsh tcl
18552 do
18553   # Extract the first word of "$ac_prog", so it can be a program name with args.
18554 set dummy $ac_prog; ac_word=$2
18555 echo "$as_me:$LINENO: checking for $ac_word" >&5
18556 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18557 if test "${ac_cv_path_TCLSH+set}" = set; then
18558   echo $ECHO_N "(cached) $ECHO_C" >&6
18559 else
18560   case $TCLSH in
18561   [\\/]* | ?:[\\/]*)
18562   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
18563   ;;
18564   *)
18565   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18566 for as_dir in $PATH
18567 do
18568   IFS=$as_save_IFS
18569   test -z "$as_dir" && as_dir=.
18570   for ac_exec_ext in '' $ac_executable_extensions; do
18571   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18572     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
18573     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18574     break 2
18575   fi
18576 done
18577 done
18578
18579   ;;
18580 esac
18581 fi
18582 TCLSH=$ac_cv_path_TCLSH
18583
18584 if test -n "$TCLSH"; then
18585   echo "$as_me:$LINENO: result: $TCLSH" >&5
18586 echo "${ECHO_T}$TCLSH" >&6
18587 else
18588   echo "$as_me:$LINENO: result: no" >&5
18589 echo "${ECHO_T}no" >&6
18590 fi
18591
18592   test -n "$TCLSH" && break
18593 done
18594
18595 echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
18596 echo $ECHO_N "checking for tclConfig.sh... $ECHO_C" >&6
18597 # Let user override test
18598 if test -z "$TCL_CONFIG_SH"; then
18599     pgac_test_dirs="$with_tclconfig"
18600
18601     set X $pgac_test_dirs; shift
18602     if test $# -eq 0; then
18603         test -z "$TCLSH" && { { echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
18604 echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
18605    { (exit 1); exit 1; }; }
18606         set X `echo 'puts $auto_path' | $TCLSH`; shift
18607     fi
18608
18609     for pgac_dir do
18610         if test -r "$pgac_dir/tclConfig.sh"; then
18611             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
18612             break
18613         fi
18614     done
18615 fi
18616
18617 if test -z "$TCL_CONFIG_SH"; then
18618     echo "$as_me:$LINENO: result: no" >&5
18619 echo "${ECHO_T}no" >&6
18620     { { echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
18621 echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
18622    { (exit 1); exit 1; }; }
18623 else
18624     echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
18625 echo "${ECHO_T}$TCL_CONFIG_SH" >&6
18626 fi
18627
18628
18629
18630     . "$TCL_CONFIG_SH"
18631 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
18632 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
18633 eval TCL_LIBS=\"$TCL_LIBS\"
18634 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
18635 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
18636
18637         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
18638     ac_save_CPPFLAGS=$CPPFLAGS
18639     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
18640     if test "${ac_cv_header_tcl_h+set}" = set; then
18641   echo "$as_me:$LINENO: checking for tcl.h" >&5
18642 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
18643 if test "${ac_cv_header_tcl_h+set}" = set; then
18644   echo $ECHO_N "(cached) $ECHO_C" >&6
18645 fi
18646 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
18647 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
18648 else
18649   # Is the header compilable?
18650 echo "$as_me:$LINENO: checking tcl.h usability" >&5
18651 echo $ECHO_N "checking tcl.h usability... $ECHO_C" >&6
18652 cat >conftest.$ac_ext <<_ACEOF
18653 #line $LINENO "configure"
18654 #include "confdefs.h"
18655 $ac_includes_default
18656 #include <tcl.h>
18657 _ACEOF
18658 rm -f conftest.$ac_objext
18659 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
18660   (eval $ac_compile) 2>&5
18661   ac_status=$?
18662   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18663   (exit $ac_status); } &&
18664          { ac_try='test -s conftest.$ac_objext'
18665   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
18666   (eval $ac_try) 2>&5
18667   ac_status=$?
18668   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18669   (exit $ac_status); }; }; then
18670   ac_header_compiler=yes
18671 else
18672   echo "$as_me: failed program was:" >&5
18673 cat conftest.$ac_ext >&5
18674 ac_header_compiler=no
18675 fi
18676 rm -f conftest.$ac_objext conftest.$ac_ext
18677 echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
18678 echo "${ECHO_T}$ac_header_compiler" >&6
18679
18680 # Is the header present?
18681 echo "$as_me:$LINENO: checking tcl.h presence" >&5
18682 echo $ECHO_N "checking tcl.h presence... $ECHO_C" >&6
18683 cat >conftest.$ac_ext <<_ACEOF
18684 #line $LINENO "configure"
18685 #include "confdefs.h"
18686 #include <tcl.h>
18687 _ACEOF
18688 if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
18689   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
18690   ac_status=$?
18691   egrep -v '^ *\+' conftest.er1 >conftest.err
18692   rm -f conftest.er1
18693   cat conftest.err >&5
18694   echo "$as_me:$LINENO: \$? = $ac_status" >&5
18695   (exit $ac_status); } >/dev/null; then
18696   if test -s conftest.err; then
18697     ac_cpp_err=$ac_c_preproc_warn_flag
18698   else
18699     ac_cpp_err=
18700   fi
18701 else
18702   ac_cpp_err=yes
18703 fi
18704 if test -z "$ac_cpp_err"; then
18705   ac_header_preproc=yes
18706 else
18707   echo "$as_me: failed program was:" >&5
18708   cat conftest.$ac_ext >&5
18709   ac_header_preproc=no
18710 fi
18711 rm -f conftest.err conftest.$ac_ext
18712 echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
18713 echo "${ECHO_T}$ac_header_preproc" >&6
18714
18715 # So?  What about this header?
18716 case $ac_header_compiler:$ac_header_preproc in
18717   yes:no )
18718     { echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
18719 echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
18720     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
18721 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;};;
18722   no:yes )
18723     { echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
18724 echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
18725     { echo "$as_me:$LINENO: WARNING: tcl.h: check for missing prerequisite headers?" >&5
18726 echo "$as_me: WARNING: tcl.h: check for missing prerequisite headers?" >&2;}
18727     { echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
18728 echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;};;
18729 esac
18730 echo "$as_me:$LINENO: checking for tcl.h" >&5
18731 echo $ECHO_N "checking for tcl.h... $ECHO_C" >&6
18732 if test "${ac_cv_header_tcl_h+set}" = set; then
18733   echo $ECHO_N "(cached) $ECHO_C" >&6
18734 else
18735   ac_cv_header_tcl_h=$ac_header_preproc
18736 fi
18737 echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
18738 echo "${ECHO_T}$ac_cv_header_tcl_h" >&6
18739
18740 fi
18741 if test $ac_cv_header_tcl_h = yes; then
18742   :
18743 else
18744   { { echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
18745 echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
18746    { (exit 1); exit 1; }; }
18747 fi
18748
18749
18750     CPPFLAGS=$ac_save_CPPFLAGS
18751 fi
18752
18753 #
18754 # Check for DocBook and tools
18755 #
18756 for ac_prog in onsgmls nsgmls
18757 do
18758   # Extract the first word of "$ac_prog", so it can be a program name with args.
18759 set dummy $ac_prog; ac_word=$2
18760 echo "$as_me:$LINENO: checking for $ac_word" >&5
18761 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18762 if test "${ac_cv_prog_NSGMLS+set}" = set; then
18763   echo $ECHO_N "(cached) $ECHO_C" >&6
18764 else
18765   if test -n "$NSGMLS"; then
18766   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
18767 else
18768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18769 for as_dir in $PATH
18770 do
18771   IFS=$as_save_IFS
18772   test -z "$as_dir" && as_dir=.
18773   for ac_exec_ext in '' $ac_executable_extensions; do
18774   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18775     ac_cv_prog_NSGMLS="$ac_prog"
18776     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18777     break 2
18778   fi
18779 done
18780 done
18781
18782 fi
18783 fi
18784 NSGMLS=$ac_cv_prog_NSGMLS
18785 if test -n "$NSGMLS"; then
18786   echo "$as_me:$LINENO: result: $NSGMLS" >&5
18787 echo "${ECHO_T}$NSGMLS" >&6
18788 else
18789   echo "$as_me:$LINENO: result: no" >&5
18790 echo "${ECHO_T}no" >&6
18791 fi
18792
18793   test -n "$NSGMLS" && break
18794 done
18795
18796 for ac_prog in openjade jade
18797 do
18798   # Extract the first word of "$ac_prog", so it can be a program name with args.
18799 set dummy $ac_prog; ac_word=$2
18800 echo "$as_me:$LINENO: checking for $ac_word" >&5
18801 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18802 if test "${ac_cv_prog_JADE+set}" = set; then
18803   echo $ECHO_N "(cached) $ECHO_C" >&6
18804 else
18805   if test -n "$JADE"; then
18806   ac_cv_prog_JADE="$JADE" # Let the user override the test.
18807 else
18808 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18809 for as_dir in $PATH
18810 do
18811   IFS=$as_save_IFS
18812   test -z "$as_dir" && as_dir=.
18813   for ac_exec_ext in '' $ac_executable_extensions; do
18814   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18815     ac_cv_prog_JADE="$ac_prog"
18816     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18817     break 2
18818   fi
18819 done
18820 done
18821
18822 fi
18823 fi
18824 JADE=$ac_cv_prog_JADE
18825 if test -n "$JADE"; then
18826   echo "$as_me:$LINENO: result: $JADE" >&5
18827 echo "${ECHO_T}$JADE" >&6
18828 else
18829   echo "$as_me:$LINENO: result: no" >&5
18830 echo "${ECHO_T}no" >&6
18831 fi
18832
18833   test -n "$JADE" && break
18834 done
18835
18836
18837 echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
18838 echo $ECHO_N "checking for DocBook V4.2... $ECHO_C" >&6
18839 if test "${pgac_cv_check_docbook+set}" = set; then
18840   echo $ECHO_N "(cached) $ECHO_C" >&6
18841 else
18842   cat >conftest.sgml <<EOF
18843 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
18844 <book>
18845  <title>test</title>
18846  <chapter>
18847   <title>random</title>
18848    <sect1>
18849     <title>testsect</title>
18850     <para>text</para>
18851   </sect1>
18852  </chapter>
18853 </book>
18854 EOF
18855
18856 pgac_cv_check_docbook=no
18857
18858 if test -n "$NSGMLS"; then
18859   $NSGMLS -s conftest.sgml 1>&5 2>&1
18860   if test $? -eq 0; then
18861     pgac_cv_check_docbook=yes
18862   fi
18863 fi
18864 rm -f conftest.sgml
18865 fi
18866 echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
18867 echo "${ECHO_T}$pgac_cv_check_docbook" >&6
18868
18869 have_docbook=$pgac_cv_check_docbook
18870
18871
18872 echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
18873 echo $ECHO_N "checking for DocBook stylesheets... $ECHO_C" >&6
18874 if test "${pgac_cv_path_stylesheets+set}" = set; then
18875   echo $ECHO_N "(cached) $ECHO_C" >&6
18876 else
18877   if test -n "$DOCBOOKSTYLE"; then
18878   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
18879 else
18880   for pgac_prefix in /usr /usr/local /opt; do
18881     for pgac_infix in share lib; do
18882       for pgac_postfix in \
18883         sgml/stylesheets/nwalsh-modular \
18884         sgml/stylesheets/docbook \
18885                 sgml/docbook-dsssl \
18886         sgml/docbook/dsssl/modular \
18887         sgml/docbook/stylesheet/dsssl/modular \
18888         sgml/docbook/dsssl-stylesheets
18889       do
18890         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
18891         if test -r "$pgac_candidate/html/docbook.dsl" \
18892            && test -r "$pgac_candidate/print/docbook.dsl"
18893         then
18894           pgac_cv_path_stylesheets=$pgac_candidate
18895           break 3
18896         fi
18897       done
18898     done
18899   done
18900 fi
18901 fi
18902
18903 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
18904
18905 if test -n "$DOCBOOKSTYLE"; then
18906   echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
18907 echo "${ECHO_T}$DOCBOOKSTYLE" >&6
18908 else
18909   echo "$as_me:$LINENO: result: no" >&5
18910 echo "${ECHO_T}no" >&6
18911 fi
18912 if test -n "$DOCBOOKSTYLE"; then
18913   for ac_prog in collateindex.pl
18914 do
18915   # Extract the first word of "$ac_prog", so it can be a program name with args.
18916 set dummy $ac_prog; ac_word=$2
18917 echo "$as_me:$LINENO: checking for $ac_word" >&5
18918 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18919 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
18920   echo $ECHO_N "(cached) $ECHO_C" >&6
18921 else
18922   case $COLLATEINDEX in
18923   [\\/]* | ?:[\\/]*)
18924   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
18925   ;;
18926   *)
18927   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18928 for as_dir in $DOCBOOKSTYLE/bin $PATH
18929 do
18930   IFS=$as_save_IFS
18931   test -z "$as_dir" && as_dir=.
18932   for ac_exec_ext in '' $ac_executable_extensions; do
18933   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18934     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
18935     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18936     break 2
18937   fi
18938 done
18939 done
18940
18941   ;;
18942 esac
18943 fi
18944 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
18945
18946 if test -n "$COLLATEINDEX"; then
18947   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
18948 echo "${ECHO_T}$COLLATEINDEX" >&6
18949 else
18950   echo "$as_me:$LINENO: result: no" >&5
18951 echo "${ECHO_T}no" >&6
18952 fi
18953
18954   test -n "$COLLATEINDEX" && break
18955 done
18956
18957 else
18958   for ac_prog in collateindex.pl
18959 do
18960   # Extract the first word of "$ac_prog", so it can be a program name with args.
18961 set dummy $ac_prog; ac_word=$2
18962 echo "$as_me:$LINENO: checking for $ac_word" >&5
18963 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
18964 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
18965   echo $ECHO_N "(cached) $ECHO_C" >&6
18966 else
18967   case $COLLATEINDEX in
18968   [\\/]* | ?:[\\/]*)
18969   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
18970   ;;
18971   *)
18972   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
18973 for as_dir in $PATH
18974 do
18975   IFS=$as_save_IFS
18976   test -z "$as_dir" && as_dir=.
18977   for ac_exec_ext in '' $ac_executable_extensions; do
18978   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
18979     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
18980     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
18981     break 2
18982   fi
18983 done
18984 done
18985
18986   ;;
18987 esac
18988 fi
18989 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
18990
18991 if test -n "$COLLATEINDEX"; then
18992   echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
18993 echo "${ECHO_T}$COLLATEINDEX" >&6
18994 else
18995   echo "$as_me:$LINENO: result: no" >&5
18996 echo "${ECHO_T}no" >&6
18997 fi
18998
18999   test -n "$COLLATEINDEX" && break
19000 done
19001
19002 fi
19003 for ac_prog in sgmlspl
19004 do
19005   # Extract the first word of "$ac_prog", so it can be a program name with args.
19006 set dummy $ac_prog; ac_word=$2
19007 echo "$as_me:$LINENO: checking for $ac_word" >&5
19008 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
19009 if test "${ac_cv_prog_SGMLSPL+set}" = set; then
19010   echo $ECHO_N "(cached) $ECHO_C" >&6
19011 else
19012   if test -n "$SGMLSPL"; then
19013   ac_cv_prog_SGMLSPL="$SGMLSPL" # Let the user override the test.
19014 else
19015 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19016 for as_dir in $PATH
19017 do
19018   IFS=$as_save_IFS
19019   test -z "$as_dir" && as_dir=.
19020   for ac_exec_ext in '' $ac_executable_extensions; do
19021   if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
19022     ac_cv_prog_SGMLSPL="$ac_prog"
19023     echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
19024     break 2
19025   fi
19026 done
19027 done
19028
19029 fi
19030 fi
19031 SGMLSPL=$ac_cv_prog_SGMLSPL
19032 if test -n "$SGMLSPL"; then
19033   echo "$as_me:$LINENO: result: $SGMLSPL" >&5
19034 echo "${ECHO_T}$SGMLSPL" >&6
19035 else
19036   echo "$as_me:$LINENO: result: no" >&5
19037 echo "${ECHO_T}no" >&6
19038 fi
19039
19040   test -n "$SGMLSPL" && break
19041 done
19042
19043
19044 # Thread testing
19045
19046 # We have to run the thread test near the end so we have all our symbols
19047 # defined.  Cross compiling throws a warning.
19048 #
19049 if test "$enable_thread_safety_force" = yes; then
19050   { echo "$as_me:$LINENO: WARNING:
19051 *** Skipping thread test program.  --enable-thread-safety-force was used.
19052 *** Run the program in src/tools/thread on the your machine and add
19053 proper locking function calls to your applications to guarantee thread
19054 safety.
19055 " >&5
19056 echo "$as_me: WARNING:
19057 *** Skipping thread test program.  --enable-thread-safety-force was used.
19058 *** Run the program in src/tools/thread on the your machine and add
19059 proper locking function calls to your applications to guarantee thread
19060 safety.
19061 " >&2;}
19062 elif test "$enable_thread_safety" = yes; then
19063 echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
19064 echo $ECHO_N "checking thread safety of required library functions... $ECHO_C" >&6
19065
19066 _CFLAGS="$CFLAGS"
19067 _LIBS="$LIBS"
19068 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
19069 LIBS="$LIBS $PTHREAD_LIBS"
19070 if test "$cross_compiling" = yes; then
19071   echo "$as_me:$LINENO: result: maybe" >&5
19072 echo "${ECHO_T}maybe" >&6
19073   { echo "$as_me:$LINENO: WARNING:
19074 *** Skipping thread test program because of cross-compile build.
19075 *** Run the program in src/tools/thread on the target machine.
19076 " >&5
19077 echo "$as_me: WARNING:
19078 *** Skipping thread test program because of cross-compile build.
19079 *** Run the program in src/tools/thread on the target machine.
19080 " >&2;}
19081 else
19082   cat >conftest.$ac_ext <<_ACEOF
19083 #line $LINENO "configure"
19084 #include "confdefs.h"
19085 #include "$srcdir/src/tools/thread/thread_test.c"
19086 _ACEOF
19087 rm -f conftest$ac_exeext
19088 if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
19089   (eval $ac_link) 2>&5
19090   ac_status=$?
19091   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19092   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19093   { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
19094   (eval $ac_try) 2>&5
19095   ac_status=$?
19096   echo "$as_me:$LINENO: \$? = $ac_status" >&5
19097   (exit $ac_status); }; }; then
19098   echo "$as_me:$LINENO: result: yes" >&5
19099 echo "${ECHO_T}yes" >&6
19100 else
19101   echo "$as_me: program exited with status $ac_status" >&5
19102 echo "$as_me: failed program was:" >&5
19103 cat conftest.$ac_ext >&5
19104 ( exit $ac_status )
19105 echo "$as_me:$LINENO: result: no" >&5
19106 echo "${ECHO_T}no" >&6
19107   { { echo "$as_me:$LINENO: error:
19108 *** Thread test program failed.  Your platform is not thread-safe.
19109 *** Check the file 'config.log'for the exact reason.
19110 ***
19111 *** You can use the configure option --enable-thread-safety-force
19112 *** to force threads to be enabled.  However, you must then run
19113 *** the program in src/tools/thread and add locking function calls
19114 *** to your applications to guarantee thread safety.
19115 " >&5
19116 echo "$as_me: error:
19117 *** Thread test program failed.  Your platform is not thread-safe.
19118 *** Check the file 'config.log'for the exact reason.
19119 ***
19120 *** You can use the configure option --enable-thread-safety-force
19121 *** to force threads to be enabled.  However, you must then run
19122 *** the program in src/tools/thread and add locking function calls
19123 *** to your applications to guarantee thread safety.
19124 " >&2;}
19125    { (exit 1); exit 1; }; }
19126 fi
19127 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19128 fi
19129 CFLAGS="$_CFLAGS"
19130 LIBS="$_LIBS"
19131 fi
19132
19133 # prepare build tree if outside source tree
19134 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
19135 # Note 2: /bin/pwd might be better than shell's built-in at getting
19136 #         a symlink-free name.
19137 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
19138   vpath_build=no
19139 else
19140   vpath_build=yes
19141   if test "$no_create" != yes; then
19142     echo $ECHO_N "preparing build tree... $ECHO_C" >&6
19143     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
19144     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
19145       || { { echo "$as_me:$LINENO: error: failed" >&5
19146 echo "$as_me: error: failed" >&2;}
19147    { (exit 1); exit 1; }; }
19148     echo "$as_me:$LINENO: result: done" >&5
19149 echo "${ECHO_T}done" >&6
19150   fi
19151 fi
19152
19153
19154
19155 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
19156
19157
19158 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}"
19159
19160
19161 if test "$PORTNAME" = "win32"; then
19162 ac_config_commands="$ac_config_commands check_win32_symlinks"
19163
19164 fi
19165
19166 ac_config_headers="$ac_config_headers src/include/pg_config.h"
19167
19168
19169 cat >confcache <<\_ACEOF
19170 # This file is a shell script that caches the results of configure
19171 # tests run on this system so they can be shared between configure
19172 # scripts and configure runs, see configure's option --config-cache.
19173 # It is not useful on other systems.  If it contains results you don't
19174 # want to keep, you may remove or edit it.
19175 #
19176 # config.status only pays attention to the cache file if you give it
19177 # the --recheck option to rerun configure.
19178 #
19179 # `ac_cv_env_foo' variables (set or unset) will be overriden when
19180 # loading this file, other *unset* `ac_cv_foo' will be assigned the
19181 # following values.
19182
19183 _ACEOF
19184
19185 # The following way of writing the cache mishandles newlines in values,
19186 # but we know of no workaround that is simple, portable, and efficient.
19187 # So, don't put newlines in cache variables' values.
19188 # Ultrix sh set writes to stderr and can't be redirected directly,
19189 # and sets the high bit in the cache file unless we assign to the vars.
19190 {
19191   (set) 2>&1 |
19192     case `(ac_space=' '; set | grep ac_space) 2>&1` in
19193     *ac_space=\ *)
19194       # `set' does not quote correctly, so add quotes (double-quote
19195       # substitution turns \\\\ into \\, and sed turns \\ into \).
19196       sed -n \
19197         "s/'/'\\\\''/g;
19198           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
19199       ;;
19200     *)
19201       # `set' quotes correctly as required by POSIX, so do not add quotes.
19202       sed -n \
19203         "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
19204       ;;
19205     esac;
19206 } |
19207   sed '
19208      t clear
19209      : clear
19210      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
19211      t end
19212      /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
19213      : end' >>confcache
19214 if cmp -s $cache_file confcache; then :; else
19215   if test -w $cache_file; then
19216     test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
19217     cat confcache >$cache_file
19218   else
19219     echo "not updating unwritable cache $cache_file"
19220   fi
19221 fi
19222 rm -f confcache
19223
19224 test "x$prefix" = xNONE && prefix=$ac_default_prefix
19225 # Let make expand exec_prefix.
19226 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
19227
19228 # VPATH may cause trouble with some makes, so we remove $(srcdir),
19229 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
19230 # trailing colons and then remove the whole line if VPATH becomes empty
19231 # (actually we leave an empty line to preserve line numbers).
19232 if test "x$srcdir" = x.; then
19233   ac_vpsub='/^[         ]*VPATH[        ]*=/{
19234 s/:*\$(srcdir):*/:/;
19235 s/:*\${srcdir}:*/:/;
19236 s/:*@srcdir@:*/:/;
19237 s/^\([^=]*=[    ]*\):*/\1/;
19238 s/:*$//;
19239 s/^[^=]*=[      ]*$//;
19240 }'
19241 fi
19242
19243 DEFS=-DHAVE_CONFIG_H
19244
19245
19246 : ${CONFIG_STATUS=./config.status}
19247 ac_clean_files_save=$ac_clean_files
19248 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
19249 { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
19250 echo "$as_me: creating $CONFIG_STATUS" >&6;}
19251 cat >$CONFIG_STATUS <<_ACEOF
19252 #! $SHELL
19253 # Generated by $as_me.
19254 # Run this file to recreate the current configuration.
19255 # Compiler output produced by configure, useful for debugging
19256 # configure, is in config.log if it exists.
19257
19258 debug=false
19259 SHELL=\${CONFIG_SHELL-$SHELL}
19260 _ACEOF
19261
19262 cat >>$CONFIG_STATUS <<\_ACEOF
19263
19264 ## --------------------- ##
19265 ## M4sh Initialization.  ##
19266 ## --------------------- ##
19267
19268 # Be Bourne compatible
19269 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
19270   emulate sh
19271   NULLCMD=:
19272 elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
19273   set -o posix
19274 fi
19275
19276 # NLS nuisances.
19277 # Support unset when possible.
19278 if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
19279   as_unset=unset
19280 else
19281   as_unset=false
19282 fi
19283
19284 (set +x; test -n "`(LANG=C; export LANG) 2>&1`") &&
19285     { $as_unset LANG || test "${LANG+set}" != set; } ||
19286       { LANG=C; export LANG; }
19287 (set +x; test -n "`(LC_ALL=C; export LC_ALL) 2>&1`") &&
19288     { $as_unset LC_ALL || test "${LC_ALL+set}" != set; } ||
19289       { LC_ALL=C; export LC_ALL; }
19290 (set +x; test -n "`(LC_TIME=C; export LC_TIME) 2>&1`") &&
19291     { $as_unset LC_TIME || test "${LC_TIME+set}" != set; } ||
19292       { LC_TIME=C; export LC_TIME; }
19293 (set +x; test -n "`(LC_CTYPE=C; export LC_CTYPE) 2>&1`") &&
19294     { $as_unset LC_CTYPE || test "${LC_CTYPE+set}" != set; } ||
19295       { LC_CTYPE=C; export LC_CTYPE; }
19296 (set +x; test -n "`(LANGUAGE=C; export LANGUAGE) 2>&1`") &&
19297     { $as_unset LANGUAGE || test "${LANGUAGE+set}" != set; } ||
19298       { LANGUAGE=C; export LANGUAGE; }
19299 (set +x; test -n "`(LC_COLLATE=C; export LC_COLLATE) 2>&1`") &&
19300     { $as_unset LC_COLLATE || test "${LC_COLLATE+set}" != set; } ||
19301       { LC_COLLATE=C; export LC_COLLATE; }
19302 (set +x; test -n "`(LC_NUMERIC=C; export LC_NUMERIC) 2>&1`") &&
19303     { $as_unset LC_NUMERIC || test "${LC_NUMERIC+set}" != set; } ||
19304       { LC_NUMERIC=C; export LC_NUMERIC; }
19305 (set +x; test -n "`(LC_MESSAGES=C; export LC_MESSAGES) 2>&1`") &&
19306     { $as_unset LC_MESSAGES || test "${LC_MESSAGES+set}" != set; } ||
19307       { LC_MESSAGES=C; export LC_MESSAGES; }
19308
19309
19310 # Name of the executable.
19311 as_me=`(basename "$0") 2>/dev/null ||
19312 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
19313          X"$0" : 'X\(//\)$' \| \
19314          X"$0" : 'X\(/\)$' \| \
19315          .     : '\(.\)' 2>/dev/null ||
19316 echo X/"$0" |
19317     sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
19318           /^X\/\(\/\/\)$/{ s//\1/; q; }
19319           /^X\/\(\/\).*/{ s//\1/; q; }
19320           s/.*/./; q'`
19321
19322 # PATH needs CR, and LINENO needs CR and PATH.
19323 # Avoid depending upon Character Ranges.
19324 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
19325 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
19326 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
19327 as_cr_digits='0123456789'
19328 as_cr_alnum=$as_cr_Letters$as_cr_digits
19329
19330 # The user is always right.
19331 if test "${PATH_SEPARATOR+set}" != set; then
19332   echo "#! /bin/sh" >conftest.sh
19333   echo  "exit 0"   >>conftest.sh
19334   chmod +x conftest.sh
19335   if (PATH=".;."; conftest.sh) >/dev/null 2>&1; then
19336     PATH_SEPARATOR=';'
19337   else
19338     PATH_SEPARATOR=:
19339   fi
19340   rm -f conftest.sh
19341 fi
19342
19343
19344   as_lineno_1=$LINENO
19345   as_lineno_2=$LINENO
19346   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
19347   test "x$as_lineno_1" != "x$as_lineno_2" &&
19348   test "x$as_lineno_3"  = "x$as_lineno_2"  || {
19349   # Find who we are.  Look in the path if we contain no path at all
19350   # relative or not.
19351   case $0 in
19352     *[\\/]* ) as_myself=$0 ;;
19353     *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19354 for as_dir in $PATH
19355 do
19356   IFS=$as_save_IFS
19357   test -z "$as_dir" && as_dir=.
19358   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
19359 done
19360
19361        ;;
19362   esac
19363   # We did not find ourselves, most probably we were run as `sh COMMAND'
19364   # in which case we are not to be found in the path.
19365   if test "x$as_myself" = x; then
19366     as_myself=$0
19367   fi
19368   if test ! -f "$as_myself"; then
19369     { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
19370 echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
19371    { (exit 1); exit 1; }; }
19372   fi
19373   case $CONFIG_SHELL in
19374   '')
19375     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
19376 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
19377 do
19378   IFS=$as_save_IFS
19379   test -z "$as_dir" && as_dir=.
19380   for as_base in sh bash ksh sh5; do
19381          case $as_dir in
19382          /*)
19383            if ("$as_dir/$as_base" -c '
19384   as_lineno_1=$LINENO
19385   as_lineno_2=$LINENO
19386   as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
19387   test "x$as_lineno_1" != "x$as_lineno_2" &&
19388   test "x$as_lineno_3"  = "x$as_lineno_2" ') 2>/dev/null; then
19389              CONFIG_SHELL=$as_dir/$as_base
19390              export CONFIG_SHELL
19391              exec "$CONFIG_SHELL" "$0" ${1+"$@"}
19392            fi;;
19393          esac
19394        done
19395 done
19396 ;;
19397   esac
19398
19399   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
19400   # uniformly replaced by the line number.  The first 'sed' inserts a
19401   # line-number line before each line; the second 'sed' does the real
19402   # work.  The second script uses 'N' to pair each line-number line
19403   # with the numbered line, and appends trailing '-' during
19404   # substitution so that $LINENO is not a special case at line end.
19405   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
19406   # second 'sed' script.  Blame Lee E. McMahon for sed's syntax.  :-)
19407   sed '=' <$as_myself |
19408     sed '
19409       N
19410       s,$,-,
19411       : loop
19412       s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
19413       t loop
19414       s,-$,,
19415       s,^['$as_cr_digits']*\n,,
19416     ' >$as_me.lineno &&
19417   chmod +x $as_me.lineno ||
19418     { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
19419 echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
19420    { (exit 1); exit 1; }; }
19421
19422   # Don't try to exec as it changes $[0], causing all sort of problems
19423   # (the dirname of $[0] is not the place where we might find the
19424   # original and so on.  Autoconf is especially sensible to this).
19425   . ./$as_me.lineno
19426   # Exit status is that of the last command.
19427   exit
19428 }
19429
19430
19431 case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
19432   *c*,-n*) ECHO_N= ECHO_C='
19433 ' ECHO_T='      ' ;;
19434   *c*,*  ) ECHO_N=-n ECHO_C= ECHO_T= ;;
19435   *)       ECHO_N= ECHO_C='\c' ECHO_T= ;;
19436 esac
19437
19438 if expr a : '\(a\)' >/dev/null 2>&1; then
19439   as_expr=expr
19440 else
19441   as_expr=false
19442 fi
19443
19444 rm -f conf$$ conf$$.exe conf$$.file
19445 echo >conf$$.file
19446 if ln -s conf$$.file conf$$ 2>/dev/null; then
19447   # We could just check for DJGPP; but this test a) works b) is more generic
19448   # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
19449   if test -f conf$$.exe; then
19450     # Don't use ln at all; we don't have any links
19451     as_ln_s='cp -p'
19452   else
19453     as_ln_s='ln -s'
19454   fi
19455 elif ln conf$$.file conf$$ 2>/dev/null; then
19456   as_ln_s=ln
19457 else
19458   as_ln_s='cp -p'
19459 fi
19460 rm -f conf$$ conf$$.exe conf$$.file
19461
19462 as_executable_p="test -f"
19463
19464 # Sed expression to map a string onto a valid CPP name.
19465 as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
19466
19467 # Sed expression to map a string onto a valid variable name.
19468 as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
19469
19470
19471 # IFS
19472 # We need space, tab and new line, in precisely that order.
19473 as_nl='
19474 '
19475 IFS="   $as_nl"
19476
19477 # CDPATH.
19478 $as_unset CDPATH || test "${CDPATH+set}" != set || { CDPATH=$PATH_SEPARATOR; export CDPATH; }
19479
19480 exec 6>&1
19481
19482 # Open the log real soon, to keep \$[0] and so on meaningful, and to
19483 # report actual input values of CONFIG_FILES etc. instead of their
19484 # values after options handling.  Logging --version etc. is OK.
19485 exec 5>>config.log
19486 {
19487   echo
19488   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
19489 ## Running $as_me. ##
19490 _ASBOX
19491 } >&5
19492 cat >&5 <<_CSEOF
19493
19494 This file was extended by PostgreSQL $as_me 8.1devel, which was
19495 generated by GNU Autoconf 2.53.  Invocation command line was
19496
19497   CONFIG_FILES    = $CONFIG_FILES
19498   CONFIG_HEADERS  = $CONFIG_HEADERS
19499   CONFIG_LINKS    = $CONFIG_LINKS
19500   CONFIG_COMMANDS = $CONFIG_COMMANDS
19501   $ $0 $@
19502
19503 _CSEOF
19504 echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
19505 echo >&5
19506 _ACEOF
19507
19508 # Files that config.status was made for.
19509 if test -n "$ac_config_files"; then
19510   echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
19511 fi
19512
19513 if test -n "$ac_config_headers"; then
19514   echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
19515 fi
19516
19517 if test -n "$ac_config_links"; then
19518   echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
19519 fi
19520
19521 if test -n "$ac_config_commands"; then
19522   echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
19523 fi
19524
19525 cat >>$CONFIG_STATUS <<\_ACEOF
19526
19527 ac_cs_usage="\
19528 \`$as_me' instantiates files from templates according to the
19529 current configuration.
19530
19531 Usage: $0 [OPTIONS] [FILE]...
19532
19533   -h, --help       print this help, then exit
19534   -V, --version    print version number, then exit
19535   -d, --debug      don't remove temporary files
19536       --recheck    update $as_me by reconfiguring in the same conditions
19537   --file=FILE[:TEMPLATE]
19538                    instantiate the configuration file FILE
19539   --header=FILE[:TEMPLATE]
19540                    instantiate the configuration header FILE
19541
19542 Configuration files:
19543 $config_files
19544
19545 Configuration headers:
19546 $config_headers
19547
19548 Configuration links:
19549 $config_links
19550
19551 Configuration commands:
19552 $config_commands
19553
19554 Report bugs to <bug-autoconf@gnu.org>."
19555 _ACEOF
19556
19557 cat >>$CONFIG_STATUS <<_ACEOF
19558 ac_cs_version="\\
19559 PostgreSQL config.status 8.1devel
19560 configured by $0, generated by GNU Autoconf 2.53,
19561   with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
19562
19563 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
19564 Free Software Foundation, Inc.
19565 This config.status script is free software; the Free Software Foundation
19566 gives unlimited permission to copy, distribute and modify it."
19567 srcdir=$srcdir
19568 _ACEOF
19569
19570 cat >>$CONFIG_STATUS <<\_ACEOF
19571 # If no file are specified by the user, then we need to provide default
19572 # value.  By we need to know if files were specified by the user.
19573 ac_need_defaults=:
19574 while test $# != 0
19575 do
19576   case $1 in
19577   --*=*)
19578     ac_option=`expr "x$1" : 'x\([^=]*\)='`
19579     ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
19580     shift
19581     set dummy "$ac_option" "$ac_optarg" ${1+"$@"}
19582     shift
19583     ;;
19584   -*);;
19585   *) # This is not an option, so the user has probably given explicit
19586      # arguments.
19587      ac_need_defaults=false;;
19588   esac
19589
19590   case $1 in
19591   # Handling of the options.
19592 _ACEOF
19593 cat >>$CONFIG_STATUS <<_ACEOF
19594   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
19595     echo "running $SHELL $0 " $ac_configure_args " --no-create --no-recursion"
19596     exec $SHELL $0 $ac_configure_args --no-create --no-recursion ;;
19597 _ACEOF
19598 cat >>$CONFIG_STATUS <<\_ACEOF
19599   --version | --vers* | -V )
19600     echo "$ac_cs_version"; exit 0 ;;
19601   --he | --h)
19602     # Conflict between --help and --header
19603     { { echo "$as_me:$LINENO: error: ambiguous option: $1
19604 Try \`$0 --help' for more information." >&5
19605 echo "$as_me: error: ambiguous option: $1
19606 Try \`$0 --help' for more information." >&2;}
19607    { (exit 1); exit 1; }; };;
19608   --help | --hel | -h )
19609     echo "$ac_cs_usage"; exit 0 ;;
19610   --debug | --d* | -d )
19611     debug=: ;;
19612   --file | --fil | --fi | --f )
19613     shift
19614     CONFIG_FILES="$CONFIG_FILES $1"
19615     ac_need_defaults=false;;
19616   --header | --heade | --head | --hea )
19617     shift
19618     CONFIG_HEADERS="$CONFIG_HEADERS $1"
19619     ac_need_defaults=false;;
19620
19621   # This is an error.
19622   -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
19623 Try \`$0 --help' for more information." >&5
19624 echo "$as_me: error: unrecognized option: $1
19625 Try \`$0 --help' for more information." >&2;}
19626    { (exit 1); exit 1; }; } ;;
19627
19628   *) ac_config_targets="$ac_config_targets $1" ;;
19629
19630   esac
19631   shift
19632 done
19633
19634 _ACEOF
19635
19636
19637
19638
19639
19640 cat >>$CONFIG_STATUS <<\_ACEOF
19641 for ac_config_target in $ac_config_targets
19642 do
19643   case "$ac_config_target" in
19644   # Handling of arguments.
19645   "GNUmakefile" ) CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
19646   "src/Makefile.global" ) CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
19647   "src/backend/port/tas.s" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
19648   "src/backend/port/dynloader.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
19649   "src/backend/port/pg_sema.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
19650   "src/backend/port/pg_shmem.c" ) CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
19651   "src/include/dynloader.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
19652   "src/include/pg_config_os.h" ) CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
19653   "src/Makefile.port" ) CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
19654   "check_win32_symlinks" ) CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
19655   "src/include/pg_config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
19656   *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
19657 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
19658    { (exit 1); exit 1; }; };;
19659   esac
19660 done
19661
19662 # If the user did not use the arguments to specify the items to instantiate,
19663 # then the envvar interface is used.  Set only those that are not.
19664 # We use the long form for the default assignment because of an extremely
19665 # bizarre bug on SunOS 4.1.3.
19666 if $ac_need_defaults; then
19667   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
19668   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
19669   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
19670   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
19671 fi
19672
19673 # Create a temporary directory, and hook for its removal unless debugging.
19674 $debug ||
19675 {
19676   trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
19677   trap '{ (exit 1); exit 1; }' 1 2 13 15
19678 }
19679
19680 # Create a (secure) tmp directory for tmp files.
19681 : ${TMPDIR=/tmp}
19682 {
19683   tmp=`(umask 077 && mktemp -d -q "$TMPDIR/csXXXXXX") 2>/dev/null` &&
19684   test -n "$tmp" && test -d "$tmp"
19685 }  ||
19686 {
19687   tmp=$TMPDIR/cs$$-$RANDOM
19688   (umask 077 && mkdir $tmp)
19689 } ||
19690 {
19691    echo "$me: cannot create a temporary directory in $TMPDIR" >&2
19692    { (exit 1); exit 1; }
19693 }
19694
19695 _ACEOF
19696
19697 cat >>$CONFIG_STATUS <<_ACEOF
19698
19699 #
19700 # CONFIG_FILES section.
19701 #
19702
19703 # No need to generate the scripts if there are no CONFIG_FILES.
19704 # This happens for instance when ./config.status config.h
19705 if test -n "\$CONFIG_FILES"; then
19706   # Protect against being on the right side of a sed subst in config.status.
19707   sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
19708    s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
19709 s,@SHELL@,$SHELL,;t t
19710 s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
19711 s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
19712 s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
19713 s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
19714 s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
19715 s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
19716 s,@exec_prefix@,$exec_prefix,;t t
19717 s,@prefix@,$prefix,;t t
19718 s,@program_transform_name@,$program_transform_name,;t t
19719 s,@bindir@,$bindir,;t t
19720 s,@sbindir@,$sbindir,;t t
19721 s,@libexecdir@,$libexecdir,;t t
19722 s,@datadir@,$datadir,;t t
19723 s,@sysconfdir@,$sysconfdir,;t t
19724 s,@sharedstatedir@,$sharedstatedir,;t t
19725 s,@localstatedir@,$localstatedir,;t t
19726 s,@libdir@,$libdir,;t t
19727 s,@includedir@,$includedir,;t t
19728 s,@oldincludedir@,$oldincludedir,;t t
19729 s,@infodir@,$infodir,;t t
19730 s,@mandir@,$mandir,;t t
19731 s,@build_alias@,$build_alias,;t t
19732 s,@host_alias@,$host_alias,;t t
19733 s,@target_alias@,$target_alias,;t t
19734 s,@DEFS@,$DEFS,;t t
19735 s,@ECHO_C@,$ECHO_C,;t t
19736 s,@ECHO_N@,$ECHO_N,;t t
19737 s,@ECHO_T@,$ECHO_T,;t t
19738 s,@LIBS@,$LIBS,;t t
19739 s,@configure_args@,$configure_args,;t t
19740 s,@build@,$build,;t t
19741 s,@build_cpu@,$build_cpu,;t t
19742 s,@build_vendor@,$build_vendor,;t t
19743 s,@build_os@,$build_os,;t t
19744 s,@host@,$host,;t t
19745 s,@host_cpu@,$host_cpu,;t t
19746 s,@host_vendor@,$host_vendor,;t t
19747 s,@host_os@,$host_os,;t t
19748 s,@PORTNAME@,$PORTNAME,;t t
19749 s,@docdir@,$docdir,;t t
19750 s,@enable_nls@,$enable_nls,;t t
19751 s,@WANTED_LANGUAGES@,$WANTED_LANGUAGES,;t t
19752 s,@default_port@,$default_port,;t t
19753 s,@enable_shared@,$enable_shared,;t t
19754 s,@enable_rpath@,$enable_rpath,;t t
19755 s,@enable_debug@,$enable_debug,;t t
19756 s,@CC@,$CC,;t t
19757 s,@CFLAGS@,$CFLAGS,;t t
19758 s,@LDFLAGS@,$LDFLAGS,;t t
19759 s,@CPPFLAGS@,$CPPFLAGS,;t t
19760 s,@ac_ct_CC@,$ac_ct_CC,;t t
19761 s,@EXEEXT@,$EXEEXT,;t t
19762 s,@OBJEXT@,$OBJEXT,;t t
19763 s,@CPP@,$CPP,;t t
19764 s,@GCC@,$GCC,;t t
19765 s,@TAS@,$TAS,;t t
19766 s,@autodepend@,$autodepend,;t t
19767 s,@INCLUDES@,$INCLUDES,;t t
19768 s,@enable_thread_safety@,$enable_thread_safety,;t t
19769 s,@with_tcl@,$with_tcl,;t t
19770 s,@with_perl@,$with_perl,;t t
19771 s,@with_python@,$with_python,;t t
19772 s,@with_krb4@,$with_krb4,;t t
19773 s,@with_krb5@,$with_krb5,;t t
19774 s,@krb_srvtab@,$krb_srvtab,;t t
19775 s,@with_pam@,$with_pam,;t t
19776 s,@with_rendezvous@,$with_rendezvous,;t t
19777 s,@with_openssl@,$with_openssl,;t t
19778 s,@ELF_SYS@,$ELF_SYS,;t t
19779 s,@LDFLAGS_SL@,$LDFLAGS_SL,;t t
19780 s,@AWK@,$AWK,;t t
19781 s,@FLEX@,$FLEX,;t t
19782 s,@FLEXFLAGS@,$FLEXFLAGS,;t t
19783 s,@LN_S@,$LN_S,;t t
19784 s,@LD@,$LD,;t t
19785 s,@with_gnu_ld@,$with_gnu_ld,;t t
19786 s,@ld_R_works@,$ld_R_works,;t t
19787 s,@RANLIB@,$RANLIB,;t t
19788 s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
19789 s,@LORDER@,$LORDER,;t t
19790 s,@TAR@,$TAR,;t t
19791 s,@STRIP@,$STRIP,;t t
19792 s,@ac_ct_STRIP@,$ac_ct_STRIP,;t t
19793 s,@STRIP_STATIC_LIB@,$STRIP_STATIC_LIB,;t t
19794 s,@STRIP_SHARED_LIB@,$STRIP_SHARED_LIB,;t t
19795 s,@YACC@,$YACC,;t t
19796 s,@YFLAGS@,$YFLAGS,;t t
19797 s,@PERL@,$PERL,;t t
19798 s,@perl_archlibexp@,$perl_archlibexp,;t t
19799 s,@perl_privlibexp@,$perl_privlibexp,;t t
19800 s,@perl_useshrplib@,$perl_useshrplib,;t t
19801 s,@perl_embed_ldflags@,$perl_embed_ldflags,;t t
19802 s,@PYTHON@,$PYTHON,;t t
19803 s,@python_version@,$python_version,;t t
19804 s,@python_configdir@,$python_configdir,;t t
19805 s,@python_includespec@,$python_includespec,;t t
19806 s,@python_libdir@,$python_libdir,;t t
19807 s,@python_libspec@,$python_libspec,;t t
19808 s,@python_additional_libs@,$python_additional_libs,;t t
19809 s,@LIBOBJS@,$LIBOBJS,;t t
19810 s,@HAVE_IPV6@,$HAVE_IPV6,;t t
19811 s,@acx_pthread_config@,$acx_pthread_config,;t t
19812 s,@PTHREAD_CC@,$PTHREAD_CC,;t t
19813 s,@PTHREAD_LIBS@,$PTHREAD_LIBS,;t t
19814 s,@PTHREAD_CFLAGS@,$PTHREAD_CFLAGS,;t t
19815 s,@HAVE_POSIX_SIGNALS@,$HAVE_POSIX_SIGNALS,;t t
19816 s,@MSGFMT@,$MSGFMT,;t t
19817 s,@MSGMERGE@,$MSGMERGE,;t t
19818 s,@XGETTEXT@,$XGETTEXT,;t t
19819 s,@localedir@,$localedir,;t t
19820 s,@TCLSH@,$TCLSH,;t t
19821 s,@TCL_CONFIG_SH@,$TCL_CONFIG_SH,;t t
19822 s,@TCL_INCLUDE_SPEC@,$TCL_INCLUDE_SPEC,;t t
19823 s,@TCL_LIB_FILE@,$TCL_LIB_FILE,;t t
19824 s,@TCL_LIBS@,$TCL_LIBS,;t t
19825 s,@TCL_LIB_SPEC@,$TCL_LIB_SPEC,;t t
19826 s,@TCL_SHARED_BUILD@,$TCL_SHARED_BUILD,;t t
19827 s,@TCL_SHLIB_LD_LIBS@,$TCL_SHLIB_LD_LIBS,;t t
19828 s,@NSGMLS@,$NSGMLS,;t t
19829 s,@JADE@,$JADE,;t t
19830 s,@have_docbook@,$have_docbook,;t t
19831 s,@DOCBOOKSTYLE@,$DOCBOOKSTYLE,;t t
19832 s,@COLLATEINDEX@,$COLLATEINDEX,;t t
19833 s,@SGMLSPL@,$SGMLSPL,;t t
19834 s,@vpath_build@,$vpath_build,;t t
19835 CEOF
19836
19837 _ACEOF
19838
19839   cat >>$CONFIG_STATUS <<\_ACEOF
19840   # Split the substitutions into bite-sized pieces for seds with
19841   # small command number limits, like on Digital OSF/1 and HP-UX.
19842   ac_max_sed_lines=48
19843   ac_sed_frag=1 # Number of current file.
19844   ac_beg=1 # First line for current file.
19845   ac_end=$ac_max_sed_lines # Line after last line for current file.
19846   ac_more_lines=:
19847   ac_sed_cmds=
19848   while $ac_more_lines; do
19849     if test $ac_beg -gt 1; then
19850       sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
19851     else
19852       sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
19853     fi
19854     if test ! -s $tmp/subs.frag; then
19855       ac_more_lines=false
19856     else
19857       # The purpose of the label and of the branching condition is to
19858       # speed up the sed processing (if there are no `@' at all, there
19859       # is no need to browse any of the substitutions).
19860       # These are the two extra sed commands mentioned above.
19861       (echo ':t
19862   /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
19863       if test -z "$ac_sed_cmds"; then
19864         ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
19865       else
19866         ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
19867       fi
19868       ac_sed_frag=`expr $ac_sed_frag + 1`
19869       ac_beg=$ac_end
19870       ac_end=`expr $ac_end + $ac_max_sed_lines`
19871     fi
19872   done
19873   if test -z "$ac_sed_cmds"; then
19874     ac_sed_cmds=cat
19875   fi
19876 fi # test -n "$CONFIG_FILES"
19877
19878 _ACEOF
19879 cat >>$CONFIG_STATUS <<\_ACEOF
19880 for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
19881   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
19882   case $ac_file in
19883   - | *:- | *:-:* ) # input from stdin
19884         cat >$tmp/stdin
19885         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19886         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19887   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
19888         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
19889   * )   ac_file_in=$ac_file.in ;;
19890   esac
19891
19892   # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
19893   ac_dir=`(dirname "$ac_file") 2>/dev/null ||
19894 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
19895          X"$ac_file" : 'X\(//\)[^/]' \| \
19896          X"$ac_file" : 'X\(//\)$' \| \
19897          X"$ac_file" : 'X\(/\)' \| \
19898          .     : '\(.\)' 2>/dev/null ||
19899 echo X"$ac_file" |
19900     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
19901           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
19902           /^X\(\/\/\)$/{ s//\1/; q; }
19903           /^X\(\/\).*/{ s//\1/; q; }
19904           s/.*/./; q'`
19905   { case "$ac_dir" in
19906   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
19907   *)                      as_incr_dir=.;;
19908 esac
19909 as_dummy="$ac_dir"
19910 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
19911   case $as_mkdir_dir in
19912     # Skip DOS drivespec
19913     ?:) as_incr_dir=$as_mkdir_dir ;;
19914     *)
19915       as_incr_dir=$as_incr_dir/$as_mkdir_dir
19916       test -d "$as_incr_dir" ||
19917         mkdir "$as_incr_dir" ||
19918         { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
19919 echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
19920    { (exit 1); exit 1; }; }
19921     ;;
19922   esac
19923 done; }
19924
19925   ac_builddir=.
19926
19927 if test "$ac_dir" != .; then
19928   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
19929   # A "../" for each directory in $ac_dir_suffix.
19930   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
19931 else
19932   ac_dir_suffix= ac_top_builddir=
19933 fi
19934
19935 case $srcdir in
19936   .)  # No --srcdir option.  We are building in place.
19937     ac_srcdir=.
19938     if test -z "$ac_top_builddir"; then
19939        ac_top_srcdir=.
19940     else
19941        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
19942     fi ;;
19943   [\\/]* | ?:[\\/]* )  # Absolute path.
19944     ac_srcdir=$srcdir$ac_dir_suffix;
19945     ac_top_srcdir=$srcdir ;;
19946   *) # Relative path.
19947     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
19948     ac_top_srcdir=$ac_top_builddir$srcdir ;;
19949 esac
19950 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
19951 # absolute.
19952 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
19953 ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
19954 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
19955 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
19956
19957
19958
19959   if test x"$ac_file" != x-; then
19960     { echo "$as_me:$LINENO: creating $ac_file" >&5
19961 echo "$as_me: creating $ac_file" >&6;}
19962     rm -f "$ac_file"
19963   fi
19964   # Let's still pretend it is `configure' which instantiates (i.e., don't
19965   # use $as_me), people would be surprised to read:
19966   #    /* config.h.  Generated by config.status.  */
19967   if test x"$ac_file" = x-; then
19968     configure_input=
19969   else
19970     configure_input="$ac_file.  "
19971   fi
19972   configure_input=$configure_input"Generated from `echo $ac_file_in |
19973                                      sed 's,.*/,,'` by configure."
19974
19975   # First look for the input files in the build tree, otherwise in the
19976   # src tree.
19977   ac_file_inputs=`IFS=:
19978     for f in $ac_file_in; do
19979       case $f in
19980       -) echo $tmp/stdin ;;
19981       [\\/$]*)
19982          # Absolute (can't be DOS-style, as IFS=:)
19983          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19984 echo "$as_me: error: cannot find input file: $f" >&2;}
19985    { (exit 1); exit 1; }; }
19986          echo $f;;
19987       *) # Relative
19988          if test -f "$f"; then
19989            # Build tree
19990            echo $f
19991          elif test -f "$srcdir/$f"; then
19992            # Source tree
19993            echo $srcdir/$f
19994          else
19995            # /dev/null tree
19996            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
19997 echo "$as_me: error: cannot find input file: $f" >&2;}
19998    { (exit 1); exit 1; }; }
19999          fi;;
20000       esac
20001     done` || { (exit 1); exit 1; }
20002 _ACEOF
20003 cat >>$CONFIG_STATUS <<_ACEOF
20004   sed "$ac_vpsub
20005 $extrasub
20006 _ACEOF
20007 cat >>$CONFIG_STATUS <<\_ACEOF
20008 :t
20009 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
20010 s,@configure_input@,$configure_input,;t t
20011 s,@srcdir@,$ac_srcdir,;t t
20012 s,@abs_srcdir@,$ac_abs_srcdir,;t t
20013 s,@top_srcdir@,$ac_top_srcdir,;t t
20014 s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
20015 s,@builddir@,$ac_builddir,;t t
20016 s,@abs_builddir@,$ac_abs_builddir,;t t
20017 s,@top_builddir@,$ac_top_builddir,;t t
20018 s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
20019 " $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
20020   rm -f $tmp/stdin
20021   if test x"$ac_file" != x-; then
20022     mv $tmp/out $ac_file
20023   else
20024     cat $tmp/out
20025     rm -f $tmp/out
20026   fi
20027
20028 done
20029 _ACEOF
20030 cat >>$CONFIG_STATUS <<\_ACEOF
20031
20032 #
20033 # CONFIG_HEADER section.
20034 #
20035
20036 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
20037 # NAME is the cpp macro being defined and VALUE is the value it is being given.
20038 #
20039 # ac_d sets the value in "#define NAME VALUE" lines.
20040 ac_dA='s,^\([   ]*\)#\([        ]*define[       ][      ]*\)'
20041 ac_dB='[        ].*$,\1#\2'
20042 ac_dC=' '
20043 ac_dD=',;t'
20044 # ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
20045 ac_uA='s,^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
20046 ac_uB='$,\1#\2define\3'
20047 ac_uC=' '
20048 ac_uD=',;t'
20049
20050 for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
20051   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
20052   case $ac_file in
20053   - | *:- | *:-:* ) # input from stdin
20054         cat >$tmp/stdin
20055         ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
20056         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
20057   *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
20058         ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
20059   * )   ac_file_in=$ac_file.in ;;
20060   esac
20061
20062   test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
20063 echo "$as_me: creating $ac_file" >&6;}
20064
20065   # First look for the input files in the build tree, otherwise in the
20066   # src tree.
20067   ac_file_inputs=`IFS=:
20068     for f in $ac_file_in; do
20069       case $f in
20070       -) echo $tmp/stdin ;;
20071       [\\/$]*)
20072          # Absolute (can't be DOS-style, as IFS=:)
20073          test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
20074 echo "$as_me: error: cannot find input file: $f" >&2;}
20075    { (exit 1); exit 1; }; }
20076          echo $f;;
20077       *) # Relative
20078          if test -f "$f"; then
20079            # Build tree
20080            echo $f
20081          elif test -f "$srcdir/$f"; then
20082            # Source tree
20083            echo $srcdir/$f
20084          else
20085            # /dev/null tree
20086            { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
20087 echo "$as_me: error: cannot find input file: $f" >&2;}
20088    { (exit 1); exit 1; }; }
20089          fi;;
20090       esac
20091     done` || { (exit 1); exit 1; }
20092   # Remove the trailing spaces.
20093   sed 's/[      ]*$//' $ac_file_inputs >$tmp/in
20094
20095 _ACEOF
20096
20097 # Transform confdefs.h into two sed scripts, `conftest.defines' and
20098 # `conftest.undefs', that substitutes the proper values into
20099 # config.h.in to produce config.h.  The first handles `#define'
20100 # templates, and the second `#undef' templates.
20101 # And first: Protect against being on the right side of a sed subst in
20102 # config.status.  Protect against being in an unquoted here document
20103 # in config.status.
20104 rm -f conftest.defines conftest.undefs
20105 # Using a here document instead of a string reduces the quoting nightmare.
20106 # Putting comments in sed scripts is not portable.
20107 #
20108 # `end' is used to avoid that the second main sed command (meant for
20109 # 0-ary CPP macros) applies to n-ary macro definitions.
20110 # See the Autoconf documentation for `clear'.
20111 cat >confdef2sed.sed <<\_ACEOF
20112 s/[\\&,]/\\&/g
20113 s,[\\$`],\\&,g
20114 t clear
20115 : clear
20116 s,^[    ]*#[    ]*define[       ][      ]*\([^  (][^    (]*\)\(([^)]*)\)[       ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
20117 t end
20118 s,^[    ]*#[    ]*define[       ][      ]*\([^  ][^     ]*\)[   ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
20119 : end
20120 _ACEOF
20121 # If some macros were called several times there might be several times
20122 # the same #defines, which is useless.  Nevertheless, we may not want to
20123 # sort them, since we want the *last* AC-DEFINE to be honored.
20124 uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
20125 sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
20126 rm -f confdef2sed.sed
20127
20128 # This sed command replaces #undef with comments.  This is necessary, for
20129 # example, in the case of _POSIX_SOURCE, which is predefined and required
20130 # on some systems where configure will not decide to define it.
20131 cat >>conftest.undefs <<\_ACEOF
20132 s,^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
20133 _ACEOF
20134
20135 # Break up conftest.defines because some shells have a limit on the size
20136 # of here documents, and old seds have small limits too (100 cmds).
20137 echo '  # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
20138 echo '  if egrep "^[    ]*#[    ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
20139 echo '  # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
20140 echo '  :' >>$CONFIG_STATUS
20141 rm -f conftest.tail
20142 while grep . conftest.defines >/dev/null
20143 do
20144   # Write a limited-size here document to $tmp/defines.sed.
20145   echo '  cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
20146   # Speed up: don't consider the non `#define' lines.
20147   echo '/^[     ]*#[    ]*define/!b' >>$CONFIG_STATUS
20148   # Work around the forget-to-reset-the-flag bug.
20149   echo 't clr' >>$CONFIG_STATUS
20150   echo ': clr' >>$CONFIG_STATUS
20151   sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
20152   echo 'CEOF
20153   sed -f $tmp/defines.sed $tmp/in >$tmp/out
20154   rm -f $tmp/in
20155   mv $tmp/out $tmp/in
20156 ' >>$CONFIG_STATUS
20157   sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
20158   rm -f conftest.defines
20159   mv conftest.tail conftest.defines
20160 done
20161 rm -f conftest.defines
20162 echo '  fi # egrep' >>$CONFIG_STATUS
20163 echo >>$CONFIG_STATUS
20164
20165 # Break up conftest.undefs because some shells have a limit on the size
20166 # of here documents, and old seds have small limits too (100 cmds).
20167 echo '  # Handle all the #undef templates' >>$CONFIG_STATUS
20168 rm -f conftest.tail
20169 while grep . conftest.undefs >/dev/null
20170 do
20171   # Write a limited-size here document to $tmp/undefs.sed.
20172   echo '  cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
20173   # Speed up: don't consider the non `#undef'
20174   echo '/^[     ]*#[    ]*undef/!b' >>$CONFIG_STATUS
20175   # Work around the forget-to-reset-the-flag bug.
20176   echo 't clr' >>$CONFIG_STATUS
20177   echo ': clr' >>$CONFIG_STATUS
20178   sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
20179   echo 'CEOF
20180   sed -f $tmp/undefs.sed $tmp/in >$tmp/out
20181   rm -f $tmp/in
20182   mv $tmp/out $tmp/in
20183 ' >>$CONFIG_STATUS
20184   sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
20185   rm -f conftest.undefs
20186   mv conftest.tail conftest.undefs
20187 done
20188 rm -f conftest.undefs
20189
20190 cat >>$CONFIG_STATUS <<\_ACEOF
20191   # Let's still pretend it is `configure' which instantiates (i.e., don't
20192   # use $as_me), people would be surprised to read:
20193   #    /* config.h.  Generated by config.status.  */
20194   if test x"$ac_file" = x-; then
20195     echo "/* Generated by configure.  */" >$tmp/config.h
20196   else
20197     echo "/* $ac_file.  Generated by configure.  */" >$tmp/config.h
20198   fi
20199   cat $tmp/in >>$tmp/config.h
20200   rm -f $tmp/in
20201   if test x"$ac_file" != x-; then
20202     if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
20203       { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
20204 echo "$as_me: $ac_file is unchanged" >&6;}
20205     else
20206       ac_dir=`(dirname "$ac_file") 2>/dev/null ||
20207 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20208          X"$ac_file" : 'X\(//\)[^/]' \| \
20209          X"$ac_file" : 'X\(//\)$' \| \
20210          X"$ac_file" : 'X\(/\)' \| \
20211          .     : '\(.\)' 2>/dev/null ||
20212 echo X"$ac_file" |
20213     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
20214           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
20215           /^X\(\/\/\)$/{ s//\1/; q; }
20216           /^X\(\/\).*/{ s//\1/; q; }
20217           s/.*/./; q'`
20218       { case "$ac_dir" in
20219   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
20220   *)                      as_incr_dir=.;;
20221 esac
20222 as_dummy="$ac_dir"
20223 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
20224   case $as_mkdir_dir in
20225     # Skip DOS drivespec
20226     ?:) as_incr_dir=$as_mkdir_dir ;;
20227     *)
20228       as_incr_dir=$as_incr_dir/$as_mkdir_dir
20229       test -d "$as_incr_dir" ||
20230         mkdir "$as_incr_dir" ||
20231         { { echo "$as_me:$LINENO: error: cannot create \"$ac_dir\"" >&5
20232 echo "$as_me: error: cannot create \"$ac_dir\"" >&2;}
20233    { (exit 1); exit 1; }; }
20234     ;;
20235   esac
20236 done; }
20237
20238       rm -f $ac_file
20239       mv $tmp/config.h $ac_file
20240     fi
20241   else
20242     cat $tmp/config.h
20243     rm -f $tmp/config.h
20244   fi
20245   # Run the commands associated with the file.
20246   case $ac_file in
20247     src/include/pg_config.h )
20248 # Update timestamp for pg_config.h (see Makefile.global)
20249 echo >src/include/stamp-h
20250  ;;
20251   esac
20252 done
20253 _ACEOF
20254 cat >>$CONFIG_STATUS <<\_ACEOF
20255
20256 #
20257 # CONFIG_LINKS section.
20258 #
20259
20260 for ac_file in : $CONFIG_LINKS; do test "x$ac_file" = x: && continue
20261   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
20262   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
20263
20264   { echo "$as_me:$LINENO: linking $srcdir/$ac_source to $ac_dest" >&5
20265 echo "$as_me: linking $srcdir/$ac_source to $ac_dest" >&6;}
20266
20267   if test ! -r $srcdir/$ac_source; then
20268     { { echo "$as_me:$LINENO: error: $srcdir/$ac_source: file not found" >&5
20269 echo "$as_me: error: $srcdir/$ac_source: file not found" >&2;}
20270    { (exit 1); exit 1; }; }
20271   fi
20272   rm -f $ac_dest
20273
20274   # Make relative symlinks.
20275   ac_dest_dir=`(dirname "$ac_dest") 2>/dev/null ||
20276 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20277          X"$ac_dest" : 'X\(//\)[^/]' \| \
20278          X"$ac_dest" : 'X\(//\)$' \| \
20279          X"$ac_dest" : 'X\(/\)' \| \
20280          .     : '\(.\)' 2>/dev/null ||
20281 echo X"$ac_dest" |
20282     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
20283           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
20284           /^X\(\/\/\)$/{ s//\1/; q; }
20285           /^X\(\/\).*/{ s//\1/; q; }
20286           s/.*/./; q'`
20287   { case "$ac_dest_dir" in
20288   [\\/]* | ?:[\\/]* ) as_incr_dir=;;
20289   *)                      as_incr_dir=.;;
20290 esac
20291 as_dummy="$ac_dest_dir"
20292 for as_mkdir_dir in `IFS='/\\'; set X $as_dummy; shift; echo "$@"`; do
20293   case $as_mkdir_dir in
20294     # Skip DOS drivespec
20295     ?:) as_incr_dir=$as_mkdir_dir ;;
20296     *)
20297       as_incr_dir=$as_incr_dir/$as_mkdir_dir
20298       test -d "$as_incr_dir" ||
20299         mkdir "$as_incr_dir" ||
20300         { { echo "$as_me:$LINENO: error: cannot create \"$ac_dest_dir\"" >&5
20301 echo "$as_me: error: cannot create \"$ac_dest_dir\"" >&2;}
20302    { (exit 1); exit 1; }; }
20303     ;;
20304   esac
20305 done; }
20306
20307   ac_builddir=.
20308
20309 if test "$ac_dest_dir" != .; then
20310   ac_dir_suffix=/`echo "$ac_dest_dir" | sed 's,^\.[\\/],,'`
20311   # A "../" for each directory in $ac_dir_suffix.
20312   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
20313 else
20314   ac_dir_suffix= ac_top_builddir=
20315 fi
20316
20317 case $srcdir in
20318   .)  # No --srcdir option.  We are building in place.
20319     ac_srcdir=.
20320     if test -z "$ac_top_builddir"; then
20321        ac_top_srcdir=.
20322     else
20323        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
20324     fi ;;
20325   [\\/]* | ?:[\\/]* )  # Absolute path.
20326     ac_srcdir=$srcdir$ac_dir_suffix;
20327     ac_top_srcdir=$srcdir ;;
20328   *) # Relative path.
20329     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
20330     ac_top_srcdir=$ac_top_builddir$srcdir ;;
20331 esac
20332 # Don't blindly perform a `cd "$ac_dest_dir"/$ac_foo && pwd` since $ac_foo can be
20333 # absolute.
20334 ac_abs_builddir=`cd "$ac_dest_dir" && cd $ac_builddir && pwd`
20335 ac_abs_top_builddir=`cd "$ac_dest_dir" && cd $ac_top_builddir && pwd`
20336 ac_abs_srcdir=`cd "$ac_dest_dir" && cd $ac_srcdir && pwd`
20337 ac_abs_top_srcdir=`cd "$ac_dest_dir" && cd $ac_top_srcdir && pwd`
20338
20339
20340   case $srcdir in
20341   [\\/$]* | ?:[\\/]* ) ac_rel_source=$srcdir/$ac_source ;;
20342       *) ac_rel_source=$ac_top_builddir$srcdir/$ac_source ;;
20343   esac
20344
20345   # Make a symlink if possible; otherwise try a hard link.
20346   ln -s $ac_rel_source $ac_dest 2>/dev/null ||
20347     ln $srcdir/$ac_source $ac_dest ||
20348     { { echo "$as_me:$LINENO: error: cannot link $ac_dest to $srcdir/$ac_source" >&5
20349 echo "$as_me: error: cannot link $ac_dest to $srcdir/$ac_source" >&2;}
20350    { (exit 1); exit 1; }; }
20351 done
20352 _ACEOF
20353 cat >>$CONFIG_STATUS <<\_ACEOF
20354
20355 #
20356 # CONFIG_COMMANDS section.
20357 #
20358 for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
20359   ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
20360   ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
20361   ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
20362 $as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
20363          X"$ac_dest" : 'X\(//\)[^/]' \| \
20364          X"$ac_dest" : 'X\(//\)$' \| \
20365          X"$ac_dest" : 'X\(/\)' \| \
20366          .     : '\(.\)' 2>/dev/null ||
20367 echo X"$ac_dest" |
20368     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
20369           /^X\(\/\/\)[^/].*/{ s//\1/; q; }
20370           /^X\(\/\/\)$/{ s//\1/; q; }
20371           /^X\(\/\).*/{ s//\1/; q; }
20372           s/.*/./; q'`
20373   ac_builddir=.
20374
20375 if test "$ac_dir" != .; then
20376   ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
20377   # A "../" for each directory in $ac_dir_suffix.
20378   ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
20379 else
20380   ac_dir_suffix= ac_top_builddir=
20381 fi
20382
20383 case $srcdir in
20384   .)  # No --srcdir option.  We are building in place.
20385     ac_srcdir=.
20386     if test -z "$ac_top_builddir"; then
20387        ac_top_srcdir=.
20388     else
20389        ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
20390     fi ;;
20391   [\\/]* | ?:[\\/]* )  # Absolute path.
20392     ac_srcdir=$srcdir$ac_dir_suffix;
20393     ac_top_srcdir=$srcdir ;;
20394   *) # Relative path.
20395     ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
20396     ac_top_srcdir=$ac_top_builddir$srcdir ;;
20397 esac
20398 # Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
20399 # absolute.
20400 ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
20401 ac_abs_top_builddir=`cd "$ac_dir" && cd $ac_top_builddir && pwd`
20402 ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
20403 ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
20404
20405
20406   { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
20407 echo "$as_me: executing $ac_dest commands" >&6;}
20408   case $ac_dest in
20409     check_win32_symlinks )
20410 # Links sometimes fail undetected on Mingw -
20411 # so here we detect it and warn the user
20412 for FILE in $CONFIG_LINKS
20413  do
20414         # test -e works for symlinks in the MinGW console
20415         test -e `expr "$FILE" : '\([^:]*\)'` || { echo "$as_me:$LINENO: WARNING: *** link for $FILE - please fix by hand" >&5
20416 echo "$as_me: WARNING: *** link for $FILE - please fix by hand" >&2;}
20417  done
20418  ;;
20419   esac
20420 done
20421 _ACEOF
20422
20423 cat >>$CONFIG_STATUS <<\_ACEOF
20424
20425 { (exit 0); exit 0; }
20426 _ACEOF
20427 chmod +x $CONFIG_STATUS
20428 ac_clean_files=$ac_clean_files_save
20429
20430
20431 # configure is writing to config.log, and then calls config.status.
20432 # config.status does its own redirection, appending to config.log.
20433 # Unfortunately, on DOS this fails, as config.log is still kept open
20434 # by configure, so config.status won't be able to write to it; its
20435 # output is simply discarded.  So we exec the FD to /dev/null,
20436 # effectively closing config.log, so it can be properly (re)opened and
20437 # appended to by config.status.  When coming back to configure, we
20438 # need to make the FD available again.
20439 if test "$no_create" != yes; then
20440   ac_cs_success=:
20441   exec 5>/dev/null
20442   $SHELL $CONFIG_STATUS || ac_cs_success=false
20443   exec 5>>config.log
20444   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
20445   # would make configure fail if this is the last instruction.
20446   $ac_cs_success || { (exit 1); exit 1; }
20447 fi
20448
20449